mail icon indicating copy to clipboard operation
mail copied to clipboard

Gtk4 port

Open leolost2605 opened this issue 2 years ago • 4 comments
trafficstars

As far as I know most features from the gtk3 version are now implemented. It still has some (mainly styling) issues (see below) and if there is anything that could still be back ported please tell me

GTK3: image

GTK4: image

A few general things:

  • SourceList was replaced with a ListView and a TreeListModel
  • VirtualizingListBox was replaced with a ListView

A few issues to note:

  • [ ] ReadMe wasn't updated yet (new deps: libadwaita, gtk4, libedataserverui4 >= 3.46.4, libedataserver >= 3.45.1, granite-7 >= 7.1, webkitgtk-6-dev)
  • [ ] Flatpak manifest wasn't updated yet
  • [ ] @danirabbit any suggestion on how to style the sidebar? Does it need to be exactly like the sourcelist was? Because currently it's way further indented because of how Gtk.TreeExpander handles indentation. This can be changed with GTK 4.10 however. It's probably best to make GTK 4.10 mandatory anyway because of some bugs it fixes with ListView. Also I don't know about the account icons I just added them because I thought they might look good :)
  • [ ] Some more styling issues, especially with the Gtk.Paned separators (at least for me) and the unread badges and their size and alignment (see TODOs). I'm gonna need some help with these :)
  • [ ] The menu for the conversations can't be activated with the menu key anymore (needed? I couldn't find an easy way to do this and make the menu appear at the right position, but it's definitely possible)
  • [ ] (I'm not sure whether Gravatars work, sometimes it seems so other times it doesn't but at least the UI won't freeze anymore.) I think they work now...
  • [ ] Position isn't remembered anymore. I heard it should be left to the window manager entirely so I don't know 🤷
  • [x] ~~Prompt for credentials if not found (E.CredentialsPrompter replacement ? Or did I miss something?)~~ Turns out it's fixed in libedatserverui4 versions >= 3.46.4 (See this issue). Therefore revert changes to that.
  • [x] Fix a crash on opening a context menu in a MessageListItem
  • [ ] Cleanup
  • [ ] Fix lint

Feedback and suggestions are always appreciated! 😀

leolost2605 avatar Apr 19 '23 17:04 leolost2605

Is there any way we could land the new accounts list in the Gtk3 version or are we relying on features in Gtk4?

It relies on Gtk.ListView and as SourceList also doesn't seem to support factories I don't think it's possible without some major tweaks but I'll give it a try.

Unfortunately we're stuck with Gtk 4.6.6 until we rebase on Ubuntu 24.04 so we either have to wait until then to land the Gtk 4 port or stick with what is available in that version

If the current look is ok we can stick with Gtk 4.6.6. Maybe a stupid question but does that mean we are stuck with 22.04 packages entirely? Or is there another reason for the gtk 4 restriction?

leolost2605 avatar Apr 24 '23 20:04 leolost2605

Yeah exactly we have to ship Mail in deb currently because of issues with accessing the host keychain with evolution and it not working with online accounts. So we're stuck with Ubuntu's packages there

danirabbit avatar Apr 24 '23 21:04 danirabbit

I guess we'll have to wait for 24.04 then anyway. In the meantime is there anything I can help with getting the flatpak version to work? I've come over this, is it still relevant?

leolost2605 avatar Apr 29 '23 16:04 leolost2605

I think @tintou probably knows the most about this since he's done upstream work with EDS but yeah my understanding is that the Flatpak EDS can't access the credentials stored in the host EDS

danirabbit avatar Apr 29 '23 16:04 danirabbit