KiCad PCB EDA Suite
schframe.h
Go to the documentation of this file.
1 /*
2  * This program source code file is part of KiCad, a free EDA CAD application.
3  *
4  * Copyright (C) 2015 Jean-Pierre Charras, jp.charras wanadoo.fr
5  * Copyright (C) 2008-2015 Wayne Stambaugh <stambaughw@verizon.net>
6  * Copyright (C) 2004-2017 KiCad Developers, see AUTHORS.txt for contributors.
7  *
8  * This program is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License
10  * as published by the Free Software Foundation; either version 2
11  * of the License, or (at your option) any later version.
12  *
13  * This program is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16  * GNU General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with this program; if not, you may find one here:
20  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
21  * or you may search the http://www.gnu.org website for the version 2 license,
22  * or you may write to the Free Software Foundation, Inc.,
23  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
24  */
25 
30 #ifndef WX_EESCHEMA_STRUCT_H
31 #define WX_EESCHEMA_STRUCT_H
32 
33 #include <sch_base_frame.h>
34 #include <config_params.h>
36 #include <template_fieldnames.h>
37 #include <block_commande.h>
38 #include <class_sch_screen.h>
39 #include <sch_collectors.h>
40 
41 // enum PINSHEETLABEL_SHAPE
42 #include <sch_text.h>
43 
44 class LIB_EDIT_FRAME;
45 class LIB_VIEW_FRAME;
46 class DRAWSEGMENT;
47 class SCH_ITEM;
48 class SCH_NO_CONNECT;
49 class EDA_ITEM;
50 class SCH_BUS_ENTRY_BASE;
51 class SCH_BUS_WIRE_ENTRY;
52 class SCH_BUS_BUS_ENTRY;
53 class SCH_GLOBALLABEL;
54 class SCH_TEXT;
55 class SCH_BITMAP;
56 class SCH_SHEET;
57 class SCH_SHEET_PATH;
58 class SCH_SHEET_PIN;
59 class SCH_COMPONENT;
60 class SCH_FIELD;
61 class LIB_PIN;
62 class SCH_JUNCTION;
63 class DIALOG_SCH_FIND;
64 class wxFindDialogEvent;
65 class wxFindReplaceData;
66 class SCHLIB_FILTER;
67 
68 
71  CMP_NORMAL, // Normal orientation, no rotation or mirror
72  CMP_ROTATE_CLOCKWISE, // Rotate -90
74  CMP_ORIENT_0, // No rotation and no mirror id CMP_NORMAL
75  CMP_ORIENT_90, // Rotate 90, no mirror
76  CMP_ORIENT_180, // Rotate 180, no mirror
77  CMP_ORIENT_270, // Rotate -90, no mirror
78  CMP_MIRROR_X = 0x100, // Mirror around X axis
79  CMP_MIRROR_Y = 0x200 // Mirror around Y axis
80 };
81 
82 
88 };
90 
91 
98 };
100 
101 
109 };
110 
111 
112 #define SCH_EDIT_FRAME_NAME wxT( "SchematicFrame" )
113 
118 {
119 private:
123 
126  wxPageSetupDialogData m_pageSetupData;
127  wxFindReplaceData* m_findReplaceData;
137  wxArrayString m_findStringHistoryList;
146  wxString m_netListerCommand;
148  int m_exec_flags;
150 
153 
157 
160 
163 
166 
168  wxString m_netListFormat;
169 
172 
173  /* these are PROJECT specific, not schematic editor specific
174  wxString m_userLibraryPath;
175  wxArrayString m_componentLibFiles;
176  */
177 
179  static wxSize m_lastSheetPinTextSize;
181 
182 protected:
184 
188  const wxSize &GetLastSheetPinTextSize();
189 
196  virtual bool doAutoSave() override;
197 
202  virtual bool isAutoSaveRequired() const override;
203 
211  void addCurrentItemToList( bool aRedraw = true );
212 
213  void updateFindReplaceView( wxFindDialogEvent& aEvent );
214 
215  void backAnnotateFootprints( const std::string& aChangedSetOfReferences )
216  throw( IO_ERROR, boost::bad_pointer );
217 
224  bool prepareForNetlist();
225 
230  void sendNetlist();
231 
232 public:
233  SCH_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent );
234  ~SCH_EDIT_FRAME();
235 
236  SCH_SCREEN* GetScreen() const override;
237 
238  void OnCloseWindow( wxCloseEvent& Event );
239 
240  bool GetForceHVLines() const { return m_forceHVLines; }
241  void SetForceHVLines( bool aForceHVdirection ) { m_forceHVLines = aForceHVdirection; }
242 
243  bool GetShowAllPins() const { return m_showAllPins; }
244 
245  void SetShowAllPins( bool aEnable ) { m_showAllPins = aEnable; }
246 
247  const wxString GetNetListFormatName() const { return m_netListFormat; }
248 
249  void SetNetListFormatName( const wxString& aFormat ) { m_netListFormat = aFormat; }
250 
252 
253  void SetSpiceAjustPassiveValues( bool aEnable ) { m_spiceAjustPassiveValues = aEnable; }
254 
255  /* These are PROJECT specific, not schematic editor specific
256  wxString GetUserLibraryPath() const { return m_userLibraryPath; }
257  void SetUserLibraryPath( const wxString& aPath ) { m_userLibraryPath = aPath; }
258  const wxArrayString& GetComponentLibraries() const { return m_componentLibFiles; }
259  void SetComponentLibraries( const wxArrayString& aList ) { m_componentLibFiles = aList; }
260  */
261 
263  const wxString& GetPlotDirectoryName() const { return m_plotDirectoryName; }
264  void SetPlotDirectoryName( const wxString& aDirName ) { m_plotDirectoryName = aDirName; }
265 
266  void Process_Special_Functions( wxCommandEvent& event );
267  void Process_Config( wxCommandEvent& event );
268  void OnSelectTool( wxCommandEvent& aEvent );
269 
270  bool GeneralControl( wxDC* aDC, const wxPoint& aPosition, EDA_KEY aHotKey = 0 ) override;
271 
282 
288  void SaveProjectSettings( bool aAskForSave ) override;
289 
296  bool LoadProjectFile();
297 
304  static wxString GetDefaultFieldName( int aFieldNdx );
305 
317  int AddTemplateFieldName( const TEMPLATE_FIELDNAME& aFieldName )
318  {
319  return m_TemplateFieldNames.AddTemplateFieldName( aFieldName );
320  }
321 
322 
328  {
329  return m_TemplateFieldNames.GetTemplateFieldNames();
330  }
331 
332 
338  {
339  return m_TemplateFieldNames;
340  }
341 
347  {
348  m_TemplateFieldNames.DeleteAllTemplateFieldNames();
349  }
350 
364 
365  void LoadSettings( wxConfigBase* aCfg ) override;
366  void SaveSettings( wxConfigBase* aCfg ) override;
367 
368  void RedrawActiveWindow( wxDC* DC, bool EraseBg ) override;
369 
370  void CreateScreens();
371  void ReCreateHToolbar() override;
372  void ReCreateVToolbar() override;
373  void ReCreateOptToolbar();
374  void ReCreateMenuBar() override;
375 
377  EDA_HOTKEY* GetHotKeyDescription( int aCommand ) const override;
378 
379  bool OnHotKey( wxDC* aDC, int aHotKey, const wxPoint& aPosition, EDA_ITEM* aItem = NULL ) override;
380 
387  void OnModify();
388 
389  virtual wxString GetScreenDesc() const override;
390 
391  void InstallConfigFrame( wxCommandEvent& event );
392 
399  virtual void ExecuteRemoteCommand( const char* cmdline ) override;
400 
401  void KiwayMailIn( KIWAY_EXPRESS& aEvent ) override;
402 
403  void OnLeftClick( wxDC* aDC, const wxPoint& aPosition ) override;
404  void OnLeftDClick( wxDC* aDC, const wxPoint& aPosition ) override;
405  bool OnRightClick( const wxPoint& aPosition, wxMenu* PopMenu ) override;
406  void OnSelectOptionToolbar( wxCommandEvent& event );
407  double BestZoom() override;
408 
425  SCH_ITEM* LocateAndShowItem( const wxPoint& aPosition,
426  const KICAD_T aFilterList[] = SCH_COLLECTOR::AllItems,
427  int aHotKeyCommandId = 0 );
428 
445  SCH_ITEM* LocateItem( const wxPoint& aPosition,
446  const KICAD_T aFilterList[] = SCH_COLLECTOR::AllItems,
447  int aHotKeyCommandId = 0 );
448 
458  bool DeleteItemAtCrossHair( wxDC* aDC );
459 
460 
470  bool HighlightConnectionAtPosition( wxPoint aPosition );
471 
482  SCH_ITEM* FindComponentAndItem( const wxString& aReference,
483  bool aSearchHierarchy,
484  SCH_SEARCH_T aSearchType,
485  const wxString& aSearchText,
486  bool aWarpMouse );
487 
501  void SendMessageToPCBNEW( EDA_ITEM* aObjectToSync, SCH_COMPONENT* aPart );
502 
511  NETLIST_OBJECT_LIST* BuildNetListBase( bool updateStatusText = true );
512 
533  bool CreateNetlist( int aFormat,
534  const wxString& aFullFileName,
535  unsigned aNetlistOptions,
536  REPORTER* aReporter = NULL );
537 
556  bool WriteNetListFile( NETLIST_OBJECT_LIST* aConnectedItemsList,
557  int aFormat,
558  const wxString& aFullFileName,
559  unsigned aNetlistOptions,
560  REPORTER* aReporter = NULL );
561 
568  void DeleteAnnotation( bool aCurrentSheetOnly );
569 
598  void AnnotateComponents( bool aAnnotateSchematic, ANNOTATE_ORDER_T aSortOption,
599  ANNOTATE_OPTION_T aAlgoOption, bool aResetAnnotation,
600  bool aRepairTimestamps, bool aLockUnits );
601 
623  int CheckAnnotate( wxArrayString* aMessageList, bool aOneSheetOnly );
624 
625  // Functions used for hierarchy handling
627 
628  void SetCurrentSheet( const SCH_SHEET_PATH& aSheet );
629 
634  void DisplayCurrentSheet();
635 
644 
657 
664  void SetSheetNumberAndCount();
665 
669  void OnPrint( wxCommandEvent& event );
670 
671  wxPageSetupDialogData& GetPageSetupData() { return m_pageSetupData; }
672 
673  void SetPreviewPosition( const wxPoint& aPoint ) { m_previewPosition = aPoint; }
674  void SetPreviewSize( const wxSize& aSize ) { m_previewSize = aSize; }
676  const wxSize& GetPreviewSize() { return m_previewSize; }
677 
678  void SetPrintDialogPosition( const wxPoint& aPoint )
679  {
680  m_printDialogPosition = aPoint;
681  }
682 
683 
684  void SetPrintDialogSize( const wxSize& aSize ) { m_printDialogSize = aSize; }
686  const wxSize& GetPrintDialogSize() { return m_printDialogSize; }
687 
689  void SetPrintMonochrome( bool aMonochrome ) { m_printMonochrome = aMonochrome; }
691  void SetPrintSheetReference( bool aShow ) { m_printSheetReference = aShow; }
692 
693  // Plot functions:
694  void PlotSchematic( wxCommandEvent& event );
695 
696  // read and save files
697  void Save_File( wxCommandEvent& event );
698 
706  void OnSaveProject( wxCommandEvent& aEvent );
707 
708  bool OpenProjectFiles( const std::vector<wxString>& aFileSet, int aCtl = 0 ) override;
709 
716  bool AppendOneEEProject();
717 
730  bool LoadOneEEFile( SCH_SCREEN* aScreen, const wxString& aFullFileName, bool append = false );
731 
740 
762  bool ProcessCmpToFootprintLinkFile( const wxString& aFullFilename,
763  bool aForceVisibilityState,
764  bool aVisibilityState );
765 
780  bool SaveEEFile( SCH_SCREEN* aScreen,
781  bool aSaveUnderNewName = false,
782  bool aCreateBackupFile = CREATE_BACKUP_FILE );
783 
784  // General search:
785 
786  bool IsSearchCacheObsolete( const SCH_FIND_REPLACE_DATA& aSearchCriteria );
787 
788 
789 private:
790 
795  void OnAutoplaceFields( wxCommandEvent& aEvent );
796 
801  void OnMoveItem( wxCommandEvent& aEvent );
802 
808  void OnRotate( wxCommandEvent& aEvent );
809 
814  void OnEditItem( wxCommandEvent& aEvent );
815 
820  void OnDragItem( wxCommandEvent& aEvent );
821 
827  void OnOrient( wxCommandEvent& aEvent );
828 
829  void OnExit( wxCommandEvent& event );
830  void OnAnnotate( wxCommandEvent& event );
831  void OnErc( wxCommandEvent& event );
832  void OnCreateNetlist( wxCommandEvent& event );
833  void OnUpdatePCB( wxCommandEvent& event );
834  void OnSimulate( wxCommandEvent& event );
835  void OnCreateBillOfMaterials( wxCommandEvent& event );
836  void OnLaunchBomManager( wxCommandEvent& event );
837  void OnFindItems( wxCommandEvent& event );
838  void OnFindDialogClose( wxFindDialogEvent& event );
839  void OnFindDrcMarker( wxFindDialogEvent& event );
840  void OnFindCompnentInLib( wxFindDialogEvent& event );
841 
848  void OnFindSchematicItem( wxFindDialogEvent& aEvent );
849 
857  void OnFindReplace( wxFindDialogEvent& aEvent );
858 
859  void OnLoadFile( wxCommandEvent& event );
860  void OnLoadCmpToFootprintLinkFile( wxCommandEvent& event );
861  void OnNewProject( wxCommandEvent& event );
862  void OnLoadProject( wxCommandEvent& event );
863  void OnAppendProject( wxCommandEvent& event );
864  void OnOpenPcbnew( wxCommandEvent& event );
865  void OnOpenPcbModuleEditor( wxCommandEvent& event );
866  void OnOpenCvpcb( wxCommandEvent& event );
867  void OnOpenLibraryEditor( wxCommandEvent& event );
868  void OnRescueProject( wxCommandEvent& event );
869  void OnPreferencesOptions( wxCommandEvent& event );
870  void OnCancelCurrentCommand( wxCommandEvent& aEvent );
871 
872  void OnSelectItem( wxCommandEvent& aEvent );
873 
878  void OnCopySchematicItemRequest( wxCommandEvent& event );
879 
880  /* User interface update event handlers. */
881  void OnUpdateBlockSelected( wxUpdateUIEvent& event );
882  void OnUpdatePaste( wxUpdateUIEvent& event );
883  void OnUpdateHiddenPins( wxUpdateUIEvent& event );
884  void OnUpdateBusOrientation( wxUpdateUIEvent& event );
885  void OnUpdateSelectTool( wxUpdateUIEvent& aEvent );
886  void OnUpdateSave( wxUpdateUIEvent& aEvent );
887  void OnUpdateSaveSheet( wxUpdateUIEvent& aEvent );
888  void OnUpdateHierarchySheet( wxUpdateUIEvent& aEvent );
889 
901  void UpdateTitle();
902 
903  // Bus Entry
906  void SetBusEntryShape( wxDC* DC, SCH_BUS_ENTRY_BASE* BusEntry, char entry_shape );
907 
915  SCH_NO_CONNECT* AddNoConnect( wxDC* aDC, const wxPoint& aPosition );
916 
921  SCH_JUNCTION* AddJunction( wxDC* aDC, const wxPoint& aPosition, bool aPutInUndoList = false );
922 
930  void PrepareMoveItem( SCH_ITEM* aItem, wxDC* aDC );
931 
932  // Text, label, glabel
933  SCH_TEXT* CreateNewText( wxDC* aDC, int aType );
934  void EditSchematicText( SCH_TEXT* TextStruct );
935  void ChangeTextOrient( SCH_TEXT* aTextItem );
936 
943  void OnConvertTextType( wxCommandEvent& aEvent );
944 
953  void BeginSegment( wxDC* DC, int type );
954 
959  void EndSegment( wxDC* DC );
960 
965  void DeleteCurrentSegment( wxDC* DC );
966  void DeleteConnection( bool DeleteFullConnection );
967 
968  // graphic lines
969  void Edge( DRAWSEGMENT* Segment, wxDC* DC );
970  void SetNewWidth( DRAWSEGMENT* DrawSegm, wxDC* DC );
971  void Layer( DRAWSEGMENT* Segment, wxDC* DC );
972  DRAWSEGMENT* Begin_Edge( DRAWSEGMENT* Segment, wxDC* DC );
973 
974  // Images:
975  SCH_BITMAP* CreateNewImage( wxDC* aDC );
976  void MoveImage( SCH_BITMAP* aItem, wxDC* aDC );
977  void RotateImage( SCH_BITMAP* aItem );
985  void MirrorImage( SCH_BITMAP* aItem, bool Is_X_axis );
986  void EditImage( SCH_BITMAP* aItem );
987 
988  // Hierarchical Sheet & PinSheet
989  void InstallHierarchyFrame( wxPoint& pos );
990  SCH_SHEET* CreateSheet( wxDC* DC );
991  void ReSizeSheet( SCH_SHEET* Sheet, wxDC* DC );
992 
1000  void RotateHierarchicalSheet( SCH_SHEET* aSheet, bool aRotCCW );
1001 
1010  void MirrorSheet( SCH_SHEET* aSheet, bool aFromXaxis );
1011 
1013  bool LoadCacheLibrary( const wxString& aFileName );
1014 
1015 public:
1041  bool EditSheet( SCH_SHEET* aSheet, SCH_SHEET_PATH* aHierarchy );
1042 
1044 
1045 private:
1053  SCH_SHEET_PIN* CreateSheetPin( SCH_SHEET* aSheet, wxDC* aDC );
1054 
1062  int EditSheetPin( SCH_SHEET_PIN* aSheetPin, bool aRedraw );
1063 
1072  SCH_SHEET_PIN* ImportSheetPin( SCH_SHEET* aSheet, wxDC* aDC );
1073 
1074 public:
1080  void DeleteItem( SCH_ITEM* aItem );
1081 
1082  int GetLabelIncrement() const { return m_repeatLabelDelta; }
1083 
1084 private:
1085 
1102  SCH_COMPONENT* Load_Component( wxDC* aDC,
1103  const SCHLIB_FILTER* aFilter,
1104  SCH_BASE_FRAME::HISTORY_LIST& aHistoryList,
1105  bool aUseLibBrowser );
1106 
1113  void EditComponent( SCH_COMPONENT* aComponent );
1114 
1115 public:
1116 
1121  void OrientComponent( COMPONENT_ORIENTATION_T aOrientation = CMP_NORMAL );
1122 
1123 private:
1124  void OnSelectUnit( wxCommandEvent& aEvent );
1125  void ConvertPart( SCH_COMPONENT* DrawComponent, wxDC* DC );
1126  void SetInitCmp( SCH_COMPONENT* DrawComponent, wxDC* DC );
1127 
1134  void EditComponentFieldText( SCH_FIELD* aField );
1135 
1136  void RotateField( SCH_FIELD* aField );
1137 
1142  void PasteListOfItems( wxDC* DC );
1143 
1144  /* Undo - redo */
1145 public:
1146 
1175  void SaveCopyInUndoList( SCH_ITEM* aItemToCopy,
1176  UNDO_REDO_T aTypeCommand,
1177  const wxPoint& aTransformPoint = wxPoint( 0, 0 ) );
1178 
1188  void SaveCopyInUndoList( const PICKED_ITEMS_LIST& aItemsList,
1189  UNDO_REDO_T aTypeCommand,
1190  const wxPoint& aTransformPoint = wxPoint( 0, 0 ) );
1191 
1192 private:
1193 
1201  void PutDataInPreviousState( PICKED_ITEMS_LIST* aList, bool aRedoCommand );
1202 
1210  void GetSchematicFromRedoList( wxCommandEvent& event );
1211 
1218  void GetSchematicFromUndoList( wxCommandEvent& event );
1219 
1226  void copyBlockItems( PICKED_ITEMS_LIST& aItemsList );
1227 
1234  void addJunctionMenuEntries( wxMenu* aMenu, SCH_JUNCTION* aJunction );
1235 
1236 public:
1237  void Key( wxDC* DC, int hotkey, EDA_ITEM* DrawStruct );
1238 
1243  void InitBlockPasteInfos() override;
1244 
1253  virtual int BlockCommand( EDA_KEY aKey ) override;
1254 
1262  virtual void HandleBlockPlace( wxDC* DC ) override;
1263 
1276  virtual bool HandleBlockEnd( wxDC* aDC ) override;
1277 
1285  void RepeatDrawItem( wxDC* DC );
1286 
1291  void SetRepeatItem( SCH_ITEM* aItem );
1292 
1299 
1308  void SetUndoItem( const SCH_ITEM* aItem );
1309 
1310  SCH_ITEM* GetUndoItem() const { return m_undoItem; }
1311 
1320  void SaveUndoItemInUndoList( SCH_ITEM* aItem );
1321 
1331  bool CreateArchiveLibraryCacheFile( bool aUseCurrentSheetFilename = false );
1332 
1340  bool CreateArchiveLibrary( const wxString& aFileName );
1341 
1357  bool RescueProject( bool aRunningOnDemand );
1358 
1367  virtual void PrintPage( wxDC* aDC, LSET aPrintMask,
1368  bool aPrintMirrorMode, void* aData = NULL ) override;
1369 
1370  void SetSimulatorCommand( const wxString& aCommand ) { m_simulatorCommand = aCommand; }
1371 
1372  wxString GetSimulatorCommand() const { return m_simulatorCommand; }
1373 
1374  void SetNetListerCommand( const wxString& aCommand ) { m_netListerCommand = aCommand; }
1375 
1381  void DefaultExecFlags() { m_exec_flags = wxEXEC_SYNC; }
1382 
1389  void SetExecFlags( const int aFlags ) { m_exec_flags |= aFlags; }
1390 
1397  void ClearExecFlags( const int aFlags ) { m_exec_flags &= ~( aFlags ); }
1398 
1399  wxString GetNetListerCommand() const { return m_netListerCommand; }
1400 
1402  const static wxCursor CURSOR_PROBE;
1403 
1405  const static wxCursor CURSOR_TUNE;
1406 
1407  DECLARE_EVENT_TABLE()
1408 };
1409 
1410 
1411 #endif // WX_EESCHEMA_STRUCT_H
void OnLoadProject(wxCommandEvent &event)
Definition: schframe.cpp:1033
void SetCurrentSheet(const SCH_SHEET_PATH &aSheet)
Definition: schframe.cpp:574
void ReCreateOptToolbar()
Definition: tool_sch.cpp:274
void OnFindDrcMarker(wxFindDialogEvent &event)
Definition: find.cpp:58
SCH_NO_CONNECT * AddNoConnect(wxDC *aDC, const wxPoint &aPosition)
Function AddNoConnect add a no connect item to the current schematic sheet at aPosition.
Class SCH_BUS_WIRE_ENTRY.
void RepeatDrawItem(wxDC *DC)
Function RepeatDrawItem repeats the last item placement if the last item was a bus, bus entry, label, or component.
ANNOTATE_ORDER_T
Schematic annotation order options.
Definition: schframe.h:84
void OrientComponent(COMPONENT_ORIENTATION_T aOrientation=CMP_NORMAL)
Function OrientComponent rotates and mirrors a component.
Definition: getpart.cpp:279
const wxString GetNetListFormatName() const
Definition: schframe.h:247
wxString m_netListerCommand
Command line to call a custom net list generator.
Definition: schframe.h:147
Class SCH_FIELD instances are attached to a component and provide a place for the component's value...
Definition: sch_field.h:56
void DeleteConnection(bool DeleteFullConnection)
Definition: schedit.cpp:652
Annotate using the first free reference number starting at the sheet number * 100.
Definition: schframe.h:95
void EditComponent(SCH_COMPONENT *aComponent)
Function EditComponent displays the edit component dialog to edit the parameters of aComponent...
void OnOpenCvpcb(wxCommandEvent &event)
Definition: schframe.cpp:1112
A list of parameters type.
void RotateField(SCH_FIELD *aField)
bool OnHotKey(wxDC *aDC, int aHotKey, const wxPoint &aPosition, EDA_ITEM *aItem=NULL) override
void OnSelectOptionToolbar(wxCommandEvent &event)
Definition: tool_sch.cpp:315
Class KIWAY_EXPRESS carries a payload from one KIWAY_PLAYER to another within a PROJECT.
Definition: kiway_express.h:39
void DefaultExecFlags()
Function DefaultExecFlags resets the execution flags to defaults for external netlist and bom generat...
Definition: schframe.h:1381
Class SCH_FIND_COLLECTOR is used to iterate over all of the items in a schematic or sheet and collect...
void Process_Config(wxCommandEvent &event)
void sendNetlist()
Function sendNetlist sends the kicad netlist over to CVPCB.
const TEMPLATES & GetTemplates()
Function GetTemplates returns the field names template for read only access.
Definition: schframe.h:337
bool OpenProjectFiles(const std::vector< wxString > &aFileSet, int aCtl=0) override
NETLIST_OBJECT_LIST * BuildNetListBase(bool updateStatusText=true)
BuildNetListBase netlist generation: Creates a flat list which stores all connected objects...
void OnMoveItem(wxCommandEvent &aEvent)
Function OnMoveItem handles the ID_SCH_MOVE_ITEM event used to move schematic itams.
Definition: schedit.cpp:422
void OnFindItems(wxCommandEvent &event)
Definition: schframe.cpp:927
void DeleteItem(SCH_ITEM *aItem)
Function DeleteItem removes aItem from the current screen and saves it in the undo list...
SCH_JUNCTION * AddJunction(wxDC *aDC, const wxPoint &aPosition, bool aPutInUndoList=false)
Function AddJunction adds a new junction at aPosition.
wxString GetSimulatorCommand() const
Definition: schframe.h:1372
void OnLoadFile(wxCommandEvent &event)
Definition: schframe.cpp:983
Find an item by it's reference designator.
Definition: schframe.h:106
void OnUpdateSaveSheet(wxUpdateUIEvent &aEvent)
Definition: schframe.cpp:816
bool LoadCmpToFootprintLinkFile()
Function ReadCmpToFootprintLinkFile Loads a .cmp file from CvPcb and update the footprin field of com...
Definition: backanno.cpp:221
void OnUpdateHiddenPins(wxUpdateUIEvent &event)
Definition: schframe.cpp:798
void SetPlotDirectoryName(const wxString &aDirName)
Definition: schframe.h:264
void OnOpenPcbModuleEditor(wxCommandEvent &event)
Definition: schframe.cpp:1094
int AddTemplateFieldName(const TEMPLATE_FIELDNAME &aFieldName)
Function AddTemplateFieldName inserts or appends a wanted symbol field name into the field names temp...
Definition: schframe.h:317
static const KICAD_T AllItems[]
A scan list for all schematic items.
bool RescueProject(bool aRunningOnDemand)
Function RescueProject performs rescue operations to recover old projects from before certain changes...
PARAM_CFG_ARRAY m_projectFileParams
Definition: schframe.h:124
void SaveCopyInUndoList(SCH_ITEM *aItemToCopy, UNDO_REDO_T aTypeCommand, const wxPoint &aTransformPoint=wxPoint(0, 0))
Function SaveCopyInUndoList.
SCH_ITEM * GetRepeatItem() const
Function GetRepeatItem returns the item which is to be repeated with the insert key.
Definition: schframe.h:1298
void OnPreferencesOptions(wxCommandEvent &event)
void SetPrintDialogPosition(const wxPoint &aPoint)
Definition: schframe.h:678
wxArrayString m_findStringHistoryList
Definition: schframe.h:137
void SetForceHVLines(bool aForceHVdirection)
Definition: schframe.h:241
bool GetForceHVLines() const
Definition: schframe.h:240
void OnModify()
Function OnModify Must be called after a schematic change in order to set the "modify" flag of the cu...
Definition: schframe.cpp:762
virtual int BlockCommand(EDA_KEY aKey) override
Function BlockCommand Returns the block command internat code (BLOCK_MOVE, BLOCK_COPY...) corresponding to the keys pressed (ALT, SHIFT, SHIFT ALT ..) when block command is started by dragging the mouse.
void OnNewProject(wxCommandEvent &event)
Definition: schframe.cpp:999
int CheckAnnotate(wxArrayString *aMessageList, bool aOneSheetOnly)
Function CheckAnnotate checks for annotation errors.
Definition: annotate.cpp:187
void OnFindDialogClose(wxFindDialogEvent &event)
Definition: schframe.cpp:965
void ReCreateMenuBar() override
Function ReCreateMenuBar Creates recreates the menu bar.
wxString m_DefaultSchematicFileName
Definition: schframe.h:121
static wxSize m_lastSheetPinTextSize
Last sheet pin text size.
Definition: schframe.h:179
wxPoint GetLastSheetPinPosition() const
Definition: schframe.h:1043
bool GetPrintMonochrome()
Definition: schframe.h:688
wxPoint m_printDialogPosition
Definition: schframe.h:130
void OnLaunchBomManager(wxCommandEvent &event)
Definition: schframe.cpp:918
void OnConvertTextType(wxCommandEvent &aEvent)
Function OnCovertTextType is a command event handler to change a text type to an other one...
Definition: edit_label.cpp:137
void ChangeTextOrient(SCH_TEXT *aTextItem)
Definition: edit_label.cpp:50
SCH_FIND_COLLECTOR m_foundItems
List of find/replace items.
Definition: schframe.h:143
void copyBlockItems(PICKED_ITEMS_LIST &aItemsList)
Function copyBlockItems copies the list of block item.
void Layer(DRAWSEGMENT *Segment, wxDC *DC)
Find a component field.
Definition: schframe.h:108
static const wxCursor CURSOR_TUNE
Tuner cursor, used by circuit simulator
Definition: schframe.h:1405
PARAM_CFG_ARRAY & GetConfigurationSettings()
Function GetConfigurationSettings returns the Eeschema applications settings.
void OnCloseWindow(wxCloseEvent &Event)
Definition: schframe.cpp:613
void addCurrentItemToList(bool aRedraw=true)
Function addCurrentItemToList adds the item currently being edited to the schematic and adds the chan...
Definition: schframe.cpp:1279
void UpdateTitle()
Function UpdateTitle sets the main window title bar text.
Definition: schframe.cpp:1376
wxFindReplaceData * m_findReplaceData
Definition: schframe.h:127
void OnAppendProject(wxCommandEvent &event)
ANNOTATE_OPTION_T
Schematic annotation type options.
Definition: schframe.h:93
int m_repeatLabelDelta
Repeat label number increment step.
Definition: schframe.h:141
std::vector< COMPONENT_SELECTION > HISTORY_LIST
bool GetPrintSheetReference()
Definition: schframe.h:690
The common library.
void OnPrint(wxCommandEvent &event)
Show the print dialog.
Definition: schframe.cpp:1223
int AddTemplateFieldName(const TEMPLATE_FIELDNAME &aFieldName)
Function AddTemplateFieldName inserts or appends a wanted symbol field name into the fieldnames templ...
void SetSimulatorCommand(const wxString &aCommand)
Definition: schframe.h:1370
void RotateHierarchicalSheet(SCH_SHEET *aSheet, bool aRotCCW)
Rotate a sheet on itself.
Definition: sheet.cpp:405
void BeginSegment(wxDC *DC, int type)
Function BeginSegment creates a new segment ( WIRE, BUS ) or terminates the current segment in progre...
void OnEditItem(wxCommandEvent &aEvent)
Function OnEditItem handles the ID_SCH_EDIT_ITEM event used to edit schematic itams.
Definition: schedit.cpp:944
SCH_ITEM * GetUndoItem() const
Definition: schframe.h:1310
Schematic editor (Eeschema) main window.
Definition: schframe.h:117
void SetPrintSheetReference(bool aShow)
Definition: schframe.h:691
SCH_COLLECTOR m_collectedItems
List of collected items.
Definition: schframe.h:142
SCH_TEXT * CreateNewText(wxDC *aDC, int aType)
Definition: edit_label.cpp:66
void MirrorImage(SCH_BITMAP *aItem, bool Is_X_axis)
Function MirrorImage Mirror a bitmap.
void SetPrintMonochrome(bool aMonochrome)
Definition: schframe.h:689
void OnRescueProject(wxCommandEvent &event)
Definition: schframe.cpp:1211
virtual void HandleBlockPlace(wxDC *DC) override
Function HandleBlockPlace Called after HandleBlockEnd, when a block command needs to be executed afte...
void DisplayCurrentSheet()
Function DisplayCurrentSheet draws the current sheet on the display.
Definition: hierarch.cpp:279
bool m_autoplaceAlign
align autoplaced fields to the grid
Definition: schframe.h:156
Class REPORTER is a pure virtual class used to derive REPORTER objects from.
Definition: reporter.h:61
TEMPLATES m_TemplateFieldNames
Definition: schframe.h:183
void EditComponentFieldText(SCH_FIELD *aField)
Function EditComponentFieldText displays the edit field dialog to edit the parameters of aField...
SCH_ITEM * LocateItem(const wxPoint &aPosition, const KICAD_T aFilterList[]=SCH_COLLECTOR::AllItems, int aHotKeyCommandId=0)
Function LocateItem checks for items at aPosition matching the types in aFilterList.
void OnUpdateBlockSelected(wxUpdateUIEvent &event)
Definition: schframe.cpp:773
Implementing DIALOG_SCH_FIND_BASE.
void OnCopySchematicItemRequest(wxCommandEvent &event)
Function OnCopySchematicItemRequest is the command event handler for duplicating the item at the curr...
Component library viewer main window.
Definition: viewlib_frame.h:49
void OnUpdateHierarchySheet(wxUpdateUIEvent &aEvent)
Definition: schframe.cpp:823
KICAD_T
Enum KICAD_T is the set of class identification values, stored in EDA_ITEM::m_StructType.
Definition: typeinfo.h:90
wxString GetNetListerCommand() const
Definition: schframe.h:1399
void SetRepeatItem(SCH_ITEM *aItem)
Function SetRepeatItem clones aItem and owns that clone in this container.
Definition: schframe.cpp:460
void PrepareMoveItem(SCH_ITEM *aItem, wxDC *aDC)
Function PrepareMoveItem start moving aItem using the mouse.
Definition: schedit.cpp:784
void SaveProjectSettings(bool aAskForSave) override
Function SaveProjectSettings saves changes to the project settings to the project (...
void InstallHierarchyFrame(wxPoint &pos)
Definition: hierarch.cpp:141
void SaveUndoItemInUndoList(SCH_ITEM *aItem)
Function SaveUndoItemInUndoList swaps the cloned item in member variable m_undoItem with aItem and sa...
Definition: schframe.cpp:598
void updateFindReplaceView(wxFindDialogEvent &aEvent)
Definition: find.cpp:453
void OnUpdateSave(wxUpdateUIEvent &aEvent)
Definition: schframe.cpp:808
Class NETLIST_OBJECT_LIST is a container holding and owning NETLIST_OBJECTs, which are connected item...
SCH_SHEET_PIN * CreateSheetPin(SCH_SHEET *aSheet, wxDC *aDC)
Function CreateSheetPin creates a new SCH_SHEET_PIN object and add it to aSheet at the current cursor...
Definition: sheetlab.cpp:110
Find a component pin in the schematic.
Definition: schframe.h:105
Class SCH_BUS_ENTRY_BASE.
Definition: sch_bus_entry.h:43
PARAM_CFG_ARRAY & GetProjectFileParametersList()
Function GetProjectFileParametersList returns the project file parameter list for Eeschema...
SCH_SCREEN * GetScreen() const override
Function GetScreen returns a pointer to a BASE_SCREEN or one of its derivatives.
Definition: schframe.cpp:521
Class SCH_COLLECTOR.
void EndSegment(wxDC *DC)
Function EndSegment called to terminate a bus, wire, or line creation.
virtual wxString GetScreenDesc() const override
Definition: schframe.cpp:527
DRAWSEGMENT * Begin_Edge(DRAWSEGMENT *Segment, wxDC *DC)
SCH_SHEET_PATH * m_CurrentSheet
which sheet we are presently working on.
Definition: schframe.h:120
double BestZoom() override
Return the zoom level which displays the full page on screen.
Definition: schframe.cpp:707
SCH_BUS_BUS_ENTRY * CreateBusBusEntry()
Definition: busentry.cpp:42
UNDO_REDO_T
Undo Redo considerations: Basically we have 3 cases New item Deleted item Modified item there is also...
void SendMessageToPCBNEW(EDA_ITEM *aObjectToSync, SCH_COMPONENT *aPart)
Function SendMessageToPcbnew send a remote to Pcbnew via a socket connection.
void OnFindSchematicItem(wxFindDialogEvent &aEvent)
Function OnFindSchematicItem finds an item in the schematic matching the search criteria in aEvent...
Definition: find.cpp:305
SCH_ITEM * LocateAndShowItem(const wxPoint &aPosition, const KICAD_T aFilterList[]=SCH_COLLECTOR::AllItems, int aHotKeyCommandId=0)
Function LocateAndShowItem checks the schematic at aPosition in logical (drawing) units for a item ma...
const wxString & GetPlotDirectoryName() const
accessor to the destination directory to use when generating plot files.
Definition: schframe.h:263
void InitBlockPasteInfos() override
Function InitBlockPasteInfos initializes the parameters used by the block paste command.
SCH_SHEET * CreateSheet(wxDC *DC)
Definition: sheet.cpp:352
void DeleteAllTemplateFieldNames()
Function DeleteAllTemplateFieldNames removes all template field names.
Definition: schframe.h:346
Annotate by X position from left to right.
Definition: schframe.h:85
bool m_forceHVLines
force H or V directions for wires, bus, line
Definition: schframe.h:152
void SetInitCmp(SCH_COMPONENT *DrawComponent, wxDC *DC)
static wxString GetDefaultFieldName(int aFieldNdx)
Function GetDefaultFieldName returns a default symbol field name for field aFieldNdx for all componen...
Annotate by position of component in the schematic sheet object list.
Definition: schframe.h:87
void addJunctionMenuEntries(wxMenu *aMenu, SCH_JUNCTION *aJunction)
Function addJunctionMenuEntries adds the context menu items to aMenu for aJunction.
void Save_File(wxCommandEvent &event)
void ReCreateHToolbar() override
Definition: tool_sch.cpp:45
void SetBusEntryShape(wxDC *DC, SCH_BUS_ENTRY_BASE *BusEntry, char entry_shape)
Definition: busentry.cpp:66
Class LSET is a set of PCB_LAYER_IDs.
std::vector< TEMPLATE_FIELDNAME > TEMPLATE_FIELDNAMES
DIALOG_SCH_FIND * m_dlgFindReplace
Definition: schframe.h:134
bool HighlightConnectionAtPosition(wxPoint aPosition)
Function HighlightConnectionAtPosition Highlight the connection found at aPosition.
static PINSHEETLABEL_SHAPE m_lastSheetPinType
Last sheet pin type.
Definition: schframe.h:178
const wxPoint & GetPreviewPosition()
Definition: schframe.h:675
bool AppendOneEEProject()
Function AppendOneEEProject read an entire project and loads it into the schematic editor without rep...
bool DeleteItemAtCrossHair(wxDC *aDC)
Function DeleteItemAtCrossHair delete the item found under the cross hair.
Definition: schedit.cpp:666
void DeleteCurrentSegment(wxDC *DC)
Function DeleteCurrentSegment erases the last segment at the current mouse position.
void DeleteAnnotation(bool aCurrentSheetOnly)
Function DeleteAnnotation clears the current component annotation.
Definition: annotate.cpp:39
void OnUpdateSelectTool(wxUpdateUIEvent &aEvent)
Definition: schedit.cpp:645
wxPageSetupDialogData m_pageSetupData
Definition: schframe.h:126
void OnUpdatePaste(wxUpdateUIEvent &event)
Definition: schframe.cpp:781
void OnRotate(wxCommandEvent &aEvent)
Function OnRotate handles the ID_SCH_ROTATE_CLOCKWISE and ID_SCH_ROTATE_COUNTERCLOCKWISE events used ...
Definition: schedit.cpp:838
bool prepareForNetlist()
Function prepareForNetlist verifies that annotation is complete so that a proper netlist is even poss...
Definitions for the Eeschema program SCH_SCREEN class.
bool GetShowAllPins() const
Definition: schframe.h:243
bool CreateNetlist(int aFormat, const wxString &aFullFileName, unsigned aNetlistOptions, REPORTER *aReporter=NULL)
Function CreateNetlist.
SCH_SHEET_PATH & GetCurrentSheet()
Definition: schframe.cpp:566
void Key(wxDC *DC, int hotkey, EDA_ITEM *DrawStruct)
SCH_ITEM * FindComponentAndItem(const wxString &aReference, bool aSearchHierarchy, SCH_SEARCH_T aSearchType, const wxString &aSearchText, bool aWarpMouse)
Function FindComponentAndItem finds a component in the schematic and an item in this component...
Definition: find.cpp:108
void PlotSchematic(wxCommandEvent &event)
bool LoadCacheLibrary(const wxString &aFileName)
Loads the cache library associated to the aFileName.
Annotate by Y position from top to bottom.
Definition: schframe.h:86
void Edge(DRAWSEGMENT *Segment, wxDC *DC)
void OnSelectUnit(wxCommandEvent &aEvent)
Definition: getpart.cpp:313
bool SaveEEFile(SCH_SCREEN *aScreen, bool aSaveUnderNewName=false, bool aCreateBackupFile=CREATE_BACKUP_FILE)
Function SaveEEFile saves aScreen to a schematic file.
bool CreateArchiveLibraryCacheFile(bool aUseCurrentSheetFilename=false)
Function CreateArchiveLibraryCacheFile creates a library file with the name of the root document plus...
Definition: libarch.cpp:43
wxSize m_printDialogSize
Definition: schframe.h:131
const wxSize & GetLastSheetPinTextSize()
Initializing accessor for the pin text size.
Definition: sheetlab.cpp:50
void OnSaveProject(wxCommandEvent &aEvent)
Function OnSaveProject is the command event handler to save the entire project and create a component...
void KiwayMailIn(KIWAY_EXPRESS &aEvent) override
Function KiwayMailIn receives KIWAY_EXPRESS messages from other players.
Class KIWAY is a minimalistic software bus for communications between various DLLs/DSOs (DSOs) within...
Definition: kiway.h:257
static const wxCursor CURSOR_PROBE
Probe cursor, used by circuit simulator
Definition: schframe.h:1402
SCH_ITEM * m_item_to_repeat
Last item to insert by the repeat command.
Definition: schframe.h:140
void RotateImage(SCH_BITMAP *aItem)
uint32_t EDA_KEY
Definition: common.h:52
wxPoint m_findDialogPosition
Definition: schframe.h:135
void backAnnotateFootprints(const std::string &aChangedSetOfReferences)
Definition: backanno.cpp:51
void OnAutoplaceFields(wxCommandEvent &aEvent)
Function OnAutoplaceFields handles the ID_AUTOPLACE_FIELDS event.
const TEMPLATE_FIELDNAMES & GetTemplateFieldNames()
Function GetTemplateFieldName returns a template fieldnames list for read only access.
bool LoadProjectFile()
Function LoadProjectFile loads the KiCad project file (*.pro) settings specific to Eeschema...
wxArrayString m_replaceStringHistoryList
Definition: schframe.h:138
void OnFindCompnentInLib(wxFindDialogEvent &event)
Class SCH_SHEET_PIN defines a sheet pin (label) used in sheets to create hierarchical schematics...
Definition: sch_sheet.h:62
virtual bool isAutoSaveRequired() const override
Function autoSaveRequired returns true if the schematic has been modified.
Definition: schframe.cpp:1263
Class SCH_SHEET_PATH.
void DeleteAllTemplateFieldNames()
Function DeleteAllTemplateFieldNames deletes the entire contents.
wxPageSetupDialogData & GetPageSetupData()
Definition: schframe.h:671
bool IsSearchCacheObsolete(const SCH_FIND_REPLACE_DATA &aSearchCriteria)
Definition: find.cpp:286
void EditSchematicText(SCH_TEXT *TextStruct)
bool m_printMonochrome
Print monochrome instead of grey scale.
Definition: schframe.h:132
Class PICKED_ITEMS_LIST is a holder to handle information on schematic or board items.
bool GetSpiceAjustPassiveValues() const
Definition: schframe.h:251
int m_foundItemIndex
An index to the last find item in the found items list m_foundItems.
Definition: schframe.h:159
const wxSize & GetPrintDialogSize()
Definition: schframe.h:686
void OnUpdatePCB(wxCommandEvent &event)
Definition: schframe.cpp:847
Annotate incrementally using the first free reference number.
Definition: schframe.h:94
void OnLoadCmpToFootprintLinkFile(wxCommandEvent &event)
Definition: schframe.cpp:992
void GetSchematicFromRedoList(wxCommandEvent &event)
Function GetSchematicFromRedoList Redo the last edition:
void SaveSettings(wxConfigBase *aCfg) override
Function SaveSettings saves common frame parameters to a configuration data file. ...
PARAM_CFG_ARRAY m_configSettings
Definition: schframe.h:125
SCH_BITMAP * CreateNewImage(wxDC *aDC)
void OnUpdateBusOrientation(wxUpdateUIEvent &event)
Definition: schframe.cpp:787
bool m_autoplaceFields
automatically place component fields
Definition: schframe.h:154
void LoadSettings(wxConfigBase *aCfg) override
Function LoadSettings loads common frame parameters from a configuration file.
void OnOpenLibraryEditor(wxCommandEvent &event)
Definition: schframe.cpp:1136
void SetPreviewPosition(const wxPoint &aPoint)
Definition: schframe.h:673
Class SCH_SHEET is the sheet symbol placed in a schematic, and is the entry point for a sub schematic...
Definition: sch_sheet.h:216
void PutDataInPreviousState(PICKED_ITEMS_LIST *aList, bool aRedoCommand)
Function PutDataInPreviousState is used in undo or redo command to put data pointed by List in the pr...
virtual bool doAutoSave() override
Function doAutoSave saves the schematic files that have been modified and not yet saved...
void OnCancelCurrentCommand(wxCommandEvent &aEvent)
Definition: schedit.cpp:497
void RedrawActiveWindow(wxDC *DC, bool EraseBg) override
Definition: eeredraw.cpp:54
Annotate using the first free reference number starting at the sheet number * 1000.
Definition: schframe.h:97
void CreateScreens()
Definition: schframe.cpp:535
void OnAnnotate(wxCommandEvent &event)
Definition: schframe.cpp:829
bool m_showAllPins
Flag to indicate show hidden pins.
Definition: schframe.h:162
void ReSizeSheet(SCH_SHEET *Sheet, wxDC *DC)
Definition: sheet.cpp:380
void MoveImage(SCH_BITMAP *aItem, wxDC *aDC)
bool m_printSheetReference
Definition: schframe.h:133
wxString m_SelectedNetName
Definition: schframe.h:122
Find an item by it's value field.
Definition: schframe.h:107
This file is part of the common library.
wxPoint m_previewPosition
Definition: schframe.h:128
void ClearExecFlags(const int aFlags)
Function ClearExecFlags clears (removes) specified flags that not needed for next execution of extern...
Definition: schframe.h:1397
PINSHEETLABEL_SHAPE
Definition: sch_text.h:46
void SetNetListFormatName(const wxString &aFormat)
Definition: schframe.h:249
wxSize m_previewSize
Definition: schframe.h:129
The component library editor main window.
Definition: libeditframe.h:51
void SetNewWidth(DRAWSEGMENT *DrawSegm, wxDC *DC)
const TEMPLATE_FIELDNAMES & GetTemplateFieldNames()
Function GetTemplateFieldName returns a template field names list for read only access.
Definition: schframe.h:327
wxSize m_findDialogSize
Definition: schframe.h:136
SCH_COMPONENT * Load_Component(wxDC *aDC, const SCHLIB_FILTER *aFilter, SCH_BASE_FRAME::HISTORY_LIST &aHistoryList, bool aUseLibBrowser)
Function Load_Component loads from a library and places a component.
Definition: getpart.cpp:196
class EDA_HOTKEY is a class to handle hot key commands.
Definition: hotkeys_basic.h:57
BLOCK_SELECTOR m_blockItems
List of selected items.
Definition: schframe.h:139
void OnExit(wxCommandEvent &event)
Definition: schframe.cpp:1217
int GetLabelIncrement() const
Definition: schframe.h:1082
Find a component in the schematic.
Definition: schframe.h:104
void OnLeftDClick(wxDC *aDC, const wxPoint &aPosition) override
Function OnLeftDClick called on a double click event from the drawpanel mouse handler if an editable ...
void SetPreviewSize(const wxSize &aSize)
Definition: schframe.h:674
SCH_EDIT_FRAME(KIWAY *aKiway, wxWindow *aParent)
void SetSheetNumberAndCount()
Function SetSheetNumberAndCount Set the m_ScreenNumber and m_NumberOfScreens members for screens must...
Definition: schframe.cpp:486
wxString m_plotDirectoryName
The name of the destination directory to use when generating plot files.
Definition: schframe.h:165
void OnLeftClick(wxDC *aDC, const wxPoint &aPosition) override
SCH_ITEM * m_undoItem
Copy of the current item being edited.
Definition: schframe.h:144
bool LoadOneEEFile(SCH_SCREEN *aScreen, const wxString &aFullFileName, bool append=false)
Function LoadOneEEFile loads the schematic (.sch) file aFullFileName into aScreen.
#define CREATE_BACKUP_FILE
Definition: wxstruct.h:59
void OnErc(wxCommandEvent &event)
Definition: schframe.cpp:835
bool m_autoplaceJustify
allow autoplace to change justification
Definition: schframe.h:155
Class SCH_FIND_REPLACE_DATA adds missing useful comparison and assignment operators to the wxFindRepl...
SCH_SEARCH_T
Schematic search type used by the socket link with Pcbnew.
Definition: schframe.h:103
void OnSelectTool(wxCommandEvent &aEvent)
Definition: schedit.cpp:519
void OnOpenPcbnew(wxCommandEvent &event)
Definition: schframe.cpp:1050
Class SCH_COMPONENT describes a real schematic component.
Definition: sch_component.h:69
Class EDA_ITEM is a base class for most all the KiCad significant classes, used in schematics and boa...
Definition: base_struct.h:151
const wxPoint & GetPrintDialogPosition()
Definition: schframe.h:685
virtual void PrintPage(wxDC *aDC, LSET aPrintMask, bool aPrintMirrorMode, void *aData=NULL) override
Function PrintPage plots or prints the current sheet to the clipboard.
Definition: schframe.cpp:1238
virtual void ExecuteRemoteCommand(const char *cmdline) override
Execute a remote command send by Pcbnew via a socket, port KICAD_SCH_PORT_SERVICE_NUMBER (currently 4...
wxString GetUniqueFilenameForCurrentSheet()
Function GetUniqueFilenameForCurrentSheet.
Definition: schframe.cpp:731
void EditImage(SCH_BITMAP *aItem)
void OnCreateNetlist(wxCommandEvent &event)
Definition: schframe.cpp:899
wxString m_simulatorCommand
Command line used to call the circuit simulator (gnucap, spice, ...)
Definition: schframe.h:145
Struct TEMPLATE_FIELDNAME holds a name of a component's field, field value, and default visibility...
void PasteListOfItems(wxDC *DC)
Function PastListOfItems pastes a list of items from the block stack.
Class SCH_BUS_WIRE_ENTRY.
wxString m_netListFormat
The name of the format to use when generating a net list.
Definition: schframe.h:168
bool OnRightClick(const wxPoint &aPosition, wxMenu *PopMenu) override
void OnDragItem(wxCommandEvent &aEvent)
Function OnDragItem handles the ID_SCH_DRAG_ITEM event used to drag schematic itams.
Definition: schedit.cpp:1065
bool GeneralControl(wxDC *aDC, const wxPoint &aPosition, EDA_KEY aHotKey=0) override
Function GeneralControl performs application specific control using aDC at aPosition in logical units...
SCH_SHEET_PIN * ImportSheetPin(SCH_SHEET *aSheet, wxDC *aDC)
Function ImportSheetPin automatically creates a sheet pin from the hierarchical labels in the schemat...
Definition: sheetlab.cpp:140
const wxSize & GetPreviewSize()
Definition: schframe.h:676
virtual bool HandleBlockEnd(wxDC *aDC) override
Function HandleBlockEnd Handle the "end" of a block command, i.e.
void OnOrient(wxCommandEvent &aEvent)
Function OnOrient handles the ID_SCH_MIRROR_X, ID_SCH_MIRROR_Y, and ID_SCH_ORIENT_NORMAL events used ...
Definition: schedit.cpp:1136
bool EditSheet(SCH_SHEET *aSheet, SCH_SHEET_PATH *aHierarchy)
Function EditSheet is used to edit an existing sheet or add a new sheet to the schematic.
Definition: sheet.cpp:44
void MirrorSheet(SCH_SHEET *aSheet, bool aFromXaxis)
Function MirrorSheet Mirror a hierarchical sheet Mirroring is made around its centre.
Definition: sheet.cpp:432
void OnSimulate(wxCommandEvent &event)
Definition: simulate.cpp:29
void SetUndoItem(const SCH_ITEM *aItem)
Function SetUndoItem clones aItem which can be used to restore the state of the item being edited whe...
Definition: schframe.cpp:580
int m_exec_flags
Flags of the wxExecute() function to call a custom net list generator.
Definition: schframe.h:149
void OnSelectItem(wxCommandEvent &aEvent)
Definition: schframe.cpp:1248
static wxPoint m_lastSheetPinPosition
Last sheet pin position.
Definition: schframe.h:180
void OnCreateBillOfMaterials(wxCommandEvent &event)
Definition: schframe.cpp:913
int EditSheetPin(SCH_SHEET_PIN *aSheetPin, bool aRedraw)
Function EditSheetPin displays the dialog for editing the parameters of aSheetPin.
Definition: sheetlab.cpp:61
SCH_BUS_WIRE_ENTRY * CreateBusWireEntry()
Definition: busentry.cpp:53
bool WriteNetListFile(NETLIST_OBJECT_LIST *aConnectedItemsList, int aFormat, const wxString &aFullFileName, unsigned aNetlistOptions, REPORTER *aReporter=NULL)
Function WriteNetListFile Create the netlist file.
Definition: netform.cpp:46
bool CreateArchiveLibrary(const wxString &aFileName)
Function CreateArchiveLibrary creates a library aFileName that contains all components used in the cu...
Definition: libarch.cpp:59
void SetPrintDialogSize(const wxSize &aSize)
Definition: schframe.h:684
void SetExecFlags(const int aFlags)
Function SetExecFlags sets (adds) specified flags for next execution of external generator of the net...
Definition: schframe.h:1389
Class SCH_BASE_FRAME is a shim class between EDA_DRAW_FRAME and several derived classes: LIB_EDIT_FRA...
bool m_spiceAjustPassiveValues
Use netcodes (net number) as net names when generating spice net lists.
Definition: schframe.h:171
void Process_Special_Functions(wxCommandEvent &event)
Definition: schedit.cpp:54
Struct IO_ERROR is a class used to hold an error message and may be used when throwing exceptions con...
Definition: ki_exception.h:47
Class SCH_ITEM is a base class for any item which can be embedded within the SCHEMATIC container clas...
Implementation of the label properties dialog.
COMPONENT_ORIENTATION_T
enum used in RotationMiroir()
Definition: schframe.h:70
void InstallConfigFrame(wxCommandEvent &event)
void SetNetListerCommand(const wxString &aCommand)
Definition: schframe.h:1374
void SetSpiceAjustPassiveValues(bool aEnable)
Definition: schframe.h:253
bool SetCurrentSheetHighlightFlags()
Function SetCurrentSheetHighlightFlags Set/reset the BRIGHTENED of connected objects inside the curre...
void SetShowAllPins(bool aEnable)
Definition: schframe.h:245
void ReCreateVToolbar() override
Definition: tool_sch.cpp:186
void AnnotateComponents(bool aAnnotateSchematic, ANNOTATE_ORDER_T aSortOption, ANNOTATE_OPTION_T aAlgoOption, bool aResetAnnotation, bool aRepairTimestamps, bool aLockUnits)
Function AnnotateComponents.
Definition: annotate.cpp:60
void GetSchematicFromUndoList(wxCommandEvent &event)
Function GetSchematicFromUndoList performs an undo the last edition:
void OnFindReplace(wxFindDialogEvent &aEvent)
Function OnReplace performs a search and replace of text in an item in the schematic matching the sea...
Definition: find.cpp:358
EDA_HOTKEY * GetHotKeyDescription(int aCommand) const override
>
void ConvertPart(SCH_COMPONENT *DrawComponent, wxDC *DC)
Definition: getpart.cpp:370
bool ProcessCmpToFootprintLinkFile(const wxString &aFullFilename, bool aForceVisibilityState, bool aVisibilityState)
Function ProcessStuffFile gets footprint info from each line in the Stuff File by Ref Desg...
Definition: backanno.cpp:132