Main¶
-
class
Main.
MainWindow
(parent, title)¶ Defines the main window that the user looks at when starting up the program. It is a subclass of wx.Frame which is just a simple Windows Frame.
Parameters: - parent (NoneType) – 99% of the time this should be None.
- title (string) – The caption of the frame’s title bar.
Return type: None
-
DisableMenuItems
()¶ Disables all the import menu items.
Return type: None
-
EnableMenuItems
()¶ Enables all the import menu items.
Return type: None
-
FitFrameInWindow
()¶ Checks if the frame fits in your screen. If not it changes the position and or the size to let it fit.
Return type: None
-
FullScreen
(event=None)¶ Sets the frame to full screen or go back from fullscreen. (This function is not available on mac)
Parameters: event (None or wx.event) – This tells the user with which event this defintions is called. (default is None) Return type: None
-
Import
(event, source)¶ Imports data.
Parameters: - event (wx.event) – This tells the user with which event this defintions is called.
- Source (definition) – This is the link to the definition that needs to be called
Return type: None
-
InitProject
()¶ This function gets called when the program is started and will see if there is a previously open project that is still available to open.
-
MainFrameMakePanels
()¶ Builds the panels of the mainframe.
Return type: None
-
MainFrameShow
()¶ Shows the frame and centers it
Return type: None
-
OnChangeMetadata
(event)¶ Makes changes to the metadata possible.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnDelete
(event)¶ Deletes the selected items.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnExit
(event)¶ closes the frame.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnKey
(event)¶ This function binds key events with functions.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnLoadProject
(event)¶ This function gets called when a user wants to load a project
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnNewProject
(event)¶ This function gets called when a user wants to create a project
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnProcess
(event=None, Source=[])¶ This function gets called when the user wants to start a process (plug-in).
Parameters: - event (wx.event or None) – This tells the user with which event this defintions is called. (default is None)
- Source (A list) – If the Opstree is not used but an other button (for example right mouse button), this list can be used to tell what process should be started.
Return type: None
-
OnRenameFile
(event)¶ Gives a textfield to renamen the selected file(s).
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnResize
(event)¶ This function updates the menu resolution list, checks fullscreen and reload the sash positions (layout). If the frame is resized this defintion is called.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnResolution
(event)¶ This function checks which resolution is clicked in resolution menu and changes the resolution.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnRightMouseFileTree
(event)¶ Gets the mouse position and checks if the mouse is in the FileTree.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnRightMouseOpsTree
(event)¶ Gets the mouse position and checks if the mouse is in the FileTree.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnSave
(event)¶ Export data to your computer.
Parameters: - event (wx.event) – This tells the user with which event this defintions is called.
- Source (string) – This gives the location where the image has to be saved.(“Disk” is from your computer, “Data” is from the database)
Return type: None
-
OnSelectFile
(event)¶ Is called when the user makes a change to the selection in the file dialog, this is for updating the metadata
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
OnSettings
(event)¶ Opens up the settings panel and checks if settings are changed and saves them.
Parameters: event (wx.event) – This tells the user with which event this defintions is called. Return type: None
-
class
ProjectFolderHandler
(patterns=None, ignore_patterns=None, ignore_directories=False, case_sensitive=False, parent=None)¶ This class checks if a change is made in the project folder. If so the message ReloadTrees is send, this can only happen ones per second.
-
class
MainWindow.
RelativePositionDictHandler
(patterns=None, ignore_patterns=None, ignore_directories=False, case_sensitive=False, parent=None)¶ This class checks for changes in the project folder, but only looks at .Tipp* files. When there is a change it will update the project metadata accordingly.
-
MainWindow.
ReloadTrees
(event=None)¶ Reloads filetree
Parameters: event (wx.event or None) – This tells the user with which event this defintions is called. (default is None) Return type: None
-
MainWindow.
SashPosLoad
()¶ Loads the current sash positions
Parameters: event (wx.event or None) – This tells the user with which event this defintions is called. (default is None) Return type: None
-
MainWindow.
SashPosSave
(event=None)¶ Saves the current sash positions
Parameters: event (wx.event or None) – This tells the user with which event this defintions is called. (default is None) Return type: None
-
MainWindow.
StartWatchdog
()¶ This starts a watchdog that keeps track if something changes in the project folder
-
MainWindow.
Timer
()¶ Makes sure you can not click an other button within the same second in the mainframe.
Return type: None
-
MainWindow.
start
()¶ Builds the frame, statusbar and the menubar.
Return type: None