TQColorDrag Class Reference
The TQColorDrag class provides a drag and drop object for
transferring colors.
More...
#include <tqdragobject.h>
Inherits TQStoredDrag.
List of all member functions.
Public Members
- TQColorDrag ( const TQColor & col, TQWidget * dragsource = 0, const char * name = 0 )
- TQColorDrag ( TQWidget * dragsource = 0, const char * name = 0 )
- void setColor ( const TQColor & col )
Static Public Members
- bool canDecode ( TQMimeSource * e )
- bool decode ( TQMimeSource * e, TQColor & col )
Detailed Description
The TQColorDrag class provides a drag and drop object for
transferring colors.
This class provides a drag object which can be used to transfer data
about colors for drag and drop and in the clipboard. For example, it
is used in TQColorDialog.
The color is set in the constructor but can be changed with
setColor().
For more information about drag and drop, see the TQDragObject class
and the drag and drop documentation.
See also Drag And Drop Classes.
Member Function Documentation
TQColorDrag::TQColorDrag ( const TQColor & col, TQWidget * dragsource = 0, const char * name = 0 )
Constructs a color drag object with the color col. Passes dragsource and name to the TQStoredDrag constructor.
TQColorDrag::TQColorDrag ( TQWidget * dragsource = 0, const char * name = 0 )
Constructs a color drag object with a white color. Passes dragsource and name to the TQStoredDrag constructor.
bool TQColorDrag::canDecode ( TQMimeSource * e ) [static]
Returns TRUE if the color drag object can decode the mime source
e; otherwise returns FALSE.
bool TQColorDrag::decode ( TQMimeSource * e, TQColor & col ) [static]
Decodes the mime source e and sets the decoded values to col.
void TQColorDrag::setColor ( const TQColor & col )
Sets the color of the color drag to col.
This file is part of the TQt toolkit.
Copyright © 1995-2007
Trolltech. All Rights Reserved.