Mercurial > pidgin
comparison src/gtkprefs.c @ 10973:65c56b8490c5
[gaim-migrate @ 12798]
sf patch #1213669, from Michael R Head
"Vertically center pref labels for dropdowns"
committer: Tailor Script <tailor@pidgin.im>
author | Mark Doliner <mark@kingant.net> |
---|---|
date | Mon, 06 Jun 2005 02:40:01 +0000 |
parents | d5ce9d01f540 |
children | d1a77ae75f23 |
comparison
equal
deleted
inserted
replaced
10972:d5ce9d01f540 | 10973:65c56b8490c5 |
---|---|
971 _("Top"), GTK_POS_TOP, | 971 _("Top"), GTK_POS_TOP, |
972 _("Bottom"), GTK_POS_BOTTOM, | 972 _("Bottom"), GTK_POS_BOTTOM, |
973 _("Left"), GTK_POS_LEFT, | 973 _("Left"), GTK_POS_LEFT, |
974 _("Right"), GTK_POS_RIGHT, | 974 _("Right"), GTK_POS_RIGHT, |
975 NULL); | 975 NULL); |
976 gtk_misc_set_alignment(GTK_MISC(label), 0, 0); | 976 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); |
977 gtk_size_group_add_widget(sg, label); | 977 gtk_size_group_add_widget(sg, label); |
978 | 978 |
979 names = gaim_conv_placement_get_options(); | 979 names = gaim_conv_placement_get_options(); |
980 label = gaim_gtk_prefs_dropdown_from_list(vbox2, _("New conversation _placement:"), | 980 label = gaim_gtk_prefs_dropdown_from_list(vbox2, _("New conversation _placement:"), |
981 GAIM_PREF_STRING, "/gaim/gtk/conversations/placement", names); | 981 GAIM_PREF_STRING, "/gaim/gtk/conversations/placement", names); |
982 gtk_size_group_add_widget(sg, label); | 982 gtk_size_group_add_widget(sg, label); |
983 gtk_misc_set_alignment(GTK_MISC(label), 0, 0); | 983 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); |
984 g_list_free(names); | 984 g_list_free(names); |
985 | 985 |
986 gtk_widget_show_all(ret); | 986 gtk_widget_show_all(ret); |
987 | 987 |
988 return ret; | 988 return ret; |
1282 browsers = get_available_browsers(); | 1282 browsers = get_available_browsers(); |
1283 if (browsers != NULL) { | 1283 if (browsers != NULL) { |
1284 label = gaim_gtk_prefs_dropdown_from_list(vbox,_("_Browser:"), GAIM_PREF_STRING, | 1284 label = gaim_gtk_prefs_dropdown_from_list(vbox,_("_Browser:"), GAIM_PREF_STRING, |
1285 "/gaim/gtk/browsers/browser", | 1285 "/gaim/gtk/browsers/browser", |
1286 browsers); | 1286 browsers); |
1287 gtk_misc_set_alignment(GTK_MISC(label), 0, 0); | 1287 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); |
1288 gtk_size_group_add_widget(sg, label); | 1288 gtk_size_group_add_widget(sg, label); |
1289 | 1289 |
1290 hbox = gtk_hbox_new(FALSE, 0); | 1290 hbox = gtk_hbox_new(FALSE, 0); |
1291 label = gaim_gtk_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT, | 1291 label = gaim_gtk_prefs_dropdown(hbox, _("_Open link in:"), GAIM_PREF_INT, |
1292 "/gaim/gtk/browsers/place", | 1292 "/gaim/gtk/browsers/place", |
1293 _("Browser default"), GAIM_BROWSER_DEFAULT, | 1293 _("Browser default"), GAIM_BROWSER_DEFAULT, |
1294 _("Existing window"), GAIM_BROWSER_CURRENT, | 1294 _("Existing window"), GAIM_BROWSER_CURRENT, |
1295 _("New window"), GAIM_BROWSER_NEW_WINDOW, | 1295 _("New window"), GAIM_BROWSER_NEW_WINDOW, |
1296 _("New tab"), GAIM_BROWSER_NEW_TAB, | 1296 _("New tab"), GAIM_BROWSER_NEW_TAB, |
1297 NULL); | 1297 NULL); |
1298 gtk_misc_set_alignment(GTK_MISC(label), 0, 0); | 1298 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); |
1299 gtk_size_group_add_widget(sg, label); | 1299 gtk_size_group_add_widget(sg, label); |
1300 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); | 1300 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); |
1301 | 1301 |
1302 if (!strcmp(gaim_prefs_get_string("/gaim/gtk/browsers/browser"), "custom")) | 1302 if (!strcmp(gaim_prefs_get_string("/gaim/gtk/browsers/browser"), "custom")) |
1303 gtk_widget_set_sensitive(hbox, FALSE); | 1303 gtk_widget_set_sensitive(hbox, FALSE); |
1585 #endif | 1585 #endif |
1586 _("Command"), "custom", | 1586 _("Command"), "custom", |
1587 _("No sounds"), "none", | 1587 _("No sounds"), "none", |
1588 NULL); | 1588 NULL); |
1589 gtk_size_group_add_widget(sg, dd); | 1589 gtk_size_group_add_widget(sg, dd); |
1590 gtk_misc_set_alignment(GTK_MISC(dd), 0, 0); | 1590 gtk_misc_set_alignment(GTK_MISC(dd), 0, 0.5); |
1591 | 1591 |
1592 hbox = gtk_hbox_new(FALSE, 5); | 1592 hbox = gtk_hbox_new(FALSE, 5); |
1593 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 5); | 1593 gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 5); |
1594 | 1594 |
1595 label = gtk_label_new_with_mnemonic(_("Sound c_ommand:\n(%s for filename)")); | 1595 label = gtk_label_new_with_mnemonic(_("Sound c_ommand:\n(%s for filename)")); |
1796 #endif | 1796 #endif |
1797 #endif | 1797 #endif |
1798 NULL); | 1798 NULL); |
1799 | 1799 |
1800 gtk_size_group_add_widget(sg, dd); | 1800 gtk_size_group_add_widget(sg, dd); |
1801 gtk_misc_set_alignment(GTK_MISC(dd), 0, 0); | 1801 gtk_misc_set_alignment(GTK_MISC(dd), 0, 0.5); |
1802 | 1802 |
1803 vbox = gaim_gtk_make_frame (ret, _("Auto-away")); | 1803 vbox = gaim_gtk_make_frame (ret, _("Auto-away")); |
1804 button = gaim_gtk_prefs_checkbox(_("Set away _when idle"), | 1804 button = gaim_gtk_prefs_checkbox(_("Set away _when idle"), |
1805 "/core/away/away_when_idle", vbox); | 1805 "/core/away/away_when_idle", vbox); |
1806 | 1806 |
1813 hbox = gtk_hbox_new(FALSE, 0); | 1813 hbox = gtk_hbox_new(FALSE, 0); |
1814 gtk_container_add(GTK_CONTAINER(vbox), hbox); | 1814 gtk_container_add(GTK_CONTAINER(vbox), hbox); |
1815 | 1815 |
1816 label = gtk_label_new_with_mnemonic(_("Away m_essage:")); | 1816 label = gtk_label_new_with_mnemonic(_("Away m_essage:")); |
1817 gtk_size_group_add_widget(sg, label); | 1817 gtk_size_group_add_widget(sg, label); |
1818 gtk_misc_set_alignment(GTK_MISC(label), 0, 0); | 1818 gtk_misc_set_alignment(GTK_MISC(label), 0, 0.5); |
1819 g_signal_connect(G_OBJECT(button), "clicked", | 1819 g_signal_connect(G_OBJECT(button), "clicked", |
1820 G_CALLBACK(gaim_gtk_toggle_sensitive), label); | 1820 G_CALLBACK(gaim_gtk_toggle_sensitive), label); |
1821 gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); | 1821 gtk_box_pack_start(GTK_BOX(hbox), label, FALSE, FALSE, 0); |
1822 | 1822 |
1823 if (!gaim_prefs_get_bool("/core/away/away_when_idle")) { | 1823 if (!gaim_prefs_get_bool("/core/away/away_when_idle")) { |