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

Qt.ImhDigitsOnly is not handled correctly #31

Open
mikix opened this issue Jun 3, 2016 · 3 comments
Open

Qt.ImhDigitsOnly is not handled correctly #31

mikix opened this issue Jun 3, 2016 · 3 comments

Comments

@mikix
Copy link

mikix commented Jun 3, 2016

In MInputContext::contentType(), the following lines of code treat Qt.ImhDigitsOnly and Qt::ImhFormattedNumbersOnly the same:

    if (hints == Qt::ImhFormattedNumbersOnly || hints == Qt::ImhDigitsOnly) {
        type = Maliit::NumberContentType;
    } else ...

This can't be correct.

The docs have the following:

ImhDigitsOnly: Only digits are allowed.
ImhFormattedNumbersOnly: Only number input is allowed. This includes decimal point and minus sign.

To correctly handle both flags, maliit needs a new contentType. Something like Maliit::DigitContentType maybe.

@dobey
Copy link
Contributor

dobey commented Sep 10, 2021

Found this as I was looking into why DigitsOnly doesn't work at all using Wayland input method protocol. It seems like fixing this the right way, probably also requires breaking ABI/API. There are also other input method hints not being handled at all by Maliit currently, which would be nice to fix.

@aleixpol
Copy link
Contributor

#66 fixes this as long as you were finding the problem when using the input_method_v1 source, @mikix can you confirm?

@dobey
Copy link
Contributor

dobey commented Sep 16, 2021

#66 fixes this as long as you were finding the problem when using the input_method_v1 source, @mikix can you confirm?

No, the issue reported here is that DigitsOnly and FormatedNumberesOnly are being treated equally, while they should be different (DigitsOnly shouldn't have -, #, etc… symbols). #66 only fixes that DigitsOnly wasn't working at all with the wayland protocol. :)

dobey added a commit to dobey/maliit-framework that referenced this issue Jun 16, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
dobey added a commit to dobey/maliit-framework that referenced this issue Jun 16, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
dobey added a commit to dobey/maliit-framework that referenced this issue Jul 6, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
dobey added a commit to dobey/maliit-framework that referenced this issue Aug 10, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
dobey added a commit to dobey/maliit-framework that referenced this issue Sep 23, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
dobey added a commit to dobey/maliit-framework that referenced this issue Oct 13, 2022
As formatted numbers and pure digits are separate content requirements
and should have separate keyboard panels, provide the API to treat them
separately, as they are treated in toolkits and wayland protocols.

Fixes maliit#31
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

3 participants