47 return Pgm().GetSettingsManager().GetColorSettings()->GetColor( aLayer );
73 Prj().GetProjectPath() );
86 if( !aInitialPage.IsEmpty() )
116 int dotSize = netSettings->m_DefaultNetClass->GetWireWidth() * sizeMultipliers[ sizeChoice ];
118 return std::max( dotSize, 1 );
128 if( !fn.HasName() || !
IsWritable( fn,
false ) )
146 if( !layoutfn.IsAbsolute() )
147 success = layoutfn.MakeAbsolute(
Prj().GetProjectPath() );
149 if( success && layoutfn.IsOk() && !layoutfn.FileExists() )
151 if( layoutfn.DirExists() && layoutfn.IsDirWritable() )
213 wxCHECK_RET( aCfg,
"Call to SCH_BASE_FRAME::LoadSettings with null settings" );
253 wxCHECK_RET( aCfg, wxS(
"Call to SCH_BASE_FRAME::SaveSettings with null settings" ) );
286 if( !prjPath.IsEmpty() )
292 tbl->
Load( fn.GetFullPath() );
297 msg.Printf(
_(
"Error loading the symbol library table '%s'." ),
APP_SETTINGS_BASE is a settings class that should be derived for each standalone KiCad application.
static wxString m_DrawingSheetFileName
the name of the drawing sheet file, or empty to use the default drawing sheet
static DS_DATA_MODEL & GetTheInstance()
static function: returns the instance of DS_DATA_MODEL used in the application
void Save(const wxString &aFullFileName)
Save the description in a file.
static const wxString ResolvePath(const wxString &aPath, const wxString &aProjectPath)
Resolve a path which might be project-relative or contain env variable references.
SETTINGS_MANAGER * GetSettingsManager() const
bool IsWritable(const wxFileName &aFileName, bool aVerbose=true)
Checks if aFileName can be written.
void ShowInfoBarError(const wxString &aErrorMsg, bool aShowCloseButton=false, WX_INFOBAR::MESSAGE_TYPE aType=WX_INFOBAR::MESSAGE_TYPE::GENERIC)
Show the WX_INFOBAR displayed on the top of the canvas with a message and an error icon on the left o...
void SaveSettings(APP_SETTINGS_BASE *aCfg) override
Save common frame parameters to a configuration data file.
void LoadSettings(APP_SETTINGS_BASE *aCfg) override
Load common frame parameters from a configuration file.
std::unique_ptr< EDA_SEARCH_DATA > m_findReplaceData
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...
FIND_REPLACE_EXTRA m_FindReplaceExtra
Hold an error message and may be used when throwing exceptions containing meaningful error messages.
virtual const wxString What() const
A composite of Problem() and Where()
A color representation with 4 components: red, green, blue, alpha.
void SetDefaultPenWidth(int aWidth)
void SetDefaultFont(const wxString &aFont)
void SetGapLengthRatio(double aRatio)
void SetDashLengthRatio(double aRatio)
bool m_ShowPinsElectricalType
void UpdateAllItems(int aUpdateFlags)
Update all items in the view according to the given flags.
void MarkDirty()
Force redraw of view on the next rendering.
PROJECT & Prj() const
Return a reference to the PROJECT associated with this KIWAY.
KIWAY & Kiway() const
Return a reference to the KIWAY that this object has an opportunity to participate in.
virtual void CommonSettingsChanged(bool aEnvVarsChanged, bool aTextVarsChanged)
Call CommonSettingsChanged() on all KIWAY_PLAYERs.
static int GetSubpartIdSeparator()
static int GetSubpartFirstId()
static void SetSubpartIdNotation(int aSep, int aFirstId)
Set the separator char between the subpart id and the reference 0 (no separator) or '.
void Load(const wxString &aFileName)
Load the library table using the path defined by aFileName aFallBackTable.
void SetInitialPage(const wxString &aPage, const wxString &aParentPage=wxEmptyString)
SCHEMATIC_SETTINGS * m_SchematicSettings
std::shared_ptr< NET_SETTINGS > & NetSettings()
virtual PROJECT_FILE & GetProjectFile() const
virtual _ELEM * GetElem(ELEM_T aIndex)
Get and set the elements for this project.
virtual void SetElem(ELEM_T aIndex, _ELEM *aElem)
These settings were stored in SCH_BASE_FRAME previously.
wxString m_SchDrawingSheetFileName
double m_DashedLineGapRatio
double m_DashedLineDashRatio
SCHEMATIC_SETTINGS & Settings() const
SCH_SCREEN * RootScreen() const
Helper to retrieve the screen of the root sheet.
void SaveSettings(APP_SETTINGS_BASE *aCfg) override
Save common frame parameters to a configuration data file.
void LoadSettings(APP_SETTINGS_BASE *aCfg) override
Load common frame parameters from a configuration file.
SCH_DRAW_PANEL * GetCanvas() const override
Return a pointer to GAL-based canvas of given EDA draw frame.
EESCHEMA_SETTINGS * eeconfig() const
KIGFX::SCH_RENDER_SETTINGS * GetRenderSettings()
KIGFX::SCH_VIEW * GetView() const override
Return a pointer to the #VIEW instance used in the panel.
void ShowSchematicSetupDialog(const wxString &aInitialPage=wxEmptyString)
void SaveProjectSettings() override
Save changes to the project settings to the project (.pro) file.
void RecordERCExclusions()
Scan existing markers and record data from any that are Excluded.
SCHEMATIC & Schematic() const
bool LoadProjectSettings()
Load the KiCad project file (*.pro) settings specific to Eeschema.
void LoadSettings(APP_SETTINGS_BASE *aCfg) override
Load common frame parameters from a configuration file.
void SaveSettings(APP_SETTINGS_BASE *aCfg) override
Save common frame parameters to a configuration data file.
static const wxString SchematicHierarchyPaneName()
int GetSchematicJunctionSize()
const wxString & GetFileName() const
bool SaveProject(const wxString &aFullPath=wxEmptyString, PROJECT *aProject=nullptr)
Saves a loaded project.
static SYMBOL_LIB_TABLE & GetGlobalLibTable()
static const wxString & GetSymbolLibTableFileName()
EDA_UNITS GetUserUnits() const
void DisplayErrorMessage(wxWindow *aParent, const wxString &aText, const wxString &aExtraInfo)
Display an error message with aMessage.
This file is part of the common library.
static std::mutex s_symbolTableMutex
COLOR4D GetLayerColor(SCH_LAYER_ID aLayer)
Helper for all the old plotting/printing code while it still exists.
const std::string ProjectFileExtension
SCH_LAYER_ID
Eeschema drawing layers.
@ REPAINT
Item needs to be redrawn.
#define PROJECT_VAR_NAME
A variable name whose value holds the current project directory.
KIWAY Kiway & Pgm(), KFCTL_STANDALONE
The global Program "get" accessor.
bool schematic_hierarchy_float
bool show_schematic_hierarchy
std::vector< double > junction_size_mult_list
std::vector< wxString > sizes
bool searchCurrentSheetOnly
std::vector< double > zoom_factors
Definition for symbol library class.
Definition of file extensions used in Kicad.
#define ZOOM_LIST_EESCHEMA