Main Page   Class Hierarchy   Compound List   File List   Compound Members  

CommandHandler Class Reference

The most important class, since it processes all commands and redirects them to the right. More...

#include <chandbas.h>

List of all members.

Public Methods

 ~CommandHandler ()
 destructor

bool Replace_Setup (Setup *new_setup)
 replace layer setup by a new setup

int ExecuteCommand ()
 all commands are handled by this function

bool DoCommand (char *Format,...)
 used in case of formatted io command string (like printf)

bool GetStepMode ()
 step through process files or not

bool StepMode ()
 are we in debug step mode?

bool GetContinue ()
 continue through process files or not?

bool SetContinue (bool a)
 continue through process files or not setting

bool SetContinueFlag ()
 continue through process files or not command

double Get_ScaleFactor ()
 the factor of zoomin compared to the whole

int Get_ZoomHistoryEmpty ()
 is there zoom history

bool ZoomOut ()
 show the whole picture

bool ZoomOut2 ()
 show the whole picture times 2

bool ZoomBack ()
 zoom one level back

bool Draw ()
 redraw/draw the picture

bool GetSpline ()
 spline polygon/polylines

bool SetSpline ()
 spline polygon/polylines

bool Get_Record ()
 are commands recorded?

groupGet_A ()
 groupA layers for boolean operations

groupGet_B ()
 groupB layers for boolean operations

int Get_Destination ()
 get destination layer for boolean operations

bool Get_Destination_Add ()
 get destination layer for boolean operations

GdsII * Get_GDSII ()
 pointer to internal database structure

void Set_GDSII (GdsII *a_gdsii)
 make this datastructure the current one

Structure * Get_TopStructure ()
 top structure of the current database contents

wxString Get_FileName ()
 current filename

void Set_FileName (const wxString &filename)
 set the current filename

bool SetWidth ()
 set width to draw primitives with this command

wxUnitGetWidth ()
 get the current width

bool SetPathtype ()
 set pathtype used in path/polyline entry

int GetPathtype ()
 get pathtype used in path/polyline entry

bool GetViewCoord ()
 get setting for viewing coordinates in status bar or not

bool SetViewCoord (bool value)
 Set setting for viewing coordinates in status bar or not.

bool GetViewOutline ()
 get setting for viewing only outlines of primitives

bool SetViewOutline (bool value)
 Set setting for viewing only outlines of primitives.

bool GetSelectedOnly ()
 work on only selected elements?

bool GetVisibleOnly ()
 save visible only?

bool GetSaveSetUpOnExit ()
 save setup on exit?

bool GetGridVisible ()
 grid visible?

bool GetEnv (const wxString &envname, wxString &envstring)
 get given environment variable

bool SetEnv ()
 set given environment variable

bool GetAlias (const wxString &aliasname, wxString &aliasstring)
 get given alias variable

bool SetAlias ()
 set given alias variable

int GetNrAlias ()
 get the total number of defined aliases

bool GetAliasNr (int i, wxString &aliasname, wxString &aliasstring)
 get the index number of the given alias

bool GetMirrorX ()
 transform settings for transform commands

bool GetMirrorY ()
 transform settings for transform commands

wxUnitGetMoveHor ()
 transform settings for transform commands

wxUnitGetMoveVer ()
 transform settings for transform commands

double GetScale ()
 transform settings for transform commands

double GetRotate ()
 transform settings for transform commands

bool GetDirection ()
 transform settings for transform commands

long GetGridColour ()
 get gridcolour in use

long GetBackColour ()
 get background colour in use

wxUnitGetGridSpace ()
 get grid spacing

int GetGridPlacement ()
 grid on forground or background

double GetSelectmarge ()
 accuracy for selecting elements

wxUnitGetSnapfactor ()
 snapfactor used in boolean algorithm

wxUnitGetCorrectionfactor ()
 correction factor used in boolean algorithm

wxUnitGetCorrectionaber ()
 correction abberation used in boolean algorithm

double GetRoundfactor ()
 rounding factor used in boolean algorithm

wxString & GetRoundtype ()
 rounding type of corners, factor used in boolean algorithm

wxUnitGetPoly2ArcRmin ()
 polygon to arc conversion factors

wxUnitGetPoly2ArcRmax ()
 polygon to arc conversion factors

wxUnitGetPoly2ArcAber ()
 polygon to arc conversion factors

wxUnitGetArc2PolyAber ()
 polygon to arc conversion factors

wxUnitGetSmoothAber ()
 factor used in smoothing polygons

wxUnitGetDisplayaber ()
 factor used while displaying arcs and circles

int GetStrucThres ()
 smaller structure will not be displayed

int GetPrimThres ()
 smaller elements will not be displayed

bool GetDrawSmallPrim ()
 small elements will be displayed?

wxUnitGetMaxlinemerge ()
 factor used in smoothing polygons

double GetDefaultAcc ()
 default accuracy used for entering elements

wxUnit GetDefaultUnit ()
 default unit used for entering elements

void AddSlash (wxString &_filename)
 add slash to path

void StripSlash (wxString &_filename)
 strip slash from path

bool SetFileType (const wxString &_filetype)
 determines the current file type

wxString GetFileType ()
 determine the current file type

bool SetFileEnv (const wxString &_filetoload)
 set path aliases

bool SetProcEnv (const wxString &_processfile)
 set process file aliases

void SetupEnv ()
 load setup file

bool SetStartPoint ()
 set startpoint for measuring distances

bool SetRelPoint ()
 set relative point for measuring distances

bool KeyString ()
 key command string for adding elements

bool Select ()
 select an area or point

bool ReplaceStruct ()
 replace structure

ElementList * GetTopElementList ()
 get the element list of the structure that is displayed

bool ToHistory (char *Format,...)
 command to put in the history list

bool ToHistory (Command *a_command)
 command to put in the history list

int GetCurrentLayer ()
 get active layer

bool AddFileToHistory (const wxString &file, const wxString &type)
 add files to the history

bool CommandHandler::SaveHistory ()
 save the history files


Public Attributes

DL_List< Alias * > * _file_history

Protected Attributes

DL_List< void * > * _zoom_history
 zoom history list

double _scale
 zoom in factor

Handler_handler [200]
 array of function pointers to call funtions based on ascii commands


Detailed Description

The most important class, since it processes all commands and redirects them to the right.

subclasses for processing. Commandhandler interprets (graphical/commandline) userinterface commands. Commands are ascii strings, the first word is the keyword, followed by arguments. Commands can be recorded to a file, for later automatic processing. A history list of commands is maintained, allowing undo in certain cases. This file also calls functions from the mainwindow, to show complete dialogs See related classes "CommandParser", for the complete syntax of commands

See also:
CommandParser , ProcessParser


Member Data Documentation

DL_List<Alias*>* CommandHandler::_file_history
 

the file history holds some of the files that were loaded


The documentation for this class was generated from the following file: CommandHandler class Reference -- Thu Nov 28 21:24:57 2002 -- 28 Nov 2002 -- 1.2.18 -- -- . -- Main Page