View Issue Details

IDProjectCategoryView StatusLast Update
0038093LazarusLCLpublic2020-11-18 12:52
ReporterReiner Sombrowsky Assigned ToBart Broersma  
PrioritynormalSeverityminorReproducibilityalways
Status assignedResolutionopen 
PlatformPcOSWindows10 
Product Version2.1 (SVN) 
Summary0038093: Keys and Shortcuts in lclproc.pas
DescriptionI use Lazarus Version 2.1.0 Trunc Rev.: 64145.
If I use the ShortCut function to catch a key and
I press the "+"-key it shows a "=".
A "+" is not supported.
I use a german keyboard layout.
I found in lclproc.pas the line:
    '=', // 0xbb - VK_OEM_PLUS - For any country/region, the '+/=' key Delphi returns '=' Issue 0036489
and in the offical version of Lazarus version 2.0.10 the line
    '+', // 0xbb - VK_OEM_PLUS - For any country/region, the '+' key
I don't understand this change to isue 0036489 because if I use a hint in
a Action of an ActionList it will also shown the false ShortCut.
In the offical version of Lazarus 2.0.10 it is shown correctly.
To check this I give a litte Application without exe to check it
TagsNo tags attached.
Fixed in Revision
LazTarget-
WidgetsetWin32/Win64
Attached Files

Relationships

related to 0036489 resolvedJuha Manninen Delphi incompatible result of ShortcutToText of "=" 

Activities

Reiner Sombrowsky

2020-11-17 13:18

reporter  

shortcut_test.zip (129,252 bytes)

Juha Manninen

2020-11-17 14:56

developer   ~0127001

Last edited: 2020-11-17 14:58

View 2 revisions

Yes I can see the problem in your test application. If I try to enter '+' as a shortcut for the Action, it gives and error :
 "Invalid property value with value "+"
Apparently you saw a slightly different behavior.

Bart, can you please look at it. Your patch was used in issue 0036489.

Bart Broersma

2020-11-17 15:42

developer   ~0127005

Last edited: 2020-11-17 16:12

View 3 revisions

AFAIK the current (new) behaviour is Delphi compatible?
If I revert that, we'll be Delphi incompatible again.

In Lazarus 2.0.10 can you enter '=' as a shortcut for the Action?

Reiner Sombrowsky

2020-11-17 16:22

reporter   ~0127008

I think it should not accepted the Delphi compatibility.
I see the "=" also in the hint of an connected control to the action.
This is not the hint for the used key. Perhaps it should be consider
the current keyboard layout (the keyboard layout of United States
have the keys "=" and "+" on the same button different the shift state,
but the German keyboard layout it is different).

Bart Broersma

2020-11-17 18:06

developer   ~0127009

> I think it should not accepted the Delphi compatibility.
That makes no sense to me whatsoever.

And you did not answer my question: In Lazarus 2.0.10 can you enter '=' as a shortcut for the Action?

Bart Broersma

2020-11-17 18:11

developer   ~0127010

Last edited: 2020-11-17 18:19

View 2 revisions

In Delphi (7.0) you cannot assign "+" as a shortcut for a TAction, so current behaviour is Delphi compatible.
TextToShortcut('+') gives 0 in both Lazarus trunk and Delphi.

Bart Broersma

2020-11-17 18:32

developer   ~0127011

I documented the changes here: https://wiki.lazarus.freepascal.org/Lazarus_2.2.0_release_notes#ShortcutToText_.2F_TextToShortcut

Reiner Sombrowsky

2020-11-18 04:25

reporter   ~0127023

Ok, beacause there is the same result for Strg+"+" and Umsch+"+" I make
me own changinging beacause I don't need the
Delphi compatibility.
I think you have made a much better Lazarus as the Delphi 7 ever was.

Bart Broersma

2020-11-18 12:52

developer   ~0127027

I asked on the lazarus devel ML if it is possible to implement some mechanisme to preserve/alter the way ShortCutToText and TextToShortCut work.
Maybe some callback mechanisme for the user.

Issue History

Date Modified Username Field Change
2020-11-17 13:18 Reiner Sombrowsky New Issue
2020-11-17 13:18 Reiner Sombrowsky File Added: shortcut_test.zip
2020-11-17 14:35 Juha Manninen Relationship added related to 0036489
2020-11-17 14:50 Juha Manninen Assigned To => Juha Manninen
2020-11-17 14:50 Juha Manninen Status new => assigned
2020-11-17 14:53 Juha Manninen Assigned To Juha Manninen => Bart Broersma
2020-11-17 14:56 Juha Manninen Note Added: 0127001
2020-11-17 14:58 Juha Manninen Note Edited: 0127001 View Revisions
2020-11-17 15:42 Bart Broersma Note Added: 0127005
2020-11-17 16:06 Bart Broersma Note Edited: 0127005 View Revisions
2020-11-17 16:12 Bart Broersma Note Edited: 0127005 View Revisions
2020-11-17 16:12 Bart Broersma Status assigned => feedback
2020-11-17 16:12 Bart Broersma LazTarget => -
2020-11-17 16:22 Reiner Sombrowsky Note Added: 0127008
2020-11-17 16:22 Reiner Sombrowsky Status feedback => assigned
2020-11-17 18:06 Bart Broersma Status assigned => feedback
2020-11-17 18:06 Bart Broersma Note Added: 0127009
2020-11-17 18:11 Bart Broersma Note Added: 0127010
2020-11-17 18:19 Bart Broersma Note Edited: 0127010 View Revisions
2020-11-17 18:32 Bart Broersma Note Added: 0127011
2020-11-18 04:25 Reiner Sombrowsky Note Added: 0127023
2020-11-18 04:25 Reiner Sombrowsky Status feedback => assigned
2020-11-18 12:52 Bart Broersma Note Added: 0127027