Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Unsolved Context Menu not showing entirely

    General and Desktop
    4
    8
    614
    Loading More Posts
    • 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.
    • D
      Dan Zebbra last edited by aha_1980

      I'm using QT 5.3.2 and in my whole app wherever I have a QLineEdit, rendered based on a UI file, the Context Menu shown on right click on an QLineEdit is not shown entirely.
      Can someone help me with this?

      Thanksalt text

      1 Reply Last reply Reply Quote 0
      • SGaist
        SGaist Lifetime Qt Champion last edited by

        Hi and welcome to devnet,

        Can you provide a minimal sample code reproducing that behaviour ?

        Did you check with a more recent version of Qt whether it still happens ?

        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 Reply Quote 2
        • D
          Dan Zebbra last edited by

          Hi SGaist,

          Thank you for your reply!
          Before going with providing that minimal sample code (which is not so easy) and changing the QT Version (which is also not so easy because we should perform a lot of testing as we have a lot of screens) can you suggest me some other approach so I could test different possibilities as the source of the bug?

          Thanks

          mrjj 1 Reply Last reply Reply Quote 0
          • mrjj
            mrjj Lifetime Qt Champion @Dan Zebbra last edited by

            @Dan-Zebbra
            Hi
            Are you using stylesheets ?
            If yes, could you disable it and see if that makes any difference ?

            1 Reply Last reply Reply Quote 3
            • D
              Dan Zebbra last edited by

              Yes, I'm using a lot of styleSheets but disabling them means giving up to my themes.

              aha_1980 mrjj 2 Replies Last reply Reply Quote 0
              • aha_1980
                aha_1980 Lifetime Qt Champion @Dan Zebbra last edited by aha_1980

                @Dan-Zebbra

                if you really want to solve your problem, you should at least try the suggestion of @SGaist and @mrjj. otherwise its hard for us to help you.

                I know that its not easy to deploy an app with a new Qt version, but it is easy to build and test against another version.

                regards

                Qt has to stay free or it will die.

                1 Reply Last reply Reply Quote 2
                • mrjj
                  mrjj Lifetime Qt Champion @Dan Zebbra last edited by

                  @Dan-Zebbra
                  If was not meant as a permanent thing.
                  Just to make sure its
                  not due to styling.
                  If it is, we must just find out why it cuts QMenu.
                  if not, we must continue investigate why it happens.
                  I have not seen that one before :)

                  1 Reply Last reply Reply Quote 1
                  • D
                    Dan Zebbra last edited by Dan Zebbra

                    I've solved it. I've added QLineEdit:ContextMenu {height: 200px;} in the stylesheet of the QLineEdit and it worked.
                    That's my entire styleSheet for th e QLineEdit element. Don't know why without the ContextMenu part it would cut off the Context Menu...

                    QLineEdit {background-color: #2b2b37; color: #FFFFFF; padding-left: 5px; font-family: 'Helvetica Neue'; height: 32px;} QLineEdit:ContextMenu {height: 200px;}

                    Thanks guys!

                    1 Reply Last reply Reply Quote 1
                    • First post
                      Last post