Results 1 to 20 of 20

Thread: how to mask the lineEdit text with asterisks for password entry?

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Join Date
    Feb 2014
    Posts
    31
    Thanks
    7
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    Sorry for the delay sir...
    yes it prints the dots in debug output..

    i was tried by changing the font styles also, but same problem i am getting..nothing displaying in the lineEdit...

    Thanks in advance..

  2. #2
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    Have you tried a different widget style? Maybe the one you are currently using is just displaying spaces?

    Cheers,
    _

  3. #3
    Join Date
    Feb 2014
    Posts
    31
    Thanks
    7
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    Thanks for the quick reply...
    I was tried with a new dialog and created every thing new..but same result.....

    Thanks in advance..

  4. #4
    Join Date
    Jan 2006
    Location
    Graz, Austria
    Posts
    8,416
    Thanks
    37
    Thanked 1,544 Times in 1,494 Posts
    Qt products
    Qt3 Qt4 Qt5
    Platforms
    Unix/X11 Windows

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    So the next thing would be to try my suggestion from comment #12

    Cheers,
    _

  5. #5
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    What anda_skoa means is, compile your simple test code and run it like this:
    Qt Code:
    1. ./program -style windows
    To copy to clipboard, switch view to plain text mode 
    (Assuming you are running on Linux)

  6. #6
    Join Date
    Feb 2014
    Posts
    31
    Thanks
    7
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    I was tried like that also..i.e. by running my application in terminal..
    $ ./password -style windows

    But the same thing is happening...is this the creator problem..My Qt creator version is 2.6.1.

    Thanks in advance..

  7. #7
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    It is irrelevant what version of Qt Creator you are using.

    It is important what version of Qt libraries you are using, what operating system you are on, what desktop environment is involved, what compiler you are
    using...

  8. #8
    Join Date
    Feb 2014
    Posts
    31
    Thanks
    7
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    Thanks for the quick reply,
    I am using...
    Qt version 4.8.1
    OS---Ubuntu 12.04 LTS (32 bit)
    Desktop Environment--Unity

  9. #9
    Join Date
    Mar 2009
    Location
    Brisbane, Australia
    Posts
    7,729
    Thanks
    13
    Thanked 1,610 Times in 1,537 Posts
    Qt products
    Qt4 Qt5
    Platforms
    Unix/X11 Windows
    Wiki edits
    17

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    Right, so does it still fail with the latest Qt 4.8.5?

  10. #10
    Join Date
    Jan 2006
    Location
    Warsaw, Poland
    Posts
    33,368
    Thanks
    3
    Thanked 5,017 Times in 4,793 Posts
    Qt products
    Qt3 Qt4 Qt5 Qt/Embedded
    Platforms
    Unix/X11 Windows Android Maemo/MeeGo
    Wiki edits
    10

    Default Re: how to mask the lineEdit text with asterisks for password entry?

    I would try setting a different font for the widget.
    Your biological and technological distinctiveness will be added to our own. Resistance is futile.

    Please ask Qt related questions on the forum and not using private messages or visitor messages.


Similar Threads

  1. Replies: 7
    Last Post: 5th February 2014, 11:20
  2. how to get the text from a LineEdit using QT??
    By Soumya Somasekhar Ram in forum Qt Programming
    Replies: 11
    Last Post: 11th September 2013, 13:43
  3. reading the latest entry text from QplaintextEdit
    By PHANI in forum Qt Programming
    Replies: 3
    Last Post: 6th February 2012, 11:30
  4. QLineEdit shadow text disappear on first entry
    By dentharg in forum Qt Programming
    Replies: 1
    Last Post: 6th July 2008, 17:40

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.