25 #ifndef TBX_RES_RESDRAGGABLE_H
26 #define TBX_RES_RESDRAGGABLE_H
28 #include "resgadget.h"
40 enum {TYPE_ID = 640 };
268 #endif // TBX_RES_RESDRAGGABLE_H
Base class for gadget memory resources.
Definition: resgadget.h:42
int flag_value(int offset, int mask) const
Get the bits for the given mask.
Definition: resbase.h:362
void init_string(int offset, const char *value)
Initialise a string in a constructor helper.
Definition: resbase.cc:1725
void has_text(bool value)
Set if the draggable includes text.
Definition: resdraggable.h:140
int max_sprite_len() const
Get the maximum length of the sprite name for the draggable.
Definition: resdraggable.h:262
void message_with_length(int offset, const char *value, int length=-1)
Assign a message where the length is at offset+4.
Definition: resbase.cc:1639
ResDraggable(const ResGadget &other)
Construct an draggable gadget resource.
Definition: resdraggable.h:48
void sprite(const char *value, int max_length=-1)
Set the sprite name for the draggable.
Definition: resdraggable.h:248
void string_with_length(int offset, const char *value, int length=-1)
Assign a string where the length is at offset+4.
Definition: resbase.cc:1591
void drop_shadow(bool value)
Set if the draggable will show a drop shadow when dragged.
Definition: resdraggable.h:187
bool flag(int offset, int mask) const
Check if any of the bits in a mask are set.
Definition: resbase.h:352
DraggableType
Enumerations for mouse actions allowed on the draggable.
Definition: resdraggable.h:145
bool drop_shadow() const
Check if the draggable will show a drop shadow when dragged.
Definition: resdraggable.h:181
void draggable_type(DraggableType value)
Set the interaction with the mouse for this draggable.
Definition: resdraggable.h:162
bool not_dithered() const
Check if the draggable will be dithered when dragged.
Definition: resdraggable.h:193
ResDraggable & operator=(const ResDraggable &other)
Assign from another draggable gadget resource.
Definition: resdraggable.h:82
only allows a drag
Definition: resdraggable.h:147
void text(const std::string &value, int max_length=-1)
Set the text for the draggable.
Definition: resdraggable.h:226
const char * message(int offset) const
Get the message string at the given offset.
Definition: resbase.cc:1602
DraggableType draggable_type() const
Get the interaction with the mouse for this draggable.
Definition: resdraggable.h:156
const char * string(int offset) const
Return a string at the given offset.
Definition: resbase.cc:1555
void not_dithered(bool value)
Set if the draggable will be dithered when dragged.
Definition: resdraggable.h:199
ResDraggable & operator=(const ResGadget &other)
Assign from a ResGadget.
Definition: resdraggable.h:70
int max_text_len() const
Get the maximum length for the text.
Definition: resdraggable.h:232
ResDraggable(const ResDraggable &other)
Construct an draggable gadget resource.
Definition: resdraggable.h:58
bool has_text() const
Check if the draggable includes text.
Definition: resdraggable.h:132
void sprite(const std::string &value, int max_length=-1)
Set the sprite name for the draggable.
Definition: resdraggable.h:258
click, drag and double click allowed
Definition: resdraggable.h:148
const char * text() const
Get the text for the draggable.
Definition: resdraggable.h:206
ResBase & operator=(const ResBase &other)
Assignment.
Definition: resbase.cc:1534
const char * sprite() const
Get the sprite name for the draggable.
Definition: resdraggable.h:238
click selects, double click and drag allowed
Definition: resdraggable.h:149
bool generate_drag_started() const
Check if draggable should generate an event when the drag has started.
Definition: resdraggable.h:106
ResDraggable()
Construct a draggable gadget resource.
Definition: resdraggable.h:93
void check_type(int type) const
Check if this gadgets type is as specified.
Definition: reswindow.cc:97
bool deliver_toolbox_ids() const
Check if the draggable will deliver Toolbox IDs on drag completion.
Definition: resdraggable.h:169
bool has_sprite() const
Check if the draggable includes a sprite.
Definition: resdraggable.h:118
void text(const char *value, int max_length=-1)
Set the text for the draggable.
Definition: resdraggable.h:216
void has_sprite(bool value)
Set if the draggable includes a sprite.
Definition: resdraggable.h:126
void generate_drag_started(bool value)
Set if the draggable should generate an event when the drag has started.
Definition: resdraggable.h:112
Class for Draggable gadget template.
Definition: resdraggable.h:36
int int_value(int offset) const
Get an integer value.
Definition: resbase.h:316
void deliver_toolbox_ids(bool value)
Set if the draggable will deliver Toolbox IDs on drag completion.
Definition: resdraggable.h:175
void init_message(int offset, const char *value)
Initialise a message in a constructor helper.
Definition: resbase.cc:1736