Modify

#22065 closed enhancement (fixed)

[RFC PATCH] add a possibility to add and remove from selection in lasso and rect mode

Reported by: dieterdreist Owned by: team
Priority: normal Milestone: 22.05
Component: Core Version:
Keywords: selection macosx Cc:

Description (last modified by dieterdreist)

Currently I can add objects from a selection in rectangle and lasso mode by holding shift, or when holding alt JOSM will select also ways that are partially in the selection area. But I cannot get it to deselect.
Strange enough, "ctrl" makes the screen pan on mouse drag (in FreeBSD and Linux this is typically done with "alt" for windows on the OS level, while many applications use "space"+drag to pan the working area), ctrl seems a bit strange for this.
Maybe it has to do with the broken modifier keys in MacOS (partially system conform, partially Java conform), I tried every key combination that came to mind but could not make it deselect.
What about adding a dedicated UI, something similar to how graphic programs work: you select the current selection mode with radio buttons between: replace, add, remove, (maybe toggle) and maybe also object type checkboxes (not radio buttons) for node, way, relation, and this would be the current selection mode if you do not hold any modifier keys (until you change the selection mode). Default is "replace" as it is now.

Attachments (4)

22065.patch (4.1 KB ) - added by taylor.smock 22 months ago.
22065.2.patch (10.9 KB ) - added by taylor.smock 22 months ago.
Replace ctrl with platform specific equivalent in most places for SelectAction
22065.3.patch (14.5 KB ) - added by taylor.smock 22 months ago.
Fix no-help lasso
josm-custom.jar (16.1 MB ) - added by taylor.smock 22 months ago.

Change History (20)

comment:1 by dieterdreist, 23 months ago

Description: modified (diff)

comment:2 by dieterdreist, 23 months ago

Version: latest

comment:3 by dieterdreist, 23 months ago

Description: modified (diff)

comment:4 by skyper, 23 months ago

Version: latest

According to Help/Action/Select Ctrl should be the modifier for removing, at least in rectangle mode.

in reply to:  4 comment:5 by taylor.smock, 23 months ago

Replying to skyper:

According to Help/Action/Select Ctrl should be the modifier for removing, at least in rectangle mode.

This is disabled on Mac. See source:trunk/src/org/openstreetmap/josm/actions/mapmode/SelectAction.java@HEAD:71,349#L349.

EDIT: This appears to still be the case, see https://support.apple.com/guide/mac-help/right-click-mh35853/mac

Last edited 23 months ago by taylor.smock (previous) (diff)

comment:6 by anonymous, 23 months ago

yes, what are ctrl actions on linux and windows, in MacGUI apps they consistently use the command-key instead of the ctrl key (e.g. copy and paste, cmd+o for opening etc.)
if it were possible rather then disable the rm action activate it with cmd on macs, that would be great (also from a general user experience point of view).

in reply to:  6 comment:7 by taylor.smock, 23 months ago

Replying to anonymous:

yes, what are ctrl actions on linux and windows, in MacGUI apps they consistently use the command-key instead of the ctrl key (e.g. copy and paste, cmd+o for opening etc.)
if it were possible rather then disable the rm action activate it with cmd on macs, that would be great (also from a general user experience point of view).

Sorry, I should have been clearer, the command + left-click is still used to simulate right-click. Not ctrl + left-click.

comment:8 by anonymous, 23 months ago

I just tried it, the command key is doing nothing in Josm select mode. In Firefox command has no effect on click (ctrl + click is like a right click in FF)

in reply to:  8 comment:9 by taylor.smock, 23 months ago

Replying to anonymous:

I just tried it, the command key is doing nothing in Josm select mode. In Firefox command has no effect on click (ctrl + click is like a right click in FF)

My bad. I'm used to converting ctrl -> cmd for mac. It is ctrl + left-click that is the problem. I'll have to look and see if we are already converting ctrl to cmd for mac (most shortcuts already do this, I just don't know if we are doing it for mapmodes).

by taylor.smock, 22 months ago

Attachment: 22065.patch added

comment:10 by taylor.smock, 22 months ago

Keywords: macosx added
Milestone: 22.05
Summary: add a possibility to add and remove from selection in lasso and rect mode[PATCH] add a possibility to add and remove from selection in lasso and rect mode

I'm going to play around with the patch for a bit and give other OSX users a chance to tell us that cmd+click is used for some built-in Mac functionality that I don't know about.

comment:11 by taylor.smock, 22 months ago

Summary: [PATCH] add a possibility to add and remove from selection in lasso and rect mode[WIP PATCH] add a possibility to add and remove from selection in lasso and rect mode

Looks like single item deselect was broken.

by taylor.smock, 22 months ago

Attachment: 22065.2.patch added

Replace ctrl with platform specific equivalent in most places for SelectAction

comment:12 by taylor.smock, 22 months ago

Summary: [WIP PATCH] add a possibility to add and remove from selection in lasso and rect mode[RFC PATCH] add a possibility to add and remove from selection in lasso and rect mode

attachment:josm-custom.jar contains attachment:22065.2.patch, along with some other modifications I've been playing with. Feel free (or not) to tell me whether or not a keyboard shortcut is broken in Mac OS X or any other platform.

in reply to:  12 ; comment:13 by skyper, 22 months ago

Replying to taylor.smock:

attachment:josm-custom.jar contains attachment:22065.2.patch, along with some other modifications I've been playing with. Feel free (or not) to tell me whether or not a keyboard shortcut is broken in Mac OS X or any other platform.

With a quick test on Linux, I miss the modifier keys listed in the most right field of the StatusBar when activating Lasso Mode thought this is probably nothing new but would be nice to have.

in reply to:  13 comment:14 by taylor.smock, 22 months ago

Replying to skyper:

With a quick test on Linux, I miss the modifier keys listed in the most right field of the StatusBar when activating Lasso Mode thought this is probably nothing new but would be nice to have.

Yep. Nothing new. This behavior existed in r17345, and probably earlier.

by taylor.smock, 22 months ago

Attachment: 22065.3.patch added

Fix no-help lasso

by taylor.smock, 22 months ago

Attachment: josm-custom.jar added

in reply to:  13 comment:15 by taylor.smock, 22 months ago

Replying to skyper:

With a quick test on Linux, I miss the modifier keys listed in the most right field of the StatusBar when activating Lasso Mode thought this is probably nothing new but would be nice to have.

This is fixed in attachment:22065.3.patch, but I think we do want to have some translators give feedback on it -- I'm trying to reuse strings, but I don't know if it breaks translation horribly.

comment:16 by taylor.smock, 22 months ago

Resolution: fixed
Status: newclosed

In 18456/josm:

Fix #22065: Mac users cannot deselect with ctrl

From the Mac OS HIG guidelines, "[as] much as possible,
avoid using the Control key as a modifier."

In this case, we were using ctrl to deselect elements (and
we disabled this on Mac), merge nodes, scale, and rotate.

All of those now use (meta) instead of ctrl on Mac.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain team.
as The resolution will be set.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.