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. Card based tabs

Card based tabs

Scheduled Pinned Locked Moved General and Desktop
7 Posts 2 Posters 2.0k 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.
  • N Offline
    N Offline
    nicky j
    wrote on last edited by
    #1

    Hello!
    So as you may know I have been working on a web browser. I was wondering if it is possible to make a tab system like the google chrome iOS/mobile app where you click the 'tab' button and you see a view with a bunch of cards. Or Safari on iOS with its horizontal-scrolling windows. I am aware that this is probably insanely difficult, but I was wondering if anyone would be so kind as to tell me how I might acheive this.
    Thanks!

    1 Reply Last reply
    0
    • raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by
      #2

      that shouldn't be that difficult.

      create a plain QWidget and place it in a QScrolllArea

      Create Thumbnails (QWidget::render() or QPixmap::grabWidget()) of your tab contents.

      set the thumbnails on QLabels and add them to a layout of your choice on the plain QWidget in the QScrollArea

      handle the clicks etc. on your labels

      is that what you are looking for?

      instead of using QLabels you could also create custom widgets for better handling and display features, etc.

      Alternatively you can use a QGraphicsView which may enable you any visual effects and handling of the items...
      I'm thinking of something similiar to "this":http://qt-project.org/forums/viewthread/4950, "this ":http://www.developer.nokia.com/Community/Wiki/Cover_Flow_With_Qt or "this":http://code.google.com/p/pictureflow/.

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      1 Reply Last reply
      0
      • N Offline
        N Offline
        nicky j
        wrote on last edited by
        #3

        yep thats it exactly! Is it possible to make multiple .ui files for a program?

        1 Reply Last reply
        0
        • raven-worxR Offline
          raven-worxR Offline
          raven-worx
          Moderators
          wrote on last edited by
          #4

          yep it should be possible. See "this":http://qt-project.org/doc/qt-5.0/qtdesigner/designer-using-a-ui-file.html for more infos.

          --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
          If you have a question please use the forum so others can benefit from the solution in the future

          1 Reply Last reply
          0
          • N Offline
            N Offline
            nicky j
            wrote on last edited by
            #5

            How about transitions? I want to set it up so that when I click on my 'home' button, a webview appears to slide down and cover the existing site. Kind of how it has a card slide feel when you scroll back a page in Safari.

            1 Reply Last reply
            0
            • raven-worxR Offline
              raven-worxR Offline
              raven-worx
              Moderators
              wrote on last edited by
              #6

              sure...see the "animation framework":http://qt-project.org/doc/qt-5.0/qtcore/animation-overview.html. (especially QPropertyAnimation)

              --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
              If you have a question please use the forum so others can benefit from the solution in the future

              1 Reply Last reply
              0
              • N Offline
                N Offline
                nicky j
                wrote on last edited by
                #7

                Awesome! Thanks for the help Raven-worx, I really do appreciate it!

                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