User Tools

Site Tools


api:dk11:delphi:vcl.giscontrolscale.tgis_controlscale

TGIS_ControlScale class

DK for Delphi | VCL.GisControlScale.TGIS_ControlScale | Classes | Constructors | Methods | Properties | Events

Visual control for displaying the current map scale for an attached TGIS_ViewerWnd.

Available also on: Delphi FMX | .NET WinForms | Java | ActiveX | Python.

Syntax

// Delphi
type
  [ComponentPlatformsAttribute(pfidWindows)]
  TGIS_ControlScale = class( TCustomPanel, IGIS_Subscribe, IGIS_PrintableControl )
  end;
// C++ Builder
class PASCALIMPLEMENTATION TGIS_ControlScale : public TCustomPanel
{
};

Inheritance

→ TCustomPanel

Implements

Constructors

Inherited Overrides Protected
Name Visibility Description
Create public Create the map scale control.
Destroy public Destroy the control.

Methods

Inherited Overrides Protected
Name Visibility Description
CreateCopy public Prepare a copy of the control for printing.
(Implements IGIS_PrintableControl.CreateCopy)
Draw public Draw the current map scale.
DrawBmp(TBitmap; Double; Integer) public Draw the control on a provided VCL bitmap.
DrawBmp(TGIS_Bitmap; Double; Integer) public Draw the control on a provided GIS bitmap.
FreeCopy public Release a copy of the control.
(Implements IGIS_PrintableControl.FreeCopy)
Invalidate public Invalidates control.
Paint protected Paint the control.
PrintBmp public Print the control on the given bitmap.
(Implements IGIS_PrintableControl.PrintBmp)
PrintClipboard public Copy the control rendering to the clipboard.
PrintPdf public Print the control on the given PDF context.
(Implements IGIS_PrintableControl.PrintPdf)
SubscribedEvent public Subscriber notification event.
(Implements IGIS_Subscribe.SubscribedEvent)
Update public Update the control.

Properties

Inherited Protected
Name Visibility Description
Align published Standard VCL property.
Anchors published Standard VCL property.
BevelInner published Standard VCL property.
BevelOuter published Standard VCL property.
BevelWidth published Standard VCL property.
Bitmap public Bitmap. Valid only if control was created by Create with a parameter.
BorderStyle published Standard VCL property.
Color published Standard VCL property.
Ctl3D published Standard VCL property.
DividerColor1 published Color of the first divider.
DividerColor2 published Color of the second divider.
Dividers published Number of dividers.
DragCursor published Standard VCL property.
DragKind published Standard VCL property.
DragMode published Standard VCL property.
Enabled published Standard VCL property.
Font published Standard VCL property.
FullRepaint published Standard VCL property.
GIS_Bitmap public Bitmap. Valid only if control was created by Create with a parameter.
GIS_Viewer published Attached map viewer used to calculate and display the scale.
Glow published Draw a glowing shadow around the scale bar and labels.
HelpContext published Standard VCL property.
Hint published Standard VCL property.
InternalName public Used internally by TatukGIS.
(Implements IGIS_PrintableControl.InternalName)
ParentColor published Standard VCL property.
ParentCtl3D published Standard VCL property.
ParentFont published Standard VCL property.
ParentShowHint published Standard VCL property.
PopupMenu published Standard VCL property.
ShowHint published Standard VCL property.
TabOrder published Standard VCL property.
TabStop published Standard VCL property.
Touch published Standard VCL property.
Transparent published If True then control will be drawn as transparent.
Units public Units used for scale output.
UnitsEPSG published EPSG (European Petroleum Survey Group) code for scale output units.
Visible published Control visibility.

Events

Inherited Protected
Name Visibility Description
OnCanResize published Standard VCL event.
OnClick published Standard VCL event.
OnContextPopup published Standard VCL event.
OnDblClick published Standard VCL event.
OnDragDrop published Standard VCL event.
OnDragOver published Standard VCL event.
OnEndDrag published Standard VCL event.
OnEnter published Standard VCL event.
OnExit published Standard VCL event.
OnGesture published Standard VCL event.
OnKeyDown published Standard VCL event.
OnKeyPress published Standard VCL event.
OnKeyUp published Standard VCL event.
OnMouseDown published Standard VCL event.
OnMouseMove published Standard VCL event.
OnMouseUp published Standard VCL event.
OnMouseWheel published Standard VCL event.
OnMouseWheelDown published Standard VCL event.
OnMouseWheelUp published Standard VCL event.
OnResize published Standard VCL event.
OnStartDrag published Standard VCL event.
PrepareEvent published Fired before the control prepares the scale measurement.

Remarks

PURPOSE: Displays a scale bar that reflects the current map view and distance units reported by the connected viewer.

BEHAVIOR: Scale computation depends on TGIS_Viewer.CS units settings. The control refreshes in response to viewer updates and can render with dividers, custom colors, glow, and transparent paint.

USAGE: Place this component on a form and connect GIS_Viewer to TGIS_ViewerWnd.

CONSTRAINTS: GIS_Viewer should reference a valid TGIS_ViewerWnd instance for scale calculation and repaint updates.

2026/07/11 00:48

Page Tools