KiCad PCB EDA Suite
Loading...
Searching...
No Matches
VIEW_OVERLAY Class Reference

#include <view_overlay.h>

Inheritance diagram for VIEW_OVERLAY:
KIGFX::VIEW_ITEM INSPECTABLE PNS_LOG_VIEWER_OVERLAY

Classes

struct  COMMAND
 
struct  COMMAND_ARC
 
struct  COMMAND_BITMAP_TEXT
 
struct  COMMAND_CIRCLE
 
struct  COMMAND_GLYPH_SIZE
 
struct  COMMAND_LINE
 
struct  COMMAND_POINT_POLYGON
 
struct  COMMAND_POLY_POLYGON
 
struct  COMMAND_POLYGON
 
struct  COMMAND_RECTANGLE
 
struct  COMMAND_SET_COLOR
 
struct  COMMAND_SET_FILL
 
struct  COMMAND_SET_STROKE
 
struct  COMMAND_SET_WIDTH
 

Public Member Functions

 VIEW_OVERLAY ()
 
 VIEW_OVERLAY (const VIEW_OVERLAY &)=delete
 
virtual ~VIEW_OVERLAY ()
 
VIEW_OVERLAYoperator= (const VIEW_OVERLAY &)=delete
 
wxString GetClass () const override
 Return the class name.
 
void Clear ()
 
virtual const BOX2I ViewBBox () const override
 Return the bounding box of the item covering all its layers.
 
virtual void ViewDraw (int aLayer, VIEW *aView) const override
 Draw the parts of the object belonging to layer aLayer.
 
virtual std::vector< int > ViewGetLayers () const override
 Return the all the layers within the VIEW the object is painted on.
 
void Line (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint)
 
void Line (const SEG &aSeg)
 
void Segment (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint, double aWidth)
 
void Circle (const VECTOR2D &aCenterPoint, double aRadius)
 
void Arc (const VECTOR2D &aCenterPoint, double aRadius, const EDA_ANGLE &aStartAngle, const EDA_ANGLE &aEndAngle)
 
void Rectangle (const VECTOR2D &aStartPoint, const VECTOR2D &aEndPoint)
 
void Cross (const VECTOR2D &aP, int aSize)
 
void Polygon (const std::deque< VECTOR2D > &aPointList)
 
void Polygon (const SHAPE_POLY_SET &aPolySet)
 
void Polygon (const VECTOR2D aPointList[], int aListSize)
 
void Polyline (const SHAPE_LINE_CHAIN &aPolyLine)
 
void BitmapText (const wxString &aText, const VECTOR2I &aPosition, const EDA_ANGLE &aAngle)
 
void SetIsFill (bool aIsFillEnabled)
 
void SetIsStroke (bool aIsStrokeEnabled)
 
void SetFillColor (const COLOR4D &aColor)
 
void SetStrokeColor (const COLOR4D &aColor)
 
void SetGlyphSize (const VECTOR2I &aSize)
 
void SetLineWidth (double aLineWidth)
 
const COLOR4DGetStrokeColor () const
 
const COLOR4DGetFillColor () const
 

Private Member Functions

void releaseCommands ()
 

Private Attributes

COLOR4D m_strokeColor
 
COLOR4D m_fillColor
 
std::vector< COMMAND * > m_commands
 

Detailed Description

Definition at line 39 of file view_overlay.h.

Constructor & Destructor Documentation

◆ VIEW_OVERLAY() [1/2]

KIGFX::VIEW_OVERLAY::VIEW_OVERLAY ( )

Definition at line 261 of file view_overlay.cpp.

◆ VIEW_OVERLAY() [2/2]

KIGFX::VIEW_OVERLAY::VIEW_OVERLAY ( const VIEW_OVERLAY & )
delete

◆ ~VIEW_OVERLAY()

KIGFX::VIEW_OVERLAY::~VIEW_OVERLAY ( )
virtual

Definition at line 266 of file view_overlay.cpp.

Member Function Documentation

◆ Arc()

void KIGFX::VIEW_OVERLAY::Arc ( const VECTOR2D & aCenterPoint,
double aRadius,
const EDA_ANGLE & aStartAngle,
const EDA_ANGLE & aEndAngle )

Definition at line 373 of file view_overlay.cpp.

◆ BitmapText()

void KIGFX::VIEW_OVERLAY::BitmapText ( const wxString & aText,
const VECTOR2I & aPosition,
const EDA_ANGLE & aAngle )

Definition at line 398 of file view_overlay.cpp.

◆ Circle()

void KIGFX::VIEW_OVERLAY::Circle ( const VECTOR2D & aCenterPoint,
double aRadius )

Definition at line 367 of file view_overlay.cpp.

◆ Clear()

void KIGFX::VIEW_OVERLAY::Clear ( )

Definition at line 287 of file view_overlay.cpp.

◆ Cross()

void KIGFX::VIEW_OVERLAY::Cross ( const VECTOR2D & aP,
int aSize )

Definition at line 431 of file view_overlay.cpp.

◆ GetClass()

wxString KIGFX::VIEW_OVERLAY::GetClass ( ) const
overridevirtual

Return the class name.

Implements KIGFX::VIEW_ITEM.

Definition at line 272 of file view_overlay.cpp.

◆ GetFillColor()

const COLOR4D & KIGFX::VIEW_OVERLAY::GetFillColor ( ) const
inline

