Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. QML and Qt Quick
  4. Scaling
Forum Updated to NodeBB v4.3 + New Features

Scaling

Scheduled Pinned Locked Moved QML and Qt Quick
8 Posts 3 Posters 2.3k 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.
  • E Offline
    E Offline
    Eraserhead
    wrote on last edited by
    #1

    hi everybody!

    How can i achieve qml objects to scale together with main window. Like example calculator in Qt. I looked at the code but is there any simpler solution?

    1 Reply Last reply
    0
    • R Offline
      R Offline
      rcari
      wrote on last edited by
      #2

      I think you'll have to use "anchors":http://doc.qt.digia.com/qt/qml-anchor-layout.html.

      1 Reply Last reply
      0
      • E Offline
        E Offline
        Eraserhead
        wrote on last edited by
        #3

        oh my. I am noob :D i forgot about anchors. Yea that might work :D.

        1 Reply Last reply
        0
        • E Offline
          E Offline
          Eraserhead
          wrote on last edited by
          #4

          Well i dont think this is gonna work :(.

          1 Reply Last reply
          0
          • A Offline
            A Offline
            andre
            wrote on last edited by
            #5

            That doesn't sound too hopeful. Care to explain why you think that?

            1 Reply Last reply
            0
            • E Offline
              E Offline
              Eraserhead
              wrote on last edited by
              #6

              First sorry for my english i will try to explain. Imagine this. I have a plan of a room. In this room i have to insert different icons which are interactive. I did that thats not a problem. For every icon i did an object and insert as a child in the room. But now i want that when i scale window, room and icons scale too. For room it was easy i just assign window height and width to room object. But icons height and width stay the same.

              1 Reply Last reply
              0
              • E Offline
                E Offline
                Eraserhead
                wrote on last edited by
                #7

                Problem is that i have images. With rectangles anchors works perfectly. With images not.

                1 Reply Last reply
                0
                • E Offline
                  E Offline
                  Eraserhead
                  wrote on last edited by
                  #8

                  sorry i am wrong. Anchors works thanks everyone :).

                  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