ipeqt::Canvas Class Reference
[Ipe Qt canvas]
A Qt widget that displays an Ipe document page.
More...
#include <ipeqtcanvas.h>
List of all members.
Classes
Signals
Public Member Functions
Protected Member Functions
Protected Attributes
Detailed Description
A Qt widget that displays an Ipe document page.
Constructor & Destructor Documentation
Canvas::Canvas |
( |
QWidget * |
parent, |
|
|
Qt::WFlags |
f = 0 | |
|
) |
| | |
Member Function Documentation
void Canvas::setPage |
( |
const Page * |
page, |
|
|
int |
pno, |
|
|
int |
view, |
|
|
const Cascade * |
sheet | |
|
) |
| | |
Set the page to be displayed.
Doesn't take ownership of any argument. The page number pno is only needed if page numbering is turned on.
void Canvas::setFontPool |
( |
const FontPool * |
fontPool |
) |
|
Vector ipeqt::Canvas::pan |
( |
|
) |
const [inline] |
double ipeqt::Canvas::zoom |
( |
|
) |
const [inline] |
const Cascade* ipeqt::Canvas::cascade |
( |
|
) |
const [inline] |
Return current style sheet cascade.
Vector ipeqt::Canvas::center |
( |
|
) |
const [inline] |
Vector ipeqt::Canvas::pos |
( |
|
) |
const [inline] |
Return last mouse position (snapped!) in user coordinates.
Vector ipeqt::Canvas::unsnappedPos |
( |
|
) |
const [inline] |
Return last unsnapped mouse position in user coordinates.
Vector ipeqt::Canvas::globalPos |
( |
|
) |
const [inline] |
Return global mouse position of last mouse press/release.
Vector Canvas::simpleSnapPos |
( |
|
) |
const |
Return snapped mouse position without angular snapping.
const Snap& ipeqt::Canvas::snap |
( |
|
) |
const [inline] |
Return current snapping information.
int ipeqt::Canvas::additionalModifiers |
( |
|
) |
const [inline] |
Return current additional modifiers.
void Canvas::setAdditionalModifiers |
( |
int |
mod |
) |
|
Set additional modifiers.
These modifier bits are passed to the Tool when a key is pressed or a drawing action is performed in addition to the actual keyboard modifiers.
Convert canvas (device) coordinates to user coordinates.
Convert user coordinates to canvas (device) coordinates.
void Canvas::setCanvasStyle |
( |
const Style & |
style |
) |
|
Set style of canvas drawing.
Includes paper color, pretty text, and grid.
Style ipeqt::Canvas::canvasStyle |
( |
|
) |
const [inline] |
void Canvas::setPan |
( |
const Vector & |
v |
) |
|
Set current pan position.
The pan position is the user coordinate that is displayed at the very center of the canvas.
void Canvas::setZoom |
( |
double |
zoom |
) |
|
Set current zoom factor.
The zoom factor maps user coordinates to screen pixel coordinates.
void Canvas::setSnap |
( |
const Snap & |
s |
) |
|
Set the snapping information.
void Canvas::setDimmed |
( |
bool |
dimmed |
) |
|
Dim whole canvas, except for the Tool.
This mode will be reset when the Tool finishes.
void Canvas::setAutoOrigin |
( |
const Vector & |
v |
) |
|
Enable automatic angular snapping with this origin.
Matrix Canvas::canvasTfm |
( |
|
) |
const |
Matrix mapping user coordinates to canvas coordinates.
void Canvas::computeFifi |
( |
double |
x, |
|
|
double |
y | |
|
) |
| | |
Stores the mouse position in iUnsnappedMousePos, computes Fifi if snapping is enabled, and stores snapped position in iMousePos.
void Canvas::setFifiVisible |
( |
bool |
visible |
) |
|
Set whether Fifi should be shown.
Fifi will only be shown if a snapping mode is active.
Mark for update with redrawing of objects.
void Canvas::updateTool |
( |
|
) |
|
Mark for update with redrawing of tool only.
void Canvas::setTool |
( |
Tool * |
tool |
) |
|
void Canvas::finishTool |
( |
|
) |
|
void ipeqt::Canvas::wheelMoved |
( |
int |
degrees |
) |
[signal] |
void ipeqt::Canvas::mouseAction |
( |
int |
button |
) |
[signal] |
void ipeqt::Canvas::positionChanged |
( |
|
) |
[signal] |
void ipeqt::Canvas::toolChanged |
( |
bool |
hasTool |
) |
[signal] |
void Canvas::paintEvent |
( |
QPaintEvent * |
ev |
) |
[protected, virtual] |
void Canvas::mousePressEvent |
( |
QMouseEvent * |
ev |
) |
[protected, virtual] |
void Canvas::mouseReleaseEvent |
( |
QMouseEvent * |
ev |
) |
[protected, virtual] |
void Canvas::mouseMoveEvent |
( |
QMouseEvent * |
ev |
) |
[protected, virtual] |
void Canvas::tabletEvent |
( |
QTabletEvent * |
ev |
) |
[protected, virtual] |
void Canvas::wheelEvent |
( |
QWheelEvent * |
ev |
) |
[protected, virtual] |
void Canvas::keyPressEvent |
( |
QKeyEvent * |
ev |
) |
[protected, virtual] |
QSize Canvas::sizeHint |
( |
|
) |
const [protected, virtual] |
void Canvas::drawPaper |
( |
cairo_t * |
cc |
) |
[protected] |
void Canvas::drawFrame |
( |
cairo_t * |
cc |
) |
[protected] |
void Canvas::drawAxes |
( |
cairo_t * |
cc |
) |
[protected] |
void Canvas::drawGrid |
( |
cairo_t * |
cc |
) |
[protected] |
void Canvas::drawObjects |
( |
cairo_t * |
cc |
) |
[protected] |
void Canvas::drawTool |
( |
Painter & |
painter |
) |
[protected] |
Draw the current canvas tool.
If no tool is set, it draws the selected objects.
bool Canvas::snapToPaperAndFrame |
( |
|
) |
[protected] |
Member Data Documentation
The documentation for this class was generated from the following files:
- ipeqtcanvas.h
- ipeqtcanvas.cpp