KiCad PCB EDA Suite
|
#include <cairo_gal.h>
Public Member Functions | |
CAIRO_GAL (GAL_DISPLAY_OPTIONS &aDisplayOptions, wxWindow *aParent, wxEvtHandler *aMouseListener=nullptr, wxEvtHandler *aPaintListener=nullptr, const wxString &aName=wxT("CairoCanvas")) | |
~CAIRO_GAL () | |
Return true if the GAL canvas is visible on the screen. | |
bool | IsVisible () const override |
Return true if the GAL canvas is visible on the screen. | |
void | ResizeScreen (int aWidth, int aHeight) override |
Resizes the canvas. | |
bool | Show (bool aShow) override |
Show/hide the GAL canvas. | |
int | BeginGroup () override |
Begin a group. | |
void | EndGroup () override |
End the group. | |
void | SetTarget (RENDER_TARGET aTarget) override |
Set the target for rendering. | |
RENDER_TARGET | GetTarget () const override |
Get the currently used target for rendering. | |
void | ClearTarget (RENDER_TARGET aTarget) override |
Clear the target for rendering. | |
void | StartDiffLayer () override |
Begins rendering of a differential layer. | |
void | EndDiffLayer () override |
Ends rendering of a differential layer. | |
void | StartNegativesLayer () override |
Begins rendering in a new layer that will be copied to the main layer in EndNegativesLayer(). | |
void | EndNegativesLayer () override |
Ends rendering of a negatives layer and draws it to the main layer. | |
void | PostPaint (wxPaintEvent &aEvent) |
Post an event to m_paint_listener. | |
void | SetMouseListener (wxEvtHandler *aMouseListener) |
void | SetPaintListener (wxEvtHandler *aPaintListener) |
bool | SetNativeCursorStyle (KICURSOR aCursor, bool aHiDPI) override |
Set the cursor in the native panel. | |
void | BeginDrawing () override |
Start/end drawing functions, draw calls can be only made in between the calls to BeginDrawing()/EndDrawing(). | |
void | EndDrawing () override |
End the drawing, needs to be called for every new frame. | |
void | initSurface () |
Prepare Cairo surfaces for drawing. | |
void | deinitSurface () |
Destroy Cairo surfaces when are not needed anymore. | |
void | allocateBitmaps () |
Allocate the bitmaps for drawing. | |
void | deleteBitmaps () |
Allocate the bitmaps for drawing. | |
void | setCompositor () |
Prepare the compositor. | |
void | onPaint (wxPaintEvent &aEvent) |
Paint event handler. | |
void | skipMouseEvent (wxMouseEvent &aEvent) |
Mouse event handler, forwards the event to the child. | |
void | skipGestureEvent (wxGestureEvent &aEvent) |
Skip the gesture event to the parent. | |
void | onSetNativeCursor (wxSetCursorEvent &aEvent) |
Give the correct cursor image when the native widget asks for it. | |
bool | updatedGalDisplayOptions (const GAL_DISPLAY_OPTIONS &aOptions) override |
Handle updating display options. | |
bool | IsCairoEngine () override |
Return true if the GAL engine is a Cairo based type. | |
void | DrawLine (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint) override |
Draw a line. | |
void | DrawSegment (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint, double aWidth) override |
Draw a rounded segment. | |
void | DrawCircle (const VECTOR2D &aCenterPoint, double aRadius) override |
Draw a circle using world coordinates. | |
void | DrawArc (const VECTOR2D &aCenterPoint, double aRadius, const EDA_ANGLE &aStartAngle, const EDA_ANGLE &aAngle) override |
Draw an arc. | |
void | DrawArcSegment (const VECTOR2D &aCenterPoint, double aRadius, const EDA_ANGLE &aStartAngle, const EDA_ANGLE &aAngle, double aWidth, double aMaxError) override |
Draw an arc segment. | |
void | DrawRectangle (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint) override |
Draw a rectangle. | |
void | DrawRectangle (const BOX2I &aRect) |
void | DrawSegmentChain (const std::vector< VECTOR2D > &aPointList, double aWidth) override |
Draw a chain of rounded segments. | |
void | DrawSegmentChain (const SHAPE_LINE_CHAIN &aLineChain, double aWidth) override |
void | DrawPolyline (const std::deque< VECTOR2D > &aPointList) override |
Draw a polyline. | |
void | DrawPolyline (const VECTOR2D aPointList[], int aListSize) override |
void | DrawPolyline (const SHAPE_LINE_CHAIN &aLineChain) override |
virtual void | DrawPolyline (const std::vector< VECTOR2D > &aPointList) |
void | DrawPolylines (const std::vector< std::vector< VECTOR2D > > &aPointLists) override |
Draw multiple polylines. | |
void | DrawPolygon (const std::deque< VECTOR2D > &aPointList) override |
Draw a polygon. | |
void | DrawPolygon (const VECTOR2D aPointList[], int aListSize) override |
void | DrawPolygon (const SHAPE_POLY_SET &aPolySet, bool aStrokeTriangulation=false) override |
void | DrawPolygon (const SHAPE_LINE_CHAIN &aPolySet) override |
void | DrawGlyph (const KIFONT::GLYPH &aPolySet, int aNth, int aTotal) override |
Draw a polygon representing a font glyph. | |
void | DrawGlyphs (const std::vector< std::unique_ptr< KIFONT::GLYPH > > &aGlyphs) override |
Draw polygons representing font glyphs. | |
void | DrawCurve (const VECTOR2D &startPoint, const VECTOR2D &controlPointA, const VECTOR2D &controlPointB, const VECTOR2D &endPoint, double aFilterValue=0.0) override |
Draw a cubic bezier spline. | |
void | DrawBitmap (const BITMAP_BASE &aBitmap, double alphaBlend=1.0) override |
Draw a bitmap image. | |
void | Flush () override |
Force all remaining objects to be drawn. | |
void | ClearScreen () override |
Clear the screen. | |
void | SetIsFill (bool aIsFillEnabled) override |
Enable/disable fill. | |
void | SetIsStroke (bool aIsStrokeEnabled) override |
Enable/disable stroked outlines. | |
void | SetStrokeColor (const COLOR4D &aColor) override |
Set the stroke color. | |
void | SetFillColor (const COLOR4D &aColor) override |
Set the fill color. | |
void | SetLineWidth (float aLineWidth) override |
Set the line width. | |
void | SetLayerDepth (double aLayerDepth) override |
Set the depth of the layer (position on the z-axis) | |
void | Transform (const MATRIX3x3D &aTransformation) override |
Transform the context. | |
void | Rotate (double aAngle) override |
Rotate the context. | |
void | Translate (const VECTOR2D &aTranslation) override |
Translate the context. | |
void | Scale (const VECTOR2D &aScale) override |
Scale the context. | |
void | Save () override |
Save the context. | |
void | Restore () override |
Restore the context. | |
void | DrawGroup (int aGroupNumber) override |
Draw the stored group. | |
void | ChangeGroupColor (int aGroupNumber, const COLOR4D &aNewColor) override |
Change the color used to draw the group. | |
void | ChangeGroupDepth (int aGroupNumber, int aDepth) override |
Change the depth (Z-axis position) of the group. | |
void | DeleteGroup (int aGroupNumber) override |
Delete the group from the memory. | |
void | ClearCache () override |
Delete all data created during caching of graphic items. | |
void | SetNegativeDrawMode (bool aSetting) override |
Set negative draw mode in the renderer. | |
void | DrawCursor (const VECTOR2D &aCursorPosition) override |
Draw the cursor. | |
void | EnableDepthTest (bool aEnabled=false) override |
void | DrawGrid () override |
virtual bool | IsInitialized () const |
Return the initialization status for the canvas. | |
virtual bool | IsOpenGlEngine () |
Return true if the GAL engine is a OpenGL based type. | |
const VECTOR2I & | GetScreenPixelSize () const |
Return GAL canvas size in pixels. | |
virtual int | GetSwapInterval () const |
Return the swap interval. -1 for adaptive, 0 for disabled/unknown. | |
void | SetClearColor (const COLOR4D &aColor) |
const COLOR4D & | GetClearColor () const |
bool | GetIsFill () const |
Get the fill status. | |
bool | GetIsStroke () const |
Get the stroke status. | |
const COLOR4D & | GetFillColor () const |
Get the fill color. | |
const COLOR4D & | GetStrokeColor () const |
Get the stroke color. | |
float | GetLineWidth () const |
Get the line width. | |
void | AdvanceDepth () |
Change the current depth to deeper, so it is possible to draw objects right beneath other. | |
virtual void | BitmapText (const wxString &aText, const VECTOR2I &aPosition, const EDA_ANGLE &aAngle) |
Draw a text using a bitmap font. | |
void | ResetTextAttributes () |
Reset text attributes to default styling. | |
void | SetGlyphSize (const VECTOR2I aSize) |
const VECTOR2I & | GetGlyphSize () const |
void | SetFontBold (const bool aBold) |
bool | IsFontBold () const |
void | SetFontItalic (bool aItalic) |
bool | IsFontItalic () const |
void | SetFontUnderlined (bool aUnderlined) |
bool | IsFontUnderlined () const |
void | SetTextMirrored (const bool aMirrored) |
bool | IsTextMirrored () const |
void | SetHorizontalJustify (const GR_TEXT_H_ALIGN_T aHorizontalJustify) |
GR_TEXT_H_ALIGN_T | GetHorizontalJustify () const |
void | SetVerticalJustify (const GR_TEXT_V_ALIGN_T aVerticalJustify) |
GR_TEXT_V_ALIGN_T | GetVerticalJustify () const |
virtual void | ComputeWorldScreenMatrix () |
Compute the world <-> screen transformation matrix. | |
const MATRIX3x3D & | GetWorldScreenMatrix () const |
Get the world <-> screen transformation matrix. | |
const MATRIX3x3D & | GetScreenWorldMatrix () const |
Get the screen <-> world transformation matrix. | |
void | SetWorldScreenMatrix (const MATRIX3x3D &aMatrix) |
Set the world <-> screen transformation matrix. | |
BOX2D | GetVisibleWorldExtents () const |
void | SetWorldUnitLength (double aWorldUnitLength) |
Set the unit length. | |
void | SetScreenSize (const VECTOR2I &aSize) |
void | SetScreenDPI (double aScreenDPI) |
Set the dots per inch of the screen. | |
void | SetLookAtPoint (const VECTOR2D &aPoint) |
Get/set the Point in world space to look at. | |
const VECTOR2D & | GetLookAtPoint () const |
void | SetZoomFactor (double aZoomFactor) |
double | GetZoomFactor () const |
void | SetRotation (double aRotation) |
Get/set the rotation angle (in radians). | |
double | GetRotation () const |
void | SetDepthRange (const VECTOR2D &aDepthRange) |
Set the range of the layer depth. | |
double | GetMinDepth () const |
double | GetMaxDepth () const |
double | GetWorldScale () const |
Get the world scale. | |
void | SetFlip (bool xAxis, bool yAxis) |
Sets flipping of the screen. | |
bool | IsFlippedX () const |
bool | IsFlippedY () const |
virtual bool | HasTarget (RENDER_TARGET aTarget) |
Return true if the target exists. | |
void | SetGridVisibility (bool aVisibility) |
Set the visibility setting of the grid. | |
bool | GetGridVisibility () const |
bool | GetGridSnapping () const |
void | SetGridOrigin (const VECTOR2D &aGridOrigin) |
Set the origin point for the grid. | |
const VECTOR2D & | GetGridOrigin () const |
void | SetGridSize (const VECTOR2D &aGridSize) |
Set the grid size. | |
const VECTOR2D & | GetGridSize () const |
Return the grid size. | |
VECTOR2D | GetVisibleGridSize () const |
Return the visible grid size in x and y directions. | |
void | SetGridColor (const COLOR4D &aGridColor) |
Set the grid color. | |
void | SetAxesColor (const COLOR4D &aAxesColor) |
Set the axes color. | |
void | SetAxesEnabled (bool aAxesEnabled) |
Enable drawing the axes. | |
void | SetCoarseGrid (int aInterval) |
Draw every tick line wider. | |
float | GetGridLineWidth () const |
Get the grid line width. | |
VECTOR2D | GetGridPoint (const VECTOR2D &aPoint) const |
For a given point it returns the nearest point belonging to the grid in world coordinates. | |
VECTOR2D | ToWorld (const VECTOR2D &aPoint) const |
Compute the point position in world coordinates from given screen coordinates. | |
VECTOR2D | ToScreen (const VECTOR2D &aPoint) const |
Compute the point position in screen coordinates from given world coordinates. | |
void | SetCursorEnabled (bool aCursorEnabled) |
Enable/disable cursor. | |
bool | IsCursorEnabled () const |
Return information about cursor visibility. | |
void | SetCursorColor (const COLOR4D &aCursorColor) |
Set the cursor color. | |
virtual bool | IsContextLocked () |
Checks the state of the context lock. | |
virtual void | LockContext (int aClientCookie) |
Use GAL_CONTEXT_LOCKER RAII object unless you know what you're doing. | |
virtual void | UnlockContext (int aClientCookie) |
Protected Types | |
enum | GRAPHICS_COMMAND { CMD_SET_FILL , CMD_SET_STROKE , CMD_SET_FILLCOLOR , CMD_SET_STROKECOLOR , CMD_SET_LINE_WIDTH , CMD_STROKE_PATH , CMD_FILL_PATH , CMD_ROTATE , CMD_TRANSLATE , CMD_SCALE , CMD_SAVE , CMD_RESTORE , CMD_CALL_GROUP } |
Definitions for the command recorder. More... | |
typedef GAL | super |
Super class definition. | |
typedef std::deque< GROUP_ELEMENT > | GROUP |
A graphic group type definition. | |
Protected Member Functions | |
double | xform (double x) |
const VECTOR2D | xform (double x, double y) |
const VECTOR2D | xform (const VECTOR2D &aP) |
double | angle_xform (double aAngle) |
Transform according to the rotation from m_currentWorld2Screen transform matrix. | |
void | arc_angles_xform_and_normalize (double &aStartAngle, double &aEndAngle) |
Transform according to the rotation from m_currentWorld2Screen transform matrix for the start angle and the end angle of an arc. | |
void | resetContext () |
void | drawGridLine (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint) |
Draw a grid line (usually a simplified line function). | |
void | drawGridCross (const VECTOR2D &aPoint) |
void | drawGridPoint (const VECTOR2D &aPoint, double aWidth, double aHeight) |
void | drawAxes (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint) |
void | flushPath () |
void | storePath () |
Store the actual path. | |
void | blitCursor (wxMemoryDC &clientDC) |
Blit cursor into the current screen. | |
void | drawPoly (const std::deque< VECTOR2D > &aPointList) |
Drawing polygons & polylines is the same in Cairo, so here is the common code. | |
void | drawPoly (const std::vector< VECTOR2D > &aPointList) |
void | drawPoly (const VECTOR2D aPointList[], int aListSize) |
void | drawPoly (const SHAPE_LINE_CHAIN &aLineChain) |
unsigned int | getNewGroupNumber () |
Return a valid key that can be used as a new group number. | |
void | syncLineWidth (bool aForceWidth=false, double aWidth=0.0) |
void | updateWorldScreenMatrix () |
const VECTOR2D | roundp (const VECTOR2D &v) |
virtual void | beginUpdate () |
Enable item update mode. | |
virtual void | endUpdate () |
Disable item update mode. | |
void | computeWorldScale () |
Compute the scaling factor for the world->screen matrix. | |
double | computeMinGridSpacing () const |
compute minimum grid spacing from the grid settings | |
COLOR4D | getCursorColor () const |
Get the actual cursor color to draw. | |
void | OnGalDisplayOptionsChanged (const GAL_DISPLAY_OPTIONS &aOptions) override |
Handler for observer settings changes. | |
template<typename T > | |
void | normalize (T &a, T &b) |
Ensure that the first element is smaller than the second. | |
Protected Attributes | |
std::shared_ptr< CAIRO_COMPOSITOR > | m_compositor |
Object for layers compositing. | |
unsigned int | m_mainBuffer |
Handle to the main buffer. | |
unsigned int | m_overlayBuffer |
Handle to the overlay buffer. | |
unsigned int | m_tempBuffer |
Handle to the temp buffer. | |
unsigned int | m_savedBuffer |
Handle to buffer to restore after rendering to temp buffer. | |
RENDER_TARGET | m_currentTarget |
Current rendering target. | |
bool | m_validCompositor |
Compositor initialization flag. | |
wxWindow * | m_parentWindow |
Parent window. | |
wxEvtHandler * | m_mouseListener |
Mouse listener. | |
wxEvtHandler * | m_paintListener |
Paint listener. | |
unsigned int | m_bufferSize |
Size of buffers cairoOutput, bitmapBuffers. | |
unsigned char * | m_wxOutput |
wxImage compatible buffer | |
unsigned char * | m_bitmapBuffer |
Storage of the Cairo image. | |
int | m_stride |
Stride value for Cairo. | |
int | m_wxBufferWidth |
bool | m_isInitialized |
Are Cairo image & surface ready to use. | |
COLOR4D | m_backgroundColor |
Background color. | |
wxCursor | m_currentwxCursor |
wxCursor showing the current native cursor | |
bool | m_isGrouping |
Is grouping enabled ? | |
bool | m_isElementAdded |
Was an graphic element added ? | |
std::map< int, GROUP > | m_groups |
List of graphic groups. | |
unsigned int | m_groupCounter |
Counter used for generating group keys. | |
GROUP * | m_currentGroup |
Currently used group. | |
double | m_lineWidthInPixels |
bool | m_lineWidthIsOdd |
cairo_matrix_t | m_cairoWorldScreenMatrix |
Cairo world to screen transform matrix. | |
cairo_matrix_t | m_currentXform |
cairo_matrix_t | m_currentWorld2Screen |
cairo_t * | m_currentContext |
Currently used Cairo context for drawing. | |
cairo_t * | m_context |
Cairo image. | |
cairo_surface_t * | m_surface |
Cairo surface. | |
std::vector< cairo_surface_t * > | m_imageSurfaces |
List of surfaces that were created by painting images, to be cleaned up later. | |
std::vector< cairo_matrix_t > | m_xformStack |
GAL_DISPLAY_OPTIONS & | m_options |
UTIL::LINK | m_observerLink |
std::stack< double > | m_depthStack |
Stored depth values. | |
VECTOR2I | m_screenSize |
Screen size in screen (wx logical) coordinates. | |
double | m_worldUnitLength |
The unit length of the world coordinates [inch]. | |
double | m_screenDPI |
The dots per inch of the screen. | |
VECTOR2D | m_lookAtPoint |
Point to be looked at in world space. | |
double | m_zoomFactor |
The zoom factor. | |
double | m_rotation |
Rotation transformation (radians) | |
MATRIX3x3D | m_worldScreenMatrix |
World transformation. | |
MATRIX3x3D | m_screenWorldMatrix |
Screen transformation. | |
double | m_worldScale |
The scale factor world->screen. | |
bool | m_globalFlipX |
Flag for X axis flipping. | |
bool | m_globalFlipY |
Flag for Y axis flipping. | |
float | m_lineWidth |
The line width. | |
bool | m_isFillEnabled |
Is filling of graphic objects enabled ? | |
bool | m_isStrokeEnabled |
Are the outlines stroked ? | |
COLOR4D | m_fillColor |
The fill color. | |
COLOR4D | m_strokeColor |
The color of the outlines. | |
COLOR4D | m_clearColor |
double | m_layerDepth |
The actual layer depth. | |
VECTOR2D | m_depthRange |
Range of the depth. | |
bool | m_gridVisibility |
Should the grid be shown. | |
GRID_STYLE | m_gridStyle |
Grid display style. | |
VECTOR2D | m_gridSize |
The grid size. | |
VECTOR2D | m_gridOrigin |
The grid origin. | |
VECTOR2D | m_gridOffset |
The grid offset to compensate cursor position. | |
COLOR4D | m_gridColor |
Color of the grid. | |
COLOR4D | m_axesColor |
Color of the axes. | |
bool | m_axesEnabled |
Should the axes be drawn. | |
int | m_gridTick |
Every tick line gets the double width. | |
float | m_gridLineWidth |
Line width of the grid. | |
int | m_gridMinSpacing |
Minimum screen size of the grid (pixels) below which the grid is not drawn. | |
bool | m_isCursorEnabled |
Is the cursor enabled? | |
bool | m_forceDisplayCursor |
Always show cursor. | |
COLOR4D | m_cursorColor |
Cursor color. | |
bool | m_fullscreenCursor |
Shape of the cursor (fullscreen or small cross) | |
VECTOR2D | m_cursorPosition |
Current cursor position (world coordinates) | |
KICURSOR | m_currentNativeCursor |
Current cursor. | |
Static Protected Attributes | |
static const int | MAX_CAIRO_ARGUMENTS = 4 |
Maximum number of arguments for one command. | |
static constexpr cairo_format_t | GAL_FORMAT = CAIRO_FORMAT_ARGB32 |
Format used to store pixels. | |
static const int | MIN_DEPTH = -1024 |
Possible depth range. | |
static const int | MAX_DEPTH = 1023 |
static const int | GRID_DEPTH = MAX_DEPTH - 1 |
Depth level on which the grid is drawn. | |
Private Member Functions | |
double | getLayerDepth () const |
Private Attributes | |
TEXT_ATTRIBUTES | m_attributes |
Definition at line 376 of file cairo_gal.h.
|
protectedinherited |
A graphic group type definition.
Definition at line 348 of file cairo_gal.h.
|
protectedinherited |
Super class definition.
Definition at line 312 of file cairo_gal.h.
|
protectedinherited |
Definitions for the command recorder.
Definition at line 318 of file cairo_gal.h.
CAIRO_GAL::CAIRO_GAL | ( | GAL_DISPLAY_OPTIONS & | aDisplayOptions, |
wxWindow * | aParent, | ||
wxEvtHandler * | aMouseListener = nullptr , |
||
wxEvtHandler * | aPaintListener = nullptr , |
||
const wxString & | aName = wxT( "CairoCanvas" ) |
||
) |
aParent | is the wxWidgets immediate wxWindow parent of this object. |
aMouseListener | is the wxEvtHandler that should receive the mouse events, this can be can be any wxWindow, but is often a wxFrame container. |
aPaintListener | is the wxEvtHandler that should receive the paint event. This can be any wxWindow, but is often a derived instance of this class or a containing wxFrame. The "paint event" here is a wxCommandEvent holding EVT_GAL_REDRAW, as sent by PostPaint(). |
aName | is the name of this window for use by wxWindow::FindWindowByName(). |
Definition at line 1324 of file cairo_gal.cpp.
References allocateBitmaps(), m_bitmapBuffer, m_currentTarget, m_isInitialized, m_mainBuffer, m_mouseListener, m_overlayBuffer, m_paintListener, m_parentWindow, m_savedBuffer, KIGFX::GAL::m_screenSize, m_tempBuffer, m_validCompositor, m_wxOutput, onPaint(), onSetNativeCursor(), SetTarget(), skipGestureEvent(), skipMouseEvent(), KIGFX::TARGET_NONCACHED, and ToVECTOR2I().
CAIRO_GAL::~CAIRO_GAL | ( | ) |
Return true if the GAL canvas is visible on the screen.
Definition at line 1388 of file cairo_gal.cpp.
References deleteBitmaps().
|
inlineinherited |
Change the current depth to deeper, so it is possible to draw objects right beneath other.
If you do this, you should consider using a GAL_SCOPED_ATTR to ensure the depth is reset to the original value.
Definition at line 402 of file graphics_abstraction_layer.h.
Referenced by KIGFX::VIEW_GROUP::ViewDraw().
void CAIRO_GAL::allocateBitmaps | ( | ) |
Allocate the bitmaps for drawing.
Definition at line 1597 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::GAL_FORMAT, m_bitmapBuffer, m_bufferSize, KIGFX::GAL::m_screenSize, m_stride, m_wxBufferWidth, m_wxOutput, VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by CAIRO_GAL(), and ResizeScreen().
|
protectedinherited |
Transform according to the rotation from m_currentWorld2Screen transform matrix.
aAngle | is the angle in radians to transform. |
Definition at line 129 of file cairo_gal.cpp.
References KIGFX::GAL::IsFlippedX(), and KIGFX::CAIRO_GAL_BASE::m_currentWorld2Screen.
Referenced by KIGFX::CAIRO_GAL_BASE::arc_angles_xform_and_normalize().
|
protectedinherited |
Transform according to the rotation from m_currentWorld2Screen transform matrix for the start angle and the end angle of an arc.
aStartAngle | is the arc starting point in radians to transform |
aEndAngle | is the arc ending point in radians to transform |
Definition at line 143 of file cairo_gal.cpp.
References std::abs(), KIGFX::CAIRO_GAL_BASE::angle_xform(), KIGFX::GAL::IsFlippedX(), and KIGFX::GAL::normalize().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), and KIGFX::CAIRO_GAL_BASE::DrawArcSegment().
|
overridevirtual |
Start/end drawing functions, draw calls can be only made in between the calls to BeginDrawing()/EndDrawing().
Normally you should create a GAL_DRAWING_CONTEXT RAII object, but I'm leaving these functions public for more precise (i.e. timing/profiling) control of the drawing process - Tom Begin the drawing, needs to be called for every new frame. Use GAL_DRAWING_CONTEXT RAII object unless you know what you're doing.
Reimplemented from KIGFX::CAIRO_GAL_BASE.
Definition at line 1394 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::BeginDrawing(), initSurface(), m_compositor, KIGFX::CAIRO_GAL_BASE::m_context, m_mainBuffer, m_validCompositor, and setCompositor().
|
overridevirtual |
Begin a group.
A group is a collection of graphic items. Hierarchical groups are possible, attributes and transformations can be used.
Reimplemented from KIGFX::CAIRO_GAL_BASE.
Definition at line 1496 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::BeginGroup(), and initSurface().
|
inlineprotectedvirtualinherited |
Enable item update mode.
Private: use GAL_UPDATE_CONTEXT RAII object
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 996 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_UPDATE_CONTEXT::GAL_UPDATE_CONTEXT().
|
virtualinherited |
Draw a text using a bitmap font.
It should be faster than StrokeText(), but can be used only for non-Gerber elements.
aText | is the text to be drawn. |
aPosition | is the text position in world coordinates. |
aAngle | is the text rotation angle. |
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 260 of file graphics_abstraction_layer.cpp.
References KIFONT::METRICS::Default(), KIFONT::FONT::Draw(), KIFONT::FONT::GetFont(), KIGFX::GAL::GetLineWidth(), TEXT_ATTRIBUTES::m_Angle, KIGFX::GAL::m_attributes, KIGFX::GAL::m_globalFlipX, TEXT_ATTRIBUTES::m_Mirrored, TEXT_ATTRIBUTES::m_Size, TEXT_ATTRIBUTES::m_StrokeWidth, VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::OPENGL_GAL::BitmapText(), KIGFX::bitmapText(), KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::VIEW_OVERLAY::COMMAND_BITMAP_TEXT::Execute(), and KIGFX::PCB_PAINTER::renderNetNameForSegment().
|
protectedinherited |
Blit cursor into the current screen.
Definition at line 1194 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, color, KIGFX::COLOR4D::g, KIGFX::GAL::getCursorColor(), KIGFX::GAL::IsCursorEnabled(), KIGFX::GAL::m_cursorPosition, KIGFX::GAL::m_fullscreenCursor, KIGFX::COLOR4D::r, KIGFX::GAL::ToScreen(), VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by EndDrawing().
|
overridevirtualinherited |
Change the color used to draw the group.
aGroupNumber | is the group number. |
aNewColor | is the new color. |
Reimplemented from KIGFX::GAL.
Definition at line 924 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::CMD_SET_FILLCOLOR, KIGFX::CAIRO_GAL_BASE::CMD_SET_STROKECOLOR, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_groups, KIGFX::COLOR4D::r, and KIGFX::CAIRO_GAL_BASE::storePath().
|
overridevirtualinherited |
Change the depth (Z-axis position) of the group.
aGroupNumber | is the group number. |
aDepth | is the new depth. |
Reimplemented from KIGFX::GAL.
Definition at line 941 of file cairo_gal.cpp.
|
overridevirtualinherited |
Delete all data created during caching of graphic items.
Reimplemented from KIGFX::GAL.
Definition at line 966 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::DeleteGroup(), and KIGFX::CAIRO_GAL_BASE::m_groups.
Referenced by KIGFX::CAIRO_GAL_BASE::~CAIRO_GAL_BASE().
|
overridevirtualinherited |
Clear the screen.
aColor | is the color used for clearing. |
Reimplemented from KIGFX::GAL.
Definition at line 594 of file cairo_gal.cpp.
References KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::GAL::m_clearColor, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_screenSize, KIGFX::COLOR4D::r, VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::resetContext().
|
overridevirtual |
Clear the target for rendering.
aTarget | is the target to be cleared. |
Reimplemented from KIGFX::GAL.
Definition at line 1540 of file cairo_gal.cpp.
References KIGFX::COLOR4D::BLACK, m_compositor, m_mainBuffer, m_overlayBuffer, m_tempBuffer, KIGFX::TARGET_CACHED, KIGFX::TARGET_NONCACHED, KIGFX::TARGET_OVERLAY, and KIGFX::TARGET_TEMP.
Referenced by StartDiffLayer(), and StartNegativesLayer().
|
protectedinherited |
compute minimum grid spacing from the grid settings
Definition at line 214 of file graphics_abstraction_layer.cpp.
References KIGFX::GAL::m_gridMinSpacing.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
inlineprotectedinherited |
Compute the scaling factor for the world->screen matrix.
Definition at line 1004 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::OPENGL_GAL::ComputeWorldScreenMatrix(), and KIGFX::GAL::GAL().
|
virtualinherited |
Compute the world <-> screen transformation matrix.
Reimplemented in KIGFX::CAIRO_PRINT_GAL, and KIGFX::OPENGL_GAL.
Definition at line 169 of file graphics_abstraction_layer.cpp.
References KIGFX::GAL::computeWorldScale(), MATRIX3x3< T >::Inverse(), KIGFX::GAL::m_globalFlipX, KIGFX::GAL::m_globalFlipY, KIGFX::GAL::m_lookAtPoint, KIGFX::GAL::m_rotation, KIGFX::GAL::m_screenSize, KIGFX::GAL::m_screenWorldMatrix, KIGFX::GAL::m_worldScale, KIGFX::GAL::m_worldScreenMatrix, scale, MATRIX3x3< T >::SetIdentity(), MATRIX3x3< T >::SetRotation(), MATRIX3x3< T >::SetScale(), MATRIX3x3< T >::SetTranslation(), VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::OPENGL_GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_GAL_BASE::resetContext(), KIGFX::VIEW::SetCenter(), and KIGFX::VIEW::SetScale().
void CAIRO_GAL::deinitSurface | ( | ) |
Destroy Cairo surfaces when are not needed anymore.
Definition at line 1583 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_context, m_isInitialized, and KIGFX::CAIRO_GAL_BASE::m_surface.
Referenced by EndDrawing(), EndGroup(), and updatedGalDisplayOptions().
void CAIRO_GAL::deleteBitmaps | ( | ) |
Allocate the bitmaps for drawing.
Definition at line 1613 of file cairo_gal.cpp.
References m_bitmapBuffer, and m_wxOutput.
Referenced by ResizeScreen(), and ~CAIRO_GAL().
|
overridevirtualinherited |
Delete the group from the memory.
aGroupNumber | is the group number. |
Reimplemented from KIGFX::GAL.
Definition at line 948 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_FILL_PATH, KIGFX::CAIRO_GAL_BASE::CMD_STROKE_PATH, KIGFX::CAIRO_GAL_BASE::m_groups, and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::ClearCache().
|
overridevirtualinherited |
Draw an arc.
aCenterPoint | is the center point of the arc. |
aRadius | is the arc radius. |
aStartAngle | is the start angle of the arc. |
aAngle | is the angle of the arc. |
Reimplemented from KIGFX::GAL.
Definition at line 341 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::arc_angles_xform_and_normalize(), EDA_ANGLE::AsRadians(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_isFillEnabled, KIGFX::CAIRO_GAL_BASE::m_lineWidthInPixels, RADIANS_T, RotatePoint(), KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArcSegment().
|
overridevirtualinherited |
Draw an arc segment.
This method differs from DrawArc() in what happens when fill/stroke are on or off. DrawArc() draws a "pie piece" when fill is turned on, and a thick stroke when fill is off. DrawArcSegment() with fill on behaves like DrawArc() with fill off. DrawArcSegment() with fill off draws the outline of what it would have drawn with fill on.
TODO: Unify Arc routines
aCenterPoint | is the center point of the arc. |
aRadius | is the arc radius. |
aStartAngle | is the start angle of the arc. |
aAngle | is the angle of the arc. |
aWidth | is the thickness of the arc (pen size). |
aMaxError | is the max allowed error to create segments to approximate a circle. It has meaning only for back ends that can't draw a true arc, and use segments to approximate. Note: aMaxError is not used in Cairo, because Cairo can draw true arcs |
Reimplemented from KIGFX::GAL.
Definition at line 385 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::CAIRO_GAL_BASE::arc_angles_xform_and_normalize(), EDA_ANGLE::AsRadians(), KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_isFillEnabled, KIGFX::GAL::m_isStrokeEnabled, KIGFX::GAL::m_lineWidth, KIGFX::GAL::m_strokeColor, KIGFX::COLOR4D::r, RADIANS_T, RotatePoint(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
protectedinherited |
Definition at line 1048 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::GAL::m_axesColor, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::COLOR4D::r, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
overridevirtualinherited |
Draw a bitmap image.
Reimplemented from KIGFX::GAL.
Definition at line 502 of file cairo_gal.cpp.
References BITMAP_BASE::GetImageData(), BITMAP_BASE::GetPPI(), BITMAP_BASE::GetSizePixels(), image, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_currentWorld2Screen, KIGFX::CAIRO_GAL_BASE::m_imageSurfaces, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_worldUnitLength, scale, VECTOR2< T >::x, and VECTOR2< T >::y.
|
overridevirtualinherited |
Draw a circle using world coordinates.
aCenterPoint | is the center point of the circle. |
aRadius | is the radius of the circle. |
Reimplemented from KIGFX::GAL.
Definition at line 325 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::m_lineWidthInPixels, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
overridevirtualinherited |
Draw the cursor.
aCursorPosition | is the cursor position in screen coordinates. |
Reimplemented from KIGFX::GAL.
Definition at line 1005 of file cairo_gal.cpp.
References KIGFX::GAL::m_cursorPosition.
|
overridevirtualinherited |
Draw a cubic bezier spline.
startPoint | is the start point of the spline. |
controlPointA | is the first control point. |
controlPointB | is the second control point. |
endPoint | is the end point of the spline. |
aFilterValue | is used by Bezier to segments approximation, if the Bezier curve is not supported and needs a curve to polyline conversion. aFilterValue = 0 means no filtering. |
Reimplemented from KIGFX::GAL.
Definition at line 480 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
overridevirtualinherited |
Draw a polygon representing a font glyph.
Reimplemented from KIGFX::GAL.
Definition at line 1833 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIFONT::GLYPH::IsOutline(), KIFONT::GLYPH::IsStroke(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::SetIsFill(), KIGFX::CAIRO_GAL_BASE::SetIsStroke(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), KIFONT::OUTLINE_GLYPH::Triangulate(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
inlineoverridevirtualinherited |
Draw polygons representing font glyphs.
Reimplemented from KIGFX::GAL.
Definition at line 127 of file cairo_gal.h.
|
overridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 1709 of file cairo_gal.cpp.
References KIGFX::GAL::computeMinGridSpacing(), KIGFX::DOTS, KIGFX::CAIRO_GAL_BASE::drawAxes(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), KIGFX::CAIRO_GAL_BASE::drawGridPoint(), KiROUND(), KIGFX::LINES, KIGFX::GAL::m_axesEnabled, KIGFX::GAL::m_depthRange, KIGFX::GAL::m_gridLineWidth, KIGFX::GAL::m_gridOrigin, KIGFX::GAL::m_gridSize, KIGFX::GAL::m_gridStyle, KIGFX::GAL::m_gridTick, KIGFX::GAL::m_gridVisibility, KIGFX::GAL::m_isStrokeEnabled, KIGFX::CAIRO_GAL_BASE::m_lineWidthIsOdd, KIGFX::GAL::m_screenSize, KIGFX::GAL::m_screenWorldMatrix, KIGFX::GAL::m_worldScale, KIGFX::GAL::normalize(), KIGFX::CAIRO_GAL_BASE::SetLayerDepth(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), KIGFX::GAL::SetTarget(), KIGFX::SMALL_CROSS, KIGFX::TARGET_NONCACHED, VECTOR2< T >::x, and VECTOR2< T >::y.
|
protectedinherited |
Definition at line 1080 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_gridColor, KIGFX::CAIRO_GAL_BASE::m_lineWidthInPixels, KIGFX::COLOR4D::r, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
protectedinherited |
Draw a grid line (usually a simplified line function).
aStartPoint | is the start point of the line. |
aEndPoint | is the end point of the line. |
Definition at line 1066 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_gridColor, KIGFX::COLOR4D::r, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
protectedinherited |
Definition at line 1101 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_gridColor, KIGFX::COLOR4D::r, KIGFX::CAIRO_GAL_BASE::roundp(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
overridevirtualinherited |
Draw the stored group.
aGroupNumber | is the group number. |
Reimplemented from KIGFX::GAL.
Definition at line 831 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::CMD_CALL_GROUP, KIGFX::CAIRO_GAL_BASE::CMD_FILL_PATH, KIGFX::CAIRO_GAL_BASE::CMD_RESTORE, KIGFX::CAIRO_GAL_BASE::CMD_ROTATE, KIGFX::CAIRO_GAL_BASE::CMD_SAVE, KIGFX::CAIRO_GAL_BASE::CMD_SCALE, KIGFX::CAIRO_GAL_BASE::CMD_SET_FILL, KIGFX::CAIRO_GAL_BASE::CMD_SET_FILLCOLOR, KIGFX::CAIRO_GAL_BASE::CMD_SET_LINE_WIDTH, KIGFX::CAIRO_GAL_BASE::CMD_SET_STROKE, KIGFX::CAIRO_GAL_BASE::CMD_SET_STROKECOLOR, KIGFX::CAIRO_GAL_BASE::CMD_STROKE_PATH, KIGFX::CAIRO_GAL_BASE::CMD_TRANSLATE, KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_fillColor, KIGFX::CAIRO_GAL_BASE::m_groups, KIGFX::GAL::m_isFillEnabled, KIGFX::GAL::m_isStrokeEnabled, KIGFX::GAL::m_strokeColor, KIGFX::COLOR4D::r, and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGroup().
|
overridevirtualinherited |
Draw a line.
Start and end points are defined as 2D-Vectors.
aStartPoint | is the start point of the line. |
aEndPoint | is the end point of the line. |
Reimplemented from KIGFX::GAL.
Definition at line 200 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
protectedinherited |
Definition at line 1285 of file cairo_gal.cpp.
References SHAPE_LINE_CHAIN::CPoint(), KIGFX::CAIRO_GAL_BASE::flushPath(), SHAPE_LINE_CHAIN::IsClosed(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, SHAPE_LINE_CHAIN::PointCount(), KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
protectedinherited |
Drawing polygons & polylines is the same in Cairo, so here is the common code.
Definition at line 1211 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGlyph(), and KIGFX::CAIRO_GAL_BASE::DrawPolygon().
|
protectedinherited |
Definition at line 1236 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
protectedinherited |
Definition at line 1261 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
overridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 474 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::drawPoly().
|
overridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 467 of file cairo_gal.cpp.
References SHAPE_POLY_SET::COutline(), KIGFX::CAIRO_GAL_BASE::drawPoly(), and SHAPE_POLY_SET::OutlineCount().
|
inlineoverridevirtualinherited |
Draw a polygon.
aPointList | is the list of the polygon points. |
Reimplemented from KIGFX::GAL.
Definition at line 114 of file cairo_gal.h.
|
inlineoverridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 115 of file cairo_gal.h.
|
inlineoverridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 104 of file cairo_gal.h.
|
inlineoverridevirtualinherited |
Draw a polyline.
aPointList | is a list of 2D-Vectors containing the polyline points. |
Reimplemented from KIGFX::GAL.
Definition at line 98 of file cairo_gal.h.
|
inlinevirtualinherited |
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 126 of file graphics_abstraction_layer.h.
|
inlineoverridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 99 of file cairo_gal.h.
|
inlineoverridevirtualinherited |
Draw multiple polylines.
aPointLists | are lists of 2D-Vectors containing the polyline points. |
Reimplemented from KIGFX::GAL.
Definition at line 107 of file cairo_gal.h.
|
inlineinherited |
Definition at line 186 of file graphics_abstraction_layer.h.
References BOX2< Vec >::GetEnd(), and BOX2< Vec >::GetOrigin().
|
overridevirtualinherited |
Draw a rectangle.
aStartPoint | is the start point of the rectangle. |
aEndPoint | is the end point of the rectangle. |
Reimplemented from KIGFX::GAL.
Definition at line 445 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
overridevirtualinherited |
Draw a rounded segment.
Start and end points are defined as 2D-Vectors.
aStartPoint | is the start point of the segment. |
aEndPoint | is the end point of the segment. |
aWidth | is a width of the segment |
Reimplemented from KIGFX::GAL.
Definition at line 257 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_fillColor, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_isFillEnabled, KIGFX::GAL::m_strokeColor, KIGFX::COLOR4D::r, KIGFX::CAIRO_GAL_BASE::roundp(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawSegmentChain().
|
overridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 245 of file cairo_gal.cpp.
References SHAPE_LINE_CHAIN::CPoint(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), SHAPE_LINE_CHAIN::IsClosed(), and SHAPE_LINE_CHAIN::PointCount().
|
overridevirtualinherited |
Draw a chain of rounded segments.
aPointList | is a list of 2D-Vectors containing the chain points. |
aWidth | is a width of the segments |
Reimplemented from KIGFX::GAL.
Definition at line 238 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::DrawSegment().
|
overridevirtualinherited |
Reimplemented from KIGFX::GAL.
Definition at line 1011 of file cairo_gal.cpp.
|
overridevirtual |
Ends rendering of a differential layer.
Objects drawn after the StartDiffLayer() will be drawn and composited with a differential blend mode, then drawing is returned to normal.
Reimplemented from KIGFX::GAL.
Definition at line 986 of file cairo_gal.cpp.
References m_compositor, m_mainBuffer, and m_tempBuffer.
|
overridevirtual |
End the drawing, needs to be called for every new frame.
Use GAL_DRAWING_CONTEXT RAII object unless you know what you're doing.
Reimplemented from KIGFX::CAIRO_GAL_BASE.
Definition at line 1408 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::blitCursor(), deinitSurface(), KIGFX::CAIRO_GAL_BASE::EndDrawing(), m_bitmapBuffer, m_compositor, m_mainBuffer, m_overlayBuffer, KIGFX::GAL::m_screenSize, m_stride, m_wxBufferWidth, m_wxOutput, VECTOR2< T >::x, and VECTOR2< T >::y.
|
overridevirtual |
End the group.
Reimplemented from KIGFX::CAIRO_GAL_BASE.
Definition at line 1503 of file cairo_gal.cpp.
References deinitSurface(), and KIGFX::CAIRO_GAL_BASE::EndGroup().
|
overridevirtual |
Ends rendering of a negatives layer and draws it to the main layer.
No-op in OpenGL.
Reimplemented from KIGFX::GAL.
Definition at line 999 of file cairo_gal.cpp.
References m_compositor, m_mainBuffer, and m_tempBuffer.
|
inlineprotectedvirtualinherited |
Disable item update mode.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 999 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_UPDATE_CONTEXT::~GAL_UPDATE_CONTEXT().
|
overridevirtualinherited |
Force all remaining objects to be drawn.
Reimplemented from KIGFX::GAL.
Definition at line 588 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::EndDrawing().
|
protectedinherited |
Definition at line 1117 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_fillColor, KIGFX::GAL::m_isFillEnabled, KIGFX::GAL::m_isStrokeEnabled, KIGFX::CAIRO_GAL_BASE::m_lineWidthInPixels, KIGFX::GAL::m_strokeColor, and KIGFX::COLOR4D::r.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), and KIGFX::CAIRO_GAL_BASE::DrawSegment().
|
inlineinherited |
Definition at line 263 of file graphics_abstraction_layer.h.
Referenced by EDIT_POINTS::ViewDraw().
|
protectedinherited |
Get the actual cursor color to draw.
Definition at line 244 of file graphics_abstraction_layer.cpp.
References color, KIGFX::GAL::m_cursorColor, and KIGFX::GAL::m_isCursorEnabled.
Referenced by KIGFX::OPENGL_GAL::blitCursor(), and KIGFX::CAIRO_GAL_BASE::blitCursor().
|
inlineinherited |
Get the fill color.
Definition at line 334 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS().
|
inlineinherited |
Definition at line 431 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText().
|
inlineinherited |
Get the grid line width.
Definition at line 880 of file graphics_abstraction_layer.h.
|
inlineinherited |
Definition at line 781 of file graphics_abstraction_layer.h.
Referenced by GRID_HELPER::GetOrigin().
For a given point it returns the nearest point belonging to the grid in world coordinates.
aPoint | is the point for which the grid point is searched. |
Definition at line 222 of file graphics_abstraction_layer.cpp.
References KiROUND(), KIGFX::GAL::m_gridOffset, KIGFX::GAL::m_gridSize, VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::WX_VIEW_CONTROLS::GetRawCursorPosition().
|
inlineinherited |
Return the grid size.
Definition at line 808 of file graphics_abstraction_layer.h.
Referenced by COMMON_TOOLS::CursorControl(), DIALOG_BOARD_REANNOTATE::DIALOG_BOARD_REANNOTATE(), GERBVIEW_FRAME::DisplayGridMsg(), GRID_HELPER::GetGrid(), GRID_HELPER::GetGridSize(), EE_GRID_HELPER::GetGridSize(), PCB_GRID_HELPER::GetGridSize(), EDA_DRAW_FRAME::GetNearestGridPosition(), EDA_DRAW_FRAME::GetNearestHalfGridPosition(), COMMON_TOOLS::PanControl(), and EDA_DRAW_PANEL_GAL::SwitchBackend().
|
inlineinherited |
Definition at line 755 of file graphics_abstraction_layer.h.
References KIGFX::ALWAYS, and KIGFX::WITH_GRID.
Referenced by GRID_HELPER::canUseGrid(), SCH_LINE_WIRE_BUS_TOOL::DrawSegments(), KIGFX::WX_VIEW_CONTROLS::GetRawCursorPosition(), ROUTER_TOOL::InlineBreakTrack(), ROUTER_TOOL::InlineDrag(), PCB_VIEWER_TOOLS::MeasureTool(), POSITION_RELATIVE_TOOL::PositionRelativeInteractively(), PNS::TOOL_BASE::updateEndItem(), and PNS::TOOL_BASE::updateStartItem().
|
inlineinherited |
Definition at line 753 of file graphics_abstraction_layer.h.
Referenced by EDA_DRAW_PANEL_GAL::SwitchBackend().
|
inlineinherited |
Definition at line 450 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText().
|
inlineinherited |
Get the fill status.
Definition at line 294 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS().
|
inlineinherited |
Get the stroke status.
Definition at line 314 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS().
|
inlineprivateinherited |
Definition at line 1116 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS().
|
inlineinherited |
Get the line width.
Definition at line 374 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::BitmapText(), CALLBACK_GAL::DrawGlyph(), KIGFX::OPENGL_GAL::DrawGrid(), ROUTER_PREVIEW_ITEM::drawLineChain(), and KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS().
|
inlineinherited |
Definition at line 617 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GetVisibleWorldExtents().
|
inlineinherited |
Definition at line 638 of file graphics_abstraction_layer.h.
Referenced by NL_SCHEMATIC_PLUGIN_IMPL::GetViewExtents(), NL_GERBVIEW_PLUGIN_IMPL::GetViewExtents(), NL_PL_EDITOR_PLUGIN_IMPL::GetViewExtents(), and NL_PCBNEW_PLUGIN_IMPL::GetViewExtents().
|
inlineinherited |
Definition at line 637 of file graphics_abstraction_layer.h.
Referenced by PNS_PCBNEW_DEBUG_DECORATOR::Clear(), NL_SCHEMATIC_PLUGIN_IMPL::GetViewExtents(), NL_GERBVIEW_PLUGIN_IMPL::GetViewExtents(), NL_PL_EDITOR_PLUGIN_IMPL::GetViewExtents(), NL_PCBNEW_PLUGIN_IMPL::GetViewExtents(), PNS_PCBNEW_DEBUG_DECORATOR::nextDepth(), PNS_PCBNEW_DEBUG_DECORATOR::SetView(), EDIT_POINTS::ViewDraw(), KIGFX::PREVIEW::RULER_ITEM::ViewDraw(), and KIGFX::VIEW_OVERLAY::ViewDraw().
|
protectedinherited |
Return a valid key that can be used as a new group number.
Definition at line 1312 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_groupCounter, and KIGFX::CAIRO_GAL_BASE::m_groups.
Referenced by KIGFX::CAIRO_GAL_BASE::BeginGroup().
|
inlineinherited |
Definition at line 626 of file graphics_abstraction_layer.h.
|
inlineinherited |
Return GAL canvas size in pixels.
Definition at line 247 of file graphics_abstraction_layer.h.
Referenced by KIGFX::WX_VIEW_CONTROLS::CenterOnCursor(), KIGFX::VIEW::GetScreenPixelSize(), KIGFX::VIEW::GetViewport(), EDA_DRAW_PANEL_GAL::onSize(), KIGFX::VIEW::Redraw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), KIGFX::VIEW::SetCenter(), KIGFX::WX_VIEW_CONTROLS::SetCrossHairCursorPosition(), KIGFX::VIEW::SetViewport(), and KIGFX::WX_VIEW_CONTROLS::WarpMouseCursor().
|
inlineinherited |
Get the screen <-> world transformation matrix.
Definition at line 572 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::SCH_PAINTER::getShadowWidth(), KIGFX::GAL::GetVisibleWorldExtents(), KIGFX::OPENGL_GAL::getWorldPixelSize(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), screenSpaceCircle(), screenSpaceLine(), KIGFX::VIEW::ToWorld(), TUNING_STATUS_VIEW_ITEM::ViewDraw(), and ROUTER_STATUS_VIEW_ITEM::ViewDraw().
|
inlineinherited |
Get the stroke color.
Definition at line 354 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PREVIEW::DrawTextNextToCursor(), KIGFX::GAL_SCOPED_ATTRS::GAL_SCOPED_ATTRS(), and KIGFX::PREVIEW::RULER_ITEM::ViewDraw().
|
inlinevirtualinherited |
Return the swap interval. -1 for adaptive, 0 for disabled/unknown.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 253 of file graphics_abstraction_layer.h.
|
overridevirtual |
Get the currently used target for rendering.
Reimplemented from KIGFX::GAL.
Definition at line 1534 of file cairo_gal.cpp.
References m_currentTarget.
|
inlineinherited |
Definition at line 457 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText().
|
inlineinherited |
Return the visible grid size in x and y directions.
Definition at line 818 of file graphics_abstraction_layer.h.
References VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::OPENGL_GAL::DrawGrid(), and GRID_HELPER::GetVisibleGrid().
|
inherited |
Definition at line 199 of file graphics_abstraction_layer.cpp.
References KIGFX::GAL::GetLookAtPoint(), MATRIX3x3< T >::GetScale(), KIGFX::GAL::GetScreenWorldMatrix(), KIGFX::GAL::m_screenSize, BOX2< Vec >::SetOrigin(), BOX2< Vec >::SetSize(), VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by ROUTER_TOOL::handleCommonEvents(), and ROUTER_TOOL::InlineDrag().
|
inlineinherited |
Get the world scale.
Definition at line 645 of file graphics_abstraction_layer.h.
Referenced by EE_GRID_HELPER::BestDragOrigin(), KIGFX::PCB_PAINTER::draw(), KIGFX::SCH_PAINTER::draw(), KIGFX::DrawDashedLine(), KIGFX::PREVIEW::DrawTextNextToCursor(), drawTicksAlongLine(), KIGFX::PREVIEW::GetConstantGlyphHeight(), NL_SCHEMATIC_PLUGIN_IMPL::GetModelExtents(), NL_GERBVIEW_PLUGIN_IMPL::GetModelExtents(), NL_PL_EDITOR_PLUGIN_IMPL::GetModelExtents(), NL_PCBNEW_PLUGIN_IMPL::GetModelExtents(), NL_SCHEMATIC_PLUGIN_IMPL::GetViewExtents(), NL_GERBVIEW_PLUGIN_IMPL::GetViewExtents(), NL_PL_EDITOR_PLUGIN_IMPL::GetViewExtents(), NL_PCBNEW_PLUGIN_IMPL::GetViewExtents(), SCH_BASE_FRAME::RefreshZoomDependentItems(), RATSNEST_VIEW_ITEM::ViewDraw(), and KIGFX::PREVIEW::RULER_ITEM::ViewDraw().
|
inlineinherited |
Get the world <-> screen transformation matrix.
Definition at line 562 of file graphics_abstraction_layer.h.
Referenced by KIGFX::VIEW::ToScreen().
|
inlineinherited |
Definition at line 620 of file graphics_abstraction_layer.h.
Referenced by COMMON_TOOLS::doZoomInOut(), KIGFX::PCB_PAINTER::draw(), EDA_DRAW_FRAME::GetZoomLevelIndicator(), EDA_DRAW_FRAME::OnUpdateSelectZoom(), ZOOM_MENU::update(), and EDA_DRAW_FRAME::UpdateZoomSelectBox().
|
inlinevirtualinherited |
Return true if the target exists.
aTarget | is the target to be checked. |
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 692 of file graphics_abstraction_layer.h.
Referenced by EDA_DRAW_PANEL_GAL::DoRePaint().
void CAIRO_GAL::initSurface | ( | ) |
Prepare Cairo surfaces for drawing.
Definition at line 1562 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::GAL_FORMAT, m_bitmapBuffer, KIGFX::CAIRO_GAL_BASE::m_context, KIGFX::CAIRO_GAL_BASE::m_currentContext, m_isInitialized, KIGFX::GAL::m_screenSize, m_stride, KIGFX::CAIRO_GAL_BASE::m_surface, m_wxBufferWidth, and VECTOR2< T >::y.
Referenced by BeginDrawing(), and BeginGroup().
|
inlineoverridevirtualinherited |
Return true if the GAL engine is a Cairo based type.
Reimplemented from KIGFX::GAL.
Definition at line 65 of file cairo_gal.h.
|
inlinevirtualinherited |
Checks the state of the context lock.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 969 of file graphics_abstraction_layer.h.
Referenced by EDA_DRAW_PANEL_GAL::DoRePaint(), and EDA_DRAW_PANEL_GAL::onSize().
|
inlineinherited |
Return information about cursor visibility.
Definition at line 941 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::blitCursor(), and KIGFX::CAIRO_GAL_BASE::blitCursor().
|
inlineinherited |
Definition at line 659 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::angle_xform(), KIGFX::CAIRO_GAL_BASE::arc_angles_xform_and_normalize(), KIGFX::PCB_PAINTER::draw(), KIGFX::PREVIEW::DrawTextNextToCursor(), DS_PROXY_VIEW_ITEM::ViewDraw(), TUNING_STATUS_VIEW_ITEM::ViewDraw(), and ROUTER_STATUS_VIEW_ITEM::ViewDraw().
|
inlineinherited |
Definition at line 660 of file graphics_abstraction_layer.h.
|
inlineinherited |
Definition at line 434 of file graphics_abstraction_layer.h.
|
inlineinherited |
Definition at line 437 of file graphics_abstraction_layer.h.
|
inlineinherited |
Definition at line 440 of file graphics_abstraction_layer.h.
|
inlinevirtualinherited |
Return the initialization status for the canvas.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 74 of file graphics_abstraction_layer.h.
Referenced by EDA_DRAW_PANEL_GAL::DoRePaint(), EDA_DRAW_PANEL_GAL::ForceRefresh(), SCH_DRAW_PANEL::onPaint(), EDA_DRAW_PANEL_GAL::onShowTimer(), and KIGFX::VIEW::UpdateItems().
|
inlinevirtualinherited |
Return true if the GAL engine is a OpenGL based type.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 83 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), and KIGFX::VIEW::draw().
|
inlineinherited |
Definition at line 443 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText().
|
inlineoverridevirtual |
Return true if the GAL canvas is visible on the screen.
Reimplemented from KIGFX::GAL.
Definition at line 397 of file cairo_gal.h.
|
inlinevirtualinherited |
Use GAL_CONTEXT_LOCKER RAII object unless you know what you're doing.
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 976 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_CONTEXT_LOCKER::GAL_CONTEXT_LOCKER().
|
inlineprotectedinherited |
Ensure that the first element is smaller than the second.
Definition at line 1050 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::arc_angles_xform_and_normalize(), KIGFX::OPENGL_GAL::DrawArc(), KIGFX::OPENGL_GAL::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::OPENGL_GAL::DrawGrid().
|
overrideprotectedvirtualinherited |
Handler for observer settings changes.
Implements KIGFX::GAL_DISPLAY_OPTIONS_OBSERVER.
Definition at line 99 of file graphics_abstraction_layer.cpp.
References KIGFX::GAL::updatedGalDisplayOptions().
void CAIRO_GAL::onPaint | ( | wxPaintEvent & | aEvent | ) |
Paint event handler.
aEvent | is the paint event. |
Definition at line 1639 of file cairo_gal.cpp.
References PostPaint().
Referenced by CAIRO_GAL().
void CAIRO_GAL::onSetNativeCursor | ( | wxSetCursorEvent & | aEvent | ) |
Give the correct cursor image when the native widget asks for it.
aEvent | is the cursor event to plac the cursor into. Cairo-specific update handlers |
Definition at line 1703 of file cairo_gal.cpp.
References m_currentwxCursor.
Referenced by CAIRO_GAL().
void CAIRO_GAL::PostPaint | ( | wxPaintEvent & | aEvent | ) |
Post an event to m_paint_listener.
A post is used so that the actual drawing function can use a device context type that is not specific to the wxEVT_PAINT event, just by changing the PostPaint code.
Definition at line 1460 of file cairo_gal.cpp.
References m_paintListener.
Referenced by onPaint().
|
protectedinherited |
Definition at line 1016 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::ClearScreen(), KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_GAL_BASE::m_cairoWorldScreenMatrix, KIGFX::CAIRO_GAL_BASE::m_context, KIGFX::CAIRO_GAL_BASE::m_currentXform, MATRIX3x3< T >::m_data, KIGFX::CAIRO_GAL_BASE::m_imageSurfaces, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_lineWidth, KIGFX::GAL::m_worldScreenMatrix, and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
Referenced by KIGFX::CAIRO_GAL_BASE::BeginDrawing(), and KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL().
|
inherited |
Reset text attributes to default styling.
FONT TODO: do we need any of this in GAL anymore?
Normally, custom attributes will be set individually after this, otherwise you can use SetTextAttributes()
Definition at line 153 of file graphics_abstraction_layer.cpp.
References GR_TEXT_H_ALIGN_CENTER, GR_TEXT_V_ALIGN_CENTER, KIGFX::GAL::SetFontBold(), KIGFX::GAL::SetFontItalic(), KIGFX::GAL::SetFontUnderlined(), KIGFX::GAL::SetGlyphSize(), KIGFX::GAL::SetHorizontalJustify(), KIGFX::GAL::SetTextMirrored(), and KIGFX::GAL::SetVerticalJustify().
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GAL::GAL(), KIGFX::PREVIEW::ARC_ASSISTANT::ViewDraw(), KIGFX::PREVIEW::BEZIER_ASSISTANT::ViewDraw(), KIGFX::PREVIEW::RULER_ITEM::ViewDraw(), and KIGFX::PREVIEW::TWO_POINT_ASSISTANT::ViewDraw().
|
overridevirtual |
Resizes the canvas.
Reimplemented from KIGFX::CAIRO_GAL_BASE.
Definition at line 1468 of file cairo_gal.cpp.
References allocateBitmaps(), deleteBitmaps(), m_compositor, m_validCompositor, and KIGFX::CAIRO_GAL_BASE::ResizeScreen().
|
overridevirtualinherited |
Restore the context.
Reimplemented from KIGFX::GAL.
Definition at line 786 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_RESTORE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_currentXform, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::CAIRO_GAL_BASE::m_xformStack, KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
|
overridevirtualinherited |
Rotate the context.
aAngle | is the rotation angle in radians. |
Reimplemented from KIGFX::GAL.
Definition at line 709 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_ROTATE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_currentXform, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
Definition at line 191 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_lineWidthIsOdd, KIGFX::CAIRO_GAL_BASE::roundp(), VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::drawAxes(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), KIGFX::CAIRO_GAL_BASE::drawGridPoint(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), and KIGFX::CAIRO_GAL_BASE::roundp().
|
overridevirtualinherited |
Save the context.
Reimplemented from KIGFX::GAL.
Definition at line 768 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_SAVE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_currentXform, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::CAIRO_GAL_BASE::m_xformStack, KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
|
overridevirtualinherited |
Scale the context.
aScale | is the scale factor for the x- and y-axis. |
Reimplemented from KIGFX::GAL.
Definition at line 748 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_SCALE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_currentXform, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::CAIRO_GAL_BASE::storePath(), KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix(), VECTOR2< T >::x, and VECTOR2< T >::y.
|
inlineinherited |
Set the axes color.
aAxesColor | is the color to draw the axes if enabled. |
Definition at line 852 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), SCH_BASE_FRAME::CommonSettingsChanged(), SYMBOL_VIEWER_FRAME::CommonSettingsChanged(), KIGFX::OPENGL_GAL::OPENGL_GAL(), SYMBOL_EDIT_FRAME::SwitchCanvas(), SYMBOL_DIFF_FRAME::SYMBOL_DIFF_FRAME(), and PCB_DRAW_PANEL_GAL::UpdateColors().
|
inlineinherited |
Enable drawing the axes.
Definition at line 860 of file graphics_abstraction_layer.h.
Referenced by FOOTPRINT_EDIT_FRAME::ActivateGalCanvas(), PANEL_EESCHEMA_COLOR_SETTINGS::createSwatches(), PANEL_PCBNEW_COLOR_SETTINGS::createSwatches(), DESIGN_BLOCK_PREVIEW_WIDGET::DESIGN_BLOCK_PREVIEW_WIDGET(), KIGFX::GAL::GAL(), DIALOG_PAD_PROPERTIES::prepareCanvas(), FP_TREE_SYNCHRONIZING_ADAPTER::ShowPreview(), SYMBOL_EDIT_FRAME::SwitchCanvas(), FOOTPRINT_EDIT_FRAME::SwitchCanvas(), and SYMBOL_PREVIEW_WIDGET::SYMBOL_PREVIEW_WIDGET().
|
inlineinherited |
Definition at line 258 of file graphics_abstraction_layer.h.
Referenced by DESIGN_BLOCK_PREVIEW_WIDGET::DESIGN_BLOCK_PREVIEW_WIDGET(), EDA_DRAW_PANEL_GAL::DoRePaint(), BOARD_PRINTOUT::DrawPage(), SCH_PRINTOUT::PrintPage(), SCH_DRAW_PANEL::SCH_DRAW_PANEL(), SYMBOL_PREVIEW_WIDGET::SYMBOL_PREVIEW_WIDGET(), PANEL_EESCHEMA_COLOR_SETTINGS::updatePreview(), and PANEL_PCBNEW_COLOR_SETTINGS::updatePreview().
|
inlineinherited |
Draw every tick line wider.
aInterval | increase the width of every aInterval line, if 0 do not use this feature. |
Definition at line 870 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().
void CAIRO_GAL::setCompositor | ( | ) |
Prepare the compositor.
Definition at line 1623 of file cairo_gal.cpp.
References KIGFX::GAL_DISPLAY_OPTIONS::cairo_antialiasing_mode, m_compositor, KIGFX::CAIRO_GAL_BASE::m_currentContext, m_mainBuffer, KIGFX::GAL::m_options, m_overlayBuffer, KIGFX::GAL::m_screenSize, m_tempBuffer, m_validCompositor, VECTOR2< T >::x, and VECTOR2< T >::y.
Referenced by BeginDrawing().
|
inlineinherited |
Set the cursor color.
aCursorColor | is the color of the cursor. |
Definition at line 951 of file graphics_abstraction_layer.h.
Referenced by EDA_DRAW_PANEL_GAL::DoRePaint(), KIGFX::GAL::GAL(), and PCB_DRAW_PANEL_GAL::UpdateColors().
|
inlineinherited |
Enable/disable cursor.
aCursorEnabled | is true if the cursor should be drawn, else false. |
Definition at line 931 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL(), SCH_PREVIEW_PANEL::SCH_PREVIEW_PANEL(), and KIGFX::VIEW_CONTROLS::ShowCursor().
|
inlineinherited |
Set the range of the layer depth.
Usually required for the OpenGL implementation, any object outside this range is not drawn.
The MinDepth (x) is closest to the clipping plane (top) while the MaxDepth (y) is farthest from the clipping plane (bottom).
Definition at line 636 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().
|
overridevirtualinherited |
Set the fill color.
aColor | is the color for filling. |
Reimplemented from KIGFX::GAL.
Definition at line 650 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::CMD_SET_FILLCOLOR, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::GAL::m_fillColor, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::COLOR4D::r, and KIGFX::CAIRO_GAL_BASE::storePath().
|
inlineinherited |
Sets flipping of the screen.
xAxis | is the flip flag for the X axis. |
yAxis | is the flip flag for the Y axis. |
Definition at line 653 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL(), KIGFX::VIEW::SetMirror(), and BOARD_PRINTOUT::setupGal().
|
inlineinherited |
Definition at line 433 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
inlineinherited |
Definition at line 436 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
inlineinherited |
Definition at line 439 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
inlineinherited |
Definition at line 430 of file graphics_abstraction_layer.h.
Referenced by LABEL_MANAGER::Add(), KIGFX::bitmapText(), KIGFX::SCH_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::VIEW_OVERLAY::COMMAND_GLYPH_SIZE::Execute(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
inlineinherited |
Set the grid color.
aGridColor | is the grid color, it should have a low alpha value for the best effect. |
Definition at line 842 of file graphics_abstraction_layer.h.
Referenced by GERBVIEW_FRAME::ActivateGalCanvas(), KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), EDA_DRAW_PANEL_GAL::DoRePaint(), KIGFX::OPENGL_GAL::OPENGL_GAL(), SCH_PREVIEW_PANEL::SCH_PREVIEW_PANEL(), GERBVIEW_FRAME::SetGridColor(), PCB_EDIT_FRAME::SetGridColor(), and PCB_DRAW_PANEL_GAL::UpdateColors().
|
inlineinherited |
Set the origin point for the grid.
aGridOrigin | is a vector containing the grid origin point, in world coordinates. |
Definition at line 766 of file graphics_abstraction_layer.h.
Referenced by PCB_CONTROL::DoSetGridOrigin(), PCB_EDIT_FRAME::RebuildAndRefresh(), and PCB_BASE_EDIT_FRAME::SetBoard().
|
inlineinherited |
Set the grid size.
aGridSize | is a vector containing the grid size in x and y direction. |
Definition at line 791 of file graphics_abstraction_layer.h.
References VECTOR2< T >::x.
Referenced by COMMON_TOOLS::OnGridChanged(), DIALOG_PAD_PROPERTIES::prepareCanvas(), SCH_PREVIEW_PANEL::SCH_PREVIEW_PANEL(), and EDA_DRAW_PANEL_GAL::SwitchBackend().
|
inlineinherited |
Set the visibility setting of the grid.
aVisibility | is the new visibility setting of the grid. |
Definition at line 751 of file graphics_abstraction_layer.h.
Referenced by DESIGN_BLOCK_PREVIEW_WIDGET::DESIGN_BLOCK_PREVIEW_WIDGET(), KIGFX::GAL::GAL(), COMMON_TOOLS::OnGridChanged(), GERBER_LAYER_WIDGET::OnRenderEnable(), DIALOG_PAD_PROPERTIES::prepareCanvas(), EDA_DRAW_FRAME::SetGridVisibility(), EDA_DRAW_PANEL_GAL::SwitchBackend(), and SYMBOL_PREVIEW_WIDGET::SYMBOL_PREVIEW_WIDGET().
|
inlineinherited |
Definition at line 445 of file graphics_abstraction_layer.h.
Referenced by KIGFX::bitmapText(), KIGFX::SCH_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
overridevirtualinherited |
Enable/disable fill.
aIsFillEnabled | is true, when the graphics objects should be filled, else false. |
Reimplemented from KIGFX::GAL.
Definition at line 602 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::BoolArg, KIGFX::CAIRO_GAL_BASE::CMD_SET_FILL, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::GAL::m_isFillEnabled, KIGFX::CAIRO_GAL_BASE::m_isGrouping, and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGlyph().
|
overridevirtualinherited |
Enable/disable stroked outlines.
aIsStrokeEnabled | is true, if the outline of an object should be stroked. |
Reimplemented from KIGFX::GAL.
Definition at line 617 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::BoolArg, KIGFX::CAIRO_GAL_BASE::CMD_SET_STROKE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::GAL::m_isStrokeEnabled, and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGlyph().
|
overridevirtualinherited |
Set the depth of the layer (position on the z-axis)
If you do this, you should consider using a GAL_SCOPED_ATTR to ensure the depth is reset to the original value.
aLayerDepth | the layer depth for the objects. Smaller is closer to the viewer. |
Reimplemented from KIGFX::GAL.
Definition at line 687 of file cairo_gal.cpp.
References KIGFX::GAL::SetLayerDepth(), and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
overridevirtualinherited |
Set the line width.
aLineWidth | is the line width. |
Reimplemented from KIGFX::GAL.
Definition at line 668 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_SET_LINE_WIDTH, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::GAL::m_lineWidth, KIGFX::GAL::SetLineWidth(), and KIGFX::CAIRO_GAL_BASE::storePath().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::CAIRO_GAL_BASE::DrawSegment().
|
inlineinherited |
Get/set the Point in world space to look at.
This point corresponds with the center of the actual drawing area.
Definition at line 616 of file graphics_abstraction_layer.h.
Referenced by BOARD_PRINTOUT::DrawPage(), KIGFX::GAL::GAL(), SCH_PRINTOUT::PrintPage(), and KIGFX::VIEW::SetCenter().
|
inline |
Definition at line 436 of file cairo_gal.h.
|
overridevirtual |
Set the cursor in the native panel.
aCursor | is the cursor to use in the native panel |
Reimplemented from KIGFX::GAL.
Definition at line 1685 of file cairo_gal.cpp.
References CURSOR_STORE::GetCursor(), CURSOR_STORE::GetHiDPICursor(), KIGFX::GAL::m_currentNativeCursor, m_currentwxCursor, and KIGFX::GAL::SetNativeCursorStyle().
|
overridevirtualinherited |
Set negative draw mode in the renderer.
When negative mode is enabled, drawn items will subtract from previously drawn items. This is mainly needed for Gerber negative item support in Cairo, since unlike in OpenGL, objects drawn with zero opacity on top of other objects would not normally mask objects in Cairo. This method is a no-op in OpenGL.
aSetting | is true if negative mode should be enabled |
Reimplemented from KIGFX::GAL.
Definition at line 973 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_currentContext.
|
inline |
Definition at line 441 of file cairo_gal.h.
|
inlineinherited |
Get/set the rotation angle (in radians).
Definition at line 625 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().
|
inlineinherited |
Set the dots per inch of the screen.
This value depends on the user screen, it should be configurable by the application. For instance a typical notebook with HD+ resolution (1600x900) has 106 DPI.
Definition at line 609 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL(), and KIGFX::GAL::GAL().
|
inlineinherited |
Definition at line 601 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::SetSheetSize().
|
overridevirtualinherited |
Set the stroke color.
aColor | is the color for stroking the outline. |
Reimplemented from KIGFX::GAL.
Definition at line 632 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::CMD_SET_STROKECOLOR, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::GAL::m_strokeColor, KIGFX::COLOR4D::r, and KIGFX::CAIRO_GAL_BASE::storePath().
|
overridevirtual |
Set the target for rendering.
aTarget | is the new target for rendering. |
Reimplemented from KIGFX::GAL.
Definition at line 1510 of file cairo_gal.cpp.
References m_compositor, m_currentTarget, m_isInitialized, m_mainBuffer, m_overlayBuffer, m_tempBuffer, m_validCompositor, KIGFX::CAIRO_GAL_BASE::storePath(), KIGFX::TARGET_CACHED, KIGFX::TARGET_NONCACHED, KIGFX::TARGET_OVERLAY, and KIGFX::TARGET_TEMP.
Referenced by CAIRO_GAL(), StartDiffLayer(), and StartNegativesLayer().
|
inlineinherited |
Definition at line 442 of file graphics_abstraction_layer.h.
Referenced by KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), KIGFX::GAL::ResetTextAttributes(), and KIGFX::PREVIEW::RULER_ITEM::ViewDraw().
|
inlineinherited |
Definition at line 452 of file graphics_abstraction_layer.h.
Referenced by KIGFX::bitmapText(), KIGFX::SCH_PAINTER::draw(), KIGFX::PCB_PAINTER::draw(), KIGFX::GERBVIEW_PAINTER::draw(), KIGFX::PCB_PAINTER::renderNetNameForSegment(), and KIGFX::GAL::ResetTextAttributes().
|
inlineinherited |
Set the world <-> screen transformation matrix.
aMatrix | is the 3x3 world <-> screen transformation matrix. |
Definition at line 582 of file graphics_abstraction_layer.h.
|
inlineinherited |
Set the unit length.
This defines the length [inch] per one integer. For instance a value 0.001 means that the coordinate [1000, 1000] corresponds with a point at (1 inch, 1 inch) or 1 mil resolution per integer.
Definition at line 599 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL(), GERBVIEW_DRAW_PANEL_GAL::GERBVIEW_DRAW_PANEL_GAL(), PL_DRAW_PANEL_GAL::PL_DRAW_PANEL_GAL(), SCH_PRINTOUT::PrintPage(), SCH_DRAW_PANEL::SCH_DRAW_PANEL(), SCH_PREVIEW_PANEL::SCH_PREVIEW_PANEL(), GERBVIEW_PRINTOUT::setupGal(), PCBNEW_PRINTOUT::setupGal(), SCH_DRAW_PANEL::SwitchBackend(), GERBVIEW_DRAW_PANEL_GAL::SwitchBackend(), PL_DRAW_PANEL_GAL::SwitchBackend(), and PCB_DRAW_PANEL_GAL::SwitchBackend().
|
inlineinherited |
Definition at line 619 of file graphics_abstraction_layer.h.
Referenced by BOARD_PRINTOUT::DrawPage(), KIGFX::GAL::GAL(), SCH_PRINTOUT::PrintPage(), and KIGFX::VIEW::SetScale().
|
overridevirtual |
Show/hide the GAL canvas.
Reimplemented from KIGFX::GAL.
Definition at line 1485 of file cairo_gal.cpp.
void CAIRO_GAL::skipGestureEvent | ( | wxGestureEvent & | aEvent | ) |
Skip the gesture event to the parent.
aEvent | is the gesture event. |
Definition at line 1653 of file cairo_gal.cpp.
References m_mouseListener.
Referenced by CAIRO_GAL().
void CAIRO_GAL::skipMouseEvent | ( | wxMouseEvent & | aEvent | ) |
Mouse event handler, forwards the event to the child.
aEvent | is the mouse event to be forwarded. |
Definition at line 1645 of file cairo_gal.cpp.
References m_mouseListener.
Referenced by CAIRO_GAL().
|
overridevirtual |
Begins rendering of a differential layer.
Used by gerbview's differential mode.
Differential layers have their drawn objects blended onto the lower layers differently so we need to end drawing of current objects and start a new set to be completed with a different blend mode.
Reimplemented from KIGFX::GAL.
Definition at line 979 of file cairo_gal.cpp.
References ClearTarget(), SetTarget(), and KIGFX::TARGET_TEMP.
|
overridevirtual |
Begins rendering in a new layer that will be copied to the main layer in EndNegativesLayer().
For Cairo, layers with negative items need a new layer so when negative layers _CLEAR sections it doesn't delete drawings on layers below them. No-op in OpenGL
Reimplemented from KIGFX::GAL.
Definition at line 992 of file cairo_gal.cpp.
References ClearTarget(), SetTarget(), and KIGFX::TARGET_TEMP.
|
protectedinherited |
Store the actual path.
Definition at line 1145 of file cairo_gal.cpp.
References KIGFX::COLOR4D::a, KIGFX::COLOR4D::b, KIGFX::CAIRO_GAL_BASE::CMD_FILL_PATH, KIGFX::CAIRO_GAL_BASE::CMD_STROKE_PATH, KIGFX::COLOR4D::g, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_CairoPath, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::GAL::m_fillColor, KIGFX::CAIRO_GAL_BASE::m_isElementAdded, KIGFX::GAL::m_isFillEnabled, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::GAL::m_isStrokeEnabled, KIGFX::GAL::m_strokeColor, and KIGFX::COLOR4D::r.
Referenced by KIGFX::CAIRO_GAL_BASE::BeginGroup(), KIGFX::CAIRO_GAL_BASE::ChangeGroupColor(), KIGFX::CAIRO_GAL_BASE::DeleteGroup(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::CAIRO_GAL_BASE::EndGroup(), KIGFX::CAIRO_GAL_BASE::Flush(), KIGFX::CAIRO_GAL_BASE::Restore(), KIGFX::CAIRO_GAL_BASE::Rotate(), KIGFX::CAIRO_GAL_BASE::Save(), KIGFX::CAIRO_GAL_BASE::Scale(), KIGFX::CAIRO_GAL_BASE::SetFillColor(), KIGFX::CAIRO_GAL_BASE::SetIsFill(), KIGFX::CAIRO_GAL_BASE::SetIsStroke(), KIGFX::CAIRO_GAL_BASE::SetLayerDepth(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), KIGFX::CAIRO_GAL_BASE::SetStrokeColor(), SetTarget(), and KIGFX::CAIRO_GAL_BASE::Translate().
|
protectedinherited |
Definition at line 214 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_currentContext, KIGFX::GAL::m_lineWidth, KIGFX::CAIRO_GAL_BASE::m_lineWidthInPixels, KIGFX::CAIRO_GAL_BASE::m_lineWidthIsOdd, and KIGFX::CAIRO_GAL_BASE::xform().
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::drawAxes(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), and KIGFX::CAIRO_GAL_BASE::DrawSegment().
Compute the point position in screen coordinates from given world coordinates.
aPoint | the point position in world coordinates. |
Definition at line 913 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::blitCursor().
Compute the point position in world coordinates from given screen coordinates.
aPoint | the point position in screen coordinates. |
Definition at line 902 of file graphics_abstraction_layer.h.
|
overridevirtualinherited |
Transform the context.
aTransformation | is the transformation matrix. |
Reimplemented from KIGFX::GAL.
Definition at line 694 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_currentXform, MATRIX3x3< T >::m_data, and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
|
overridevirtualinherited |
Translate the context.
aTranslation | is the translation vector. |
Reimplemented from KIGFX::GAL.
Definition at line 728 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::CMD_TRANSLATE, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::DblArg, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Argument, KIGFX::CAIRO_GAL_BASE::GROUP_ELEMENT::m_Command, KIGFX::CAIRO_GAL_BASE::m_currentGroup, KIGFX::CAIRO_GAL_BASE::m_currentXform, KIGFX::CAIRO_GAL_BASE::m_isGrouping, KIGFX::CAIRO_GAL_BASE::storePath(), KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix(), VECTOR2< T >::x, and VECTOR2< T >::y.
|
inlinevirtualinherited |
Reimplemented in KIGFX::OPENGL_GAL.
Definition at line 978 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL_CONTEXT_LOCKER::~GAL_CONTEXT_LOCKER().
|
overridevirtual |
Handle updating display options.
Derived classes should call up to this to set base-class methods.
Reimplemented from KIGFX::GAL.
Definition at line 1661 of file cairo_gal.cpp.
References KIGFX::GAL_DISPLAY_OPTIONS::cairo_antialiasing_mode, deinitSurface(), m_compositor, KIGFX::GAL::m_options, m_validCompositor, refresh, Refresh(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
Definition at line 107 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_cairoWorldScreenMatrix, KIGFX::CAIRO_GAL_BASE::m_currentWorld2Screen, and KIGFX::CAIRO_GAL_BASE::m_currentXform.
Referenced by KIGFX::CAIRO_GAL_BASE::resetContext(), KIGFX::CAIRO_GAL_BASE::Restore(), KIGFX::CAIRO_GAL_BASE::Rotate(), KIGFX::CAIRO_GAL_BASE::Save(), KIGFX::CAIRO_GAL_BASE::Scale(), KIGFX::CAIRO_GAL_BASE::Transform(), and KIGFX::CAIRO_GAL_BASE::Translate().
Definition at line 123 of file cairo_gal.cpp.
References VECTOR2< T >::x, KIGFX::CAIRO_GAL_BASE::xform(), and VECTOR2< T >::y.
|
protectedinherited |
Definition at line 177 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_currentWorld2Screen.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::drawAxes(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), KIGFX::CAIRO_GAL_BASE::drawGridPoint(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::CAIRO_GAL_BASE::syncLineWidth(), and KIGFX::CAIRO_GAL_BASE::xform().
|
protectedinherited |
Definition at line 113 of file cairo_gal.cpp.
References KIGFX::CAIRO_GAL_BASE::m_currentWorld2Screen, VECTOR2< T >::x, and VECTOR2< T >::y.
|
staticconstexprprotectedinherited |
Format used to store pixels.
Definition at line 372 of file cairo_gal.h.
Referenced by allocateBitmaps(), and initSurface().
|
staticprotectedinherited |
Depth level on which the grid is drawn.
Definition at line 1021 of file graphics_abstraction_layer.h.
|
privateinherited |
Definition at line 1121 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::BitmapText().
|
protectedinherited |
Color of the axes.
Definition at line 1098 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::drawAxes(), and KIGFX::OPENGL_GAL::DrawGrid().
|
protectedinherited |
Should the axes be drawn.
Definition at line 1099 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::OPENGL_GAL::DrawGrid(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protected |
Background color.
Definition at line 524 of file cairo_gal.h.
|
protected |
Storage of the Cairo image.
Definition at line 520 of file cairo_gal.h.
Referenced by allocateBitmaps(), CAIRO_GAL(), deleteBitmaps(), EndDrawing(), and initSurface().
|
protected |
Size of buffers cairoOutput, bitmapBuffers.
Definition at line 516 of file cairo_gal.h.
Referenced by allocateBitmaps().
|
protectedinherited |
Cairo world to screen transform matrix.
Definition at line 360 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::resetContext(), and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
|
protectedinherited |
Definition at line 1086 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL(), KIGFX::CAIRO_GAL_BASE::ClearScreen(), and KIGFX::OPENGL_GAL::ClearTarget().
|
protected |
Object for layers compositing.
Definition at line 504 of file cairo_gal.h.
Referenced by BeginDrawing(), ClearTarget(), EndDiffLayer(), EndDrawing(), EndNegativesLayer(), ResizeScreen(), setCompositor(), SetTarget(), and updatedGalDisplayOptions().
|
protectedinherited |
Cairo image.
Definition at line 364 of file cairo_gal.h.
Referenced by BeginDrawing(), KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL(), deinitSurface(), initSurface(), KIGFX::CAIRO_GAL_BASE::resetContext(), and KIGFX::CAIRO_GAL_BASE::~CAIRO_GAL_BASE().
|
protectedinherited |
Currently used Cairo context for drawing.
Definition at line 363 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL(), KIGFX::CAIRO_GAL_BASE::ClearScreen(), KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::drawAxes(), KIGFX::CAIRO_GAL_BASE::DrawBitmap(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), KIGFX::CAIRO_GAL_BASE::drawGridPoint(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::CAIRO_GAL_BASE::flushPath(), initSurface(), setCompositor(), KIGFX::CAIRO_GAL_BASE::SetNegativeDrawMode(), KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::syncLineWidth().
|
protectedinherited |
Currently used group.
Definition at line 355 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::BeginGroup(), KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::Restore(), KIGFX::CAIRO_GAL_BASE::Rotate(), KIGFX::CAIRO_GAL_BASE::Save(), KIGFX::CAIRO_GAL_BASE::Scale(), KIGFX::CAIRO_GAL_BASE::SetFillColor(), KIGFX::CAIRO_GAL_BASE::SetIsFill(), KIGFX::CAIRO_GAL_BASE::SetIsStroke(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), KIGFX::CAIRO_GAL_BASE::SetStrokeColor(), KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::Translate().
|
protectedinherited |
Current cursor.
Definition at line 1112 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::SetNativeCursorStyle(), SetNativeCursorStyle(), and KIGFX::OPENGL_GAL::SetNativeCursorStyle().
|
protected |
Current rendering target.
Definition at line 509 of file cairo_gal.h.
Referenced by CAIRO_GAL(), GetTarget(), and SetTarget().
|
protectedinherited |
Definition at line 362 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::angle_xform(), KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::DrawBitmap(), KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix(), and KIGFX::CAIRO_GAL_BASE::xform().
|
protected |
wxCursor showing the current native cursor
Definition at line 525 of file cairo_gal.h.
Referenced by onSetNativeCursor(), and SetNativeCursorStyle().
|
protectedinherited |
Definition at line 361 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::resetContext(), KIGFX::CAIRO_GAL_BASE::Restore(), KIGFX::CAIRO_GAL_BASE::Rotate(), KIGFX::CAIRO_GAL_BASE::Save(), KIGFX::CAIRO_GAL_BASE::Scale(), KIGFX::CAIRO_GAL_BASE::Transform(), KIGFX::CAIRO_GAL_BASE::Translate(), and KIGFX::CAIRO_GAL_BASE::updateWorldScreenMatrix().
|
protectedinherited |
Cursor color.
Definition at line 1108 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::getCursorColor().
|
protectedinherited |
Current cursor position (world coordinates)
Definition at line 1110 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::blitCursor(), KIGFX::CAIRO_GAL_BASE::blitCursor(), KIGFX::CAIRO_GAL_BASE::DrawCursor(), and KIGFX::OPENGL_GAL::DrawCursor().
|
protectedinherited |
Range of the depth.
Definition at line 1089 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BeginDrawing(), and KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
protectedinherited |
Stored depth values.
Definition at line 1063 of file graphics_abstraction_layer.h.
|
protectedinherited |
The fill color.
Definition at line 1084 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BeginDrawing(), KIGFX::OPENGL_GAL::DrawArc(), KIGFX::OPENGL_GAL::DrawArcSegment(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::OPENGL_GAL::DrawGlyph(), KIGFX::OPENGL_GAL::DrawGlyphs(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::OPENGL_GAL::drawPolygon(), KIGFX::OPENGL_GAL::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::OPENGL_GAL::drawSegment(), KIGFX::OPENGL_GAL::drawSemiCircle(), KIGFX::OPENGL_GAL::drawTriangulatedPolyset(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::SetFillColor(), and KIGFX::CAIRO_GAL_BASE::storePath().
|
protectedinherited |
Always show cursor.
Definition at line 1107 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
Shape of the cursor (fullscreen or small cross)
Definition at line 1109 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::blitCursor(), KIGFX::CAIRO_GAL_BASE::blitCursor(), KIGFX::GAL::GAL(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
Flag for X axis flipping.
Definition at line 1076 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::BitmapText(), KIGFX::OPENGL_GAL::BitmapText(), KIGFX::GAL::ComputeWorldScreenMatrix(), and KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix().
|
protectedinherited |
Flag for Y axis flipping.
Definition at line 1077 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText(), KIGFX::GAL::ComputeWorldScreenMatrix(), and KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix().
|
protectedinherited |
Color of the grid.
Definition at line 1097 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::DrawGrid(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::drawGridLine(), and KIGFX::CAIRO_GAL_BASE::drawGridPoint().
|
protectedinherited |
Line width of the grid.
Definition at line 1101 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::OPENGL_GAL::DrawGrid(), KIGFX::GAL::GAL(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
Minimum screen size of the grid (pixels) below which the grid is not drawn.
Definition at line 1102 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::computeMinGridSpacing(), KIGFX::GAL::GAL(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
The grid offset to compensate cursor position.
Definition at line 1096 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GetGridPoint().
|
protectedinherited |
The grid origin.
Definition at line 1095 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::OPENGL_GAL::DrawGrid().
|
protectedinherited |
The grid size.
Definition at line 1094 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::OPENGL_GAL::DrawGrid(), and KIGFX::GAL::GetGridPoint().
|
protectedinherited |
Grid display style.
Definition at line 1093 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::OPENGL_GAL::DrawGrid(), KIGFX::GAL::GAL(), and KIGFX::GAL::updatedGalDisplayOptions().
|
protectedinherited |
Every tick line gets the double width.
Definition at line 1100 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::OPENGL_GAL::DrawGrid().
|
protectedinherited |
Should the grid be shown.
Definition at line 1092 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::OPENGL_GAL::DrawGrid().
|
protectedinherited |
Counter used for generating group keys.
Definition at line 354 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), and KIGFX::CAIRO_GAL_BASE::getNewGroupNumber().
|
protectedinherited |
List of graphic groups.
Definition at line 353 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::BeginGroup(), KIGFX::CAIRO_GAL_BASE::ChangeGroupColor(), KIGFX::CAIRO_GAL_BASE::ClearCache(), KIGFX::CAIRO_GAL_BASE::DeleteGroup(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), and KIGFX::CAIRO_GAL_BASE::getNewGroupNumber().
|
protectedinherited |
List of surfaces that were created by painting images, to be cleaned up later.
Definition at line 368 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawBitmap(), KIGFX::CAIRO_GAL_BASE::resetContext(), and KIGFX::CAIRO_GAL_BASE::~CAIRO_GAL_BASE().
|
protectedinherited |
Is the cursor enabled?
Definition at line 1106 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::getCursorColor().
|
protectedinherited |
Was an graphic element added ?
Definition at line 352 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::CAIRO_GAL_BASE::DrawBitmap(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::DrawCurve(), KIGFX::CAIRO_GAL_BASE::DrawGlyph(), KIGFX::CAIRO_GAL_BASE::DrawLine(), KIGFX::CAIRO_GAL_BASE::drawPoly(), KIGFX::CAIRO_GAL_BASE::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::CAIRO_GAL_BASE::resetContext(), and KIGFX::CAIRO_GAL_BASE::storePath().
|
protectedinherited |
Is filling of graphic objects enabled ?
Definition at line 1081 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::OPENGL_GAL::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::OPENGL_GAL::DrawArcSegment(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::OPENGL_GAL::drawPolygon(), KIGFX::OPENGL_GAL::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::OPENGL_GAL::drawSegment(), KIGFX::OPENGL_GAL::drawSegmentChain(), KIGFX::OPENGL_GAL::drawSemiCircle(), KIGFX::OPENGL_GAL::drawTriangulatedPolyset(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::SetIsFill(), and KIGFX::CAIRO_GAL_BASE::storePath().
|
protectedinherited |
Is grouping enabled ?
Definition at line 351 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::BeginGroup(), KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::EndGroup(), KIGFX::CAIRO_GAL_BASE::Restore(), KIGFX::CAIRO_GAL_BASE::Rotate(), KIGFX::CAIRO_GAL_BASE::Save(), KIGFX::CAIRO_GAL_BASE::Scale(), KIGFX::CAIRO_GAL_BASE::SetFillColor(), KIGFX::CAIRO_GAL_BASE::SetIsFill(), KIGFX::CAIRO_GAL_BASE::SetIsStroke(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), KIGFX::CAIRO_GAL_BASE::SetStrokeColor(), KIGFX::CAIRO_GAL_BASE::storePath(), and KIGFX::CAIRO_GAL_BASE::Translate().
|
protected |
Are Cairo image & surface ready to use.
Definition at line 523 of file cairo_gal.h.
Referenced by CAIRO_GAL(), deinitSurface(), initSurface(), and SetTarget().
|
protectedinherited |
Are the outlines stroked ?
Definition at line 1082 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::OPENGL_GAL::DrawArcSegment(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::OPENGL_GAL::drawPolygon(), KIGFX::OPENGL_GAL::DrawRectangle(), KIGFX::OPENGL_GAL::drawSemiCircle(), KIGFX::OPENGL_GAL::drawTriangulatedPolyset(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::SetIsStroke(), and KIGFX::CAIRO_GAL_BASE::storePath().
|
protectedinherited |
The actual layer depth.
Definition at line 1088 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BitmapText(), KIGFX::OPENGL_GAL::DrawArc(), KIGFX::OPENGL_GAL::DrawBitmap(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::OPENGL_GAL::drawFilledSemiCircle(), KIGFX::OPENGL_GAL::DrawGlyph(), KIGFX::OPENGL_GAL::DrawGlyphs(), KIGFX::OPENGL_GAL::drawLineQuad(), KIGFX::OPENGL_GAL::DrawPolygon(), KIGFX::OPENGL_GAL::DrawRectangle(), KIGFX::OPENGL_GAL::drawStrokedSemiCircle(), and KIGFX::OPENGL_GAL::drawTriangulatedPolyset().
|
protectedinherited |
The line width.
Definition at line 1079 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::OPENGL_GAL::drawLineQuad(), KIGFX::OPENGL_GAL::drawStrokedSemiCircle(), KIGFX::CAIRO_GAL_BASE::resetContext(), KIGFX::CAIRO_GAL_BASE::SetLineWidth(), and KIGFX::CAIRO_GAL_BASE::syncLineWidth().
|
protectedinherited |
Definition at line 357 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawCircle(), KIGFX::CAIRO_GAL_BASE::drawGridCross(), KIGFX::CAIRO_GAL_BASE::flushPath(), and KIGFX::CAIRO_GAL_BASE::syncLineWidth().
|
protectedinherited |
Definition at line 358 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::CAIRO_GAL_BASE::roundp(), and KIGFX::CAIRO_GAL_BASE::syncLineWidth().
|
protectedinherited |
Point to be looked at in world space.
Definition at line 1068 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), and KIGFX::OPENGL_GAL::ComputeWorldScreenMatrix().
|
protected |
Handle to the main buffer.
Definition at line 505 of file cairo_gal.h.
Referenced by BeginDrawing(), CAIRO_GAL(), ClearTarget(), EndDiffLayer(), EndDrawing(), EndNegativesLayer(), setCompositor(), and SetTarget().
|
protected |
Mouse listener.
Definition at line 514 of file cairo_gal.h.
Referenced by CAIRO_GAL(), skipGestureEvent(), and skipMouseEvent().
|
protectedinherited |
Definition at line 1061 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().
|
protectedinherited |
Definition at line 1060 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL(), KIGFX::OPENGL_GAL::OPENGL_GAL(), setCompositor(), KIGFX::GAL::updatedGalDisplayOptions(), updatedGalDisplayOptions(), and KIGFX::OPENGL_GAL::updatedGalDisplayOptions().
|
protected |
Handle to the overlay buffer.
Definition at line 506 of file cairo_gal.h.
Referenced by CAIRO_GAL(), ClearTarget(), EndDrawing(), setCompositor(), and SetTarget().
|
protected |
Paint listener.
Definition at line 515 of file cairo_gal.h.
Referenced by CAIRO_GAL(), and PostPaint().
|
protected |
|
protectedinherited |
Rotation transformation (radians)
Definition at line 1071 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::ComputeWorldScreenMatrix().
|
protected |
Handle to buffer to restore after rendering to temp buffer.
Definition at line 508 of file cairo_gal.h.
Referenced by CAIRO_GAL().
|
protectedinherited |
The dots per inch of the screen.
Definition at line 1067 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), and KIGFX::CAIRO_PRINT_GAL::SetSheetSize().
|
protectedinherited |
Screen size in screen (wx logical) coordinates.
Definition at line 1064 of file graphics_abstraction_layer.h.
Referenced by allocateBitmaps(), KIGFX::OPENGL_GAL::BeginDrawing(), CAIRO_GAL(), KIGFX::CAIRO_GAL_BASE::ClearScreen(), KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_GAL_BASE::DrawGrid(), KIGFX::OPENGL_GAL::DrawGrid(), EndDrawing(), KIGFX::OPENGL_GAL::getScreenPixelSize(), KIGFX::GAL::GetVisibleWorldExtents(), initSurface(), KIGFX::OPENGL_GAL::OPENGL_GAL(), KIGFX::CAIRO_GAL_BASE::ResizeScreen(), KIGFX::OPENGL_GAL::ResizeScreen(), and setCompositor().
|
protectedinherited |
Screen transformation.
Definition at line 1073 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_GAL_BASE::DrawGrid(), and KIGFX::OPENGL_GAL::DrawGrid().
|
protected |
Stride value for Cairo.
Definition at line 521 of file cairo_gal.h.
Referenced by allocateBitmaps(), EndDrawing(), and initSurface().
|
protectedinherited |
The color of the outlines.
Definition at line 1085 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BeginDrawing(), KIGFX::OPENGL_GAL::BitmapText(), KIGFX::OPENGL_GAL::DrawArc(), KIGFX::CAIRO_GAL_BASE::DrawArcSegment(), KIGFX::OPENGL_GAL::DrawArcSegment(), KIGFX::OPENGL_GAL::drawBitmapOverbar(), KIGFX::OPENGL_GAL::drawCircle(), KIGFX::CAIRO_GAL_BASE::DrawGroup(), KIGFX::OPENGL_GAL::DrawLine(), KIGFX::OPENGL_GAL::drawPolyline(), KIGFX::OPENGL_GAL::DrawRectangle(), KIGFX::CAIRO_GAL_BASE::DrawSegment(), KIGFX::OPENGL_GAL::drawSegment(), KIGFX::OPENGL_GAL::drawSegmentChain(), KIGFX::OPENGL_GAL::drawSemiCircle(), KIGFX::CAIRO_GAL_BASE::flushPath(), KIGFX::CAIRO_GAL_BASE::SetStrokeColor(), and KIGFX::CAIRO_GAL_BASE::storePath().
|
protectedinherited |
Cairo surface.
Definition at line 365 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::CAIRO_GAL_BASE(), KIGFX::CAIRO_PRINT_GAL::CAIRO_PRINT_GAL(), deinitSurface(), initSurface(), and KIGFX::CAIRO_GAL_BASE::~CAIRO_GAL_BASE().
|
protected |
Handle to the temp buffer.
Definition at line 507 of file cairo_gal.h.
Referenced by CAIRO_GAL(), ClearTarget(), EndDiffLayer(), EndNegativesLayer(), setCompositor(), and SetTarget().
|
protected |
Compositor initialization flag.
Definition at line 510 of file cairo_gal.h.
Referenced by BeginDrawing(), CAIRO_GAL(), ResizeScreen(), setCompositor(), SetTarget(), and updatedGalDisplayOptions().
|
protectedinherited |
The scale factor world->screen.
Definition at line 1074 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::blitCursor(), KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), KIGFX::OPENGL_GAL::ComputeWorldScreenMatrix(), and KIGFX::CAIRO_GAL_BASE::DrawGrid().
|
protectedinherited |
World transformation.
Definition at line 1072 of file graphics_abstraction_layer.h.
Referenced by KIGFX::OPENGL_GAL::BeginDrawing(), KIGFX::GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), and KIGFX::CAIRO_GAL_BASE::resetContext().
|
protectedinherited |
The unit length of the world coordinates [inch].
Definition at line 1066 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix(), KIGFX::CAIRO_GAL_BASE::DrawBitmap(), and KIGFX::OPENGL_GAL::DrawBitmap().
|
protected |
Definition at line 522 of file cairo_gal.h.
Referenced by allocateBitmaps(), EndDrawing(), and initSurface().
|
protected |
wxImage compatible buffer
Definition at line 517 of file cairo_gal.h.
Referenced by allocateBitmaps(), CAIRO_GAL(), deleteBitmaps(), and EndDrawing().
|
protectedinherited |
Definition at line 370 of file cairo_gal.h.
Referenced by KIGFX::CAIRO_GAL_BASE::Restore(), and KIGFX::CAIRO_GAL_BASE::Save().
|
protectedinherited |
The zoom factor.
Definition at line 1070 of file graphics_abstraction_layer.h.
Referenced by KIGFX::CAIRO_PRINT_GAL::ComputeWorldScreenMatrix().
|
staticprotectedinherited |
Maximum number of arguments for one command.
Definition at line 315 of file cairo_gal.h.
|
staticprotectedinherited |
Definition at line 1018 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().
|
staticprotectedinherited |
Possible depth range.
Definition at line 1017 of file graphics_abstraction_layer.h.
Referenced by KIGFX::GAL::GAL().