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. How to make MainWindow toolbar user-resizable?

How to make MainWindow toolbar user-resizable?

Scheduled Pinned Locked Moved Unsolved General and Desktop
2 Posts 2 Posters 772 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.
  • M Offline
    M Offline
    mayaknife
    wrote on last edited by
    #1

    I have a QToolBar placed in the left toolbar area of a QMainWindow. The contents of the toolbar are dynamic and it's possible that some of the content in the toolbar could be clipped. I don't want to automatically have the toolbar resize to show the clipped content, but I would like the user to be able to drag the toolbar wider if they so desire.

    Normally I would use a QSplitter to provide resizability, but I don't see any way to apply that within the context of QMainWindow's left toolbar area and its center widget.

    Is there a straightforward way of doing this or should I give up on QMainWindow and roll my own main window from scratch?

    raven-worxR 1 Reply Last reply
    0
    • M mayaknife

      I have a QToolBar placed in the left toolbar area of a QMainWindow. The contents of the toolbar are dynamic and it's possible that some of the content in the toolbar could be clipped. I don't want to automatically have the toolbar resize to show the clipped content, but I would like the user to be able to drag the toolbar wider if they so desire.

      Normally I would use a QSplitter to provide resizability, but I don't see any way to apply that within the context of QMainWindow's left toolbar area and its center widget.

      Is there a straightforward way of doing this or should I give up on QMainWindow and roll my own main window from scratch?

      raven-worxR Offline
      raven-worxR Offline
      raven-worx
      Moderators
      wrote on last edited by
      #2

      @mayaknife said in How to make MainWindow toolbar user-resizable?:

      Is there a straightforward way of doing this or should I give up on QMainWindow and roll my own main window from scratch?

      the toolbar and dockwidget areas are pretty fixed implemented. no room for big customizations.
      If you can relinquish most of QMainWIndow's built-in features you might be better off creating your custom main window widget.

      --- SUPPORT REQUESTS VIA CHAT WILL BE IGNORED ---
      If you have a question please use the forum so others can benefit from the solution in the future

      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