MityDSP::tcGuiImage Class Reference
#include <ggui/gui_image.h>
List of all members.
Detailed Description
The tcGuiImage class is derived tcGuiObject class implementing image management.
- See also:
- tcGuiImage Page
Constructor & Destructor Documentation
tcGuiImage::tcGuiImage |
( |
const char * |
name, |
|
|
tcBench * |
bench, |
|
|
int |
idd | |
|
) |
| | |
Constructor
- Parameters:
-
| name | Object ID name from the XML file. |
| bench | The Controlling tcBench object for this widget. |
| name | The windows control ID that we assigned to this control. |
tcGuiImage::~tcGuiImage |
( |
|
) |
[virtual] |
Member Function Documentation
bool tcGuiImage::ParseXML |
( |
TiXmlElement * |
apElement |
) |
[virtual] |
bool tcGuiImage::set_bitmap |
( |
const char * |
apFilename |
) |
|
This routine sets the bitmap used for the image
- Parameters:
-
| pd | reference to painting device context to render into. |
| x | x location (screen coordinates) to draw to |
| y | y location (screen coordinates) to draw to |
void tcGuiImage::create |
( |
|
) |
[virtual] |
This function creates the image control.
- Note:
- This function is called after all of the XML file settings are read.
-
the bitmap information is assumed to be stored in the same pixel depth as the active screen coordinates. No bitmap conversion is performed during creation.
Reimplemented from MityDSP::tcGuiObject.
void MityDSP::tcGuiImage::set_file |
( |
const char * |
file_name |
) |
[inline] |
void MityDSP::tcGuiImage::set_trans_color |
( |
tsRgb |
color |
) |
[inline] |
void MityDSP::tcGuiImage::set_section_count |
( |
int |
section_count |
) |
[inline] |
virtual bool MityDSP::tcGuiImage::does_l_mouse |
( |
|
) |
[inline, virtual] |
This function draws the image to it's default position.
- Parameters:
-
| pd | reference to painting device context to render into. |
Reimplemented from MityDSP::tcGuiObject.
This function draws the image to the specified x/y location
- Parameters:
-
| pd | reference to painting device context to render into. |
| x | x location (screen coordinates) to draw to |
| y | y location (screen coordinates) to draw to |
void tcGuiImage::draw_section |
( |
tcGuiDspDisplay & |
pd, |
|
|
int |
x, |
|
|
int |
y, |
|
|
int |
offset | |
|
) |
| | |
This function draws a sub-section of an image to the specified location.
- Parameters:
-
| pd | reference to painting device context to render into. |
| x | x location (screen coordinates) to draw to |
| y | y location (screen coordinates) to draw to |
| offset | index number of section to display (0 <= index <= m_section_count) |
- Note:
- if a bad offset is provided or the bitmap is not set, a red "X" is displayed on the screen.
void tcGuiImage::draw_default |
( |
tcGuiDspDisplay & |
pd, |
|
|
int |
x, |
|
|
int |
y | |
|
) |
| | [static] |
This routine draws a basic box with an "X" on the screen. It is primarily used to indicate a lack of bitmap information or an invalid section request.
- Parameters:
-
| pd | reference to painting device context to render into. |
| x | x location (screen coordinates) to draw to |
| y | y location (screen coordinates) to draw to |
int MityDSP::tcGuiImage::get_section_count |
( |
|
) |
[inline] |
Member Data Documentation
source file name used to build image
has a color reserved as transparent
the number of sections in the bitmap (tiled "horizontally")