Improvement of rectangular selection

Have some feature requests, feedback, cool stuff to share, or want to know where FreeCAD is going? This is the place.
Forum rules
Be nice to others! Read the FreeCAD code of conduct!
SparkyCola
Posts: 22
Joined: Mon May 29, 2017 11:29 pm

Improvement of rectangular selection

Postby SparkyCola » Thu Sep 28, 2017 6:55 pm

So in addition to the "normal" selection which is currently there I'd like to add a selection that selects the whole object when it's only touched on one corner/line/point.
It could be switched like in SolidWorks where it depends if you make the selection bottom to top or top to bottom (not sure which was which). Using a key like the M key is another option however the start-point method seems simpler to me (especially when you have to switch a lot between the modes).
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Improvement of rectangular selection

Postby bejant » Fri Sep 29, 2017 1:33 am

AutoCAD has a similar behavior - there is (or was) a ticket in the tracker for this (and I may have commented on it) but I don't know what became of it. Let me check...
Edit: Sorry - that will have to wait because the tracker is too slow for me now. The ticket might have been submitted by Oldestfox but I'm not sure.
wmayer
Site Admin
Posts: 14999
Joined: Thu Feb 19, 2009 10:32 am

Re: Improvement of rectangular selection

Postby wmayer » Fri Sep 29, 2017 6:16 am

So in addition to the "normal" selection which is currently there I'd like to add a selection that selects the whole object when it's only touched on one corner/line/point.
It could be switched like in SolidWorks where it depends if you make the selection bottom to top or top to bottom (not sure which was which).
This is already implemented with the difference that it's not top <=> bottom/bottom <=> top but left <=> right/right <=> left.
User avatar
bejant
Posts: 5953
Joined: Thu Jul 11, 2013 3:06 pm

Re: Improvement of rectangular selection

Postby bejant » Sat Sep 30, 2017 2:04 am

wmayer wrote:
Fri Sep 29, 2017 6:16 am
This is already implemented
I didn't know - thanks! I just tested it and think I have found a glitch which can be replicated by doing this:
Create the default Cube.
Create a Sketch (I used the X-Y Plane at the default Z = 0) and make a zig-zag pattern larger than the footprint of the Cube, something like this:
20170929a.png
20170929a.png (3.75 KiB) Viewed 891 times
Now try the right-to-left Box Select on a portion of the Cube without intersecting the Sketch geometry and the all the Sketch geometry is selected. I'm guessing right-to-left selection uses something like a bounding box instead of using the geometry itself?

OS: Ubuntu 16.04.3 LTS
Word size of OS: 32-bit
Word size of FreeCAD: 32-bit
Version: 0.17.12223 (Git)
Build type: None
Branch: master
Hash: 917e61a3be12f3316d571ebf6fd6e3c537691c14
Python version: 2.7.12
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.1.0
Locale: English/UnitedStates (en_US)
chrisb
Posts: 19635
Joined: Tue Mar 17, 2015 9:14 am

Re: Improvement of rectangular selection

Postby chrisb » Sat Sep 30, 2017 5:24 am

How do you perform this selection anyway? I guess it's a rubberband selection, which I don't have at all. It exists only in Sketcher.
I use the Gesture mouse model.
wmayer
Site Admin
Posts: 14999
Joined: Thu Feb 19, 2009 10:32 am

Re: Improvement of rectangular selection

Postby wmayer » Sat Sep 30, 2017 7:56 am

For performance reasons it doesn't check each element of an object if it's inside the rectangle but instead it just uses an object's (projected) bounding box.
peterl94
Posts: 999
Joined: Thu May 23, 2013 7:31 pm
Location: United States

Re: Improvement of rectangular selection

Postby peterl94 » Sat Sep 30, 2017 12:08 pm

chrisb wrote:
Sat Sep 30, 2017 5:24 am
How do you perform this selection anyway?
Shift + B starts the box select command (edit menu).
User avatar
Kunda1
Posts: 5937
Joined: Thu Jan 05, 2017 9:03 pm

Re: Improvement of rectangular selection

Postby Kunda1 » Sat Sep 30, 2017 12:28 pm

sort of unrelated but here's another box issue that is open on the tracker: issue #2706 - Box selection does not select dimension or text
Want to contribute back to FC? Checkout:
#lowhangingfruit | Use the Source, Luke. | How to Help FreeCAD | How to report FC bugs and features
SparkyCola
Posts: 22
Joined: Mon May 29, 2017 11:29 pm

Re: Improvement of rectangular selection

Postby SparkyCola » Sat Sep 30, 2017 1:24 pm

wmayer wrote:
Fri Sep 29, 2017 6:16 am
So in addition to the "normal" selection which is currently there I'd like to add a selection that selects the whole object when it's only touched on one corner/line/point.
It could be switched like in SolidWorks where it depends if you make the selection bottom to top or top to bottom (not sure which was which).
This is already implemented with the difference that it's not top <=> bottom/bottom <=> top but left <=> right/right <=> left.
I can't get Sketcher to select the whole line/circle/element when I only box a part of it, no matter from where I start the selection. That is what I was looking for.
GeneFC
Posts: 1025
Joined: Sat Mar 19, 2016 3:36 pm
Location: Punta Gorda, FL

Re: Improvement of rectangular selection

Postby GeneFC » Sat Sep 30, 2017 3:32 pm

SparkyCola wrote:
Sat Sep 30, 2017 1:24 pm
I can't get Sketcher to select the whole line/circle/element when I only box a part of it, no matter from where I start the selection. That is what I was looking for.
That sort of behavior is a choice made by the program designers. I have some graphics-related programs that work on the "touch" method and other that require the entire object to be selected.

There are pluses and minuses to both approaches. The "touch" method sounds easy, but it also makes it very easy to select unwanted elements that may have portions close to the desired selection. The "entire" method is generally more definite for selection, but it is slightly more work.

I don't see an obvious advantage for one method over the other.

Just learn the "rules" and go forward.

Gene