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. QGridLayout vs QHBoxLayout & QVBoxLayout for TV Guide?
Forum Updated to NodeBB v4.3 + New Features

QGridLayout vs QHBoxLayout & QVBoxLayout for TV Guide?

Scheduled Pinned Locked Moved General and Desktop
3 Posts 3 Posters 2.4k 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.
  • C Offline
    C Offline
    CrimsonGT
    wrote on last edited by
    #1

    I have recently come back to Qt (tried it for previous projects and opted against it) and am really liking everything about it thus far. I am writing a TV Guide style application that will display Episode Guide Data (EPG) for anywhere from 3-7 days, and this data will be fed in from a Database source.

    Right now I am having a hard time determining if I should use a QGridLayout or a combination of QHBoxLayouts (for the episode data) with a single QVBoxLayout on the left side (for the channel name/icons). My main concern with QGridLayout is that I would break it up into "30 minute" blocks, but when programs started at say 3:45, I am not sure it would work correctly. To give a better idea of what I am going for with the GUI, this screenshot can be viewed...

    [img]http://www.itvt.com/files/u3/AT&T-u-verse-tv-epg-2009.jpg[/img]

    Just on a side note, if I want to only display a segment of this (i.e. 3:00AM - 4:30AM) and say 10 channels, which option would it be easier to implement vertical/horizontal scrolling with? Would I need to stick them in a different widget for that behavior?

    Thanks!

    1 Reply Last reply
    0
    • W Offline
      W Offline
      weblife
      wrote on last edited by
      #2

      Hello,

      I stumbled upon your post but am not a real expert on the grid layout structure and am sure you probably found a solution by now. Here is my idea of what your should do and a question also for you:

      I would go with individual QHBoxLayout for an entire row (channel/station/programming) so it becomes its own objects that can be deleted upon desire without the hassle of the addition linking of objects. I would have each object control the contents of (channel/station/programming) which would be composed of QVBoxLayout's. To hold all created objects (channel/station/programming) I would use a QVBoxLayout. Again, maybe not the best route depending on the functionality you desire, but it is how I would think about doing it.

      Now a question: What method did you go about for integrating the U-Verse API?

      Brandon Clark
      www.themindspot.com

      1 Reply Last reply
      0
      • B Offline
        B Offline
        bkerdev
        wrote on last edited by
        #3

        Such information will be powered by a database.
        The best one is to reimplement QTableView (for the view) and QStyledItemDelegate (for displaying information)

        "QStyledItemDelegate":http://qt-project.org/doc/qt-4.8/qstyleditemdelegate.html
        "Example - Star":http://qt-project.org/doc/qt-4.8/itemviews-stardelegate.html

        Boris Bker

        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