123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609 |
- diff --git a/Makefile.am b/Makefile.am
- index 22f7501..e2a86ba 100644
- --- a/Makefile.am
- +++ b/Makefile.am
- @@ -58,6 +58,7 @@ src_obconf_la_SOURCES = \
- src/tree.h
-
- dist_glade_DATA = \
- + src/obconf-gtk3.glade \
- src/obconf.glade
-
- EXTRA_DIST = \
- diff --git a/Makefile.in b/Makefile.in
- index c308cc7..dd0a378 100644
- --- a/Makefile.in
- +++ b/Makefile.in
- @@ -480,6 +480,7 @@ src_obconf_la_SOURCES = \
- src/tree.h
-
- dist_glade_DATA = \
- + src/obconf-gtk3.glade \
- src/obconf.glade
-
- EXTRA_DIST = \
- diff --git a/src/main.c b/src/main.c
- index a39faf1..15c65d8 100644
- --- a/src/main.c
- +++ b/src/main.c
- @@ -171,12 +171,22 @@ extern gboolean plugin_load(LXAppearance* app, GtkBuilder* lxappearance_builder)
-
- builder = gtk_builder_new();
- gtk_builder_set_translation_domain(builder, GETTEXT_PACKAGE);
- +#if GTK_CHECK_VERSION(3, 0, 0)
- + // hide theme preview for GTKv3 (ticket #768)
- + g_debug(GLADEDIR"/obconf-gtk3.glade");
- + if(!gtk_builder_add_from_file(builder, GLADEDIR"/obconf-gtk3.glade", NULL))
- + {
- + obconf_error(_("Failed to load the obconf-gtk3.glade interface file. ObConf is probably not installed correctly."), TRUE);
- + exit_with_error = TRUE;
- + }
- +#elif // GTK_CHECK_VERSION(3, 0, 0)
- g_debug(GLADEDIR"/obconf.glade");
- if(!gtk_builder_add_from_file(builder, GLADEDIR"/obconf.glade", NULL))
- {
- obconf_error(_("Failed to load the obconf.glade interface file. ObConf is probably not installed correctly."), TRUE);
- exit_with_error = TRUE;
- }
- +#endif // GTK_CHECK_VERSION(3, 0, 0)
- gtk_builder_connect_signals(builder, NULL);
- gtk_box_pack_start( GTK_BOX(app->wm_page), get_widget("obconf_vbox"), TRUE, TRUE, 0);
- gtk_widget_show_all(app->wm_page);
- diff --git a/src/obconf-gtk3.glade b/src/obconf-gtk3.glade
- new file mode 100644
- index 0000000..eb738e4
- --- /dev/null
- +++ b/src/obconf-gtk3.glade
- @@ -0,0 +1,551 @@
- +<?xml version="1.0" encoding="UTF-8"?>
- +<interface>
- + <requires lib="gtk+" version="2.16"/>
- + <!-- interface-naming-policy project-wide -->
- + <object class="GtkVBox" id="obconf_vbox">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkHBox" id="hbox1">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">12</property>
- + <child>
- + <object class="GtkNotebook" id="notebook1">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="scrollable">True</property>
- + <child>
- + <object class="GtkVBox" id="vbox1">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="border_width">12</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkVBox" id="vbox3">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkLabel" id="label3">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes"><span weight="bold">Theme</span></property>
- + <property name="use_markup">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkScrolledWindow" id="scrolledwindow1">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="hscrollbar_policy">never</property>
- + <property name="vscrollbar_policy">automatic</property>
- + <property name="shadow_type">in</property>
- + <child>
- + <object class="GtkTreeView" id="theme_names">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="headers_visible">False</property>
- + </object>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkVBox" id="vbox5">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <child>
- + <object class="GtkButton" id="install_theme">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <signal name="clicked" handler="on_install_theme_clicked" swapped="no"/>
- + <child>
- + <object class="GtkAlignment" id="alignment3">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="xscale">0</property>
- + <property name="yscale">0</property>
- + <child>
- + <object class="GtkHBox" id="hbox3">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">2</property>
- + <child>
- + <object class="GtkImage" id="image3">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="stock">gtk-open</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label5">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="label" translatable="yes">_Install a new theme...</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + </child>
- + </object>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkVBox" id="vbox6">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <child>
- + <object class="GtkButton" id="theme_archive">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <signal name="clicked" handler="on_theme_archive_clicked" swapped="no"/>
- + <child>
- + <object class="GtkAlignment" id="alignment4">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="xscale">0</property>
- + <property name="yscale">0</property>
- + <child>
- + <object class="GtkHBox" id="hbox4">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">2</property>
- + <child>
- + <object class="GtkImage" id="image4">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="stock">gtk-save</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label6">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="label" translatable="yes">Create a theme _archive (.obt)...</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + </child>
- + </object>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">False</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">2</property>
- + </packing>
- + </child>
- + </object>
- + </child>
- + <child type="tab">
- + <object class="GtkLabel" id="label7">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Theme</property>
- + </object>
- + <packing>
- + <property name="tab_fill">False</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkVBox" id="vbox7">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="border_width">12</property>
- + <property name="spacing">18</property>
- + <child>
- + <object class="GtkVBox" id="vbox8">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkLabel" id="label15">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for active window title:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_active">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_active_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label16">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for inactive window title:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">2</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_inactive">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_inactive_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">3</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkVBox" id="vbox11">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkHBox" id="hbox6">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkLabel" id="label10">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="label" translatable="yes">_Button order:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkEntry" id="title_layout">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="invisible_char">●</property>
- + <property name="primary_icon_activatable">False</property>
- + <property name="secondary_icon_activatable">False</property>
- + <property name="primary_icon_sensitive">True</property>
- + <property name="secondary_icon_sensitive">True</property>
- + <signal name="changed" handler="on_title_layout_changed" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label11">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="yalign">0</property>
- + <property name="label" translatable="yes">N: Window icon
- +L: Window label (Title)
- +I: Iconify (Minimize)
- +M: Maximize
- +C: Close
- +S: Shade (Roll up)
- +D: Omnipresent (On all desktops)</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + <child type="tab">
- + <object class="GtkLabel" id="label12">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Title Bar</property>
- + </object>
- + <packing>
- + <property name="position">1</property>
- + <property name="tab_fill">False</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkVBox" id="vbox10">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="border_width">12</property>
- + <child>
- + <object class="GtkVBox" id="vbox2">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="spacing">6</property>
- + <child>
- + <object class="GtkLabel" id="label17">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for menu header:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_menu_header">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_menu_header_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">1</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label18">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for menu Item:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">2</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_menu_item">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_menu_item_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">3</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label19">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for on-screen display:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">4</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_active_display">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_active_display_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">5</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkLabel" id="label1">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Font for inactive on-screen display:</property>
- + <property name="use_underline">True</property>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">6</property>
- + </packing>
- + </child>
- + <child>
- + <object class="GtkFontButton" id="font_inactive_display">
- + <property name="visible">True</property>
- + <property name="can_focus">True</property>
- + <property name="receives_default">True</property>
- + <property name="use_action_appearance">False</property>
- + <property name="use_font">True</property>
- + <signal name="font-set" handler="on_font_inactive_display_font_set" swapped="no"/>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">7</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">False</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="position">2</property>
- + </packing>
- + </child>
- + <child type="tab">
- + <object class="GtkLabel" id="label20">
- + <property name="visible">True</property>
- + <property name="can_focus">False</property>
- + <property name="xalign">0</property>
- + <property name="label" translatable="yes">Misc.</property>
- + </object>
- + <packing>
- + <property name="position">2</property>
- + <property name="tab_fill">False</property>
- + </packing>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + <child>
- + </child>
- + </object>
- + <packing>
- + <property name="expand">True</property>
- + <property name="fill">True</property>
- + <property name="position">0</property>
- + </packing>
- + </child>
- + </object>
- +</interface>
|