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

OpenBangla Keyboard should respect primary OS keyboard #39

Merged
merged 11 commits into from
Jun 19, 2018
Merged

Conversation

mominul
Copy link
Member

@mominul mominul commented May 30, 2018

OpenBangla Keyboard has always used US keyboard layout internally. But issue #36 pointed out that this causes issues when typing some characters using other keyboard layouts such as DE, Fr etc.

We now respect the primary OS keyboard layout. So OBK is now keyboard layout independent! 🎉

Closes #36

@@ -24,51 +24,10 @@ void FixedLayoutParser::setLayout(QJsonObject l) {
layout = l;
}

QString FixedLayoutParser::getCharForKey(int keyNum, bool shift, bool altgr, bool shiftaltgr) {
QString FixedLayoutParser::processAlphabetKey(int keyNum, bool shift, bool altgr, bool shiftaltgr) {

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why not just rename this to getCharForKey and be with it? 🤔

Copy link
Member Author

@mominul mominul Jun 8, 2018

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I am also not very satisfied with this implementation. I had to do this because we now only check shift or other modifiers when the key is an alphabet key. But when the key is a metacharacter or numeric we need to handle them differently, if you look them closely.

Thanks!

@mominul mominul merged commit 6171736 into master Jun 19, 2018
@mominul mominul deleted the keyboard branch June 19, 2018 08:49
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

Successfully merging this pull request may close these issues.

2 participants