summaryrefslogtreecommitdiffstats
path: root/doc/dnd.doc
diff options
context:
space:
mode:
authorMichele Calgaro <[email protected]>2023-09-23 12:42:20 +0900
committerMichele Calgaro <[email protected]>2023-09-23 12:42:20 +0900
commitb35e0845dc9b3c8b9a5e52a682c769f383933fae (patch)
treee4eeca8f6fe0ca87e774be98eabf89b4c7fca347 /doc/dnd.doc
parent1ba13366a7a377d50b9e8df9044ce11d8209f98c (diff)
downloadtqt3-b35e0845dc9b3c8b9a5e52a682c769f383933fae.tar.gz
tqt3-b35e0845dc9b3c8b9a5e52a682c769f383933fae.zip
Replace QObject, QWidget, QImage, QPair, QRgb, QColor, QChar, QString, QIODevice with TQ* version
Signed-off-by: Michele Calgaro <[email protected]>
Diffstat (limited to 'doc/dnd.doc')
-rw-r--r--doc/dnd.doc24
1 files changed, 12 insertions, 12 deletions
diff --git a/doc/dnd.doc b/doc/dnd.doc
index b7d54c151..27ac5937d 100644
--- a/doc/dnd.doc
+++ b/doc/dnd.doc
@@ -57,7 +57,7 @@ QTextEdit widget source code.
\section1 Dragging
-To start a drag, for example in a \link QWidget::mouseMoveEvent()
+To start a drag, for example in a \link TQWidget::mouseMoveEvent()
mouse motion event\endlink, create an object of the QDragObject
subclass appropriate for your media, such as QTextDrag for text and
QImageDrag for images. Then call the drag() method. This is all you
@@ -84,20 +84,20 @@ references.
\section1 Dropping
To be able to receive media dropped on a widget, call
-\link QWidget::setAcceptDrops() setAcceptDrops(TRUE)\endlink
+\link TQWidget::setAcceptDrops() setAcceptDrops(TRUE)\endlink
for the widget (e.g. in its constructor), and override the
event handler methods
-\link QWidget::dragEnterEvent() dragEnterEvent()\endlink and
-\link QWidget::dropEvent() dropEvent()\endlink.
+\link TQWidget::dragEnterEvent() dragEnterEvent()\endlink and
+\link TQWidget::dropEvent() dropEvent()\endlink.
For more sophisticated applications overriding
-\link QWidget::dragMoveEvent() dragMoveEvent()\endlink and
-\link QWidget::dragLeaveEvent() dragLeaveEvent()\endlink will also be
+\link TQWidget::dragMoveEvent() dragMoveEvent()\endlink and
+\link TQWidget::dragLeaveEvent() dragLeaveEvent()\endlink will also be
necessary.
For example, to accept text and image drops:
\code
MyWidget::MyWidget(...) :
- QWidget(...)
+ TQWidget(...)
{
...
setAcceptDrops(TRUE);
@@ -113,8 +113,8 @@ void MyWidget::dragEnterEvent(QDragEnterEvent* event)
void MyWidget::dropEvent(QDropEvent* event)
{
- QImage image;
- QString text;
+ TQImage image;
+ TQString text;
if ( QImageDrag::decode(event, image) ) {
insertImageAt(image, event->pos());
@@ -146,7 +146,7 @@ void MyWidget::copy()
void MyWidget::paste()
{
- QString text;
+ TQString text;
if ( QTextDrag::decode(QApplication::clipboard()->data(), text) )
insertText( text );
}
@@ -283,7 +283,7 @@ void MyEditor::startDrag()
void MyEditor::dropEvent(QDropEvent* event)
{
- QString text;
+ TQString text;
if ( QTextDrag::decode(event, text) ) {
if ( event->source() == this && event->action() == QDropEvent::Move ) {
@@ -300,7 +300,7 @@ void MyEditor::dropEvent(QDropEvent* event)
Some widgets are more specific than just a "yes" or "no" response when
data is dragged onto them. For example, a CAD program might only
accept drops of text onto text objects in the view. In these cases,
-the \link QWidget::dragMoveEvent() dragMoveEvent()\endlink is used and
+the \link TQWidget::dragMoveEvent() dragMoveEvent()\endlink is used and
an \e area is given for which the drag is accepted or ignored:
\code
void MyWidget::dragMoveEvent(QDragMoveEvent* event)