Public Member Functions | |
this (WindowBase w) | |
Constructs a new Caret with unspecified size and position. | |
this (WindowBase w, Point p) | |
Constructs a new Caret at the given position. | |
this (WindowBase w, RectDim d) | |
Constructs a new Caret with the given dimensions. | |
this (WindowBase w, Point p, RectDim d) | |
Constructs a new Caret with the given position and dimensions. | |
this (WindowBase w, Bitmap b) | |
Constructs a new Caret from a bitmap. | |
this (WindowBase w, Point p, Bitmap b) | |
Constructs a new Caret with the given position and bitmap. | |
CARET_STYLE | style () |
How the caret is displayed. | |
CARET_STYLE | style (CARET_STYLE s) |
How the caret is displayed. | |
RectDim | dim () |
The dimensions of a rectangular (non-bitmap) caret. | |
RectDim | dim (RectDim d) |
The dimensions of a rectangular (non-bitmap) caret. | |
Bitmap | bitmap () |
The bitmap used to display the caret. | |
Bitmap | bitmap (Bitmap b) |
The bitmap used to display the caret. | |
Point | position () |
The current position of the caret within its window. | |
Point | position (Point p) |
The current position of the caret within its window. | |
void | show () |
Displays the caret and starts it blinking. | |
void | hide () |
Hides the caret. | |
uint | timesHidden () |
The caret's hide count. |
Unlike the Windows system caret, which is a single object that is passed between windows and controls that acquire keyboard focus, each Caret object belongs to a single window and persists for the window's lifetime.
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w | ) |
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w, | |
Point | p | |||
) |
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w, | |
RectDim | d | |||
) |
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w, | |
Point | p, | |||
RectDim | d | |||
) |
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w, | |
Bitmap | b | |||
) |
smjg.libs.sdwf.caret.Caret.this | ( | WindowBase | w, | |
Point | p, | |||
Bitmap | b | |||
) |
CARET_STYLE smjg.libs.sdwf.caret.Caret.style | ( | ) |
How the caret is displayed.
CARET_STYLE smjg.libs.sdwf.caret.Caret.style | ( | CARET_STYLE | s | ) |
RectDim smjg.libs.sdwf.caret.Caret.dim | ( | ) |
The dimensions of a rectangular (non-bitmap) caret.
RectDim smjg.libs.sdwf.caret.Caret.dim | ( | RectDim | d | ) |
Bitmap smjg.libs.sdwf.caret.Caret.bitmap | ( | ) |
The bitmap used to display the caret.
Bitmap smjg.libs.sdwf.caret.Caret.bitmap | ( | Bitmap | b | ) |
The bitmap used to display the caret.
Point smjg.libs.sdwf.caret.Caret.position | ( | Point | p | ) |
void smjg.libs.sdwf.caret.Caret.show | ( | ) |
void smjg.libs.sdwf.caret.Caret.hide | ( | ) |
Hides the caret.
Call this function before doing any drawing operations to the window containing the caret, to prevent display interference at the caret position. Call Caret.show to redisplay the caret afterwards.
Hiding is cumulative, so Caret.hide calls must be balanced by an equal number of Caret.show calls to restore visibility. This makes it possible to nest calls to functions that hide and redisplay the caret, and the caret will not reappear until all have finished.
uint smjg.libs.sdwf.caret.Caret.timesHidden | ( | ) |
The caret's hide count.
This is equal to the number of times Caret.show must be called to restore the caret's visibility.
This figure does not include instances in which an internal working of SDWF temporarily hides the caret.