Author Topic: I want to modify the source code to support custom key mapping  (Read 1353 times)

Offline lz978

  • Single posting newcomer
  • *
  • Posts: 2
I want to modify the source code to support custom key mapping
« on: January 06, 2025, 11:18:18 am »
When using the internal editor of Code::Blocks (on the Windows platform), I found that pressing Shift and Space simultaneously does not input a space, whereas on the Ubuntu platform, Code::Blocks allows it, and other editors on Windows also support this. I have successfully built Code::Blocks from source, and now I want to determine which part of the code files needs to be modified to make Shift+Space work. Could you provide any information you know about this? It can be general; it doesn't need to pinpoint the exact code location.

Offline Pecan

  • Plugin developer
  • Lives here!
  • ****
  • Posts: 2814
Re: I want to modify the source code to support custom key mapping
« Reply #1 on: January 06, 2025, 09:43:25 pm »
When using the internal editor of Code::Blocks (on the Windows platform), I found that pressing Shift and Space simultaneously does not input a space, whereas on the Ubuntu platform, Code::Blocks allows it, and other editors on Windows also support this. I have successfully built Code::Blocks from source, and now I want to determine which part of the code files needs to be modified to make Shift+Space work. Could you provide any information you know about this? It can be general; it doesn't need to pinpoint the exact code location.

The keyboard is handled via Menu/Settings/Keyboard Shortcuts.
For me, on Windows with Codeblocks Nightly version, Shift+space is unassigned, and works as you describe.
Look to see  if something else has been assigned to shift + space key combination.

Offline PB

  • Multiple posting newcomer
  • *
  • Posts: 64
Re: I want to modify the source code to support custom key mapping
« Reply #2 on: January 06, 2025, 10:30:05 pm »
I have vanilla C::B 20.03 (i.e., no extra plugins) on Windows 10 and Shift+Space inserts a plain space there, at least in .h and .cpp files.