Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not possible to enter { }and [] in normal nodes #2423

Closed
Hoffenbar opened this issue Jan 6, 2024 · 9 comments
Closed

Not possible to enter { }and [] in normal nodes #2423

Hoffenbar opened this issue Jan 6, 2024 · 9 comments

Comments

@Hoffenbar
Copy link

Hoffenbar commented Jan 6, 2024

Version, Operative system
1.0.4 on Windows10

Describe the bug
It is not possible, in rtf-nodes and text-nodes and code-boxes (possibly everywhere outside tables?) to enter the characters "[]{}" via keyboard:

Screenshots

image

@Hoffenbar Hoffenbar changed the title Not possible to enter { and [ Not possible to enter { }and [] in normal nodes Jan 6, 2024
@giuspen
Copy link
Owner

giuspen commented Jan 12, 2024

What key combination do you need to press on your keyboard to get "[]{}"?
Have you tried to reset all the keyboard shortcuts to the default in the preferences dialog?
I'm surprised because the issues were coming from the default shortcuts Ctrl+Alt (triggered by AltGr on windows) but now they are all gone in 1.0.4

@Groberen
Copy link

I have same problem (probably) and same OS and CT version. Norwegian keyboard layout.

Assume original keymap without any custom changes in CT settings:
Pressing AltGr+8 (to produce left square bracket) or AltGr+9 gives an error message about a table (didn't wrote down the exact error message, but it obvious expect the cursor to be located in a table).

Solution is to disable the shortcuts for "increase/decrease height of codebox". However, looking at this keyboard shortcut doesn't suggest this conflict should be able to exist.

That is - there shouldn't be a conflict/confusion between program shortcut Alt+] and actual user input AltGr+9. The shortcut Alt+] is not possible to press using a Scandinavian keyboard layout (possible true for other European languages like German as well) because the character ] can only be inserted by pressing AltGr+9.

@giuspen
Copy link
Owner

giuspen commented Jan 25, 2024

Thanks @Groberen I will investigate. Would be useful if you can confirm the exact warning messages that you get, it's surprising that are related to the table but it's disabling the codebox shortcut that fixes it

@Groberen
Copy link

Ok I've tested. First I renamed the config.cfg so to reset all settings.
Then created a new instance (not save) and a new node. Then placed the cursor within the terminal/text.

AltGr+8 (is expected to insert «[» character)

But it gives this error message:
_

Error
No Table is Selected
[OK]

_

Likewise AltGr+9 (is expected to insert «]» character), but also gives the excact same error message.

Also, the following key combinations give the same error message
AltGr+0 (is expected to insert «}» character)
AltGr+7 (is expected to insert «{» character)

Hope this helps

@giuspen
Copy link
Owner

giuspen commented Jan 26, 2024

@Groberen your test is very useful and would be very useful if you will accept to give a try to a development build I will prepare after a proposal fix.

@Groberen
Copy link

Yes - but I'll be pretty busy the next days, but after that (i.e. late in next week) I may be able to find time to test the Windows.

@giuspen
Copy link
Owner

giuspen commented Jan 26, 2024

Apparently the offending keyboard shortcuts are Ctrl+[, Ctrl+], Ctrl+{, Ctrl+}
Theoretically AltGr should be detected as Ctrl+Alt on windows but for some reason it is still triggering those.
I will see if I can reproduce myself adding the Norwegian and German keyboards.

giuspen added a commit that referenced this issue Jan 26, 2024
@giuspen
Copy link
Owner

giuspen commented Jan 26, 2024

I managed to add keyboard layouts to my Win11 and reproduce the issue. I'm confident with the fix (6 default keyboard shortcuts changed) but if anybody is interested in having a pre release build just write here and I'll build it

@giuspen giuspen closed this as completed Jan 26, 2024
@vitusb
Copy link

vitusb commented Apr 14, 2024

Hello ...

The ALT-GR+"backslash" issue on a german keyboard is still not "masked to another mapping", so ALT-GR+"\" is not usable in order to enter a "\" on german keyboards.

For Details, see: bdd8737#commitcomment-140949469

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants