63 const wxPoint& aPosition,
const wxSize& aSize,
GAL_TYPE aGalType ) :
70 m_view->UseDrawPriority(
true );
75 ShowScrollbars( wxSHOW_SB_NEVER, wxSHOW_SB_NEVER );
77 m_painter->GetSettings()->SetBackgroundColor(
88 BOX2I area = aBoardEdgesOnly ?
m_pcb->GetBoardEdgesBoundingBox() :
m_pcb->GetBoundingBox();
94 area.
SetEnd( pageSize.x, pageSize.y );
147 return wxSize( sizeIU.
x, sizeIU.
y );
156 const wxSize clientSize = GetSize();
158 VECTOR2D(
static_cast<double>( clientSize.x ),
static_cast<double>( clientSize.y ) ),
166 / std::max( fabs( vsize.
x / screenSize.
x ), fabs( vsize.
y / screenSize.
y ) );
168 if( !std::isfinite(
scale ) )
BASE_SCREEN class implementation.
constexpr EDA_IU_SCALE pcbIUScale
Information pertinent to a Pcbnew printed circuit board.
constexpr void SetOrigin(const Vec &pos)
constexpr size_type GetWidth() const
constexpr Vec Centre() const
constexpr size_type GetHeight() const
constexpr const SizeVec & GetSize() const
constexpr void SetEnd(coord_type x, coord_type y)
std::unique_ptr< KIGFX::PAINTER > m_painter
Contains information about how to draw items using GAL.
KIGFX::GAL * m_gal
Interface for drawing objects on a 2D-surface.
KIGFX::VIEW * m_view
Stores view settings (scale, center, etc.) and items to be drawn.
void StartDrawing()
Begin drawing if it was stopped previously.
const BOX2I GetDocumentExtents(bool aIncludeAllVisible=true) const
void ActivateSelectedZone(ZONE *aZone) override
BOX2I GetBoardBoundingBox(bool aBoardEdgesOnly) const
PANEL_ZONE_GAL(BOARD *aPcb, wxWindow *aParentWindow, KIGFX::GAL_DISPLAY_OPTIONS &aOptions, wxWindowID aWindowId=0, const wxPoint &aPosition=wxDefaultPosition, const wxSize &aSize=wxDefaultSize, GAL_TYPE aGalType=GAL_TYPE_OPENGL)
const wxSize GetPageSizeIU() const
std::unique_ptr< BOARD_EDGES_BOUNDING_ITEM > m_pcb_bounding_box
bool OnLayerSelected(int aLayer)
Show the zone painting on layer.
~PANEL_ZONE_GAL() override
void UpdateColors()
Update the color settings in the painter and GAL.
PCB_DRAW_PANEL_GAL(wxWindow *aParentWindow, wxWindowID aWindowId, const wxPoint &aPosition, const wxSize &aSize, KIGFX::GAL_DISPLAY_OPTIONS &aOptions, GAL_TYPE aGalType=GAL_TYPE_OPENGL)
BOX2I GetDefaultViewBBox() const override
Return the bounding box of the view that should be used if model is not valid.
static wxColour GetCanvasBackgroundColor()
Handle a list of polygons defining a copper zone.
PCB_LAYER_ID GetFirstLayer() const
@ FRAME_FOOTPRINT_PREVIEW
@ DRAW_ORDER_BOARD_BOUNDING
void Refresh()
Update the board display after modifying it by a python script (note: it is automatically called by a...
VECTOR2< double > VECTOR2D