GRASS Programmer's Manual
6.4.4(2014)-r
|
A Buffered window extended for vector digitizer. More...
Public Member Functions | |
def | __init__ (self, parent, id=wx.ID_ANY, Map=None, tree=None, lmgr=None, style=wx.NO_FULL_REPAINT_ON_RESIZE, kwargs) |
def | GetDisplay (self) |
def | SetToolbar (self, toolbar) |
Set up related toolbar. More... | |
def | OnKeyDown (self, event) |
Key pressed. More... | |
def | OnLeftDownAddLine (self, event) |
Left mouse button pressed - add new feature. More... | |
def | OnLeftDownEditLine (self, event) |
Left mouse button pressed - edit linear feature - add new vertex. More... | |
def | OnLeftDownMoveLine (self, event) |
Left mouse button pressed - vector digitizer move feature/vertex, edit linear feature. More... | |
def | OnLeftDownDisplayCA (self, event) |
Left mouse button pressed - vector digitizer display categories or attributes action. More... | |
def | OnLeftDownCopyCA (self, event) |
Left mouse button pressed - vector digitizer copy categories or attributes action. More... | |
def | OnLeftDownCopyLine (self, event) |
Left mouse button pressed - vector digitizer copy lines action. More... | |
def | OnLeftDownBulkLine (self, event) |
Left mouse button pressed - vector digitizer label 3D vector lines. More... | |
def | OnLeftDownUndo (self, event) |
Left mouse button pressed with control key - vector digitizer undo functionality. More... | |
def | OnLeftUpVarious (self, event) |
Left mouse button released - vector digitizer various actions. More... | |
def | OnLeftUpModifyLine (self, event) |
Left mouse button released - vector digitizer split line, add/remove vertex action. More... | |
def | OnLeftUpCopyLine (self, event) |
Left mouse button released - vector digitizer copy feature action. More... | |
def | OnLeftUpBulkLine (self, event) |
Left mouse button released - vector digitizer z-bulk line action. More... | |
def | OnLeftUpConnectLine (self, event) |
Left mouse button released - vector digitizer connect line action. More... | |
![]() | |
def | __init__ (self, parent, id=wx.ID_ANY, Map=None, tree=None, lmgr=None, overlays=None, style=wx.NO_FULL_REPAINT_ON_RESIZE, kwargs) |
def | Draw (self, pdc, img=None, drawid=None, pdctype='image', coords=[0) |
Draws map and overlay decorations. More... | |
def | TextBounds |
Return text boundary data. More... | |
def | OnPaint (self, event) |
Draw PseudoDC's to buffered paint DC. More... | |
def | OnSize (self, event) |
Scale map image so that it is the same size as the Window. More... | |
def | OnIdle (self, event) |
Only re-render a composite map image from GRASS during idle time instead of multiple times during resizing. More... | |
def | SaveToFile (self, FileName, FileType, width, height) |
This draws the pseudo DC to a buffer that can be saved to a file. More... | |
def | GetOverlay (self) |
Converts rendered overlay files to wx.Image. More... | |
def | GetImage (self) |
Converts redered map files to wx.Image. More... | |
def | UpdateMap |
Updates the canvas anytime there is a change to the underlaying images or to the geometry of the canvas. More... | |
def | DrawCompRegionExtent (self) |
Draw computational region extent in the display. More... | |
def | IsInRegion (self, region, refRegion) |
Test if 'region' is inside of 'refRegion'. More... | |
def | EraseMap (self) |
Erase map canvas. More... | |
def | DragMap (self, moveto) |
Drag the entire map image for panning. More... | |
def | DragItem (self, id, event) |
Drag an overlay decoration item. More... | |
def | MouseDraw |
Mouse box or line from 'begin' to 'end'. More... | |
def | DrawLines |
Draw polyline in PseudoDC. More... | |
def | DrawCross (self, pdc, coords, size, rotation=0, text=None, textAlign='lr', textOffset=(5, 5) |
Draw cross in PseudoDC. More... | |
def | MouseActions (self, event) |
Mouse motion and button click notifier. More... | |
def | OnMouseWheel (self, event) |
Mouse wheel moved. More... | |
def | OnDragging (self, event) |
Mouse dragging. More... | |
def | OnLeftDown (self, event) |
Left mouse button pressed. More... | |
def | OnLeftUp (self, event) |
Left mouse button released. More... | |
def | OnButtonDClick (self, event) |
Mouse button double click. More... | |
def | OnRightDown (self, event) |
Right mouse button pressed. More... | |
def | OnRightUp (self, event) |
Right mouse button released. More... | |
def | OnMiddleDown (self, event) |
Middle mouse button pressed. More... | |
def | OnMiddleUp (self, event) |
Middle mouse button released. More... | |
def | OnMouseEnter (self, event) |
Mouse entered window and no mouse buttons were pressed. More... | |
def | OnMouseMoving (self, event) |
Motion event and no mouse buttons were pressed. More... | |
def | ClearLines |
Clears temporary drawn lines from PseudoDC. More... | |
def | Pixel2Cell (self, x, y) |
Convert image coordinates to real word coordinates. More... | |
def | Cell2Pixel (self, east, north) |
Convert real word coordinates to image coordinates. More... | |
def | Zoom (self, begin, end, zoomtype) |
Calculates new region while (un)zoom/pan-ing. More... | |
def | ZoomBack (self) |
Zoom to previous extents in zoomhistory list. More... | |
def | ZoomHistory (self, n, s, e, w) |
Manages a list of last 10 zoom extents. More... | |
def | ResetZoomHistory (self) |
Reset zoom history. More... | |
def | ZoomToMap |
Set display extents to match selected raster or vector map(s). More... | |
def | ZoomToWind (self) |
Set display geometry to match computational region settings (set with g.region) More... | |
def | ZoomToDefault (self) |
Set display geometry to match default region settings. More... | |
def | GoTo (self, e, n) |
def | DisplayToWind (self) |
Set computational region (WIND file) to match display extents. More... | |
def | ZoomToSaved (self) |
Set display geometry to match extents in saved region file. More... | |
def | SaveDisplayRegion (self) |
Save display extents to named region file. More... | |
def | SaveRegion (self, wind) |
Save region settings. More... | |
def | Distance |
Calculete distance. More... | |
![]() | |
def | __init__ (self, parent, id=wx.ID_ANY, Map=None, tree=None, lmgr=None, kwargs) |
def | RegisterMouseEventHandler |
Binds event handler. More... | |
def | UnregisterMouseEventHandler (self, event) |
Unbinds event handler a restores previous state. More... | |
def | Pixel2Cell (self, x, y) |
def | Cell2Pixel (self, east, north) |
def | OnMotion (self, event) |
Tracks mouse motion and update statusbar. More... | |
def | GetLastEN (self) |
Returns last coordinates of mouse cursor. More... | |
def | GetLayerByName |
Get layer from layer tree by nam. More... | |
def | GetSelectedLayer |
Get selected layer from layer tree. More... | |
Data Fields | |
pdcVector | |
toolbar | |
digit | |
redrawAll | |
moveInfo | |
pen | |
polypen | |
copyCatsList | |
copyCatsIds | |
copyIds | |
layerTmp | |
polycoords | |
![]() | |
resize | |
dragimg | |
pen | |
polypen | |
polycoords | |
lineid | |
plineid | |
processMouse | |
mapfile | |
img | |
overlays | |
imagedict | |
select | |
textdict | |
currtxtid | |
zoomhistory | |
currzoom | |
zoomtype | |
hitradius | |
dialogOffset | |
redrawAll | |
self.OnSize(None) More... | |
dragid | |
lastpos | |
pdc | |
pdcVector | |
pdcDec | |
pdcTmp | |
bufferLast | |
buffer | |
self.Map.AlignExtentFromDisplay() More... | |
regionCoords | |
idlist | |
![]() | |
parent | |
Map | |
tree | |
lmgr | |
mouse | |
lastEN | |
A Buffered window extended for vector digitizer.
Definition at line 28 of file vdigit/mapwindow.py.
def mapwindow.VDigitWindow.__init__ | ( | self, | |
parent, | |||
id = wx.ID_ANY , |
|||
Map = None , |
|||
tree = None , |
|||
lmgr = None , |
|||
style = wx.NO_FULL_REPAINT_ON_RESIZE , |
|||
kwargs | |||
) |
Definition at line 33 of file vdigit/mapwindow.py.
def mapwindow.VDigitWindow.GetDisplay | ( | self | ) |
Definition at line 43 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow.digit, dialogs.VDigitCategoryDialog.digit, and mapdisplay.MapFrame.digit.
def mapwindow.VDigitWindow.OnKeyDown | ( | self, | |
event | |||
) |
Key pressed.
Definition at line 81 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow.toolbar, frame.PsMapFrame.toolbar, frame.ModelFrame.toolbar, and histogram.HistogramFrame.toolbar.
def mapwindow.VDigitWindow.OnLeftDownAddLine | ( | self, | |
event | |||
) |
Left mouse button pressed - add new feature.
Definition at line 131 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow._geomAttrb(), mapwindow.VDigitWindow._updateATM(), mapwindow.BufferedWindow.dialogOffset, mapwindow.BufferedWindow.DrawLines(), mapwindow.MapWindow.mouse, mapwindow.BufferedWindow.pdcTmp, mapwindow.MapWindow.Pixel2Cell(), gcmd.RunCommand(), and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownBulkLine | ( | self, | |
event | |||
) |
Left mouse button pressed - vector digitizer label 3D vector lines.
Definition at line 406 of file vdigit/mapwindow.py.
References mapwindow.BufferedWindow.polycoords.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownCopyCA | ( | self, | |
event | |||
) |
Left mouse button pressed - vector digitizer copy categories or attributes action.
Definition at line 388 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownCopyLine | ( | self, | |
event | |||
) |
Left mouse button pressed - vector digitizer copy lines action.
Definition at line 398 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownDisplayCA | ( | self, | |
event | |||
) |
Left mouse button pressed - vector digitizer display categories or attributes action.
Definition at line 304 of file vdigit/mapwindow.py.
References mapwindow.BufferedWindow.dialogOffset, mapwindow.MapWindow.mouse, mapwindow.MapWindow.Pixel2Cell(), forms.UpdateDialog(), and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownEditLine | ( | self, | |
event | |||
) |
Left mouse button pressed - edit linear feature - add new vertex.
Definition at line 278 of file vdigit/mapwindow.py.
References mapwindow.BufferedWindow.DrawLines(), mapwindow.MapWindow.mouse, mapwindow.VDigitWindow.moveInfo, mapwindow.BufferedWindow.pdcTmp, and mapwindow.MapWindow.Pixel2Cell().
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownMoveLine | ( | self, | |
event | |||
) |
Left mouse button pressed - vector digitizer move feature/vertex, edit linear feature.
Definition at line 286 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo().
def mapwindow.VDigitWindow.OnLeftDownUndo | ( | self, | |
event | |||
) |
Left mouse button pressed with control key - vector digitizer undo functionality.
Definition at line 423 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow.copyCatsIds, mapwindow.VDigitWindow.copyCatsList, mapwindow.VDigitWindow.copyIds, mapwindow.VDigitWindow.layerTmp, mapwindow.MapWindow.mouse, mapwindow.VDigitWindow.moveInfo, mapwindow.VDigitWindow.OnLeftDownAddLine(), mapwindow.VDigitWindow.OnLeftDownBulkLine(), mapwindow.VDigitWindow.OnLeftDownCopyCA(), mapwindow.VDigitWindow.OnLeftDownCopyLine(), mapwindow.VDigitWindow.OnLeftDownDisplayCA(), mapwindow.VDigitWindow.OnLeftDownEditLine(), mapwindow.VDigitWindow.OnLeftDownMoveLine(), mapwindow.BufferedWindow.pen, mapwindow.BufferedWindow.polycoords, mapwindow.BufferedWindow.polypen, mapwindow.BufferedWindow.redrawAll, mapwindow.VDigitWindow.toolbar, frame.PsMapFrame.toolbar, frame.ModelFrame.toolbar, histogram.HistogramFrame.toolbar, and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.BufferedWindow.OnLeftDown().
def mapwindow.VDigitWindow.OnLeftUpBulkLine | ( | self, | |
event | |||
) |
Left mouse button released - vector digitizer z-bulk line action.
Definition at line 756 of file vdigit/mapwindow.py.
References mapwindow.BufferedWindow.DrawLines(), mapwindow.BufferedWindow.pdcTmp, mapwindow.BufferedWindow.polycoords, and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftUpConnectLine().
def mapwindow.VDigitWindow.OnLeftUpConnectLine | ( | self, | |
event | |||
) |
Left mouse button released - vector digitizer connect line action.
Definition at line 772 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow._geomAttrb(), mapwindow.VDigitWindow._geomAttrbUpdate(), mapwindow.VDigitWindow._updateATM(), mapwindow.MapWindow.Cell2Pixel(), mapwindow.BufferedWindow.ClearLines(), mapwindow.VDigitWindow.copyCatsIds, mapwindow.VDigitWindow.copyCatsList, mapwindow.VDigitWindow.copyIds, mapwindow.BufferedWindow.dialogOffset, mapwindow.BufferedWindow.DrawLines(), mapwindow.VDigitWindow.layerTmp, mapwindow.MapWindow.mouse, mapwindow.BufferedWindow.MouseDraw(), mapwindow.VDigitWindow.moveInfo, mapwindow.VDigitWindow.OnLeftUpBulkLine(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), mapwindow.VDigitWindow.OnLeftUpCopyLine(), mapwindow.VDigitWindow.OnLeftUpModifyLine(), mapwindow.VDigitWindow.OnLeftUpVarious(), mapwindow.BufferedWindow.pdcTmp, mapwindow.MapWindow.Pixel2Cell(), mapwindow.BufferedWindow.polycoords, mapwindow.BufferedWindow.redrawAll, gcmd.RunCommand(), and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftUpConnectLine().
def mapwindow.VDigitWindow.OnLeftUpCopyLine | ( | self, | |
event | |||
) |
Left mouse button released - vector digitizer copy feature action.
Definition at line 709 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow.copyIds, mapwindow.VDigitWindow.layerTmp, utils.ListOfCatsToRange(), mapwindow.MapWindow.mouse, mapwindow.MapWindow.Pixel2Cell(), and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftUpConnectLine().
def mapwindow.VDigitWindow.OnLeftUpModifyLine | ( | self, | |
event | |||
) |
Left mouse button released - vector digitizer split line, add/remove vertex action.
Definition at line 677 of file vdigit/mapwindow.py.
References mapwindow.MapWindow.Cell2Pixel(), mapwindow.BufferedWindow.DrawCross(), mapwindow.MapWindow.mouse, mapwindow.BufferedWindow.pdcTmp, mapwindow.MapWindow.Pixel2Cell(), and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftUpConnectLine().
def mapwindow.VDigitWindow.OnLeftUpVarious | ( | self, | |
event | |||
) |
Left mouse button released - vector digitizer various actions.
Definition at line 550 of file vdigit/mapwindow.py.
References mapwindow.VDigitWindow.copyCatsIds, mapwindow.VDigitWindow.copyCatsList, mapwindow.BufferedWindow.dialogOffset, mapwindow.MapWindow.mouse, mapwindow.VDigitWindow.moveInfo, mapwindow.MapWindow.Pixel2Cell(), mapwindow.BufferedWindow.polycoords, and mapwindow.BufferedWindow.UpdateMap().
Referenced by mapwindow.VDigitWindow.OnLeftUpConnectLine().
def mapwindow.VDigitWindow.SetToolbar | ( | self, | |
toolbar | |||
) |
Set up related toolbar.
Definition at line 48 of file vdigit/mapwindow.py.
References mapwindow.BufferedWindow.Distance(), mapwindow.BufferedWindow.polycoords, tools.range, mapwindow.VDigitWindow.toolbar, frame.PsMapFrame.toolbar, frame.ModelFrame.toolbar, and histogram.HistogramFrame.toolbar.
mapwindow.VDigitWindow.copyCatsIds |
Definition at line 395 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), and mapwindow.VDigitWindow.OnLeftUpVarious().
mapwindow.VDigitWindow.copyCatsList |
Definition at line 393 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), and mapwindow.VDigitWindow.OnLeftUpVarious().
mapwindow.VDigitWindow.copyIds |
Definition at line 403 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), and mapwindow.VDigitWindow.OnLeftUpCopyLine().
mapwindow.VDigitWindow.digit |
Definition at line 39 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.GetDisplay(), toolbars.VDigitToolbar.OnSettings(), toolbars.VDigitToolbar.OnTool(), toolbars.VDigitToolbar.StartEditing(), and toolbars.VDigitToolbar.StopEditing().
mapwindow.VDigitWindow.layerTmp |
Definition at line 404 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownUndo(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), and mapwindow.VDigitWindow.OnLeftUpCopyLine().
mapwindow.VDigitWindow.moveInfo |
Definition at line 290 of file vdigit/mapwindow.py.
Referenced by mapwindow.VDigitWindow.OnLeftDownEditLine(), mapwindow.VDigitWindow.OnLeftDownUndo(), mapwindow.VDigitWindow.OnLeftUpConnectLine(), and mapwindow.VDigitWindow.OnLeftUpVarious().
mapwindow.VDigitWindow.pdcVector |
Definition at line 37 of file vdigit/mapwindow.py.
mapwindow.VDigitWindow.pen |
Definition at line 300 of file vdigit/mapwindow.py.
mapwindow.VDigitWindow.polycoords |
Definition at line 411 of file vdigit/mapwindow.py.
mapwindow.VDigitWindow.polypen |
Definition at line 300 of file vdigit/mapwindow.py.
mapwindow.VDigitWindow.redrawAll |
Definition at line 117 of file vdigit/mapwindow.py.
mapwindow.VDigitWindow.toolbar |
Definition at line 38 of file vdigit/mapwindow.py.
Referenced by mapwindow.BufferedWindow.OnDragging(), mapwindow.VDigitWindow.OnKeyDown(), mapwindow.VDigitWindow.OnLeftDownUndo(), and mapwindow.VDigitWindow.SetToolbar().