FerroUI/ docs

Search guides, controls, Rust APIs, and XAML.

    GitHub ↗

    TextCell

    struct · ferroui-controls-treedatagrid · v0.5.0

    struct TextCell<T: Clone + PartialEq + 'static>
    

    TextCell<T>: a cell whose value of type T is shown and edited as text.

    View source

    Members

    from_value

    fn from_value(value: Option<T>) -> Rc<Self>
    

    A read-only cell of a constant value (TextCell(T? value)).

    Source

    new

    fn new(binding: Rc<dyn ICellBinding<T>>, is_read_only: bool, options: Option<Rc<dyn ITextCellCultureOptions>>) -> Rc<Self>
    

    A cell of the value binding pushes; a cell that is not read only writes its changes back to the binding.

    Source

    is_read_only

    fn is_read_only(self: &Self) -> bool
    

    Whether the cell's value can be changed.

    Source

    value

    fn value(self: &Self) -> Option<T>
    

    The value of the cell.

    Source

    set_value

    fn set_value(self: &Self, value: Option<T>)
    

    Sets the value; a cell that is not read only and not editing writes it to its binding.

    Source

    text

    fn text(self: &Self) -> Option<String>
    

    The text of the cell: the text being edited, or the value formatted with the string format of the options, or the value's text.

    Source

    set_text

    fn set_text(self: &Self, value: Option<String>)
    

    Sets the text: while editing, the text being edited; otherwise the value converted from the text (a text that does not convert is ignored).

    Source

    try_set_source

    fn try_set_source(self: &Self, source: Option<&BoxedValue>) -> bool
    

    Points the cell's binding at another model (TrySetSource); false when the binding cannot be retargeted.

    Source

    this

    fn this(self: &Self) -> Option<Rc<Self>>
    

    The cell as a shared cell.

    Source

    Trait implementations

    Availability

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