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. Columnview delete empty last column
Forum Updated to NodeBB v4.3 + New Features

Columnview delete empty last column

Scheduled Pinned Locked Moved General and Desktop
1 Posts 1 Posters 799 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.
  • K Offline
    K Offline
    kingjoe23
    wrote on last edited by
    #1

    Hello,

    I'm building a columnview in Python for maya. The problems is when there are no more children for an item a final column gets created which is always empty. I found this online and I believe it is the answer but can't get it to work:

    PySide.QtGui.QColumnView.createColumn(rootIndex)
    Parameters: rootIndex – PySide.QtCore.QModelIndex
    Return type: PySide.QtGui.QAbstractItemView
    To use a custom widget for the final column when you select an item overload this function and return a widget. index is the root index that will be assigned to the view.

    Return the new view. PySide.QtGui.QColumnView will automatically take ownership of the widget.

    I haven't quite been able to work it out, so if someone could tell me how to make it so that the last column doesn't appear if there is no items to add I would be very grateful.

    Many thanks in advance.

    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