MiniatureWindow Namespace Reference


Classes

class  SystemWindow
class  SystemPanel
class  RectangleArea

Functions

def __init__
def OnClose
def DrawSystem
def OnDbUpdate
def OnLeftWindow
def OnMouseMove
def DrawSystem
def OnSize

Variables

int SYSTEM_PANEL = 6001
int SYSTEM_WINDOW_HEIGHT = 200
int SYSTEM_WINDOW_WIDTH = 200
int CLOSE_BUTTON = 101
int CREATE_SUBSYSTEM = 8001
int CLOSE_WINDOW = 8002
int MODIFY_SUBSYSTEM = 8003
int SET_AS_ACTIVE = 8004
 main
 systemPanel
 main
 height
 centerX
 centerY
 zoomarea
 dragMode
 moveOriginX
 moveOriginY
 movedX
 movedY
 zoomarea
 dragMode
 moveOriginY
 dragMode
 moveOriginY
 dragMode
 dragMode
 zoomarea
 zoomarea
 height
 centerX
 centerY


Function Documentation

def MiniatureWindow::__init__ (   self,
  main,
  parent 
)

The constructor: Initializes the System Window.

Parameters: - the instance object of this class - the parent window (usually mainWindow) TURNING OBSELETE -> - ID of _this_ window, that the parent sets - Our communication object (mainWindow)

Constructor.

Parameters: - parent of this panel (usually SystemWindow) - id of this window (for widget reference), set by the parent - reference to the communication object (MainWindow)

Definition at line 45 of file MiniatureWindow.py.

def MiniatureWindow::DrawSystem (   self,
  event,
  donotchangearea = True,
  setScrollBars = False 
)

This is the paint method for this class disguised as a method to draw the system in a miniature view. This method can be called from the system (paint event) or an user (if we just need to repaint the window of some reason).

Parameters: - not used - (default: True), if we scroll on the scroll bars in the visual window, then we would like to update the relative position of the red rectangle to the rest of the SystemPanel as well. Only set when the scroll bars change in the visual window by the user or by code. - (default: False), whether we should update the scroll bars of the visual window or not (only on mouse button up after a drag of the red rectangle)

Definition at line 264 of file MiniatureWindow.py.

def MiniatureWindow::DrawSystem (   self  ) 

Whenever something is changed in Visual Window, we need to redraw the contents of the miniature window as well. This method is then called from the paint method in Visual Window to inform this window that the miniature window needs a repaint. We send the information further to the "real" miniature window: the system panel, which actually shows the contents.

Definition at line 82 of file MiniatureWindow.py.

def MiniatureWindow::OnClose (   self,
  event 
)

We need to know when this window closes to update the view menu in the main window; remove the hatch telling us whether this window is shown or not.

Parameters: - additional information sent from the close event trigger in this object

Definition at line 71 of file MiniatureWindow.py.

def MiniatureWindow::OnDbUpdate (   self,
  evtReason,
  cdb 
)

Whenever the status of the database connection changes, this needs to be informed to "all" the classes, so it is this method that is called from its parent to tell this. We need to tell the SystemPanel about this as well. At the moment we don't need to take any action from this.

Parameters: - A constant defining what kind of database connection change that occured. - Reference to the database connection object.

Whenever the status of the database connection changes, this needs to be informed to "all" the classes, so it is this method that is called from its parent to tell this. We clear the miniature window. (and hide it? TBC)

Parameters: - A constant defining what kind of database connection change that occured. - Reference to the database connection object.

Definition at line 96 of file MiniatureWindow.py.

def MiniatureWindow::OnLeftWindow (   self,
  event 
)

Whenever the cursor leaves the miniature window; we have to change it to the normal cursor again; as we may have changed it to something else when dragging or resizing.

Parameters: - event object with information about the event

Definition at line 189 of file MiniatureWindow.py.

def MiniatureWindow::OnMouseMove (   self,
  event 
)

