wxCaret

wxCaret
A caret is a blinking cursor showing the position where the typed text will appear. The text controls usually have a caret but wxCaret class also allows to use a caret in other windows.

Currently, the caret appears as a rectangle of the given size. In the future, it will be possible to specify a bitmap to be used for the caret shape.

A caret is always associated with a window and the current caret can be retrieved using get_caret_window(). The same caret can't be reused in two different windows.

Functions/Procedures
Supertopics

wxCaret

[func]
caret_isok
( atom caret )

Category: wxCaret

Returns true if the caret was created successfully.


wxCaret

[func]
caret_isvisible
( atom caret )

Category: wxCaret

Returns true if the caret is visible and false if it is permanently hidden (if it is is blinking and not shown currently but will be after the next blink, this method still returns true).


wxCaret

[proc]
caret_kill_focus
( atom caret )

Category: wxCaret

Performs internal maintenance on the caret. Call this when your window loses focus.


wxCaret

[proc]
caret_set_focus
( atom caret )

Category: wxCaret

Performs internal maintenance on the caret. Call this when your window gains focus.


wxCaret

[func]
get_caret_blink_time
( atom caret )

Category: wxCaret

Returns the blink time which is measured in milliseconds and is the time elapsed between 2 inversions of the caret (blink time of the caret is the same for all carets, so this functions is static).


wxCaret

[func]
get_caret_position
( atom caret )

Category: wxCaret

Get the caret position (in pixels).


wxCaret

[func]
get_caret_size
( atom caret )

Category: wxCaret

Get the caret size.


wxCaret

[func]
get_caret_window
( atom caret )

Category: wxCaret

Get the window the caret is associated with.


wxCaret

[proc]
hide_caret
( atom caret )

Category: wxCaret

Hides the caret. Notice that if the caret was hidden N times, it must be shown N times as well to reappear on the screen.


wxCaret

[proc]
kill_caret_focus
( atom caret )

Category: wxCaret

Performs internal maintenance on the caret when focus is lost. Call this from your wxEVT_KILL_FOCUS event handler.


wxCaret

[proc]
move_caret
( atom caret, atom x, atom y )

Category: wxCaret

Move the caret to given position (in logical coordinates).


wxCaret

[proc]
set_caret_blink_time
( atom caret, atom milliseconds )

Category: wxCaret

Sets the blink time for all the carets.

Remarks

Under Windows, this function will change the blink time for all carets permanently (until the next time it is called), even for the carets in other applications.


wxCaret

[proc]
set_caret_focus
( atom caret )

Category: wxCaret

Performs internal maintenance on the caret when focus is gained. Call this from your wxEVT_SET_FOCUS event handler.


wxCaret

[proc]
set_caret_size
( atom caret, atom width, atom height )

Category: wxCaret

Changes the size of the caret.


wxCaret

[proc]
show_caret
( atom caret )

Category: wxCaret

Shows the caret. Notice that if the caret was hidden N times, it must be shown N times as well to reappear on the screen.