ddebian 12 input err! lazarus / 1-Linux ---------------------------------------------------------------------- d99net · 2024-04-30 23:56 Using TMemo from Lazarus 2.2.6 under Debian 12 will display: 112233 when inputting: 123 (Due to not understanding English, the above content has been translated from Chinese to English) ---------------------------------------------------------------------- TRon · 2024-05-01 00:02 Quote from: d99net on May 01, 2024, 01:56:50 amUsing TMemo from Lazarus 2.2.6 under Debian 12 will display: 112233 when inputting: 123 That is a known issue (and afaik has been fixed). Please upgrade your Lazarus to a more recent one (preferably 3.2) ---------------------------------------------------------------------- d99net · 2024-05-01 00:08 Thank ---------------------------------------------------------------------- TRon · 2024-05-01 00:19 Quote from: d99net on May 01, 2024, 02:08:42 amThank You are welcome  Oh, and hi  (I just noticed that was your first post) ... For references see also thread and issue 26926 in the bug-tracker. ---------------------------------------------------------------------- d99net · 2024-05-01 00:53 Because I don't understand English, I can only search code ---------------------------------------------------------------------- d99net · 2024-05-01 00:56 Lazarus is very good ---------------------------------------------------------------------- TRon · 2024-05-01 01:01 Quote from: d99net on May 01, 2024, 02:53:29 amBecause I don't understand English, I can only search code I understand, that is ok. If you have any questions or otherwise require help then you could perhaps ask another forum user for help (there are other forum users who are able to communicate in Chinese). I write in the hopes that a (online) translation tool is able to help you out. ---------------------------------------------------------------------- d99net · 2024-05-01 01:24 v3.99 ---------------------------------------------------------------------- TRon · 2024-05-01 01:34 Ok, acknowledged d99net. I feel very uncomfortable advising to install ibus because of the language barrier and the fact that I know nothing about Chinese language configuration. Is there someone around that would be able to advise ? ---------------------------------------------------------------------- d99net · 2024-05-01 01:37 Debian, Ubuntu, Deepin, Lubuntu, Fedora, OpenSuse are all normal, debian12 is not normal ---------------------------------------------------------------------- d99net · 2024-05-01 01:39 Debian uses default installation ---------------------------------------------------------------------- TRon · 2024-05-01 01:49 Quote from: d99net on May 01, 2024, 03:39:41 am Debian uses default installation Yes, I understand d99net. However, I do not fully grasp what the issue is because I myself am running debian 12 (Mate, without ibus installed) and do not have the same problem so have to assume that it must be something related to a particular configuration. Is your Debian display server X-windows or Wayland ? PS: and to make sure: are you running your Debian native or do you use a virtual machine ? ---------------------------------------------------------------------- d99net · 2024-05-01 02:00 Sorry, I'm not by my computer right now and I can't view computer information ---------------------------------------------------------------------- d99net · 2024-05-01 02:15 Debian native ---------------------------------------------------------------------- TRon · 2024-05-01 02:28 Quote from: d99net on May 01, 2024, 04:00:13 amSorry, I'm not by my computer right now and I can't view computer information Ok, then let's wait for that then. Quote from: d99net on May 01, 2024, 04:15:40 am Debian native Ok, thank you for the information. ---------------------------------------------------------------------- d99net · 2024-05-01 06:36 cinnamon Linux debian 6.1.0-20-amd64 #1 SMP PREEMPT_DYNAMIC Debian 6.1.85-1 (2024-04-11) x86_64 GNU/Linux ---------------------------------------------------------------------- d99net · 2024-05-01 06:54 -------------------------- Edit1KeyDown Edit1KeyPress Edit1KeyUp -------------------------- Edit1KeyDown Edit1KeyPress Edit1KeyUp -------------------------- Edit1KeyDown Edit1KeyPress Edit1KeyUp ---------------------------------------------------------------------- d99net · 2024-05-01 12:04 procedure TForm1.Edit1KeyDown(Sender: TObject; var Key: Word; Shift: TShiftState   ); begin   writeln('--------------------------');   writeln('Edit1KeyDown'); end; procedure TForm1.Edit1KeyPress(Sender: TObject; var Key: char); begin   writeln('Edit1KeyPress');  // Key := #0; end; procedure TForm1.Edit1KeyUp(Sender: TObject; var Key: Word; Shift: TShiftState); begin    writeln('Edit1KeyUp'); end; ================================================================= gtk2callback.inc ================================================================= function GTKKeyPress(Widget: PGtkWidget; Event: pgdkeventkey;   Data: gPointer): GBoolean; cdecl; begin   debugln(['[GTKKeyPress]', 'Widget:', hexstr(Widget), ' Event:',     hexstr(Event), '|type:', Ord(Event^._type), '|time:', Event^.time,     '|keyval:', Event^.keyval, '|state:', Event^.state, ' Data:', hexstr(Data)]);   Result := HandleGtkKeyUpDown(Widget, Event, Data, True, True, 'key- press-event'); end; #######################################       debian12 ####################################### [GTKKeyPress]Widget:00000000024D4390 Event:0000000002624AD0|type:8|time:293618|keyval:49|state:16 Data:00007F8312BFF5D0 -------------------------- Edit1KeyDown Edit1KeyPress [GTKKeyPress]Widget:00000000025D9060 Event:0000000002624AD0|type:8|time:293618|keyval:49|state:16 Data:00007F8312BEB010 [GTKKeyPress]Widget:00000000024D4390 Event:0000000002624A60|type:8|time:293618|keyval:49|state:16 Data:00007F8312BFF5D0 [GTKKeyPress]Widget:00000000025D9060 Event:0000000002624A60|type:8|time:293618|keyval:49|state:16 Data:00007F8312BEB010 [GTKKeyPress]Widget:00000000024D4390 Event:0000000002635660|type:8|time:293618|keyval:49|state:16 Data:00007F8312BFF5D0 [GTKKeyPress]Widget:00000000025D9060 Event:0000000002635660|type:8|time:293618|keyval:49|state:16 Data:00007F8312BEB010 Edit1KeyUp #######################################       lubuntu ####################################### [GTKKeyPress]Widget:0000000001C133A0 Event:0000000001EAB500|type:8|time:542247|keyval:49|state:33554432 Data:00007FF0355675D0 -------------------------- Edit1KeyDown Edit1KeyPress [GTKKeyPress]Widget:0000000001DB8070 Event:0000000001EAB500|type:8|time:542247|keyval:49|state:33554432 Data:00007FF035553010 Edit1KeyUp ---------------------------------------------------------------------- d99net · 2024-05-01 12:31 The installed system Windows+Linux ---------------------------------------------------------------------- korba812 · 2024-05-01 12:53 Take a look at this, it may be helpful: https://wiki.freepascal.org/Lazarus_FAQ#Typing_in_edit_fields_generate _duplicate_letters https://forum.lazarus.freepascal.org/index.php/topic,39213.msg268286.h tml#msg268286 ---------------------------------------------------------------------- d99net · 2024-05-01 14:28 Quote from: korba812 on May 01, 2024, 02:53:37 pmTake a look at this, it may be helpful: https://wiki.freepascal.org/Lazarus_FAQ#Typing_in_edit_fields_generate _duplicate_letters https://forum.lazarus.freepascal.org/index.php/topic,39213.msg268286.h tml#msg268286 export GTK_IM_MODULE=gtk-im-context-simple export QT_IM_MODULE=simple export XMODIFIERS=@im=none It's normal, thank you ---------------------------------------------------------------------- d99net · 2024-05-01 15:48 //---------------------------------------------------------------- //   gtk2callback.inc //---------------------------------------------------------------- threadvar   g_KeyPress_count: integer;   g_KeyPress_keyval: integer; // Event^.keyval   g_KeyPress_time: guint32; // Event^.time function GTKKeyPress(Widget: PGtkWidget; Event: pgdkeventkey;   Data: gPointer): GBoolean; cdecl; begin   if (g_KeyPress_time = Event^.time) and (g_KeyPress_keyval = Event^.keyval) then   begin     Inc(g_KeyPress_count);     if g_KeyPress_count > 3 then     begin       Result := True;       exit;     end;   end   else   begin     g_KeyPress_count := 0;     g_KeyPress_keyval := Event^.keyval;     g_KeyPress_time := Event^.time;   end;   Result := HandleGtkKeyUpDown(Widget, Event, Data, True, True, 'key- press-event'); end;  ---------------------------------------------------------------------- ----------------------------------------- ubuntu,deepin,lubuntu,OpenSuse,debian12   test ok! (Only tested in English char) ---------------------------------------------------------------------- TRon · 2024-05-01 17:15 Thank you @korba812 next step in my process was asking about input method configuration  ) ---------------------------------------------------------------------- myisjwj · 2025-12-02 13:25 可能是输入法的问题。 vi /usr/lib/arm-linux-gnueabihf/gtk-2.0/2.10.0/immodules.cache 例 "/usr/lib/arm-linux-gnueabihf/gtk-2.0/2.10.0/immodules/im-fcitx.so" "fcitx" "X Input Method" "gtk20" "/usr/share/locale" "ko:ja:th:zh" 就可以了 ---------------------------------------------------------------------- PascalDragon · 2025-12-04 20:39 Quote from: myisjwj on December 02, 2025, 02:25:06 pm可能是输入法的问题。 vi /usr/lib/arm-linux-gnueabihf/gtk-2.0/2.10.0/immodules.cache 例 "/usr/lib/arm-linux-gnueabihf/gtk-2.0/2.10.0/immodules/im-fcitx.so" "fcitx" "X Input Method" "gtk20" "/usr/share/locale" "ko:ja:th:zh" 就可以了 Please use English in the international part of the forum or at least include a translation.