#include <papyrusmm/viewport.h>
Public Types | |
| typedef std::set< Papyrus::Controller::pointer > | Controllers |
Public Member Functions | |
| virtual void | clear () |
| Papyrus::Canvas::pointer | canvas () |
| Get the root canvas object. | |
| void | set_canvas (Papyrus::Canvas::pointer canvas) |
| Set the root canvas object. | |
| void | set_scroll_point (SCROLL_TO scroll_to=SCROLL_TO_CENTER) |
| SCROLL_TO | scroll_point () |
| void | scroll_offsets (double &x, double &y) const |
| void | scroll_to (double offset_x, double offset_y) |
| void | scroll_to_center () |
| void | window_to_canvas (double winx, double winy, double &canvasx, double &canvasy) const |
| Convert window coordinates to canvas coordinates. | |
| void | canvas_to_window (double canvasx, double canvasy, double &winx, double &winy) const |
| Convert canvas coordinates to window coordinates. | |
| const Controllers & | controllers () |
| void | add_controller (Papyrus::Controller::pointer controller) |
| void | remove_controller (Papyrus::Controller::pointer controller) |
| bool | canvas_size_tied_to_viewport () |
| void | tie_canvas_size_to_viewport (bool tie=true) |
| bool | viewport_size_tied_to_canvas () |
| void | tie_viewport_size_to_canvas (bool tie=true) |
Protected Member Functions | |
| void | on_canvas_size_changed () |
| void | on_need_redraw (double x, double y, double w, double h) |
| bool | expose_event_callback (GdkEventExpose *e) |
| void | size_allocate_callback (Gtk::Allocation &allocation) |
| bool | button_press_event_callback (GdkEventButton *event) |
| bool | button_release_event_callback (GdkEventButton *event) |
| bool | key_press_event_callback (GdkEventKey *event) |
| bool | key_release_event_callback (GdkEventKey *event) |
| bool | motion_notify_event_callback (GdkEventMotion *event) |
| bool | scroll_event_callback (GdkEventScroll *event) |
Protected Attributes | |
| Papyrus::Canvas::pointer | m_canvas |
| Papyrus::Group::pointer | m_root |
| int | m_width |
| int | m_height |
| double | m_scroll_x |
| double | m_scroll_y |
| bool | m_tie_canvas_size_to_viewport |
| bool | m_tie_viewport_size_to_canvas |
| Controllers | m_controllers |
| sigc::connection | m_canvas_redraw_connection |
| sigc::connection | m_canvas_size_connection |
| SCROLL_TO | m_scroll_to |
| Cairo::RefPtr< Cairo::Context > | m_context |
| void PapyrusGtk::Viewport::window_to_canvas | ( | double | winx, | |
| double | winy, | |||
| double & | canvasx, | |||
| double & | canvasy | |||
| ) | const |
Convert window coordinates to canvas coordinates.
| [in] | winx | The window x coordinate |
| [in] | winy | The window y coordinate |
| [out] | canvasx | The canvas x coordinate relating to (winx, winy) |
| [out] | canvasy | The canvas y coordinate relating to (winx, winy) |
| void PapyrusGtk::Viewport::canvas_to_window | ( | double | canvasx, | |
| double | canvasy, | |||
| double & | winx, | |||
| double & | winy | |||
| ) | const |
Convert canvas coordinates to window coordinates.
| [in] | canvasx | The canvas x coordinate |
| [in] | canvasy | The canvas y coordinate |
| [out] | winx | The window x coordinate relating to (canvasx, canvasy) |
| [out] | winy | The window y coordinate relating to (canvasx, canvasy) |
| bool PapyrusGtk::Viewport::expose_event_callback | ( | GdkEventExpose * | e | ) | [protected] |
1.5.1