When the mouse cursor is moved around in this window (on the SystemPanel, which covers the whole SystemWindow), we have to detect whether the we just move the mouse cursor or if we also hold down the left mousebutton, and if it is the latter one, if the mouse cursor is within the red rectangle. If all those are true: the user can move the red rectangle around, and when he/she releases the mouse button the view in the visual window is changed.

- event object; we make use of the x and y positions of the mouse cursor, and the actions with the left mouse button (mouse down and mouse up)

Definition at line 202 of file MiniatureWindow.py.

def MiniatureWindow::OnSize (   self,
  event 
)

If we resize the miniature window, we redraw the contents with the new proportion factor to the visual window.

Definition at line 353 of file MiniatureWindow.py.


Variable Documentation

MiniatureWindow::centerX

Definition at line 356 of file MiniatureWindow.py.

MiniatureWindow::centerX

Definition at line 146 of file MiniatureWindow.py.

MiniatureWindow::centerY

Definition at line 357 of file MiniatureWindow.py.

MiniatureWindow::centerY

Definition at line 147 of file MiniatureWindow.py.

int MiniatureWindow::CLOSE_BUTTON = 101 [static]

Definition at line 106 of file MiniatureWindow.py.

int MiniatureWindow::CLOSE_WINDOW = 8002 [static]

Definition at line 108 of file MiniatureWindow.py.

int MiniatureWindow::CREATE_SUBSYSTEM = 8001 [static]

Definition at line 107 of file MiniatureWindow.py.

MiniatureWindow::dragMode

Definition at line 240 of file MiniatureWindow.py.

MiniatureWindow::dragMode

Definition at line 239 of file MiniatureWindow.py.

MiniatureWindow::dragMode

Definition at line 225 of file MiniatureWindow.py.

MiniatureWindow::dragMode

Definition at line 217 of file MiniatureWindow.py.

MiniatureWindow::dragMode

Definition at line 160 of file MiniatureWindow.py.

MiniatureWindow::height

Definition at line 355 of file MiniatureWindow.py.

MiniatureWindow::height

Definition at line 145 of file MiniatureWindow.py.

MiniatureWindow::main

Definition at line 135 of file MiniatureWindow.py.

MiniatureWindow::main

Definition at line 57 of file MiniatureWindow.py.

int MiniatureWindow::MODIFY_SUBSYSTEM = 8003 [static]

Definition at line 109 of file MiniatureWindow.py.

MiniatureWindow::movedX

Definition at line 163 of file MiniatureWindow.py.

MiniatureWindow::movedY

Definition at line 164 of file MiniatureWindow.py.

MiniatureWindow::moveOriginX

Definition at line 161 of file MiniatureWindow.py.

MiniatureWindow::moveOriginY

Definition at line 231 of file MiniatureWindow.py.

MiniatureWindow::moveOriginY

Definition at line 220 of file MiniatureWindow.py.

MiniatureWindow::moveOriginY

Definition at line 162 of file MiniatureWindow.py.

int MiniatureWindow::SET_AS_ACTIVE = 8004 [static]

Definition at line 110 of file MiniatureWindow.py.

int MiniatureWindow::SYSTEM_PANEL = 6001 [static]

Definition at line 15 of file MiniatureWindow.py.

int MiniatureWindow::SYSTEM_WINDOW_HEIGHT = 200 [static]

Definition at line 16 of file MiniatureWindow.py.

int MiniatureWindow::SYSTEM_WINDOW_WIDTH = 200 [static]

Definition at line 17 of file MiniatureWindow.py.

MiniatureWindow::systemPanel

Definition at line 60 of file MiniatureWindow.py.

MiniatureWindow::zoomarea

Definition at line 287 of file MiniatureWindow.py.

MiniatureWindow::zoomarea

Definition at line 286 of file MiniatureWindow.py.

MiniatureWindow::zoomarea

Definition at line 208 of file MiniatureWindow.py.

MiniatureWindow::zoomarea

Definition at line 159 of file MiniatureWindow.py.


Generated on Fri Aug 31 11:11:19 2007 for CDBVis by  doxygen 1.5.3