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. How I can to paste text at cursor position of focused input element?
Forum Updated to NodeBB v4.3 + New Features

How I can to paste text at cursor position of focused input element?

Scheduled Pinned Locked Moved Solved QML and Qt Quick
3 Posts 2 Posters 472 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.
  • maratoriyM Offline
    maratoriyM Offline
    maratoriy
    wrote on last edited by
    #1

    I have a GridView with ToolButtons (kind of keyboard). I want a click on a symbol to copy it to the cursor position regardless of which input element it is in (based on focus)
    Thank you in advance!

    7ad6b1f2-8fdd-4646-89b4-87ffbc145590-image.png

    jsulmJ 1 Reply Last reply
    0
    • maratoriyM maratoriy

      I have a GridView with ToolButtons (kind of keyboard). I want a click on a symbol to copy it to the cursor position regardless of which input element it is in (based on focus)
      Thank you in advance!

      7ad6b1f2-8fdd-4646-89b4-87ffbc145590-image.png

      jsulmJ Offline
      jsulmJ Offline
      jsulm
      Lifetime Qt Champion
      wrote on last edited by
      #2

      @maratoriy You can iterate over https://doc.qt.io/qt-5/qobject.html#children and check which child has focus using https://doc.qt.io/qt-5/qwidget.html#focus-prop

      https://forum.qt.io/topic/113070/qt-code-of-conduct

      maratoriyM 1 Reply Last reply
      3
      • jsulmJ jsulm

        @maratoriy You can iterate over https://doc.qt.io/qt-5/qobject.html#children and check which child has focus using https://doc.qt.io/qt-5/qwidget.html#focus-prop

        maratoriyM Offline
        maratoriyM Offline
        maratoriy
        wrote on last edited by
        #3

        @jsulm A lot of thanks!

        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