View Issue Details

IDProjectCategoryView StatusLast Update
0036489LazarusLCLpublic2020-11-17 14:35
ReporterCudaText man Assigned ToJuha Manninen  
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
PlatformWin 10 
Product Version2.1 (SVN) 
Summary0036489: Delphi incompatible result of ShortcutToText of "="
DescriptionThis program can be run on Delphi 10.3 and on Lazarus.
uses LCLProc, LCLType, Menus; //adjust in Delphi
...
procedure TForm1.FormKeyDown(Sender: TObject; var Key: Word; Shift: TShiftState);
begin
  caption:= ShortCutToText(ShortCut(Key, Shift));
end;


on pressing a key, form shows hotkey in form title. Try it with Alt+= / Ctrl+= hotkeys.
Delphi: you see "Alt+="
Lazarus: you see "Alt++"

Users of CudaText are confused, because now they see different text of hotkey for Alt+=, not like in Delphi editor SynWrite.
TagsNo tags attached.
Fixed in Revisionr62468
LazTarget-
WidgetsetWin32/Win64
Attached Files

Relationships

related to 0030992 resolvedMichl Patches ShortcutToText faster, with array 
related to 0038093 assignedBart Broersma Lazarus Keys and Shortcuts in lclproc.pas 

Activities

Juha Manninen

2019-12-28 17:16

developer   ~0120110

Did it happen also before r57373. See the related issue.

Bart Broersma

2019-12-28 18:08

developer   ~0120111

As far as Goofle can tell, me VK_OEM_PLUS always has both '+' and '='.
Patch attached.
KeyCodeToKeyString.diff (691 bytes)   
Index: lcl/lclproc.pas
===================================================================
--- lcl/lclproc.pas	(revision 62422)
+++ lcl/lclproc.pas	(working copy)
@@ -569,7 +569,7 @@
     '', // 0xb8
     '', // 0xb9
     ';', // 0xba - VK_OEM_1 - Can vary by keyboard, US keyboard, the ';:' key
-    '+', // 0xbb - VK_OEM_PLUS - For any country/region, the '+' key
+    '=', // 0xbb - VK_OEM_PLUS - For any country/region, the '+/=' key Delphi returns '=' Issue #0036489
     ',', // 0xbc - VK_OEM_COMMA - For any country/region, the ',' key
     '-', // 0xbd - VK_OEM_MINUS - For any country/region, the '-' key
     '.', // 0xbe - VK_OEM_PERIOD - For any country/region, the '.' key
KeyCodeToKeyString.diff (691 bytes)   

Bart Broersma

2019-12-28 18:11

developer   ~0120112

> Did it happen also before r57373
Yes, it also returned Alt+'+' (according to the patchfile attached to the related issue).

CudaText man

2019-12-29 13:09

reporter   ~0120129

Pls apply this fix.

Juha Manninen

2019-12-30 00:19

developer   ~0120140

Applied, thanks.

Issue History

Date Modified Username Field Change
2019-12-28 13:56 CudaText man New Issue
2019-12-28 16:55 Juha Manninen Relationship added related to 0030992
2019-12-28 17:16 Juha Manninen Note Added: 0120110
2019-12-28 18:08 Bart Broersma File Added: KeyCodeToKeyString.diff
2019-12-28 18:08 Bart Broersma Note Added: 0120111
2019-12-28 18:11 Bart Broersma Note Added: 0120112
2019-12-29 13:09 CudaText man Note Added: 0120129
2019-12-30 00:07 Juha Manninen Assigned To => Juha Manninen
2019-12-30 00:07 Juha Manninen Status new => assigned
2019-12-30 00:19 Juha Manninen Status assigned => resolved
2019-12-30 00:19 Juha Manninen Resolution open => fixed
2019-12-30 00:19 Juha Manninen Fixed in Revision => r62468
2019-12-30 00:19 Juha Manninen LazTarget => -
2019-12-30 00:19 Juha Manninen Widgetset Win32/Win64 => Win32/Win64
2019-12-30 00:19 Juha Manninen Note Added: 0120140
2020-11-17 14:35 Juha Manninen Relationship added related to 0038093