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. Customize title bar (without FramelessWindowHint). How?
Forum Updated to NodeBB v4.3 + New Features

Customize title bar (without FramelessWindowHint). How?

Scheduled Pinned Locked Moved General and Desktop
6 Posts 2 Posters 3.2k 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.
  • N Offline
    N Offline
    nikitablack
    wrote on last edited by
    #1

    Greetings dear community,

    I'm at the very beginning of my QT path. I'm searching a solution to my question for several days but without success. All I could find is to hide native title bar and draw custom buttons on top of that. I don't like this solution because this doesn't look native. For example, if that way I press minimize button qt window immediately becomes minimized while "true" window (on windows) minimized smoothly. Another example - it I grab native window and shake it I'll get behavior that hard to reproduce.

    So my question - how to achieve. I see probably two solutions - send a signal to native window. But I don't know which signal, how to send. That's why I'm asking. The second solution - use native window drawing. Is it possible at all? How?

    1 Reply Last reply
    0
    • SGaistS Offline
      SGaistS Offline
      SGaist
      Lifetime Qt Champion
      wrote on last edited by
      #2

      Hi and welcome to devnet,

      Can you also explain your use case ? You want to draw a custom title bar but you also state that it doesn't look native so it's a bit confusing.

      Interested in AI ? www.idiap.ch
      Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

      1 Reply Last reply
      0
      • N Offline
        N Offline
        nikitablack
        wrote on last edited by
        #3

        Hi!

        Sorry for unclear question. I just want to change the look of the title bar - color, min/max/close buttons etc but retain full "native" functionality. I already tried solutions with frameless window and custom title bar. It works, but not good - I described a differences in behavior comparing with native.

        1 Reply Last reply
        0
        • SGaistS Offline
          SGaistS Offline
          SGaist
          Lifetime Qt Champion
          wrote on last edited by
          #4

          What OS are you using ? And what version of Qt ?

          Interested in AI ? www.idiap.ch
          Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          0
          • N Offline
            N Offline
            nikitablack
            wrote on last edited by
            #5

            Qt 5.3. Ideally it should be crossplatform, but for now I'm using Win7. I googled a lot and it seems that I need dive deep into windows programming.

            1 Reply Last reply
            0
            • SGaistS Offline
              SGaistS Offline
              SGaist
              Lifetime Qt Champion
              wrote on last edited by
              #6

              Be aware that you're wandering on dangerous grounds, e.g. OS X users won't generally like that you modify the title bar.

              Interested in AI ? www.idiap.ch
              Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct

              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