[Qt-interest] LineEdit accepting the first character as a smallletter.

Ulf-Alexander v. Ceumern-Lindenstjerna ceumern at vrmagic.com
Fri Feb 12 10:26:02 CET 2010


Hi,

if you want your QLineEdit to accept only capitalized text, take a look
at

http://doc.trolltech.com/4.6/qlineedit.html#setValidator
and QRegExp.

If you want to capitalize the first char after it was entered, take a
look at 

http://doc.trolltech.com/4.6/qstring.html#toUpper

Cheers, Ulf

> -----Original Message-----
> From: qt-interest-bounces at trolltech.com [mailto:qt-interest-
> bounces at trolltech.com] On Behalf Of Mohammed Imran B
> Sent: Friday, February 12, 2010 9:36 AM
> To: qt-interest at trolltech.com
> Subject: [Qt-interest] LineEdit accepting the first character as a
> smallletter.
> 
> Hi,
> 
> I have QLineEdit which always accepts the first character as a small
> letter.
> 
> Is there any property through which I can set the first letter to be
> capital.
> 
> Thank you.
> 
> Regards,
> Imran.





More information about the Qt-interest-old mailing list