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. Use some timer in sender - QTimer
Forum Update on Monday, May 27th 2025

Use some timer in sender - QTimer

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 475 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.
  • J Offline
    J Offline
    Jeronimo
    wrote on last edited by
    #1

    Hi it's possible to include in my signal/slot in sender some timer to repeat each 1 second or 5 second and start this timer.
    The signal slot mine is this:
    connect (ui->botonpaint,SIGNAL(clicked()),this,SLOT(paint()));

    1 Reply Last reply
    0
    • mrjjM Offline
      mrjjM Offline
      mrjj
      Lifetime Qt Champion
      wrote on last edited by mrjj
      #2

      Hi a timer can signal timeout() with no parameters so it call any other slot that has
      a matching signature.

      So a timer can call update() to make something redraw and stuff like that.

      Im not sure what you are asking with "include in my signal/slot in sender some timer to repeat each 1 second or 5 second "

      When you start the timer you give it its speed.

      timer->start(5000); // 5 secs

      1 Reply Last reply
      2

      • Login

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