GClasses
|
A painting canvas.
#include <GWidgets.h>
Public Member Functions | |
GWidgetCanvas (GWidgetGroup *pParent, int x, int y, int w, int h, GImage *pImage) | |
virtual | ~GWidgetCanvas () |
virtual void | draw (GImage *pCanvas, int x, int y) |
Draws this widget on pCanvas at (x,y) More... | |
void | setDirty () |
void | setHorizScroll (int x) |
void | setImage (GImage *pImage) |
void | setSelectionMask (GImage *pMask) |
Only the alpha channel of the mask is used. The other values should be constant, or else the selection border will cut through the selection. If you change what is selected, you should call this method again, even though it may still be the same mask image. More... | |
void | setVertScroll (int y) |
void | setZoom (float f) |
virtual WidgetType | type () |
float | zoom () |
void | zoomToFit () |
Public Member Functions inherited from GClasses::GWidgetAtomic | |
GWidgetAtomic (GWidgetGroup *pParent, int x, int y, int w, int h) | |
virtual | ~GWidgetAtomic () |
virtual bool | isAtomic () |
virtual bool | isClickable () |
virtual void | onChar (char c) |
virtual void | onGetFocus () |
virtual void | onLoseFocus () |
virtual void | onSpecialKey (int key) |
Public Member Functions inherited from GClasses::GWidget | |
GWidget (GWidgetGroup *m_pParent, int x, int y, int w, int h) | |
virtual | ~GWidget () |
int | id () |
GWidgetGroup * | parent () |
GRect * | rect () |
void | setPos (int x, int y) |
Protected Member Functions | |
virtual void | grab (int button, int x, int y) |
virtual void | onMouseMove (int dx, int dy) |
virtual void | release (int button) |
Protected Attributes | |
float | m_fZoom |
int | m_nHScroll |
int | m_nMouseX |
int | m_nMouseY |
int | m_nVScroll |
GImage * | m_pImageIn |
bool | m_pressed |
GImage * | m_pSelectionMask |
Protected Attributes inherited from GClasses::GWidget | |
GWidgetCommon * | m_common |
int | m_nID |
GWidgetGroup * | m_pParent |
GRect | m_rect |
Additional Inherited Members | |
Public Types inherited from GClasses::GWidget |
GClasses::GWidgetCanvas::GWidgetCanvas | ( | GWidgetGroup * | pParent, |
int | x, | ||
int | y, | ||
int | w, | ||
int | h, | ||
GImage * | pImage | ||
) |
|
virtual |
|
virtual |
Draws this widget on pCanvas at (x,y)
Implements GClasses::GWidget.
|
protectedvirtual |
Reimplemented from GClasses::GWidgetAtomic.
|
protectedvirtual |
Reimplemented from GClasses::GWidgetAtomic.
|
protectedvirtual |
Reimplemented from GClasses::GWidgetAtomic.
void GClasses::GWidgetCanvas::setDirty | ( | ) |
void GClasses::GWidgetCanvas::setHorizScroll | ( | int | x | ) |
void GClasses::GWidgetCanvas::setImage | ( | GImage * | pImage | ) |
void GClasses::GWidgetCanvas::setSelectionMask | ( | GImage * | pMask | ) |
Only the alpha channel of the mask is used. The other values should be constant, or else the selection border will cut through the selection. If you change what is selected, you should call this method again, even though it may still be the same mask image.
void GClasses::GWidgetCanvas::setVertScroll | ( | int | y | ) |
void GClasses::GWidgetCanvas::setZoom | ( | float | f | ) |
|
inlinevirtual |
Implements GClasses::GWidget.
|
inline |
void GClasses::GWidgetCanvas::zoomToFit | ( | ) |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |