Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. QML Keyboard for touch screen
Forum Updated to NodeBB v4.3 + New Features

QML Keyboard for touch screen

Scheduled Pinned Locked Moved QML and Qt Quick
37 Posts 12 Posters 49.9k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • R Offline
    R Offline
    rotoZOOM
    wrote on last edited by
    #21

    No. This is just UI. It sends signal which of key is pressed.
    In case of backspace pressed it sends sigButtonPressed ('backspace').
    Your application should handle it.
    You can see it from my example.

    1 Reply Last reply
    0
    • A Offline
      A Offline
      aabc
      wrote on last edited by
      #22

      Can I use it with QML TextInput ?

      1 Reply Last reply
      0
      • R Offline
        R Offline
        rotoZOOM
        wrote on last edited by
        #23

        Yes. You can manual handle sigButtonPressed and in case of button=='backspace' remove character just before cursorPosition of the TextInput.

        1 Reply Last reply
        0
        • A Offline
          A Offline
          aabc
          wrote on last edited by
          #24

          Isnt there is something more generic that use sendEvent(QKeyEvent) that simulate the real Keyboard ?

          1 Reply Last reply
          0
          • R Offline
            R Offline
            rotoZOOM
            wrote on last edited by
            #25

            In my example I do
            QCoreApplication::postEvent(_target, key_event_press);
            QCoreApplication::postEvent(_target, key_event_release);

            that, I believe, emulate click on to the key.

            1 Reply Last reply
            0
            • A Offline
              A Offline
              aabc
              wrote on last edited by
              #26

              What is the _target ? Is it the TextInput ?

              1 Reply Last reply
              0
              • R Offline
                R Offline
                rotoZOOM
                wrote on last edited by
                #27

                It is QWidget object, that setted by client and accept QKeyEvent

                1 Reply Last reply
                0
                • A Offline
                  A Offline
                  aabc
                  wrote on last edited by
                  #28

                  Did you try it with a QML Item ?

                  1 Reply Last reply
                  0
                  • R Offline
                    R Offline
                    rotoZOOM
                    wrote on last edited by
                    #29

                    No, I didn't. What's difference between QML Item and QWidget*?
                    If you can obtain QTextInput QWidget pointer (and you can), than it'll be work.

                    1 Reply Last reply
                    0
                    • A Offline
                      A Offline
                      aabc
                      wrote on last edited by
                      #30

                      I try it and it din't work

                      1 Reply Last reply
                      0
                      • R Offline
                        R Offline
                        rotoZOOM
                        wrote on last edited by
                        #31

                        Ok, as soon as I have time I'll check it.

                        1 Reply Last reply
                        0
                        • A Offline
                          A Offline
                          aabc
                          wrote on last edited by
                          #32

                          Thanks.
                          I'll wait

                          1 Reply Last reply
                          0
                          • P Offline
                            P Offline
                            pritamghanghas
                            wrote on last edited by
                            #33

                            you can also try maliit. Its a full framework for input methods. Has virtual keyboards also. I think they have QML keyboards as well now.

                            1 Reply Last reply
                            0
                            • A Offline
                              A Offline
                              aabc
                              wrote on last edited by
                              #34

                              What is maliit ?

                              1 Reply Last reply
                              0
                              • P Offline
                                P Offline
                                pritamghanghas
                                wrote on last edited by
                                #35

                                see here https://wiki.maliit.org/Main_Page

                                1 Reply Last reply
                                0
                                • M Offline
                                  M Offline
                                  mlvljr
                                  wrote on last edited by
                                  #36

                                  For sending emulated events to QML items, see http://qt-project.org/forums/viewthread/17360/

                                  1 Reply Last reply
                                  0
                                  • D Offline
                                    D Offline
                                    donPhilipp
                                    wrote on last edited by
                                    #37

                                    i know its pretty late,
                                    but i just stumbled upon colibri and i had (as rodrigob) quite a hard time to figure how to use clkeyboard together with a lineedit. But it is possible by
                                    letting the lineedit read the keyboard internal text.
                                    So basically the lineedit is just used to show a text which belongs to the keyboard itself!

                                    @CLLineEdit{
                                    id: textInput
                                    text: keyboard.text
                                    }
                                    Rectangle{
                                    height: 100
                                    width: 200
                                    color: "black"
                                    CLKeyboard{
                                    id: keyboard
                                    anchors.fill: parent
                                    }
                                    }
                                    @

                                    1 Reply Last reply
                                    0

                                    • Login

                                    • Login or register to search.
                                    • First post
                                      Last post
                                    0
                                    • Categories
                                    • Recent
                                    • Tags
                                    • Popular
                                    • Users
                                    • Groups
                                    • Search
                                    • Get Qt Extensions
                                    • Unsolved