Results 1 to 2 of 2

Thread: Arrange QtoolButton in QToolBar ?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2016
    Location
    Venice, California
    Posts
    87
    Thanks
    7
    Qt products
    Qt4
    Platforms
    Windows

    Default Arrange QtoolButton in QToolBar ?

    Hello,

    I'm wondering if there is a way to re-arrange the QToolButton in a QToolbar?
    I have a QToolbutton at the end of my ToolBar, and I would like to move it up. (see image)

    I was searching the forums and found .takeAt() and insertWidget() for layouts, I'm looking for something similar for ToolButtons

    Thanks!

    Nick

    QToolbar.jpg

  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: Arrange QtoolButton in QToolBar ?

    You could try

    1) call actions() to retrieve a list of the actions "behind" the buttons
    2) call clear()
    2) modify the list
    3) call addActions() with the modified list

    Cheers,
    _

Similar Threads

  1. QToolButton outside of QToolBar
    By dictoon in forum Qt Programming
    Replies: 2
    Last Post: 15th February 2016, 23:15
  2. Replies: 2
    Last Post: 10th October 2013, 16:08
  3. Unable to add QToolButton to QToolbar on QWidget
    By rawfool in forum Qt Programming
    Replies: 0
    Last Post: 17th August 2012, 11:52
  4. Hiding a QToolButton in a QToolBar
    By elcuco in forum Qt Programming
    Replies: 3
    Last Post: 24th November 2009, 21:35
  5. drag and drop QToolButton in QToolBar
    By NBilal in forum Qt Programming
    Replies: 1
    Last Post: 28th December 2008, 21:11

Tags for this Thread

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.