Definition at line 107 of file view_overlay.h.

◆ GetStrokeColor()

const COLOR4D & KIGFX::VIEW_OVERLAY::GetStrokeColor ( ) const
inline

Definition at line 106 of file view_overlay.h.

◆ Line() [1/2]

void KIGFX::VIEW_OVERLAY::Line ( const SEG & aSeg)

Definition at line 326 of file view_overlay.cpp.

◆ Line() [2/2]

void KIGFX::VIEW_OVERLAY::Line ( const VECTOR2D & aStartPoint,
const VECTOR2D & aEndPoint )

Definition at line 320 of file view_overlay.cpp.

◆ operator=()

VIEW_OVERLAY & KIGFX::VIEW_OVERLAY::operator= ( const VIEW_OVERLAY & )
delete

◆ Polygon() [1/3]

void KIGFX::VIEW_OVERLAY::Polygon ( const SHAPE_POLY_SET & aPolySet)

Definition at line 349 of file view_overlay.cpp.

◆ Polygon() [2/3]

void KIGFX::VIEW_OVERLAY::Polygon ( const std::deque< VECTOR2D > & aPointList)

Definition at line 355 of file view_overlay.cpp.

◆ Polygon() [3/3]

void KIGFX::VIEW_OVERLAY::Polygon ( const VECTOR2D aPointList[],
int aListSize )

Definition at line 361 of file view_overlay.cpp.

◆ Polyline()

void KIGFX::VIEW_OVERLAY::Polyline ( const SHAPE_LINE_CHAIN & aPolyLine)

Definition at line 339 of file view_overlay.cpp.

◆ Rectangle()

void KIGFX::VIEW_OVERLAY::Rectangle ( const VECTOR2D & aStartPoint,
const VECTOR2D & aEndPoint )

Definition at line 380 of file view_overlay.cpp.

◆ releaseCommands()

void KIGFX::VIEW_OVERLAY::releaseCommands ( )
private

Definition at line 278 of file view_overlay.cpp.

◆ Segment()

void KIGFX::VIEW_OVERLAY::Segment ( const VECTOR2D & aStartPoint,
const VECTOR2D & aEndPoint,
double aWidth )

Definition at line 332 of file view_overlay.cpp.

◆ SetFillColor()

void KIGFX::VIEW_OVERLAY::SetFillColor ( const COLOR4D & aColor)

Definition at line 411 of file view_overlay.cpp.

◆ SetGlyphSize()

void KIGFX::VIEW_OVERLAY::SetGlyphSize ( const VECTOR2I & aSize)

Definition at line 392 of file view_overlay.cpp.

◆ SetIsFill()

void KIGFX::VIEW_OVERLAY::SetIsFill ( bool aIsFillEnabled)

Definition at line 386 of file view_overlay.cpp.

◆ SetIsStroke()

void KIGFX::VIEW_OVERLAY::SetIsStroke ( bool aIsStrokeEnabled)

Definition at line 405 of file view_overlay.cpp.

◆ SetLineWidth()

void KIGFX::VIEW_OVERLAY::SetLineWidth ( double aLineWidth)

Definition at line 425 of file view_overlay.cpp.

◆ SetStrokeColor()

void KIGFX::VIEW_OVERLAY::SetStrokeColor ( const COLOR4D & aColor)

Definition at line 418 of file view_overlay.cpp.

◆ ViewBBox()

const BOX2I KIGFX::VIEW_OVERLAY::ViewBBox ( ) const
overridevirtual

Return the bounding box of the item covering all its layers.

Returns
the current bounding box.

Implements KIGFX::VIEW_ITEM.

Definition at line 293 of file view_overlay.cpp.

◆ ViewDraw()

void KIGFX::VIEW_OVERLAY::ViewDraw ( int aLayer,
VIEW * aView ) const
overridevirtual

Draw the parts of the object belonging to layer aLayer.

An alternative way for drawing objects if there is no #PAINTER assigned for the view or if the PAINTER doesn't know how to paint this particular implementation of VIEW_ITEM. The preferred way of drawing is to design an appropriate PAINTER object, the method below is intended only for quick hacks and debugging purposes.

Parameters
aLayeris the current drawing layer.
aViewis a pointer to the VIEW device we are drawing on.

Reimplemented from KIGFX::VIEW_ITEM.

Definition at line 302 of file view_overlay.cpp.

◆ ViewGetLayers()

std::vector< int > KIGFX::VIEW_OVERLAY::ViewGetLayers ( ) const
overridevirtual

Return the all the layers within the VIEW the object is painted on.

For instance, a PAD spans zero or more copper layers and a few technical layers. ViewDraw() or PAINTER::Draw() is repeatedly called for each of the layers returned by ViewGetLayers(), depending on the rendering order.

Implements KIGFX::VIEW_ITEM.

Definition at line 314 of file view_overlay.cpp.

Member Data Documentation

◆ m_commands

std::vector<COMMAND*> KIGFX::VIEW_OVERLAY::m_commands
private

Definition at line 115 of file view_overlay.h.

◆ m_fillColor

COLOR4D KIGFX::VIEW_OVERLAY::m_fillColor
private

Definition at line 114 of file view_overlay.h.

◆ m_strokeColor

COLOR4D KIGFX::VIEW_OVERLAY::m_strokeColor
private

Definition at line 113 of file view_overlay.h.


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