Nicer layout for the preferences window

This commit is contained in:
Pierre Pronchery 2011-02-02 05:44:11 +00:00
parent 4f639e5773
commit d5b402f776
5 changed files with 12 additions and 10 deletions

View File

@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Editor 0.1.1\n" "Project-Id-Version: Editor 0.1.1\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-02-02 06:40+0100\n" "POT-Creation-Date: 2011-02-02 06:43+0100\n"
"PO-Revision-Date: 2010-04-07 22:05+0200\n" "PO-Revision-Date: 2010-04-07 22:05+0200\n"
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n" "Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
"Language-Team: German\n" "Language-Team: German\n"
@ -221,7 +221,7 @@ msgstr "Text Editor Einstellungen"
msgid "Font:" msgid "Font:"
msgstr "" msgstr ""
#: ../src/editor.c:878 #: ../src/editor.c:879
msgid "Wrap mode:" msgid "Wrap mode:"
msgstr "" msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Editor 0.1.1\n" "Project-Id-Version: Editor 0.1.1\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-02-02 06:40+0100\n" "POT-Creation-Date: 2011-02-02 06:43+0100\n"
"PO-Revision-Date: 2010-04-07 22:07+0200\n" "PO-Revision-Date: 2010-04-07 22:07+0200\n"
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n" "Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
"Language-Team: Spanish\n" "Language-Team: Spanish\n"
@ -221,7 +221,7 @@ msgstr ""
msgid "Font:" msgid "Font:"
msgstr "" msgstr ""
#: ../src/editor.c:878 #: ../src/editor.c:879
msgid "Wrap mode:" msgid "Wrap mode:"
msgstr "" msgstr ""

View File

@ -7,7 +7,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Editor 0.1.1\n" "Project-Id-Version: Editor 0.1.1\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-02-02 06:40+0100\n" "POT-Creation-Date: 2011-02-02 06:43+0100\n"
"PO-Revision-Date: 2010-04-11 12:32+0200\n" "PO-Revision-Date: 2010-04-11 12:32+0200\n"
"Last-Translator: Calimero <calimeroteknik@free.fr>\n" "Last-Translator: Calimero <calimeroteknik@free.fr>\n"
"Language-Team: French\n" "Language-Team: French\n"
@ -225,7 +225,7 @@ msgstr "Préférences de l'éditeur de texte"
msgid "Font:" msgid "Font:"
msgstr "Police :" msgstr "Police :"
#: ../src/editor.c:878 #: ../src/editor.c:879
msgid "Wrap mode:" msgid "Wrap mode:"
msgstr "Retour à la ligne :" msgstr "Retour à la ligne :"

View File

@ -8,7 +8,7 @@ msgid ""
msgstr "" msgstr ""
"Project-Id-Version: Editor 0.1.1\n" "Project-Id-Version: Editor 0.1.1\n"
"Report-Msgid-Bugs-To: \n" "Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2011-02-02 06:40+0100\n" "POT-Creation-Date: 2011-02-02 06:43+0100\n"
"PO-Revision-Date: 2010-04-09 16:43+0200\n" "PO-Revision-Date: 2010-04-09 16:43+0200\n"
"Last-Translator: Pierre Pronchery <khorben@defora.org>\n" "Last-Translator: Pierre Pronchery <khorben@defora.org>\n"
"Language-Team: Italian\n" "Language-Team: Italian\n"
@ -222,7 +222,7 @@ msgstr ""
msgid "Font:" msgid "Font:"
msgstr "" msgstr ""
#: ../src/editor.c:878 #: ../src/editor.c:879
msgid "Wrap mode:" msgid "Wrap mode:"
msgstr "" msgstr ""

View File

@ -867,21 +867,23 @@ void editor_show_preferences(Editor * editor, gboolean show)
/* font */ /* font */
hbox = gtk_hbox_new(FALSE, 4); hbox = gtk_hbox_new(FALSE, 4);
widget = gtk_label_new(_("Font:")); widget = gtk_label_new(_("Font:"));
gtk_misc_set_alignment(GTK_MISC(widget), 0.0, 0.5);
gtk_size_group_add_widget(group, widget);
gtk_box_pack_start(GTK_BOX(hbox), widget, FALSE, TRUE, 0); gtk_box_pack_start(GTK_BOX(hbox), widget, FALSE, TRUE, 0);
editor->pr_font = gtk_font_button_new(); editor->pr_font = gtk_font_button_new();
gtk_font_button_set_use_font(GTK_FONT_BUTTON(editor->pr_font), TRUE); gtk_font_button_set_use_font(GTK_FONT_BUTTON(editor->pr_font), TRUE);
gtk_size_group_add_widget(group, editor->pr_font);
gtk_box_pack_start(GTK_BOX(hbox), editor->pr_font, TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(hbox), editor->pr_font, TRUE, TRUE, 0);
gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
/* wrap mode */ /* wrap mode */
hbox = gtk_hbox_new(FALSE, 4); hbox = gtk_hbox_new(FALSE, 4);
widget = gtk_label_new(_("Wrap mode:")); widget = gtk_label_new(_("Wrap mode:"));
gtk_misc_set_alignment(GTK_MISC(widget), 0.0, 0.5);
gtk_size_group_add_widget(group, widget);
gtk_box_pack_start(GTK_BOX(hbox), widget, FALSE, TRUE, 0); gtk_box_pack_start(GTK_BOX(hbox), widget, FALSE, TRUE, 0);
editor->pr_wrap = gtk_combo_box_new_text(); editor->pr_wrap = gtk_combo_box_new_text();
for(i = 0; i < sizeof(_editor_wrap) / sizeof(*_editor_wrap); i++) for(i = 0; i < sizeof(_editor_wrap) / sizeof(*_editor_wrap); i++)
gtk_combo_box_append_text(GTK_COMBO_BOX(editor->pr_wrap), gtk_combo_box_append_text(GTK_COMBO_BOX(editor->pr_wrap),
_(_editor_wrap[i].name)); _(_editor_wrap[i].name));
gtk_size_group_add_widget(group, editor->pr_wrap);
gtk_box_pack_start(GTK_BOX(hbox), editor->pr_wrap, TRUE, TRUE, 0); gtk_box_pack_start(GTK_BOX(hbox), editor->pr_wrap, TRUE, TRUE, 0);
gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0); gtk_box_pack_start(GTK_BOX(vbox), hbox, FALSE, FALSE, 0);
_preferences_on_cancel(editor); _preferences_on_cancel(editor);