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. qt custom UI vertical slider?
Forum Updated to NodeBB v4.3 + New Features

qt custom UI vertical slider?

Scheduled Pinned Locked Moved Solved General and Desktop
6 Posts 2 Posters 477 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.
  • I Offline
    I Offline
    IknowQT
    wrote on 5 Jul 2021, 00:55 last edited by
    #1

    16294cf4-2cf7-4e5b-b295-beb9cf66224f-image.png

    I have a question while I'm making customization, and I'd like to drag up and down the part that I checked in red.

    How can I approach it and make a ui?
    My guess is we can make a variation of the vertical slider, but I'm wondering if there's a better way.

    1 Reply Last reply
    0
    • S Offline
      S Offline
      SGaist
      Lifetime Qt Champion
      wrote on 5 Jul 2021, 04:48 last edited by
      #2

      Hi,

      Since it's a form of slider, it's not a bad idea. You would already have the value handling available from the start.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      I 1 Reply Last reply 5 Jul 2021, 09:01
      0
      • S SGaist
        5 Jul 2021, 04:48

        Hi,

        Since it's a form of slider, it's not a bad idea. You would already have the value handling available from the start.

        I Offline
        I Offline
        IknowQT
        wrote on 5 Jul 2021, 09:01 last edited by
        #3

        @SGaist

        Is it implemented using qstyleoptionslider?
        I don't know, maybe a simple example.

        1 Reply Last reply
        0
        • S Offline
          S Offline
          SGaist
          Lifetime Qt Champion
          wrote on 5 Jul 2021, 19:05 last edited by
          #4

          No, it should be based on QAbstractSlider with custom painting.

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          I 1 Reply Last reply 6 Jul 2021, 04:40
          0
          • S SGaist
            5 Jul 2021, 19:05

            No, it should be based on QAbstractSlider with custom painting.

            I Offline
            I Offline
            IknowQT
            wrote on 6 Jul 2021, 04:40 last edited by
            #5

            @SGaist

            df481ec8-797e-48d6-9ea5-3d2b3496076f-image.png

            06144678-e13f-407f-b74c-230bca021369-image.png

            I think the way you taught me is too much for me, so I've transformed Slider into a stylesheet in the simplest way.

            I want to write text in the slider, how can I access it?

            And when the slider handle comes down to the top or bottom, the border-radius doesn't apply, so it comes out angled. What should I do?

            1 Reply Last reply
            0
            • S Offline
              S Offline
              SGaist
              Lifetime Qt Champion
              wrote on 6 Jul 2021, 20:21 last edited by
              #6

              @IknowQT said in qt custom UI vertical slider?:

              I want to write text in the slider, how can I access it?

              Subclass and do custom painting so you are back at my initial suggestion.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              1 Reply Last reply
              0

              1/6

              5 Jul 2021, 00:55

              • Login

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