|
| button (gui *parent) |
|
void | imageFile (const std::string &name) |
| Specify bitmap image to be used for button, read from file. More...
|
|
int | imageResource (const std::string &name) |
| Specify bitmap image to be used for button, read from resource. More...
|
|
| gui () |
| Construct top level window with no parent. More...
|
|
| gui (gui *parent, const char *window_class="windex", unsigned long style=WS_CHILD, unsigned long exstyle=WS_EX_CONTROLPARENT) |
| Construct child of a parent. More...
|
|
void | child (gui *w) |
| register child on this window
|
|
children_t & | children () |
| get vector of children
|
|
gui * | parent () |
|
gui * | find (int id) |
| find child window with specified id
|
|
void | focus () |
|
void | bgcolor (int color) |
| Change background color. More...
|
|
void | nobgerase () |
|
void | enable (bool f=true) |
| Enable/Disable, default enable.
|
|
bool | isEnabled () const |
|
void | fontHeight (int h) |
| Change font height for this and all child windows.
|
|
void | fontName (const std::string &name) |
|
void | icon (const std::string &iconfilename) |
| Change icon. More...
|
|
void | cursor (char *cursorID) |
|
int | id () |
|
int | bgcolor () const |
|
void | textColor (int c) |
| Set text color. More...
|
|
void | text (const std::string &text) |
|
std::string | text () const |
|
void | scroll (bool fHoriz=true) |
| Add scrollbars. More...
|
|
void | scrollRange (int width, int height) |
| Set the scrolling range. More...
|
|
sMouse | getMouseStatus () |
| Get mouse status. More...
|
|
void | run () |
| Run the windows message loop. More...
|
|
void | tooltip (const std::string &text, int width=0) |
| Add tooltip that pops up helpfully when mouse cursor hovers over widget. More...
|
|
virtual LRESULT | WindowMessageHandler (HWND hwnd, UINT uMsg, WPARAM wParam, LPARAM lParam) |
|
virtual void | show (bool f=true) |
| Show window and all children.
|
|
void | showModal (gui &appWindow) |
| Show this window and suspend all other windows interactions until this is closed. More...
|
|
void | endModal () |
| Stop modal interaction and close window.
|
|
void | update () |
| force widget to redraw completely More...
|
|
void | move (const std::vector< int > &r) |
| Move the window. More...
|
|
void | size (int w, int h) |
| Change size without moving top left corner. More...
|
|
void | move (int x, int y) |
| Change position without changing size. More...
|
|
void | move (int x, int y, int w, int h) |
|
std::vector< int > | size () |
| Size of window client area. More...
|
|
std::vector< int > | lefttop () |
|
eventhandler & | events () |
| Get event handler.
|
|
HWND | handle () |
| get window handle
|
|
void | delete_list (std::vector< HWND > *list) |
| set delete list for when gui is detroyed
|
|
void | setfont (LOGFONT &logfont, HFONT &font) |
| change font for this and all child windows
|
|
void | setAsyncReadCompleteMsgID (int id) |
|
A widget that user can click to start an action.
int wex::button::imageResource |
( |
const std::string & |
name | ) |
|
|
inline |
Specify bitmap image to be used for button, read from resource.
- Parameters
-
- Returns
- 0 for no error
The image is stored in the executable.
Specify images to be built into the executable in a .rc file
MAINICON ICON "app.ico"
ZOOM_IN_BLACK BITMAP "zoom_in_black.bmp"
ZOOM_IN_RED BITMAP "zoom_in_red.bmp"
On error, will set button to blank.