Callbacks

This module provides callback functions for handling keyboard and mouse input, as well as predefined button actions in EZGL applications.

Input Event Callbacks

bool ezgl::press_key(QWidget *widget, QKeyEvent *event, void *data)
bool ezgl::press_mouse(QWidget*, QMouseEvent *event, void *data)
bool ezgl::release_mouse(QWidget*, QMouseEvent *event, void *data)
bool ezgl::move_mouse(QWidget*, QMouseEvent *event, void *data)
bool ezgl::scroll_mouse(QWidget *widget, QWheelEvent *event, void *data)

Button Action Callbacks

bool ezgl::press_zoom_fit(QWidget *widget, void *data)

React to the clicked zoom_fit button

Parameters:
  • widget – The GUI widget where this event came from.

  • data – A pointer to any user-specified data you passed in.

Returns:

FALSE to allow other handlers to see this event, too. TRUE otherwise.

bool ezgl::press_zoom_in(QWidget *widget, void *data)

React to the clicked zoom_in button

Parameters:
  • widget – The GUI widget where this event came from.

  • data – A pointer to any user-specified data you passed in.

Returns:

FALSE to allow other handlers to see this event, too. TRUE otherwise.

bool ezgl::press_zoom_out(QWidget *widget, void *data)

React to the clicked zoom_out button

Parameters:
  • widget – The GUI widget where this event came from.

  • data – A pointer to any user-specified data you passed in.

Returns:

FALSE to allow other handlers to see this event, too. TRUE otherwise.

Other Callbacks

bool ezgl::press_proceed(QWidget *widget, void *data)

React to the clicked proceed button

Parameters:
  • widget – The GUI widget where this event came from.

  • data – A pointer to any user-specified data you passed in.

Returns:

FALSE to allow other handlers to see this event, too. TRUE otherwise.