libidxgui
|
Public Member Functions | |
win2d (uint wid, const char *wname=NULL, uint height=1, uint width=1) | |
virtual void | set_wupdate (bool ud) |
virtual void | clear () |
virtual void | clear_resize () |
Clears the window and resizes it to 1x1. | |
virtual void | resize_window (uint h, uint w, bool force=false) |
virtual void | update_window (bool activate=false) |
virtual void | repaint_pixmap () |
virtual void | set_bg_colors (ubyte r, ubyte g, ubyte b) |
Set color of background. | |
void | update_pixmap (idx< ubyte > *img, uint h0, uint w0, bool updatepix=true) |
add img to the window and delete img. | |
void | update_pixmap (idx< ubyte > &img, uint h0, uint w0, bool updatepix=true) |
add img to the window. | |
Protected Member Functions | |
void | paintEvent (QPaintEvent *event) |
The event triggered when painting is needed. | |
void | wheelEvent (QWheelEvent *event) |
void | mousePressEvent (QMouseEvent *event) |
void | mouseMoveEvent (QMouseEvent *event) |
void | mouseReleaseEvent (QMouseEvent *event) |
void | keyPressEvent (QKeyEvent *event) |
void | keyReleaseEvent (QKeyEvent *event) |
void | buffer_resize (uint h, uint w, bool force=false) |
void | buffer_fill (idx< ubyte > *buf) |
Fill given buffer with background color. | |
void | update_qimage (uint mode=0) |
void | swap () |
void | draw_arrows (QPainter &painter) |
void | draw_boxes (QPainter &painter) |
void | draw_crosses (QPainter &painter) |
void | draw_ellipses (QPainter &painter) |
void | draw_masks (QPainter &painter) |
void | draw_images (bool update=false) |
void ebl::win2d::buffer_resize | ( | uint | h, |
uint | w, | ||
bool | force = false |
||
) | [protected] |
Resize current buffer to given height and width.
force | If true, will resize to any size, otherwise, will not accept to resize smaller than current size. |
void ebl::win2d::clear | ( | ) | [virtual] |
Clears the window, but does not resize it, leaves it to the current size.
Reimplemented from ebl::win.
void ebl::win2d::repaint_pixmap | ( | ) | [virtual] |
Repaints the pixmap and updates window. This will take changes in drawing_mode into account.
void ebl::win2d::resize_window | ( | uint | h, |
uint | w, | ||
bool | force = false |
||
) | [virtual] |
Resize this window to hxw.
force | If true, will resize to any size, otherwise, will not accept to resize smaller than current size. |
Reimplemented from ebl::win.
void ebl::win2d::set_wupdate | ( | bool | ud | ) | [virtual] |
used to disable or enable updating of window, for batch displaying. this is useful to avoid flickering and speed up display.
Reimplemented from ebl::win.
void ebl::win2d::update_qimage | ( | uint | mode = 0 | ) | [protected] |
mode | The channel(s) to display, 0: RGB, 1: R, 2: G, 3: B. |
void ebl::win2d::update_window | ( | bool | activate = false | ) | [virtual] |
Refresh display of the window.
activate | Raises the focus to this window if true. |
Reimplemented from ebl::win.