After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 720850 - Use GtkListBox for conversation list
Use GtkListBox for conversation list
Status: RESOLVED DUPLICATE of bug 730682
Product: geary
Classification: Other
Component: client
master
Other Linux
: Normal normal
: ---
Assigned To: Geary Maintainers
Geary Maintainers
: 714846 (view as bug list)
Depends on: 764812
Blocks:
 
 
Reported: 2013-12-20 20:25 UTC by Jim Nelson
Modified: 2017-12-13 23:24 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Jim Nelson 2013-12-20 20:25:45 UTC
GtkTreeView / GtkCellRenderer has proven to be problematic for our Conversation List needs (see bug #720783, bug #713041, bug #713081, bug #714972).  GTK 3.10 has a new GtkListBox which (hopefully) will solve a lot of our issues, in particular because it allows for widgets to be laid out rather than rendering the text by hand.
Comment 1 Yosef Or Boczko 2013-12-21 18:58:56 UTC
Also, it will fix the problem with RTL (the conversation list
look realy bad with Hebrew text and RTL layout).
Comment 2 Wolfgang Steitz 2013-12-30 13:50:58 UTC
I don't think GtkListBox supports everything geary needs, e.g. it does not allow multiple selection [1].


[1] https://developer.gnome.org/gtk3/3.10/GtkListBox.html#gtk-list-box-set-selection-mode
Comment 3 Jim Nelson 2014-01-04 00:45:32 UTC
Ah-ha -- that's kind of a deal-breaker.  I've filed a request with the GTK+ team at bug #721440.
Comment 4 Jim Nelson 2014-05-23 19:30:20 UTC
GtkListBox now supports multiple selections.  That plus a list box model would go a long way to making it the perfect choice for Geary.
Comment 5 Jim Nelson 2014-05-26 17:32:06 UTC
See also bug #730682.
Comment 6 Wolfgang Steitz 2014-05-29 08:28:00 UTC
Currently GtkListBox does not use a model (bug #710414). Do you think it is still worth to try or should we wait until it supports a model?
Comment 7 Jim Nelson 2014-05-29 20:23:17 UTC
Geary is still tied to GTK+ 3.10, so using GtkListBox in Geary is a ways off anyway.

I would *prefer* to wait for a proper model.  I wrote my own list box model for California [1] but it doesn't deal with creating/destroying widgets as they come off and on the viewport, which is not a problem for California but would be a perfect fit for Geary.

That said, there's a lot of work to be done to get this to work (moving to GtkListBox, laying out the widgets to replace the formatted cell, and so one).  If someone wanted to tackle this now, a lot of that work would be reused with or without a model.  But until Geary targets GTK 3.14 (where GtkListBox has multiple selection support), we can't land anything in master.

[1] https://git.gnome.org/browse/california/tree/src/toolkit/toolkit-listbox-model.vala
Comment 8 Yosef Or Boczko 2014-05-29 20:26:33 UTC
(In reply to comment #7)
> Geary is still tied to GTK+ 3.10, so using GtkListBox in Geary is a ways off
> anyway.
> 
> I would *prefer* to wait for a proper model.  I wrote my own list box model for
> California [1] but it doesn't deal with creating/destroying widgets as they
> come off and on the viewport, which is not a problem for California but would
> be a perfect fit for Geary.
> 
> That said, there's a lot of work to be done to get this to work (moving to
> GtkListBox, laying out the widgets to replace the formatted cell, and so one). 
> If someone wanted to tackle this now, a lot of that work would be reused with
> or without a model.  But until Geary targets GTK 3.14 (where GtkListBox has
> multiple selection support), we can't land anything in master.
> 

Jim, I think it will be great idea to try to move your code [1] to GTK+ itself.
I guess the GTK+'s devs will take it in C + some changes, but it something
we needs in GTK+ itself.

> [1]
> https://git.gnome.org/browse/california/tree/src/toolkit/toolkit-listbox-model.vala
Comment 9 Jim Nelson 2014-05-29 20:32:11 UTC
(In reply to comment #8)
> Jim, I think it will be great idea to try to move your code [1] to GTK+ itself.
> I guess the GTK+'s devs will take it in C + some changes, but it something
> we needs in GTK+ itself.

Unfortunately, I don't have the time to port the code to C.  Plus, it's quite possible that some of the widget's functionality will be moved into the model (i.e. filtering and sorting) which I personally think is a good idea.  My model piggybacks on those features in the widget itself rather than replicate it in the model code.

I'll comment on the ticket, though, to be involved in the discussion.
Comment 10 Yosef Or Boczko 2014-05-29 20:34:45 UTC
(In reply to comment #9)
> (In reply to comment #8)
> > Jim, I think it will be great idea to try to move your code [1] to GTK+ itself.
> > I guess the GTK+'s devs will take it in C + some changes, but it something
> > we needs in GTK+ itself.
> 
> Unfortunately, I don't have the time to port the code to C.  Plus, it's quite
> possible that some of the widget's functionality will be moved into the model
> (i.e. filtering and sorting) which I personally think is a good idea.  My model
> piggybacks on those features in the widget itself rather than replicate it in
> the model code.
> 
> I'll comment on the ticket, though, to be involved in the discussion.

On second thought, maybe this is the time to start coding in Vala in GTK+?
After all, for the tarball it not a problem (we can to provide the c-gen code
from valac in the tarball, so there isn't any depend on valac in tarbal).
Comment 11 Jim Nelson 2014-09-10 18:46:36 UTC
See also bug #736434.
Comment 12 Jim Nelson 2014-10-09 01:35:17 UTC
*** Bug 714846 has been marked as a duplicate of this bug. ***
Comment 13 Michael Gratton 2016-04-21 04:40:40 UTC
Marking as a duplicate of Bug 730682 since the plan is to use a GtkListBox for that.

*** This bug has been marked as a duplicate of bug 730682 ***