diff options
Diffstat (limited to 'src/ui/util.c')
-rw-r--r-- | src/ui/util.c | 23 |
1 files changed, 17 insertions, 6 deletions
diff --git a/src/ui/util.c b/src/ui/util.c index 0361cd72..c626759a 100644 --- a/src/ui/util.c +++ b/src/ui/util.c | |||
@@ -872,12 +872,13 @@ iWidget *makeValueInput_Widget(iWidget *parent, const iString *initialValue, con | |||
872 | iWidget *div = new_Widget(); { | 872 | iWidget *div = new_Widget(); { |
873 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); | 873 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); |
874 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); | 874 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); |
875 | addChild_Widget( | 875 | iLabelWidget *accept = addChild_Widget( |
876 | div, | 876 | div, |
877 | iClob(newKeyMods_LabelWidget(acceptLabel ? acceptLabel : uiTextAction_ColorEscape "OK", | 877 | iClob(newKeyMods_LabelWidget(acceptLabel ? acceptLabel : uiTextAction_ColorEscape "OK", |
878 | SDLK_RETURN, | 878 | SDLK_RETURN, |
879 | 0, | 879 | 0, |
880 | "valueinput.accept"))); | 880 | "valueinput.accept"))); |
881 | setFont_LabelWidget(accept, uiLabelBold_FontId); | ||
881 | } | 882 | } |
882 | addChild_Widget(dlg, iClob(div)); | 883 | addChild_Widget(dlg, iClob(div)); |
883 | centerSheet_Widget(dlg); | 884 | centerSheet_Widget(dlg); |
@@ -924,8 +925,12 @@ iWidget *makeQuestion_Widget(const char *title, const char *msg, const char *lab | |||
924 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); | 925 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); |
925 | for (size_t i = 0; i < count; ++i) { | 926 | for (size_t i = 0; i < count; ++i) { |
926 | /* The last one is the default option. */ | 927 | /* The last one is the default option. */ |
927 | const int key = (i == count - 1 ? SDLK_RETURN : 0); | 928 | const int key = (i == count - 1 ? SDLK_RETURN : 0); |
928 | addChild_Widget(div, iClob(newKeyMods_LabelWidget(labels[i], key, 0, commands[i]))); | 929 | iLabelWidget *btn = |
930 | addChild_Widget(div, iClob(newKeyMods_LabelWidget(labels[i], key, 0, commands[i]))); | ||
931 | if (key) { | ||
932 | setFont_LabelWidget(btn, uiLabelBold_FontId); | ||
933 | } | ||
929 | } | 934 | } |
930 | } | 935 | } |
931 | addChild_Widget(dlg, iClob(div)); | 936 | addChild_Widget(dlg, iClob(div)); |
@@ -1168,7 +1173,10 @@ iWidget *makePreferences_Widget(void) { | |||
1168 | } | 1173 | } |
1169 | iWidget *div = new_Widget(); { | 1174 | iWidget *div = new_Widget(); { |
1170 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); | 1175 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); |
1171 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Dismiss", SDLK_ESCAPE, 0, "prefs.dismiss"))); | 1176 | setFont_LabelWidget( |
1177 | addChild_Widget( | ||
1178 | div, iClob(newKeyMods_LabelWidget("Dismiss", SDLK_ESCAPE, 0, "prefs.dismiss"))), | ||
1179 | uiLabelBold_FontId); | ||
1172 | } | 1180 | } |
1173 | addChild_Widget(dlg, iClob(div)); | 1181 | addChild_Widget(dlg, iClob(div)); |
1174 | addChild_Widget(get_Window()->root, iClob(dlg)); | 1182 | addChild_Widget(get_Window()->root, iClob(dlg)); |
@@ -1205,10 +1213,11 @@ iWidget *makeBookmarkEditor_Widget(void) { | |||
1205 | iWidget *div = new_Widget(); { | 1213 | iWidget *div = new_Widget(); { |
1206 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); | 1214 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); |
1207 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); | 1215 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); |
1208 | addChild_Widget( | 1216 | iLabelWidget *accept = addChild_Widget( |
1209 | div, | 1217 | div, |
1210 | iClob(newKeyMods_LabelWidget( | 1218 | iClob(newKeyMods_LabelWidget( |
1211 | uiTextCaution_ColorEscape "Save Bookmark", SDLK_RETURN, KMOD_PRIMARY, "bmed.accept"))); | 1219 | uiTextCaution_ColorEscape "Save Bookmark", SDLK_RETURN, KMOD_PRIMARY, "bmed.accept"))); |
1220 | setFont_LabelWidget(accept, uiLabelBold_FontId); | ||
1212 | } | 1221 | } |
1213 | addChild_Widget(dlg, iClob(div)); | 1222 | addChild_Widget(dlg, iClob(div)); |
1214 | addChild_Widget(get_Window()->root, iClob(dlg)); | 1223 | addChild_Widget(get_Window()->root, iClob(dlg)); |
@@ -1345,6 +1354,7 @@ iWidget *makeFeedSettings_Widget(uint32_t bookmarkId) { | |||
1345 | KMOD_PRIMARY, | 1354 | KMOD_PRIMARY, |
1346 | format_CStr("feedcfg.accept bmid:%d", bookmarkId)))), | 1355 | format_CStr("feedcfg.accept bmid:%d", bookmarkId)))), |
1347 | "feedcfg.save"); | 1356 | "feedcfg.save"); |
1357 | setFont_LabelWidget(findChild_Widget(div, "feedcfg.save"), uiLabelBold_FontId); | ||
1348 | } | 1358 | } |
1349 | addChild_Widget(dlg, iClob(div)); | 1359 | addChild_Widget(dlg, iClob(div)); |
1350 | arrange_Widget(dlg); | 1360 | arrange_Widget(dlg); |
@@ -1421,10 +1431,11 @@ iWidget *makeIdentityCreation_Widget(void) { | |||
1421 | iWidget *div = new_Widget(); { | 1431 | iWidget *div = new_Widget(); { |
1422 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); | 1432 | setFlags_Widget(div, arrangeHorizontal_WidgetFlag | arrangeSize_WidgetFlag, iTrue); |
1423 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); | 1433 | addChild_Widget(div, iClob(newKeyMods_LabelWidget("Cancel", SDLK_ESCAPE, 0, "cancel"))); |
1424 | addChild_Widget( | 1434 | iLabelWidget *accept = addChild_Widget( |
1425 | div, | 1435 | div, |
1426 | iClob(newKeyMods_LabelWidget( | 1436 | iClob(newKeyMods_LabelWidget( |
1427 | uiTextAction_ColorEscape "Create Identity", SDLK_RETURN, KMOD_PRIMARY, "ident.accept"))); | 1437 | uiTextAction_ColorEscape "Create Identity", SDLK_RETURN, KMOD_PRIMARY, "ident.accept"))); |
1438 | setFont_LabelWidget(accept, uiLabelBold_FontId); | ||
1428 | } | 1439 | } |
1429 | addChild_Widget(dlg, iClob(div)); | 1440 | addChild_Widget(dlg, iClob(div)); |
1430 | addChild_Widget(get_Window()->root, iClob(dlg)); | 1441 | addChild_Widget(get_Window()->root, iClob(dlg)); |