Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. How automation on qt?

How automation on qt?

Scheduled Pinned Locked Moved Unsolved General and Desktop
mouseautomationscreenshot
3 Posts 3 Posters 359 Views
  • 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.
  • T Offline
    T Offline
    timob256
    wrote on 3 Aug 2023, 22:33 last edited by timob256 8 Mar 2023, 22:34
    #1

    I want to write a program (small) that will:

    1. move the mouse pixel by pixel without human intervention.

    2. take a screenshot (print screen) the center of the screenshot at the location of the mouse and it is also desirable to set the size in pixels of the snapshot (not the entire monitor)

    But I can't find libraries, preferably some kind of unified library for automation (and move the mouse and type the keyboard and monitor the screen) that can be connected to qt.

    J 1 Reply Last reply 4 Aug 2023, 05:12
    0
    • P Offline
      P Offline
      Pl45m4
      wrote on 4 Aug 2023, 05:07 last edited by
      #2

      @timob256 said in How automation on qt?:

      move the mouse pixel by pixel without human intervention.

      Try this function:

      • https://doc.qt.io/qt-6/qcursor.html#setPos

      and how to make a screenshot is described here in this example:

      • https://doc.qt.io/qt-6/qtwidgets-desktop-screenshot-example.html

      If debugging is the process of removing software bugs, then programming must be the process of putting them in.

      ~E. W. Dijkstra

      1 Reply Last reply
      1
      • T timob256
        3 Aug 2023, 22:33

        I want to write a program (small) that will:

        1. move the mouse pixel by pixel without human intervention.

        2. take a screenshot (print screen) the center of the screenshot at the location of the mouse and it is also desirable to set the size in pixels of the snapshot (not the entire monitor)

        But I can't find libraries, preferably some kind of unified library for automation (and move the mouse and type the keyboard and monitor the screen) that can be connected to qt.

        J Online
        J Online
        jsulm
        Lifetime Qt Champion
        wrote on 4 Aug 2023, 05:12 last edited by
        #3

        @timob256 I'm not sure whether you want to animate the mouse cursor movement, if that is what you want then take a look at https://doc.qt.io/qt-5/animation-overview.html

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

        1 Reply Last reply
        1

        3/3

        4 Aug 2023, 05:12

        • Login

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