Ipelib
Public Member Functions | List of all members
Canvas Class Reference

#include <ipecanvas_cocoa.h>

Inherits ipe::CanvasBase.

Public Member Functions

 Canvas (IpeCanvasView *view)
 
virtual ~Canvas ()
 
IpeCanvasView * view ()
 
void button (bool press, NSEvent *event)
 
void mouseMove (NSEvent *event)
 
bool key (NSEvent *event)
 
void scrollWheel (NSEvent *event)
 
void magnify (NSEvent *event)
 
void drawRect (NSRect rect)
 
- Public Member Functions inherited from ipe::CanvasBase
virtual ~CanvasBase ()
 
void setPage (const Page *page, int pno, int view, const Cascade *sheet)
 
void setResources (const PdfResources *resources)
 
Vector pan () const
 
double zoom () const
 
const Cascade * cascade () const
 
Vector center () const
 
Vector pos () const
 
Vector unsnappedPos () const
 
Vector globalPos () const
 
Vector simpleSnapPos () const
 
const Snap & snap () const
 
void setInkMode (bool ink)
 
int additionalModifiers () const
 
void setAdditionalModifiers (int mod)
 
bool type3Font ()
 
Vector devToUser (const Vector &arg) const
 
Vector userToDev (const Vector &arg) const
 
void setCanvasStyle (const Style &style)
 
Style canvasStyle () const
 
void setPan (const Vector &v)
 
void setZoom (double zoom)
 
void setSnap (const Snap &s)
 
void setDimmed (bool dimmed)
 
void setAutoOrigin (const Vector &v)
 
void setVisibleVariant (Attribute variant)
 
Attribute visibleVariant () const noexcept
 
Matrix canvasTfm () const
 
void setObserver (CanvasObserver *observer)
 
void setFifiVisible (bool visible)
 
void setSelectionVisible (bool visible)
 
void setTool (Tool *tool)
 
void finishTool ()
 
Tool * tool ()
 
void update ()
 
void updateTool ()
 
int canvasWidth () const
 
int canvasHeight () const
 

Additional Inherited Members

- Public Types inherited from ipe::CanvasBase
enum  TModifiers {
  EShift = 0x100 , EControl = 0x200 , EAlt = 0x400 , EMeta = 0x800 ,
  ECommand = 0x1000
}
 
enum  TCursor { EStandardCursor , EHandCursor , ECrossCursor , EDotCursor }
 
- Static Public Member Functions inherited from ipe::CanvasBase
static int selectPageOrView (Document *doc, int page=-1, int startIndex=0, int pageWidth=240, int width=600, int height=480)
 
- Protected Member Functions inherited from ipe::CanvasBase
 CanvasBase ()
 
void drawPaper (cairo_t *cc)
 
void drawFrame (cairo_t *cc)
 
void drawAxes (cairo_t *cc)
 
void drawGrid (cairo_t *cc)
 
void drawObjects (cairo_t *cc)
 
void drawTool (Painter &painter)
 
void snapToPaperAndFrame ()
 
bool refreshSurface ()
 
void computeFifi (double x, double y)
 
void drawFifi (cairo_t *cr)
 
- Protected Attributes inherited from ipe::CanvasBase
CanvasObserver * iObserver
 
Tool * iTool
 
const Page * iPage
 
int iPageNumber
 
int iView
 
const Cascade * iCascade
 
Attribute iVisibleVariant
 
Style iStyle
 
Vector iPan
 
double iZoom
 
Snap iSnap
 
bool iDimmed
 
bool iAutoSnap
 
Vector iAutoOrigin
 
int iAdditionalModifiers
 
bool isInkMode
 
bool iRepaintObjects
 
double iWidth
 
double iHeight
 
double iBWidth
 
double iBHeight
 
cairo_surface_t * iSurface
 
Vector iUnsnappedMousePos
 
Vector iMousePos
 
Vector iGlobalPos
 
Vector iOldFifi
 
bool iFifiVisible
 
Snap::TSnapModes iFifiMode
 
bool iSelectionVisible
 
const PdfResources * iResources
 
std::unique_ptr< Fonts > iFonts
 
bool iType3Font
 

Constructor & Destructor Documentation

◆ Canvas()

Canvas::Canvas ( IpeCanvasView *  view)

References view().

◆ ~Canvas()

Canvas::~Canvas ( )
virtual

Member Function Documentation

◆ view()

IpeCanvasView * Canvas::view ( )
inline

Referenced by Canvas().

◆ button()

void Canvas::button ( bool  press,
NSEvent *  event 
)

◆ mouseMove()

void Canvas::mouseMove ( NSEvent *  event)

◆ key()

bool Canvas::key ( NSEvent *  event)

◆ scrollWheel()

void Canvas::scrollWheel ( NSEvent *  event)

◆ magnify()

void Canvas::magnify ( NSEvent *  event)

◆ drawRect()

void Canvas::drawRect ( NSRect  rect)

The documentation for this class was generated from the following files: