[Overview][Constants][Types][Procedures and functions][Variables][Index] Reference for unit 'video' (#rtl)

GetCursorType

Get screen cursor type

Declaration

Source position: videoh.inc line 139

function GetCursorType: Word;

Description

GetCursorType returns the current cursor type. It is one of the following values:

crHidden
Hide cursor
crUnderLine
Underline cursor
crBlock
Block cursor
crHalfBlock
Half block cursor

Note that not all drivers support all types of cursors.

Errors

None.

See also

SetCursorType

  

Set cursor type

GetCapabilities

  

Get current driver capabilities.

Example

Program Example5;

{ Program to demonstrate the GetCursorType function. }

Uses video,keyboard,vidutil;

Const
  Cursortypes : Array[crHidden..crHalfBlock] of string =
    ('Hidden','UnderLine','Block','HalfBlock');

begin
  InitVideo;
  InitKeyboard;
  TextOut(1,1,'Cursor type: '+CursorTypes[GetCursorType]);
  TextOut(1,2,'Press any key to exit.');
  UpdateScreen(False);
  GetKeyEvent;
  DoneKeyboard;
  DoneVideo;
end.
The latest version of this document can be found at lazarus-ccr.sourceforge.net.