Results 1 to 2 of 2

Thread: Prevent reordering of DockWidget Tabs

  1. #1
    Join Date
    Oct 2010
    Location
    Berlin, Germany
    Posts
    358
    Thanks
    18
    Thanked 68 Times in 66 Posts
    Qt products
    Qt4
    Platforms
    Windows

    Default Prevent reordering of DockWidget Tabs

    Hello,

    since 5.6 it is possible to reorder Tabs of tabbed DockWidgets. Is there a way to forbid this? In our Application, we have a "special" DockWidget which is supposed to be always at the right side (like the "+"-button in Firefox). We enforce this programmatically when a new Widget gets added.

    So, I need a way to disable reordering of dockwidget tabs oder a slot to react on a changed order of tabs. Any hints?

    thanks!
    Felix

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: Prevent reordering of DockWidget Tabs

    I don't see anything explicit but you could look for the QTabBars in the widget hierarchy and set their movable properties to false.

    Assuming this uses QTabBar, you'll have to check the QMainWindow code https://code.woboq.org/qt5/qtbase/sr...nwindow.h.html

    Cheers,
    _

  3. The following user says thank you to anda_skoa for this useful post:

    FelixB (18th July 2016)

Similar Threads

  1. QTabWidget - prevent change of tab without disabling tabs
    By ashtray4241 in forum Qt Programming
    Replies: 4
    Last Post: 23rd September 2016, 11:12
  2. Replies: 1
    Last Post: 12th June 2014, 07:27
  3. QListWidget - reordering
    By ComServant in forum Newbie
    Replies: 1
    Last Post: 24th August 2010, 19:03
  4. QTreeWidget Column Reordering
    By jimc1200 in forum Newbie
    Replies: 1
    Last Post: 8th January 2009, 08:51
  5. reordering QListWidgetItems of a QListWidget
    By OriginalCopy in forum Qt Programming
    Replies: 14
    Last Post: 4th December 2007, 15:49

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Digia, Qt and their respective logos are trademarks of Digia Plc in Finland and/or other countries worldwide.