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 167047 - improve selection of overlapping elements: rotating selection
improve selection of overlapping elements: rotating selection
Status: RESOLVED FIXED
Product: Gazpacho
Classification: Deprecated
Component: user interface
0.5.3
Other All
: Normal enhancement
: ---
Assigned To: Gazpacho Maintainer(s)
Gazpacho Maintainer(s)
Depends on:
Blocks: 172261
 
 
Reported: 2005-02-11 12:14 UTC by Rafael Villar Burke
Modified: 2005-04-06 23:03 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch implementing a simplified version of the feature (4.53 KB, patch)
2005-03-15 13:19 UTC, Mattias Karlsson
none Details | Review
Patch for the race bug (797 bytes, patch)
2005-04-06 22:43 UTC, Mattias Karlsson
none Details | Review

Description Rafael Villar Burke 2005-02-11 12:14:08 UTC
I would be fine to have a rotating selection mode to be able to choose elements
that are stacked. Now we can select a parent widget using shift-click, but we
could extend this idea, so while you have shift pressed or until you do
right-click, each normal click highlights one of the stacked objects and rotates
between them until the rotation is broken and the object gets selected. The
highlighted widget is displayed on the statusbar as "Widget01 highlighted" and
when it gets selected it is shown as "Widget01 selected". It would be great also
having a visual tip of the highlighted status (for instance, with a thick
coloured border around the highlighted widget) as well as the textual tip given
on the status bar.

For example:

- We have objects A, B and C piled up and with A on top and C at the bottom.
- if we normal click on the intersection area then just object A is selected and
"A selected" is shown in the statusbar as it is the topmost object on the pile.
- But, if we shift+click on the intersection area then A is highlighted and "A
highlighted" is shown on the statusbar. If we keep clicking again then B is
highlighted and "B highlighted" is displayed on the statusbar. If we do it once
again we have C, and next we have A back as highlighted, then B, then C...
- To get one of these selected and break the circular selection we just right
click or end pressing the shift key (what we like best) and the currently
highlighted object gets fully selected, so on the statusbar we can read "[ABC]
selected".

This way you should only need to use the widget treeview to operate on large
branchs, to copy, cut or move them, but for normal operation you wouldn't need
it... so we can get that screen space back (maybe leaving an expander to
ocasionally show it).
Comment 1 Mattias Karlsson 2005-03-15 13:19:26 UTC
Created attachment 38747 [details] [review]
Patch implementing a simplified version of the feature

I've created a patch that implements a simplified version of the feature
requested. It makes Gazpacho behave as glade2 in this respect.

When you shift click on a widget it will select the parent of the selected
widget (if the selected widget is in the current branch of the tree). If the
selected widget is a toplevel widget we select the leaf widget. If no widgets
have been selected (in the current tree) we select the leaf widget.

I've put the circle_select method in utils.py not sure if that's ok, but I
couldn't think of another place.
Comment 2 Lorenzo Gil Sanchez 2005-04-06 19:25:40 UTC
There is a problem with this patch I haven't being able to fix: If the user
clicks very fast the selection goes weird.

No idea of what is going on.

I applied the patch but the bug is not fixed since we have this race condition
Comment 3 Mattias Karlsson 2005-04-06 21:07:21 UTC
I'll take a look at it. One thing I noticed is that it only seems to affect
widgets, not placeholders (unless I just was lucky).
Comment 4 Lorenzo Gil Sanchez 2005-04-06 21:18:13 UTC
That's true, only with widgets
Comment 5 Mattias Karlsson 2005-04-06 22:43:07 UTC
Created attachment 39774 [details] [review]
Patch for the race bug

We just had to make sure not to call circle_select on double and tripple click
events.

The placeholder code already did this, that's why it worked from the beginning.
Comment 6 Lorenzo Gil Sanchez 2005-04-06 23:03:50 UTC
Thanks Mattias, you did a great job with this one