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 660324 - Support lists of custom results
Support lists of custom results
Status: RESOLVED WONTFIX
Product: reinteract
Classification: Other
Component: general
unspecified
Other Linux
: Normal normal
: ---
Assigned To: reinteract-maint
reinteract-maint
gnome[unmaintained]
Depends on:
Blocks:
 
 
Reported: 2011-09-28 03:48 UTC by Owen Taylor
Modified: 2018-07-10 22:06 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Proof of concept patch (2.99 KB, patch)
2011-09-28 03:51 UTC, Owen Taylor
none Details | Review

Description Owen Taylor 2011-09-28 03:48:59 UTC
[ Originally filed as http://www.reinteract.org/trac/ticket/73

Transcribing a suggestion from an old thread on the Reinteract group:

Tero Jäntti wrote:

===
I like it, not because it outputs HTML, but because it presents lists nicely.

I like Reinteract because it is great for experimenting things. So, what if, when receiving a list of CustomResult objects, they would all be drawn as a list. With list comprehensions, such list would be great for experimenting with different parameter values, like:

 [ plot( f(x, 5) ) for x in range(-5, 5) ]

 [ rere.search(x, 'foo') for x in ['foo',  'foo|bar',  '[a-z]+'] ]

That way you would immediately see which values suit best in whatever case you are doing.

Better yet, drawing nested lists of CustomResults as two-dimensional tables... Although that would eat a lot of screen space.
===

Another possibility would be to support a list of custom results as a "slide deck" where you could page through the different results. Actually you could implement

 slides([ plot( f(x, 5) ) for x in range(-5, 5) ])

Right now without any changes to the Reinteract core ... it would just be a widget (GtkNotebook with or without tabs, perhaps) that embedded each all the custom result widgets and allowed selection between them.
Comment 1 Owen Taylor 2011-09-28 03:50:07 UTC
Proof of concept patch
10/04/09 16:04:48 changed by rschroll
=====================================

This patch makes lists or tuples of CustomResults be displayed. There are two modes for display, and the user may toggle between them. In the first, the widgets are displayed in a vertical list. In the second, each widget is a page in a gtk.Notebook.

Some questions I have about this solution: - Should this work with general iterables, not just lists and tuples? - It only works if all elements of the list are CustomResults. Should it also support mixed lists? - Does the all() check short-circuit correctly? Otherwise, this could become a bottleneck when dealing with large arrays. - Is being able to toggle between the views helpful or confusing? - Can the toggle triangle be moved into the gutter? - Should the default view depend on the number or size of widgets?
Comment 2 Owen Taylor 2011-09-28 03:51:01 UTC
Created attachment 197627 [details] [review]
Proof of concept patch

Patch from the original ticket
Comment 3 Robert Schroll 2011-09-28 05:21:50 UTC
This could be done more easily with wrappers nowadays.  If we don't want to make this the default behavior, the wrapper still could come with Reinteract for the user to enable as desired.
Comment 4 André Klapper 2018-07-10 22:06:25 UTC
Reinteract is not under active development anymore and had its last code changes
in early 2012: http://git.fishsoup.net/cgit/reinteract/log/

Closing this report as WONTFIX as part of Bugzilla Housekeeping to reflect
reality. Please feel free to reopen this ticket (or rather transfer the project
to GNOME Gitlab, as GNOME Bugzilla is deprecated) if anyone takes the
responsibility for active development again.