Skip to content

Conversation

@tpikonen
Copy link
Contributor

This PR removes all usage of deprecated GTK stock features. I used Glade to fix the ui-files, which caused quite a bit of churn, but hopefully this makes future UI changes easier.

One instance of (deprecated) Gtk.Action was also replaced by Gio.SimpleAction.

I went through all the dialogs and they seem to work, but I mostly use the adaptive version, so I may have missed some of the breakage caused by saving the ui-files with Glade. Please test.

Glade does not allow to set it in the ui-file.
Resize:
 * hbox_search_episodes
 * hboxContainer
 * hboxUpdateFeeds
 * vbox_episode_list
 * vbox42
 * vboxChannelNavigator
 * vMain
@auouymous
Copy link
Member

The menu bar is missing with GTK_CSD=0.

@tpikonen
Copy link
Contributor Author

@auouymous, I can't replicate the missing menubar with GTK_CSD=0 here. Can you provide more details or bisect the patch stack? Can you test without GTK_CSD=0?

My guess is that this is related to setting the 'application' property in the code in fc6177a. Could you try if putting it back to gpodder.ui with this patch helps?

diff --git a/share/gpodder/ui/gtk/gpodder.ui b/share/gpodder/ui/gtk/gpodder.ui
index f2faf177..d3e3e0c7 100644
--- a/share/gpodder/ui/gtk/gpodder.ui
+++ b/share/gpodder/ui/gtk/gpodder.ui
@@ -15,6 +15,7 @@
   </object>
   <object class="GtkApplicationWindow" id="gPodder">
     <property name="name">gPodder</property>
+    <property name="application">app</property>
     <property name="can-focus">False</property>
     <property name="title">gPodder</property>
     <property name="window-position">center</property>

@auouymous
Copy link
Member

That patch fixed the menubar.

Why did you replace checkboxes with toggle buttons?

@auouymous
Copy link
Member

The quit button on toolbar is missing an icon.

The close icon in channel and episode find entries are missing.

What are all the placeholders in progress tab?

The Select None button on episode selector dialog is missing an icon.

@tpikonen
Copy link
Contributor Author

tpikonen commented Sep 1, 2021

Thanks for testing @auouymous. The latest push should fix all the problems you found.

The aim of this PR was to leave everything visibly as it was, but apparently the gtk-* icons which replace the stock items are not included in the default GTK theme (Adwaita). The generic replacements are not exactly the same in some cases ('edit-clear' and 'edit'), but should be close enough.

Could you check if the last commit fixes the missing menubar without the previous app-setting patch?

@auouymous
Copy link
Member

The menubar is still missing.

The '_builder_expose' argument to GtkBuilderWidget.__init__() allowed
binding of names in the ui-file to objects defined outside of the
ui-file.

Glade does not allow setting properties to values which are not defined
in the ui-file, so we set GTK/Gobject properties explicitly. This is
made with a new kwarg '_gtk_properties' in GtkBuilderWidget.__init__()
which is a dict with a (object_id, property_name) key.
@tpikonen
Copy link
Contributor Author

tpikonen commented Sep 3, 2021

Ok, one more try. @auouymous, could you check if the latest push fixes the menubar?

@tpikonen tpikonen added the wip label Sep 3, 2021
@auouymous
Copy link
Member

That fixed the menubar.

The General tab in preferences is missing icons on the two configure buttons.

The gpodder.net tab in prefs is missing padding for the container.

Using tab key to focus is broken in all preference tabs.

@tpikonen
Copy link
Contributor Author

tpikonen commented Sep 9, 2021

More fixes, thanks @auouymous.

Since this PR is getting ridiculously long, I'm going to squash and split it to smaller parts.

I'm also having second thoughts about bd77467, i.e. using the GTK gettext domain. Would it be better to just add the standard dialog button strings ('OK, 'Close', etc.) to be translated in gpodder?

@auouymous
Copy link
Member

Using GTK's translations would be better since gpodder has almost none.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants