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. QComboBox is removing text after I tab out of it
Qt 6.11 is out! See what's new in the release blog

QComboBox is removing text after I tab out of it

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

    I have a QComboBox where if I set the maxLength to anything less than 50 it simply truncates my text to the number of characters equal to the maxLength. If I set the max length to anything above 50 it simply does not accept any selections with over 50 characters and displays no selected value. It does not even do any truncations.

    For example, I set my maxlength to 100 but anything over 50 characters is just resolved as whitespace. I have been trying to fix this for hours and am at a loss of how to fix it. Any help would be appreciated!!

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

      Hi,

      What version of Qt are you using ?
      On what platform ?

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

      P 1 Reply Last reply
      0
      • P Offline
        P Offline
        psigil
        wrote on last edited by
        #3
        This post is deleted!
        1 Reply Last reply
        0
        • SGaistS SGaist

          Hi,

          What version of Qt are you using ?
          On what platform ?

          P Offline
          P Offline
          psigil
          wrote on last edited by
          #4

          @SGaist

          Yea sorry, I should have been more specific.

          I am using QT 4.5.1 on Linux (Centos 6).

          The maxlength is also a dynamic parameter

          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