FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    RichTextBlockImpl

    trait · ferroui-controls · v0.5.0

    trait RichTextBlockImpl: ControlImpl + $crate::Upcast<RichTextBlock>
    

    The overridable members introduced by the class.

    View source

    Members

    render_text

    fn render_text(this: &Self, context: &mut DrawingContext<'_>)
    

    Paints text content after the background and selection highlights.

    Source

    caret_visible

    fn caret_visible(this: &Self) -> bool
    

    Whether the insertion caret is visible (editable views override this).

    Source

    fn allow_hyperlink_navigation(this: &Self, modifiers: KeyModifiers) -> bool
    

    Whether pointer input activates a hyperlink or edits its text.

    Source

    on_selection_changing

    fn on_selection_changing(this: &Self, args: &RichTextSelectionChangedEventArgs) -> bool
    

    Runs synchronously while the proposed selection is visible to readers. Returning false cancels it unless a handler selected a different range.

    Source

    request_selection_change

    fn request_selection_change(this: &Self, start: usize, end: usize) -> bool
    

    Lets an editable view arbitrate a normalized selection through its editor.

    Source

    rebase_selection_on_document_change

    fn rebase_selection_on_document_change(this: &Self) -> bool
    

    Editors publish their final transaction selection after document changes.

    Source

    text_insets

    fn text_insets(this: &Self) -> Thickness
    

    Space outside the document's formatted text, including editor adornments.

    Source

    text_layout_constraint

    fn text_layout_constraint(this: &Self, available_size: Size) -> Size
    

    The formatter constraint, independent of a scrollable view's viewport.

    Source

    default_incremental_tab

    fn default_incremental_tab(this: &Self, font_size: f64) -> f64
    

    Implicit tab interval for a paragraph without an assigned override.

    Source

    text_origin

    fn text_origin(this: &Self) -> Point
    

    Shared origin for text, inline controls, caret, selection and hit testing.

    Source

    selection_is_visible

    fn selection_is_visible(this: &Self) -> bool
    

    Whether the selection is currently drawn in this view (its highlight, and the selection foreground of the selected text).

    Source

    selection_render_brush

    fn selection_render_brush(this: &Self) -> Option<Rc<dyn IBrush>>
    

    The selection background after the host's focus policy is applied.

    Source

    raise_selection_changed_event

    fn raise_selection_changed_event(this: &Self)
    

    Publishes the selection event on the owning control.

    Source

    text_focus_target

    fn text_focus_target(this: &Self) -> Ref<InputElement>
    

    The keyboard focus target for pointer interaction with text.

    Source

    text_background_bounds

    fn text_background_bounds(this: &Self) -> Rect
    

    Bounds painted by the document background; editor headers are outside it.

    Source

    additional_visual_children

    fn additional_visual_children(this: &Self) -> Vec<Ref<Visual>>
    

    Native framework visuals displayed beside the document's inline controls.

    Source

    Trait implementations

    Availability

    Extracted for aarch64-apple-darwin. Cargo features are listed in the crate index.