26#include <wx/imaglist.h>
27#include <wx/wupdlock.h>
169 void Draw( wxGrid& aGrid, wxGridCellAttr& aAttr,
170 wxDC& aDc,
const wxRect& aRect,
171 int aRow,
int aCol,
bool aIsSelected)
override;
205 wxWindowUpdateLocker
dummy(
this );
214 wxFileName fn(
static_cast<PL_EDITOR_FRAME*
>( GetParent() )->GetCurrentFileName() );
216 if( fn.GetName().IsEmpty() )
217 SetTitle(
"<default drawing sheet>" );
219 SetTitle( fn.GetName() );
238 const char** img =
nullptr;
240 switch( item->GetType() )
282 int cols_to_resize[] =
287 for(
int ii = 0; ; ii++ )
289 int col = cols_to_resize[ii];
296 #define BITMAP_SIZE 16
312 for(
unsigned row = 1; row <
m_itemsList.size(); ++row )
332 int row =
event.GetRow();
351 wxDC& aDc,
const wxRect& aRect,
352 int aRow,
int aCol,
bool aIsSelected)
354 wxGridCellStringRenderer::Draw( aGrid, aAttr, aDc, aRect, aRow, aCol, aIsSelected);
356 aDc.DrawBitmap( bm,aRect.GetX()+5, aRect.GetY()+2,
true);
constexpr EDA_IU_SCALE drawSheetIUScale
const char ** m_BitmapXPM
BitmapGridCellRenderer(const char **aBitmapXPM)
void Draw(wxGrid &aGrid, wxGridCellAttr &aAttr, wxDC &aDc, const wxRect &aRect, int aRow, int aCol, bool aIsSelected) override
Class DIALOG_INSPECTOR_BASE.
DESIGN_INSPECTOR is the left window showing the list of items.
void ReCreateDesignList()
void onCellClicked(wxGridEvent &event) override
DS_DATA_ITEM * GetDrawingSheetDataItem(int aRow) const
wxGrid * GetGridList() const
void SelectRow(DS_DATA_ITEM *aItem)
DIALOG_INSPECTOR(PL_EDITOR_FRAME *aParent)
PL_EDITOR_FRAME * m_editorFrame
std::vector< DS_DATA_ITEM * > m_itemsList
void finishDialogSettings()
In all dialogs, we must call the same functions to fix minimal dlg size, the default position and per...
Drawing sheet structure type definitions.
const std::vector< DS_DRAW_ITEM_BASE * > & GetDrawItems() const
Handle the graphic items list to draw/plot the frame and title block.
static DS_DATA_MODEL & GetTheInstance()
static function: returns the instance of DS_DATA_MODEL used in the application
std::vector< DS_DATA_ITEM * > & GetItems()
virtual void Refresh(bool aEraseBackground=true, const wxRect *aRect=nullptr) override
Update the board display after modifying it by a python script (note: it is automatically called by a...
A base class for most all the KiCad significant classes used in schematics and boards.
Describe the page size and margins of a paper page on which to eventually print or plot.
const wxString & GetType() const
The main window used in the drawing sheet editor.
void ShowDesignInspector()
Show the dialog displaying the list of DS_DATA_ITEM items in the page layout.
const wxSize GetPageSizeIU() const override
Works off of GetPageSettings() to return the size of the paper page in the internal units of this par...
PROPERTIES_FRAME * GetPropertiesFrame()
const PL_EDITOR_LAYOUT & GetPageLayout() const
PL_DRAW_PANEL_GAL * GetCanvas() const override
Return a pointer to GAL-based canvas of given EDA draw frame.
PAGE_INFO & GetPageSettings()
void CopyPrmsFromItemToPanel(DS_DATA_ITEM *aItem)
static const char * poly_xpm[]
static const char * root_xpm[]
static const char * text_xpm[]
static const char * rect_xpm[]
static const char * line_xpm[]
static const char * img_xpm[]
void Format(OUTPUTFORMATTER *out, int aNestLevel, int aCtl, const CPTREE &aTree)
Output a PTREE into s-expression format via an OUTPUTFORMATTER derivative.
std::vector< FAB_LAYER_COLOR > dummy
constexpr double IUTomm(int iu) const