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. Is there any way to set the orientation of the QSPinBox Vertical??

Is there any way to set the orientation of the QSPinBox Vertical??

Scheduled Pinned Locked Moved Unsolved General and Desktop
7 Posts 3 Posters 590 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.
  • M Offline
    M Offline
    Meera Hadid
    wrote on last edited by
    #1

    Re: How to create a vertical spinbox (arrows on top and bottom)

    jsulmJ JonBJ 2 Replies Last reply
    0
    • M Meera Hadid

      Re: How to create a vertical spinbox (arrows on top and bottom)

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

      @Meera-Hadid The last post in the thread you linked provided a solution. Did you try it?

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

      1 Reply Last reply
      0
      • M Meera Hadid

        Re: How to create a vertical spinbox (arrows on top and bottom)

        JonBJ Offline
        JonBJ Offline
        JonB
        wrote on last edited by
        #3

        @Meera-Hadid
        Hi and welcome,

        What is your question? If it's exactly the same as the link you reference, then the last post there claims to give a working solution. If your question is different then what is it?

        1 Reply Last reply
        0
        • M Offline
          M Offline
          Meera Hadid
          wrote on last edited by
          #4

          I just want the spinBox to be vertical, with out changing ant arrow Position.
          like in slider there is a method to chage orientation which is setOrientation(Qt::Vertical), in the same way does QSpinBox have any??

          JonBJ 1 Reply Last reply
          0
          • M Meera Hadid

            I just want the spinBox to be vertical, with out changing ant arrow Position.
            like in slider there is a method to chage orientation which is setOrientation(Qt::Vertical), in the same way does QSpinBox have any??

            JonBJ Offline
            JonBJ Offline
            JonB
            wrote on last edited by JonB
            #5

            @Meera-Hadid said in Is there any way to set the orientation of the QSPinBox Vertical??:

            I just want the spinBox to be vertical, with out changing ant arrow Position.

            But it already is vertical! Do you by any chance mean you want it horizontal instead??

            Hang on: you want the box where you type in (the QLineEdit), forget about the arrows, to be vertical?? That makes sense for a QSlider, but how does it make sense for a QSpinBox which contains characters? So it won't have an "orientation", you would have to do your own painting.

            1 Reply Last reply
            0
            • M Offline
              M Offline
              Meera Hadid
              wrote on last edited by
              #6

              yes!
              Screenshot (279).png

              I am actually new to Qt, can you give me any reference how to do that.

              JonBJ 1 Reply Last reply
              0
              • M Meera Hadid

                yes!
                Screenshot (279).png

                I am actually new to Qt, can you give me any reference how to do that.

                JonBJ Offline
                JonBJ Offline
                JonB
                wrote on last edited by
                #7

                @Meera-Hadid
                I can only imagine you would need to draw all of this yourself. And then I have no idea how you could make the QLineEdit it uses be vertical and still work, as I just don't think there is any support for this. Unless someone knows better, like how to rotate if that is really possible....

                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