PDA

View Full Version : Qlabel indication



jerkymotion
26th March 2011, 18:17
Is it possible to....provide....X-coordinate value to qlabel from lineedit and show the position in Qlabel(just to indicate)

wysota
27th March 2011, 10:54
I'm not sure what you want as this seems to be a trivial question. Is the following not what you expect?

label->setText(lineEdit->text());

Optionally you can connect the textChanged() signal from the line edit to label's setText() slot.

BalaQT
28th March 2011, 09:02
hi,

I'm not sure what you are asking, but if you simply want to show the line edit x position try ,

showLabel->setText(QString::number(urLineEdit->x()));

hope it helps,
bala