Hi,
- create two QLineEdits's
- connect them using the signal slot mechanism
connect(edit1, SIGNAL(textChanged(const QString&)), edit2, SLOT(setText(const QString&)));
connect(edit2, SIGNAL(textChanged(const QString&)), edit1, SLOT(setText(const QString&)));
connect(edit1, SIGNAL(textChanged(const QString&)), edit2, SLOT(setText(const QString&)));
connect(edit2, SIGNAL(textChanged(const QString&)), edit1, SLOT(setText(const QString&)));
To copy to clipboard, switch view to plain text mode
EDIT: äh, QTextEdit... The same concept but use textChanged() signal and connect to a custom slot where you change the value of the other edit...
Bookmarks