PDA

View Full Version : char arrays to "multiline editor"



baray98
29th January 2008, 00:33
I have a char array of "some size" and i want my user to change its values thru a GUI(widget). I was looking for like Q3MultiLineEdit equivalent in Qt4 of some sort . I would like to limit the input to "some size" so that i don't have worry about memory pointers on the loose when i convert my QString to my char arrays,

Is there such a thing that i can limit the number of inputs in QLineEdit or QTextBrowser?

baray98

gfunk
29th January 2008, 00:50
You could try QLineEdit::setMaxLength(n) to set it to a max of n characters.

baray98
29th January 2008, 06:19
I saw that but I want to give a Multiline look a.k.a QTextBrowser