pub trait GenericLayoutDataTrait:
Any
+ MallocSizeOfTrait
+ Send
+ Sync
+ 'static {
// Required methods
fn as_any(&self) -> &dyn Any;
fn set_text_run_selection(
&self,
new_range: Option<RangeAny<Utf32CodeUnits>>,
) -> bool;
fn set_element_selection(&self, selected: bool) -> bool;
fn rendered_text(&self, range: RangeAny<Utf32CodeUnits>) -> Option<String>;
}Required Methods§
fn as_any(&self) -> &dyn Any
Sourcefn set_text_run_selection(
&self,
new_range: Option<RangeAny<Utf32CodeUnits>>,
) -> bool
fn set_text_run_selection( &self, new_range: Option<RangeAny<Utf32CodeUnits>>, ) -> bool
Returns whether new_range was successfully set on an existing text run
Sourcefn set_element_selection(&self, selected: bool) -> bool
fn set_element_selection(&self, selected: bool) -> bool
Set whether or not this node is selected when it is an element. Returns true
if anything changed that requires a new display list.
Sourcefn rendered_text(&self, range: RangeAny<Utf32CodeUnits>) -> Option<String>
fn rendered_text(&self, range: RangeAny<Utf32CodeUnits>) -> Option<String>
Get the text rendered by this node, if it is a CharacterData node and produces
a TextRun in the box tree.