57 m_XRef = cfg->m_ExportIdf.ref_x;
58 m_YRef = cfg->m_ExportIdf.ref_y;
103 catch(
const std::runtime_error& e )
105 wxFAIL_MSG( e.what() );
187 if( fn.FileExists() )
189 wxString msg = wxString::Format(
_(
"File %s already exists." ), fn.GetPath() );
190 KIDIALOG dlg(
this, msg,
_(
"Confirmation" ), wxOK | wxCANCEL | wxICON_WARNING );
191 dlg.SetOKLabel(
_(
"Overwrite" ) );
209 brdFile.SetExt( wxT(
"emn" ) );
210 path = brdFile.GetFullPath();
216 if ( dlg.ShowModal() != wxID_OK )
246 wxString fullFilename = dlg.
FilePicker()->GetPath();
252 wxString msg = wxString::Format(
_(
"Failed to create file '%s'." ), fullFilename );
constexpr EDA_IU_SCALE pcbIUScale
const BOX2I GetBoardEdgesBoundingBox() const
Return the board bounding box calculated using exclusively the board edges (graphics on Edge....
const wxString & GetFileName() const
Class DIALOG_EXPORT_IDF3_BASE.
TEXT_CTRL_EVAL * m_IDF_Xref
wxCheckBox * m_cbRemoveDNP
wxFilePickerCtrl * m_filePickerIDF
wxCheckBox * m_cbAutoAdjustOffset
wxCheckBox * m_cbRemoveUnspecified
wxRadioBox * m_rbUnitSelection
TEXT_CTRL_EVAL * m_IDF_Yref
wxChoice * m_IDF_RefUnitChoice
DIALOG_EXPORT_IDF3(PCB_EDIT_FRAME *parent)
bool GetAutoAdjustOffset()
wxFilePickerCtrl * FilePicker()
bool TransferDataFromWindow() override
void OnAutoAdjustOffset(wxCommandEvent &event)
PCB_EDIT_FRAME * m_parent
bool GetNoUnspecifiedOption()
void SetupStandardButtons(std::map< int, wxString > aLabels={})
void finishDialogSettings()
In all dialogs, we must call the same functions to fix minimal dlg size, the default position and per...
Helper class to create more flexible dialogs, including 'do not show again' checkbox handling.
void DoNotShowCheckbox(wxString file, int line)
Checks the 'do not show again' setting for the dialog.
DIALOG_EXPORT_IDF m_ExportIdf
PCBNEW_SETTINGS * GetPcbNewSettings() const
The main frame for Pcbnew.
void SetLastPath(LAST_PATH_TYPE aType, const wxString &aLastPath)
Set the path of the last file successfully read.
wxString GetLastPath(LAST_PATH_TYPE aType)
Get the last path for a particular type.
void OnExportIDF3(wxCommandEvent &event)
Export the current BOARD to a IDFv3 board and lib files.
bool Export_IDF3(BOARD *aPcb, const wxString &aFullFileName, bool aUseThou, double aXRef, double aYRef, bool aIncludeUnspecified, bool aIncludeDNP)
Create an IDF3 compliant BOARD (*.emn) and LIBRARY (*.emp) file.
void SetValue(const wxString &aValue) override
Set a new value in evaluator buffer, and display it in the wxTextCtrl.
This file is part of the common library.
KICOMMON_API double DoubleValueFromString(const EDA_IU_SCALE &aIuScale, EDA_UNITS aUnits, const wxString &aTextValue, EDA_DATA_TYPE aType=EDA_DATA_TYPE::DISTANCE)
Function DoubleValueFromString converts aTextValue to a double.
std::vector< FAB_LAYER_COLOR > dummy