Validating QML TextInput's text by using virtual keyboard on MeeGo 1.1.80.6 OS



  • Hi All,

    I am using QML TextInput control. I want to validate the entered text (only alphanumeric is allowed)
    so i wrote code like this -
    @
    if ( ( event.key >= Qt.Key_A ) && ( event.key <= Qt.Key_Z ) )
    {
    event.accepted = false;
    }
    else if ( ( event.key >= Qt.Key_0 ) && ( event.key <= Qt.Key_9 ) )
    {
    event.accepted = false;
    }
    @
    Please note my underlying OS is MeeGo 1.1.80.6 and test machine is Lenove S10-3t netbook.
    This code is working fine when i am using netbook's keyboard but when i am using virtual keyboard then this code is not working.

    Anybody have an idea?

    Regards,
    Meraj

    [edit: code highlighted / Denis Kormalev]



  • Please don't forget to use @ tags.


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.