Re: validating input to QLineEdit while seting it through "setText()" method.
Originally Posted by d_stranz
Anyway, why would you want to display text like that in a line edit when it is forbidden for the user to type the same text? If you are trying to describe what the line edit should be used for, then either implement a tool tip on it or put a label next to it.
The QLineEdit already has a the placeholderText property to provide an in-widget prompt without actually putting the text in the editor's text buffer (since Qt 4.7, Sept 2010).
"We can't solve problems by using the same kind of thinking we used when we created them." -- Einstein
If you are posting code then please use [code] [/code] tags around it - makes addressing the problem easier.
Bookmarks