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 to add slider in QGridLayout?

How to add slider in QGridLayout?

Scheduled Pinned Locked Moved Solved General and Desktop
4 Posts 3 Posters 1.1k 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.
  • S Offline
    S Offline
    ShinSat
    wrote on last edited by
    #1

    Hi All,

    A quick question.
    How can I add vertical/horizontal slider in QGridLayout?

    Many thanks in advance for your help.
    Regards,
    Sat

    1 Reply Last reply
    0
    • VRoninV Offline
      VRoninV Offline
      VRonin
      wrote on last edited by VRonin
      #2

      As any other widget: http://doc.qt.io/qt-5/qgridlayout.html#addWidget
      layout->addWidget(slider,row,column);

      "La mort n'est rien, mais vivre vaincu et sans gloire, c'est mourir tous les jours"
      ~Napoleon Bonaparte

      On a crusade to banish setIndexWidget() from the holy land of Qt

      1 Reply Last reply
      4
      • Pradeep KumarP Offline
        Pradeep KumarP Offline
        Pradeep Kumar
        wrote on last edited by
        #3

        Hi,

        As Slider is a widget u can use addWidget() method to add it for QGridLayout,

        Thanks,

        Pradeep Kumar
        Qt,QML Developer

        1 Reply Last reply
        6
        • S Offline
          S Offline
          ShinSat
          wrote on last edited by
          #4

          Perfect!
          Thank you very much for your help, all!! :)

          Sat

          1 Reply Last reply
          1

          • Login

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