summaryrefslogtreecommitdiff
path: root/textscreen/txt_spinctrl.c
diff options
context:
space:
mode:
Diffstat (limited to 'textscreen/txt_spinctrl.c')
-rw-r--r--textscreen/txt_spinctrl.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/textscreen/txt_spinctrl.c b/textscreen/txt_spinctrl.c
index a4d20343..1015ece5 100644
--- a/textscreen/txt_spinctrl.c
+++ b/textscreen/txt_spinctrl.c
@@ -147,16 +147,17 @@ static void TXT_SpinControlDrawer(TXT_UNCAST_ARG(spincontrol))
TXT_CAST_ARG(txt_spincontrol_t, spincontrol);
unsigned int i;
unsigned int padding;
+ txt_saved_colors_t colors;
int focused;
focused = spincontrol->widget.focused;
- TXT_FGColor(TXT_COLOR_BRIGHT_CYAN);
- TXT_BGColor(TXT_WINDOW_BACKGROUND, 0);
+ TXT_SaveColors(&colors);
+ TXT_FGColor(TXT_COLOR_BRIGHT_CYAN);
TXT_DrawString("\x1b ");
-
- TXT_FGColor(TXT_COLOR_BRIGHT_WHITE);
+
+ TXT_RestoreColors(&colors);
// Choose background color
@@ -173,7 +174,7 @@ static void TXT_SpinControlDrawer(TXT_UNCAST_ARG(spincontrol))
{
SetBuffer(spincontrol);
}
-
+
i = 0;
padding = spincontrol->widget.w - strlen(spincontrol->buffer) - 4;
@@ -193,8 +194,8 @@ static void TXT_SpinControlDrawer(TXT_UNCAST_ARG(spincontrol))
++i;
}
+ TXT_RestoreColors(&colors);
TXT_FGColor(TXT_COLOR_BRIGHT_CYAN);
- TXT_BGColor(TXT_WINDOW_BACKGROUND, 0);
TXT_DrawString(" \x1a");
}