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

Key Mapping for non-german layouts #262

Open
thilomichael opened this issue Apr 30, 2019 · 1 comment
Open

Key Mapping for non-german layouts #262

thilomichael opened this issue Apr 30, 2019 · 1 comment

Comments

@thilomichael
Copy link

First, let me thank you for the EMU webApp, you are doing amazing work!

I have (had) some problems with the keyboard shortcuts of the web app. For example, the "Shrink / Expand Selected Segment" shortcuts are not working for me. The problem is that I use the U.S. keyboard layout, so I get my plus sign ("+") by pressing Shift=. So for what the App says is "Shift + +" I had to press Shift7 which is the *-symbol on the US layout.

When looking into the config file default_emuwebappConfig.json I see that the ASCII-Codes are mapped to the different functionalities, so I changed them and now it works (I use = so ASCII 61 for expand left and +/ASCII 43 for expand right). But that change breaks the functionality for other layouts.

Would it may be possible to use the keyCodes instead of ASCII codes? That way the keys stay the same in different keyboard layouts.

@raphywink
Copy link
Contributor

Thanks 4 your kind words :-)

@Keymapping: good point! In the EMU-webApp2 we are currently using the following npm module to handle the key mapping 4 us:

https://github.com/IPS-LMU/EMU-webApp2/blob/master/src/app/main-layout/mainlayout.component.ts#L6

as far as I am aware, these work with keyCodes anyway. So that should solve the issue.

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

2 participants