Results 1 to 3 of 3

Thread: StatusBar customization

  1. #1
    Join Date
    Jul 2017
    Posts
    13
    Thanks
    3
    Qt products
    Qt4
    Platforms
    Unix/X11

    Question StatusBar customization

    Hi
    I am newbie to qt creator. I have a problem with Qstatusbar class. If i use QStatusbar in mainwindow it constantly appears in the bottom(left side) of mainwindow. but i need to display my status bar in top of my gui mainwindow. please share code example or Snippet? thanks

  2. #2
    Join Date
    Mar 2011
    Location
    Hyderabad, India
    Posts
    1,882
    Thanks
    3
    Thanked 452 Times in 435 Posts
    Qt products
    Qt4 Qt5
    Platforms
    MacOS X Unix/X11 Windows
    Wiki edits
    15

    Default Re: StatusBar customization

    Not possible with QMainWindow, you will have write a custom QWidget with layouts
    When you know how to do it then you may do it wrong.
    When you don't know how to do it then it is not that you may do it wrong but you may not do it right.

  3. #3
    Join Date
    Jan 2008
    Location
    Alameda, CA, USA
    Posts
    5,230
    Thanks
    302
    Thanked 864 Times in 851 Posts
    Qt products
    Qt5
    Platforms
    Windows

    Default Re: StatusBar customization

    Or you can add a QToolBar to the main window and add a QLabel to it to display your status messages. Set the allowed area to be Qt::TopToolBarArea and set movable and floatable to false.
    <=== The Great Pumpkin says ===>
    Please use CODE tags when posting source code so it is more readable. Click "Go Advanced" and then the "#" icon to insert the tags. Paste your code between them.

Similar Threads

  1. QTabWidget customization
    By asafzakay in forum Qt Programming
    Replies: 16
    Last Post: 26th November 2017, 11:01
  2. QMake QMake customization
    By csgib in forum Qt Tools
    Replies: 9
    Last Post: 15th June 2012, 08:59
  3. QWT legend customization
    By alexmal in forum Qwt
    Replies: 1
    Last Post: 20th May 2011, 07:27
  4. Customization of Qt Demo
    By nivditha in forum Newbie
    Replies: 7
    Last Post: 26th October 2010, 22:58
  5. Window customization
    By Kostanev in forum Qt Programming
    Replies: 11
    Last Post: 14th August 2008, 18:04

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.