Class TCustomCreateScreenObjectTool

DescriptionHierarchyFieldsMethodsProperties

Unit

Declaration

type TCustomCreateScreenObjectTool = class(TCustomStoreVerticesTool)

Description

TCustomCreateScreenObjectTool is an abstract base class for TCustomInteractiveTools for creating TScreenObjects.

Hierarchy

Overview

Fields

Protected FCurrentUndo: TCustomUndo;
Protected FDoubleClicked: boolean;
Protected FPriorCursorX: integer;
Protected FPriorCursorY: integer;

Methods

Private function CanAddPoint32: boolean;
Protected function CanAddPoint: boolean;
Protected procedure SetDefaultElevationFormulas;
Protected function ShouldClosePolygon(X, Y: integer): boolean; virtual;
Public procedure RemoveScreenObject;
Public constructor Create(AOwner: TComponent); override;
Public destructor Destroy; override;
Public procedure DoubleClick(Sender: TObject); override;
Public procedure FinishScreenObjects;
Public procedure MouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); override;
Public procedure MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); override;

Properties

Protected property CurrentUndo: TCustomUndo read FCurrentUndo;

Description

Fields

Protected FCurrentUndo: TCustomUndo;

FCurrentUndo: TCustomUndo; See CurrentUndo.

Protected FDoubleClicked: boolean;

FDoubleClicked: boolean; FDoubleClicked is set to true in DoubleClick and is used in MouseUp to indicate when the TScreenObject has been completed.

Protected FPriorCursorX: integer;

FPriorCursorX: integer; FPriorCursorX is set to the X-coordinate of the cursor in MouseUp. In some descendants it is tested for identity with the current X-coordinate of the cursor before being set and action is taken if the location is different.

Protected FPriorCursorY: integer;

FPriorCursorY: integer; FPriorCursorY is set to the Y-coordinate of the cursor in MouseUp. In some descendants it is tested for identity with the current X-coordinate of the cursor before being set and action is taken if the location is different.

Methods

Private function CanAddPoint32: boolean;
 
Protected function CanAddPoint: boolean;

CanAddPoint returns true if the mouse is over the correct view to add a point to CurrentScreenObject.

Protected procedure SetDefaultElevationFormulas;

SetDefaultElevationFormulas is used to set the default values for the elevation formulas when creating a TScreenObject.

Protected function ShouldClosePolygon(X, Y: integer): boolean; virtual;
 
Public procedure RemoveScreenObject;
 
Public constructor Create(AOwner: TComponent); override;
 
Public destructor Destroy; override;
 
Public procedure DoubleClick(Sender: TObject); override;

DoubleClick responds to Double-Click events to set FDoubleClicked to True. FDoubleClicked is used in MouseUp to indicate when the TScreenObject has been completed.

Public procedure FinishScreenObjects;

FinishScreenObjects shows the form that allows the user to specify the properties of the new TScreenObject.

Public procedure MouseUp(Sender: TObject; Button: TMouseButton; Shift: TShiftState; X, Y: Integer); override;

MouseUp checks if FDoubleClicked is True. if so, it calls FinishScreenObjects. It also sets FPriorCursorX and FPriorCursorY.

Public procedure MouseMove(Sender: TObject; Shift: TShiftState; X, Y: Integer); override;
 

Properties

Protected property CurrentUndo: TCustomUndo read FCurrentUndo;

CurrentUndo is used to undo or redo the creation of the TScreenObject.


Generated by PasDoc 0.12.1 on 2013-05-13 15:41:42