68 wxString msg =
wxString::Format(
_(
"Board edges must be defined on the %s layer." ),
88 std::unique_ptr<WX_PROGRESS_REPORTER> progressReporter =
89 std::make_unique<WX_PROGRESS_REPORTER>(
frame(),
_(
"Autoplace Components" ), 1 );
95 commit.
Push(
_(
"Autoplace components" ) );
105 std::vector<FOOTPRINT*> footprints;
110 footprints.push_back(
static_cast<FOOTPRINT*
>( item ) );
119 std::vector<FOOTPRINT*> footprints;
AR_RESULT AutoplaceFootprints(std::vector< FOOTPRINT * > &aFootprints, BOARD_COMMIT *aCommit, bool aPlaceOffboardModules=false)
void SetOverlay(std::shared_ptr< KIGFX::VIEW_OVERLAY > aOverlay)
Set a VIEW overlay to draw items during a autoplace session.
void SetRefreshCallback(std::function< int(FOOTPRINT *aFootprint)> aCallback)
Callback to redraw on screen the view after changes, for instance after moving a footprint.
void SetProgressReporter(PROGRESS_REPORTER *aReporter)
virtual void Revert() override
virtual void Push(const wxString &aMessage=wxT("A commit"), int aCommitFlags=0) override
Revert the commit by restoring the modified items state.
const BOX2I GetBoardEdgesBoundingBox() const
Return the board bounding box calculated using exclusively the board edges (graphics on Edge....
coord_type GetHeight() const
coord_type GetWidth() const
WX_INFOBAR * GetInfoBar()
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.
virtual void Update(const VIEW_ITEM *aItem, int aUpdateFlags) const override
For dynamic VIEWs, inform the associated VIEW that the graphical representation of this item has chan...
std::shared_ptr< VIEW_OVERLAY > MakeOverlay()
void MarkDirty()
Force redraw of view on the next rendering.
static TOOL_ACTION autoplaceOffboardComponents
static TOOL_ACTION autoplaceSelectedComponents
Common, abstract interface for edit frames.
PCB_DRAW_PANEL_GAL * GetCanvas() const override
Return a pointer to GAL-based canvas of given EDA draw frame.
virtual KIGFX::PCB_VIEW * GetView() const override
Return a pointer to the #VIEW instance used in the panel.
void RemoveAllButtons()
Remove all the buttons that have been added by the user.
void ShowMessageFor(const wxString &aMessage, int aTime, int aFlags=wxICON_INFORMATION, MESSAGE_TYPE aType=WX_INFOBAR::MESSAGE_TYPE::GENERIC)
Show the infobar with the provided message and icon for a specific period of time.
wxString LayerName(int aLayer)
Returns the default display name for a given layer.
std::shared_ptr< PNS_LOG_VIEWER_OVERLAY > overlay
void Format(OUTPUTFORMATTER *out, int aNestLevel, int aCtl, const CPTREE &aTree)
Output a PTREE into s-expression format via an OUTPUTFORMATTER derivative.
@ PCB_FOOTPRINT_T
class FOOTPRINT, a footprint