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. QPushButton doesn't get the Focus in Linux Mint

QPushButton doesn't get the Focus in Linux Mint

Scheduled Pinned Locked Moved Unsolved General and Desktop
qpushbuttonfocuslinux mint
5 Posts 3 Posters 2.1k Views
  • 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.
  • PabloArgP Offline
    PabloArgP Offline
    PabloArg
    wrote on last edited by
    #1

    I think I tried everything to make the Focus work.
    In my Form (QMainWindows) I set the focusPolicy property as "StrongFocus".
    Also I did it with my qpushbuttons and my lineEdits. But it does not work.
    Also I tried to set the property as "TabFocus" and didn't work.

    Among lineEdit, the Tab key works properly. But I never reach my qpushbutton.

    Any ideas?

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

      Hi and welcome
      I tested with Qt 5.6 on win 10
      https://www.dropbox.com/s/n1pr0mc5kf2l76i/focus_test.zip?dl=0

      Default it just works.
      Can you try the sample and tell me if pressing tab dont move between buttons?

      1 Reply Last reply
      0
      • PabloArgP Offline
        PabloArgP Offline
        PabloArg
        wrote on last edited by
        #3

        Hi,

        Thanks man for your soon answer, I downloaded your example but I got the following error trying build the project:

        :-1: warning: File `../focus_test/focus_test.pro' has modification time 2.8e+03 s in the future

        There are many lines as those.

        I assume it's because I am using the version 5.5.1.

        I will try to download the new version of Qt and I will try again and I will let you know if the problem disappeared.

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

          This message is not related to Qt version. It just says that the modification time of the ../focus_test/focus_test.pro file is in the future. Just change something in that line (add a new line at the end) and save it.

          https://forum.qt.io/topic/113070/qt-code-of-conduct

          1 Reply Last reply
          1
          • PabloArgP Offline
            PabloArgP Offline
            PabloArg
            wrote on last edited by
            #5

            Hi guys,

            Many thanks for your replay but I want to confirm that Qpushbutton has an issue in the focus [tabkey and setfocus()] for QT 5.5.1 32 bits on LINUX mint 17.3.

            I run my project in QT 5.6 64 bits and works fine !!!!

            So, we can close this topic or probably somebody know how to fix it.

            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