Skip to main content

SyntheticKind

Enum SyntheticKind 

Source
#[repr(u8)]
pub enum SyntheticKind { Paragraph = 1, TextRun = 2, ImageRun = 3, Link = 4, SceneItem = 5, SceneGroup = 6, SceneMagnet = 7, ChartMark = 8, Annotation = 9, LaneMark = 10, }
Expand description

Discriminator kind for synthetic-NodeId hashing. Different kinds sharing the same (widget_id, element_id) tuple produce distinct NodeIds so paragraph and run nodes for the same source element don’t collide.

Variants§

§

Paragraph = 1

§

TextRun = 2

§

ImageRun = 3

An inline link span inside a label-style widget’s text (e.g. [docs](url) inside a TextWidget with .markup(true) enabled). Each link span becomes one synthetic child of the hosting widget’s own node, with Role::Link and the link label as its name.

§

SceneItem = 5

A lightweight SceneItem rendered by teksilo_scene::SceneView. Items live outside the arena — SceneView::accessibility emits one synthetic child per visible item using push_scene_child.

§

SceneGroup = 6

A logical grouping declared via Scene::add_a11y_group. Pure AT structure — no visual counterpart. The parent’s children list orders mixed SceneItem and SceneGroup synthetic NodeIds however the app declared the logical tree.

§

SceneMagnet = 7

A magnetism anchor (“magnet”) attached to a scene item. Emitted as a synthetic child of the owning item’s node by SceneView::accessibility when magnetism is enabled, so the anchor is screen-reader perceivable and can be the target of the view’s active_descendant during the keyboard connect flow.

§

ChartMark = 8

A per-datum mark (bar / line point / pie slice) emitted by a teksilo-charts widget’s accessibility().

§

Annotation = 9

An annotation body (a comment thread) attached to a run of text, emitted by a rich-text widget alongside the TextRun that carries it. The run points at this node through the details relation — AccessKit’s aria-details — which is what lets a screen reader say “has comment” and let the user navigate in, rather than reciting the thread inline every time the caret crosses the span.

§

LaneMark = 10

A positional mark in a margin lane — the strip beside a scroll area that maps where things are in a document rather than picturing it.

Emitted by the lane widget’s accessibility(), one synthetic child per mark, the same shape SyntheticKind::ChartMark uses per datum. Marks get their own nodes, rather than riding the content they refer to, for the reason CodeGutter gives for not doing so: line numbers are uniform, dense and derivable from the text, so they belong on the paragraph node as position_in_set; lane marks are sparse, heterogeneous and not derivable from anything — “a comment from Marie at 62 percent” is not in the paragraph, so there is no node to delegate to.

Trait Implementations§

Source§

impl Clone for SyntheticKind

Source§

fn clone(&self) -> SyntheticKind

Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Copy for SyntheticKind

Source§

impl Debug for SyntheticKind

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.