Class TCefTextfieldRef

Description
Hierarchy
Fields
Methods
Properties

Unit

Declaration

type TCefTextfieldRef = class(TCefViewRef, ICefTextfield)

Description

A Textfield supports editing of text. This control is custom rendered with no platform-specific code. Methods must be called on the browser process UI thread unless otherwise indicated.

<see href="https://bitbucket.org/chromiumembedded/cef/src/master/include/capi/views/cef_textfield_capi.h">CEF source file: /include/capi/views/cef_textfield_capi.h (cef_textfield_t))

Hierarchy

Overview

Methods

Protected procedure SetPasswordInput(password_input: boolean);
Protected function IsPasswordInput: boolean;
Protected procedure SetReadOnly(read_only: boolean);
Protected function IsReadOnly: boolean;
Protected function GetText: ustring;
Protected procedure SetText(const text_: ustring);
Protected procedure AppendText(const text_: ustring);
Protected procedure InsertOrReplaceText(const text_: ustring);
Protected function HasSelection: boolean;
Protected function GetSelectedText: ustring;
Protected procedure SelectAll(reversed: boolean);
Protected procedure ClearSelection;
Protected function GetSelectedRange: TCefRange;
Protected procedure SelectRange(const range: TCefRange);
Protected function GetCursorPosition: NativeUInt;
Protected procedure SetTextColor(color: TCefColor);
Protected function GetTextColor: TCefColor;
Protected procedure SetSelectionTextColor(color: TCefColor);
Protected function GetSelectionTextColor: TCefColor;
Protected procedure SetSelectionBackgroundColor(color: TCefColor);
Protected function GetSelectionBackgroundColor: TCefColor;
Protected procedure SetFontList(const font_list: ustring);
Protected procedure ApplyTextColor(color: TCefColor; const range: TCefRange);
Protected procedure ApplyTextStyle(style: TCefTextStyle; add: boolean; const range: TCefRange);
Protected function IsCommandEnabled(command_id: TCefTextFieldCommands): boolean;
Protected procedure ExecuteCommand(command_id: TCefTextFieldCommands);
Protected procedure ClearEditHistory;
Protected procedure SetPlaceholderText(const text_: ustring);
Protected function GetPlaceholderText: ustring;
Protected procedure SetPlaceholderTextColor(color: TCefColor);
Protected procedure SetAccessibleName(const name: ustring);
Public class function UnWrap(data: Pointer): ICefTextfield;
Public class function CreateTextField(const delegate: ICefTextfieldDelegate): ICefTextfield;

Description

Methods

Protected procedure SetPasswordInput(password_input: boolean);

Sets whether the text will be displayed as asterisks.

Protected function IsPasswordInput: boolean;

Returns true (1) if the text will be displayed as asterisks.

Protected procedure SetReadOnly(read_only: boolean);

Sets whether the text will read-only.

Protected function IsReadOnly: boolean;

Returns true (1) if the text is read-only.

Protected function GetText: ustring;

Returns the currently displayed text.

Protected procedure SetText(const text_: ustring);

Sets the contents to |text|. The cursor will be moved to end of the text if the current position is outside of the text range.

Protected procedure AppendText(const text_: ustring);

Appends |text| to the previously-existing text.

Protected procedure InsertOrReplaceText(const text_: ustring);

Inserts |text| at the current cursor position replacing any selected text.

Protected function HasSelection: boolean;

Returns true (1) if there is any selected text.

Protected function GetSelectedText: ustring;

Returns the currently selected text.

Protected procedure SelectAll(reversed: boolean);

Selects all text. If |reversed| is true (1) the range will end at the logical beginning of the text; this generally shows the leading portion of text that overflows its display area.

Protected procedure ClearSelection;

Clears the text selection and sets the caret to the end.

Protected function GetSelectedRange: TCefRange;

Returns the selected logical text range.

Protected procedure SelectRange(const range: TCefRange);

Selects the specified logical text range.

Protected function GetCursorPosition: NativeUInt;

Returns the current cursor position.

Protected procedure SetTextColor(color: TCefColor);

Sets the text color.

Protected function GetTextColor: TCefColor;

Returns the text color.

Protected procedure SetSelectionTextColor(color: TCefColor);

Sets the selection text color.

Protected function GetSelectionTextColor: TCefColor;

Returns the selection text color.

Protected procedure SetSelectionBackgroundColor(color: TCefColor);

Sets the selection background color.

Protected function GetSelectionBackgroundColor: TCefColor;

Returns the selection background color.

Protected procedure SetFontList(const font_list: ustring);

Sets the font list. The format is "<FONT_FAMILY_LIST>,[STYLES] <SIZE>", where: - FONT_FAMILY_LIST is a comma-separated list of font family names, - STYLES is an optional space-separated list of style names (case-sensitive "Bold" and "Italic" are supported), and - SIZE is an integer font size in pixels with the suffix "px".

Here are examples of valid font description strings: - "Arial, Helvetica, Bold Italic 14px" - "Arial, 14px"

Protected procedure ApplyTextColor(color: TCefColor; const range: TCefRange);

Applies |color| to the specified |range| without changing the default color. If |range| is NULL the color will be set on the complete text contents.

Protected procedure ApplyTextStyle(style: TCefTextStyle; add: boolean; const range: TCefRange);

Applies |style| to the specified |range| without changing the default style. If |add| is true (1) the style will be added, otherwise the style will be removed. If |range| is NULL the style will be set on the complete text contents.

Protected function IsCommandEnabled(command_id: TCefTextFieldCommands): boolean;

Returns true (1) if the action associated with the specified command id is enabled. See additional comments on execute_command().

Protected procedure ExecuteCommand(command_id: TCefTextFieldCommands);

Performs the action associated with the specified command id.

Protected procedure ClearEditHistory;

Clears Edit history.

Protected procedure SetPlaceholderText(const text_: ustring);

Sets the placeholder text that will be displayed when the Textfield is NULL.

Protected function GetPlaceholderText: ustring;

Returns the placeholder text that will be displayed when the Textfield is NULL.

Protected procedure SetPlaceholderTextColor(color: TCefColor);

Sets the placeholder text color.

Protected procedure SetAccessibleName(const name: ustring);

Set the accessible name that will be exposed to assistive technology (AT).

Public class function UnWrap(data: Pointer): ICefTextfield;

Returns a ICefTextfield instance using a PCefTextfield data pointer.

Public class function CreateTextField(const delegate: ICefTextfieldDelegate): ICefTextfield;

Create a new Textfield.


Generated by PasDoc 0.16.0-snapshot.