Masking QLineEdit text

后端 未结 5 1000
灰色年华
灰色年华 2021-02-06 11:53

I am using PyQt4 QLineEdit widget to accept password. There is a setMasking property, but not following how to set the masking character.<

5条回答
  •  我在风中等你
    2021-02-06 12:35

    As docs say http://doc-snapshot.qt-project.org/4.8/stylesheet-examples.html#customizing-qlineedit:

    The password character of line edits that have QLineEdit::Password echo mode can be set using:

    QLineEdit[echoMode="2"] {
        lineedit-password-character: 9679;
    }
    

提交回复
热议问题