FEATURE: 404829
Adds the option to have spectacle accept the selected region as soon
as the mouse button is released, similar to how other screenshot tools
allow it (eg. scrot -s).
Details
- Reviewers
ngraham - Group Reviewers
VDG Spectacle - Commits
- R166:bda92cdc2681: Add option to auto-accept box selection on mouse release
To enable the option go to
Configure -> General -> Rectangular Region -> Accept region on mouse release
then set the Capture mode to Rectangular Region and take a new screenshot.
Behaviour should be the following:
-When selecting a new region, without a previously saved region available, click->drag->release should immediately capture the selected region. -When a previously saved region is shown, the saved region can be manipulated further and saving this region requires manual confirmation (Enter/Double LMB). -Clicking and dragging outside of the previously saved region captures the newly selected region immediately.
Diff Detail
- Repository
- R166 Spectacle
- Lint
Automatic diff as part of commit; lint not applicable. - Unit
Automatic diff as part of commit; unit tests not applicable.
Sweet, that was fast!
Let's make sure to update the explanatory text appropriately when this mode is being used--including in conjunction with remembered regions.
src/Gui/SettingsDialog/GeneralOptionsPage.cpp | ||
---|---|---|
77 | Not everybody has a mouse. In fact my only machine is a laptop that I use with its built-in touchpad. I bet we can come up with a more universally appropriate string. Maybe Accept immediately? Accept on click-and-release? |
Accept on Click-and-release sounds good to me, however I'm not sure what exactly I could add to the help text to make this functionality clear in a concise manner,
especially considering the current functionality of being able to drag and expand an existing region is only explained through visual cues (grab-handles on the region, changing cursor).
Maybe I'm misunderstanding which help text you mean, I assume you are talking about the key-bindings overlay (aka mBottomHelpText)?
Yep, that one. When accept-on-click-and-release is being used, and one of the "remember the region" modes is NOT being used, we should make the text just say something like "Click and drag to select the desired region", because everything else pertains to manipulating the region. But when accept-on-click-and-release and one of the "remember the region" modes IS being used, then we should just change "Enter, double-click:" to "Click and drag, Enter, double-click:"
Does that make sense?
Okay, here's the new option text:
and the three different help-text variants that can show, depending on which options are enabled:
- Release-to-capture disabled (Unchanged):
- Release-to-capture enabled but saving disabled or no previously saved region available:
- Release-to-capture enabled and saving enabled with a previous region displayed:
A couple of notes:
I dislike the way the help text box looks a bit off-center in variant 3) because of the longer first line.
Should I add a line-break to the keybind-section? Should it align at the bottom:
Click and drag, Enter, double-click: Take screenshot Shift: Hold to toggle magnifier
or top:
Click and drag, Enter: Take screenshot double-click Shift: Hold to toggle magnifier
Another thing I've noticed while testing this is that the arrow keys can still modify the rectangle while in the middle of drawing it,
but further movement of the mouse resets the area back to the cursor, so they're pretty useless at that point. This happens
regardless of if release-to-capture is enabled or not. Should I just disable the arrow keys completely while the left mouse button is held and
remove the option from the help text in variant 2)?
Yeah, agreed.
Should I add a line-break to the keybind-section? Should it align at the bottom:
Click and drag, Enter, double-click: Take screenshot Shift: Hold to toggle magnifier
Cool, I think this one could work.
Another thing I've noticed while testing this is that the arrow keys can still modify the rectangle while in the middle of drawing it,
but further movement of the mouse resets the area back to the cursor, so they're pretty useless at that point. This happens
regardless of if release-to-capture is enabled or not. Should I just disable the arrow keys completely while the left mouse button is held and
remove the option from the help text in variant 2)?
Yes, that makes sense!
Adjust help-text to be more contextual and improve the new settings' description
Alright, the help text for variant 3 now has a line break to make the first
line not stand out so much. The help text for variant 2 has been adjusted
to not include the arrow key bindings, which are now disabled while
click-and-dragging. Additionally the text for the shift key in
this mode has been shortened from
"Hold to toggle magnifier while dragging selection handles"
to just
"Hold to toggle magnifier",
since you are already holding the selection handles when you are in this mode.
The text for the option in the settings menu has also been adjusted.
Since I know you use a dual screen setup, for your next trick would you like to have a crack at https://bugs.kde.org/show_bug.cgi?id=385885?
Feel free to check out any of the other Spectacle bugs too if you're interested in continuing with Spectacle: https://bugs.kde.org/buglist.cgi?component=General&list_id=1594330&product=Spectacle&resolution=---
https://bugs.kde.org/show_bug.cgi?id=390856 looks like another possibility.