Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. QDockWidget border gap
Qt 6.11 is out! See what's new in the release blog

QDockWidget border gap

Scheduled Pinned Locked Moved General and Desktop
2 Posts 2 Posters 2.3k 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.
  • ? Offline
    ? Offline
    A Former User
    wrote on last edited by
    #1

    Hello everyone.

    I recently started developing a simple application with Qt 5.1 and have encountered a problem, which may be a newbie question.
    In my main view I use QDockWidget for my top tool bar, instead of QToolBar (which I cannot find in designer but it seems to be present in code).
    To get the best look and feel from it, I also removed title bar, and set it's minimum and maximum height 100px.

    This is where my problem started. Usually when a dock widget is docked, it will have some sort of border which you can use to grab and resize the widget, however when minimum and maximum height are the same value, widget cannot be resized and the border disappears, and leaves an ugly 1px gap between dock and main widget.

    I want to either remove this gap or get border to appear and re-color it to suit my needs.

    I found that this gap/border may set by pixel metrics, but i have no idea how to use that.

    1 Reply Last reply
    0
    • K Offline
      K Offline
      kenchan
      wrote on last edited by
      #2

      Hi,

      If you remove the title bar I think you have no where to grab it. That is what the title bar is for. If you remove the default title bar I think you must implement your own.

      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
      • Unsolved