API v0.2.0
mod dom
165 typesDomconstruction and configurationstruct Dom
has destructorThe document model, similar to HTML. This is a create-only structure, you don't actually read anything back from it. It's designed for ease of construction.
4 fields
The data for the root node of this DOM (or sub-DOM).
root: NodeData
The children of this DOM node.
children: DomVec
Ordered list of CSS stylesheets to apply to this DOM subtree. Stylesheets are applied in push order during the single deferred cascade pass. Later entries override earlier ones (higher cascade priority).
css: CssVec
estimated_total_children: usize
192 constructors
constructor create_div:
-> Dom
constructor create_body:
-> Dom
constructor create_text_do_not_use_without_block_level_wrapper:
constructor create_div_with_text:
constructor create_p_with_text:
constructor create_h1_with_text:
constructor create_h2_with_text:
constructor create_span_with_text:
constructor create_li_with_text:
constructor create_image:
constructor create_button:
arg text: String
arg aria: SmallAriaInfo
-> Dom
constructor create_button_no_a11y:
constructor create_icon:
constructor create_icon_view:
constructor create_from_parsed_xml:
constructor create_br:
-> Dom
constructor create_virtual_view:
arg data: RefAny
arg callback: VirtualViewCallback
-> Dom
constructor create_node:
constructor create_from_data:
constructor create_html:
-> Dom
constructor create_head:
-> Dom
constructor create_article:
-> Dom
constructor create_section:
-> Dom
constructor create_aside:
-> Dom
constructor create_header:
-> Dom
constructor create_main:
-> Dom
constructor create_figure:
-> Dom
constructor create_figcaption:
-> Dom
constructor create_details:
arg aria: SmallAriaInfo
-> Dom
constructor create_details_no_a11y:
-> Dom
constructor create_summary:
arg aria: SmallAriaInfo
-> Dom
constructor create_summary_no_a11y:
-> Dom
constructor create_summary_with_text:
arg text: String
arg aria: SmallAriaInfo
-> Dom
constructor create_summary_with_text_no_a11y:
constructor create_dialog:
arg aria: DialogAriaInfo
-> Dom
constructor create_dialog_no_a11y:
-> Dom
constructor create_p:
-> Dom
constructor create_h1:
-> Dom
constructor create_h2:
-> Dom
constructor create_h3:
-> Dom
constructor create_h3_with_text:
constructor create_h4:
-> Dom
constructor create_h4_with_text:
constructor create_h5:
-> Dom
constructor create_h5_with_text:
constructor create_h6:
-> Dom
constructor create_h6_with_text:
constructor create_span:
-> Dom
constructor create_strong:
-> Dom
constructor create_strong_with_text:
constructor create_em:
-> Dom
constructor create_em_with_text:
constructor create_code:
-> Dom
constructor create_code_with_text:
constructor create_pre:
-> Dom
constructor create_pre_with_text:
constructor create_blockquote:
-> Dom
constructor create_blockquote_with_text:
constructor create_cite:
-> Dom
constructor create_cite_with_text:
constructor create_abbr:
-> Dom
constructor create_abbr_with_title:
constructor create_kbd:
-> Dom
constructor create_kbd_with_text:
constructor create_samp:
-> Dom
constructor create_samp_with_text:
constructor create_var:
-> Dom
constructor create_var_with_text:
constructor create_sub:
-> Dom
constructor create_sub_with_text:
constructor create_sup:
-> Dom
constructor create_sup_with_text:
constructor create_u:
-> Dom
constructor create_u_with_text:
constructor create_s:
-> Dom
constructor create_s_with_text:
constructor create_mark:
-> Dom
constructor create_mark_with_text:
constructor create_del:
-> Dom
constructor create_del_with_text:
constructor create_ins:
-> Dom
constructor create_ins_with_text:
constructor create_dfn:
-> Dom
constructor create_dfn_with_text:
constructor create_time:
arg text: String
arg datetime: OptionString
-> Dom
constructor create_bdo:
-> Dom
constructor create_bdo_with_text:
constructor create_a:
arg href: String
arg text: String
arg aria: SmallAriaInfo
-> Dom
constructor create_a_no_a11y:
arg href: String
arg label: OptionString
-> Dom
constructor create_label:
arg for_id: String
arg text: String
arg aria: SmallAriaInfo
-> Dom
constructor create_label_no_a11y:
constructor create_input:
arg input_type: String
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> Dom
constructor create_input_no_a11y:
constructor create_textarea:
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> Dom
constructor create_textarea_no_a11y:
constructor create_select:
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> Dom
constructor create_select_no_a11y:
constructor create_option:
arg value: String
arg text: String
arg aria: SmallAriaInfo
-> Dom
constructor create_option_no_a11y:
constructor create_ul:
-> Dom
constructor create_ol:
-> Dom
constructor create_li:
-> Dom
constructor create_table:
arg caption: String
arg aria: SmallAriaInfo
-> Dom
constructor create_table_no_a11y:
-> Dom
constructor create_caption:
-> Dom
constructor create_thead:
-> Dom
constructor create_tbody:
-> Dom
constructor create_tfoot:
-> Dom
constructor create_tr:
-> Dom
constructor create_th:
-> Dom
constructor create_td:
-> Dom
constructor create_form:
arg aria: SmallAriaInfo
-> Dom
constructor create_form_no_a11y:
-> Dom
constructor create_fieldset:
arg aria: SmallAriaInfo
-> Dom
constructor create_fieldset_no_a11y:
-> Dom
constructor create_legend:
arg aria: SmallAriaInfo
-> Dom
constructor create_legend_no_a11y:
-> Dom
constructor create_hr:
-> Dom
constructor create_address:
-> Dom
constructor create_dl:
-> Dom
constructor create_dt:
-> Dom
constructor create_dd:
-> Dom
constructor create_colgroup:
-> Dom
constructor create_col:
arg span: i32
-> Dom
constructor create_optgroup:
arg label: String
arg aria: SmallAriaInfo
-> Dom
constructor create_optgroup_no_a11y:
constructor create_q:
-> Dom
constructor create_acronym:
-> Dom
constructor create_acronym_with_text:
constructor create_output:
arg aria: SmallAriaInfo
-> Dom
constructor create_output_no_a11y:
-> Dom
constructor create_progress:
arg aria: ProgressAriaInfo
-> Dom
constructor create_progress_no_a11y:
arg value: f32
arg max: f32
-> Dom
constructor create_meter:
arg aria: MeterAriaInfo
-> Dom
constructor create_meter_no_a11y:
arg value: f32
arg min: f32
arg max: f32
-> Dom
constructor create_datalist:
arg aria: SmallAriaInfo
-> Dom
constructor create_datalist_no_a11y:
-> Dom
constructor create_canvas:
arg aria: SmallAriaInfo
-> Dom
constructor create_canvas_no_a11y:
-> Dom
constructor create_object:
-> Dom
constructor create_param:
constructor create_embed:
-> Dom
constructor create_audio:
arg aria: SmallAriaInfo
-> Dom
constructor create_audio_no_a11y:
-> Dom
constructor create_video:
arg aria: SmallAriaInfo
-> Dom
constructor create_video_no_a11y:
-> Dom
constructor create_source:
constructor create_track:
constructor create_map:
-> Dom
constructor create_area:
arg aria: SmallAriaInfo
-> Dom
constructor create_area_no_a11y:
-> Dom
constructor create_title:
-> Dom
constructor create_title_with_text:
constructor create_meta:
-> Dom
constructor create_link:
-> Dom
constructor create_script:
-> Dom
constructor create_style:
-> Dom
constructor create_style_with_text:
constructor create_base:
constructor create_b:
-> Dom
constructor create_b_with_text:
constructor create_i:
-> Dom
constructor create_i_with_text:
constructor create_small:
-> Dom
constructor create_small_with_text:
constructor create_big:
-> Dom
constructor create_big_with_text:
constructor create_bdi:
-> Dom
constructor create_bdi_with_text:
constructor create_wbr:
-> Dom
constructor create_ruby:
-> Dom
constructor create_rt:
-> Dom
constructor create_rt_with_text:
constructor create_rtc:
-> Dom
constructor create_rp:
-> Dom
constructor create_rp_with_text:
constructor create_data:
constructor create_data_with_text:
constructor create_dir:
-> Dom
constructor create_svg:
-> Dom
constructor create_th_with_scope:
constructor create_td_with_text:
constructor create_th_with_text:
constructor create_geolocation_probe:
arg config: GeolocationProbeConfig
-> Dom
Creates a generic block-level container.
More
Accessibility: Prefer semantic elements like
<article>,<section>,<nav>when applicable.Creates a raw text node - only valid as the leaf inside a block-level wrapper (
p,div,h1, ...).More
Azul does not auto-wrap text in an anonymous block the way browsers do: a bare text node has no box, so every box-model property, callback,
tab_indexanddataseton it is inert. Prefercreate_*_with_text(create_p_with_text,create_div_with_text,create_span_with_text, ...) instead. The engine logs a warning after layout if it finds an unwrapped text node.Creates a generic block container (div) with text.
More
The div is the box the text lives in: put your styling, callbacks and tab_index on the DIV, never on the text leaf (a text node has no box of its own - see create_text_do_not_use_without_block_level_wrapper).
Creates a paragraph with text.
More
Parameters: -
text: Paragraph contentCreates a heading level 1 element with text.
More
Accessibility: Use
h1for the main page title. There should typically be only oneh1per page.Parameters: -
text: Heading textCreates a heading level 2 element with text.
More
Accessibility: Use
h2for major section headings underh1.Parameters: -
text: Heading textCreates a generic inline container (span) with text.
More
Accessibility: Prefer semantic elements like
strong,em,code, etc. when applicable.Parameters: -
text: Span contentCreates a list item with text.
More
Parameters: -
text: List item contentCreates a button element with text content and accessibility information.
More
Use
create_button_no_a11yonly as a deliberate escape hatch.Parameters: -
text: Button label text -aria: Accessibility information (role, description, etc.)Creates a button element without accessibility information.
More
Prefer
create_buttonso that the element has a meaningful accessible name for screen readers.Parameters: -
text: Button label textCreates an icon element that will be resolved by the icon provider.
More
Accessibility: Icons are resolved to images or font glyphs with automatic aria-label generation. The icon name is used to generate the accessibility label.
The icon resolution happens during the StyledDom creation phase, before layout. The icon provider returns a StyledDom subtree that replaces the icon node.
An icon that can be SWAPPED at runtime, without a full layout().
More
create_icon bakes the spec into the tree the cascade consumes, so changing it means producing a different tree - a full layout() - and by the time a callback runs, the DOM it would edit has already been built. This wraps the icon in a VirtualView instead: the view owns the spec, renders create_icon(spec) as its child DOM, and CallbackInfo::set_icon rewrites the spec and asks that ONE view to re-render. Nothing else relayouts.
A view rather than an in-place text swap because AN ICON IS NOT ONE NODE: it resolves to a subtree (an SVG icon is a tree of paths), and a nested DOM of arbitrary shape, re-materialized in place, is what a VirtualView is.
Sizing: the view reports the icon's MEASURED size, so auto width/height gives the icon's natural size, like an image. A definite size still wins, also like an image, and is what a toolbar or titlebar button should give it.
Creates a Dom from an already-parsed Xml structure. CSS from <style> tags is attached to the Dom.css field and will be applied during the cascade pass. This is the correct function for layout callbacks that return Dom.
Creates an empty DOM with a given
NodeType. Doesn't allocate until you add at least one child node.Creates the root HTML element.
More
Accessibility: The
<html>element is the root of an HTML document and should have alangattribute.Creates the document head element.
More
Accessibility: The
<head>contains metadata. Use<title>for page titles.Creates an article element.
More
Accessibility: Represents self-contained content that could be distributed independently. Screen readers can navigate by articles. Consider adding aria-label for multiple articles.
Creates a section element.
More
Accessibility: Represents a thematic grouping of content with a heading. Should typically have a heading (h1-h6) as a child. Consider aria-labelledby.
Creates a navigation element.
More
Accessibility: Represents navigation links. Screen readers can jump to navigation. Use aria-label to distinguish multiple nav elements (e.g., "Main navigation", "Footer links").
Creates an aside element.
More
Accessibility: Represents content tangentially related to main content (sidebars, callouts). Screen readers announce this as complementary content.
Creates a header element.
More
Accessibility: Represents introductory content or navigational aids. Can be used for page headers or section headers.
Creates a footer element.
More
Accessibility: Represents footer for nearest section or page. Typically contains copyright, author info, or related links.
Creates a main content element.
More
Accessibility: Represents the dominant content. There should be only ONE main per page. Screen readers can jump directly to main content. Do not nest inside article/aside/footer/header/nav.
Creates a figure element.
More
Accessibility: Represents self-contained content like diagrams, photos, code listings. Use with
<figcaption>to provide a caption. Screen readers associate caption with figure.Creates a figure caption element.
More
Accessibility: Provides a caption for
<figure>. Screen readers announce this as the figure description.Creates a details disclosure element with accessibility information.
More
Use
create_details_no_a11yonly as a deliberate escape hatch.Accessibility: Creates a disclosure widget. Screen readers announce expanded/collapsed state. Must contain a
<summary>element. Keyboard accessible by default.Creates a details disclosure element without accessibility information.
More
Prefer
create_detailsso that screen readers announce the disclosure widget's purpose.Creates an empty summary element for details with accessibility information.
More
Use
create_summary_no_a11yonly as a deliberate escape hatch.Accessibility: The visible heading/label for
<details>. Must be the first child of details. Keyboard accessible (Enter/Space to toggle).Creates an empty summary element for details without accessibility information.
More
Prefer
create_summaryso that screen readers can announce the disclosure heading.Creates a summary element with text and accessibility information for details.
More
Use
create_summary_with_text_no_a11yonly as a deliberate escape hatch.Accessibility: The visible heading/label for
<details>. Must be the first child of details. Keyboard accessible (Enter/Space to toggle).Creates a summary element with text without accessibility information.
More
Prefer
create_summary_with_textso that screen readers announce the disclosure heading.Creates a dialog element with accessibility information.
More
Accessibility: Represents a modal or non-modal dialog. When opened as modal, focus is trapped. Use aria-label or aria-labelledby. Escape key should close modal dialogs.
Creates a dialog element without accessibility information.
More
Prefer
create_dialogso that the dialog's modality and purpose are announced.Creates a paragraph element.
More
Accessibility: Paragraphs provide semantic structure for screen readers.
Creates an empty heading level 1 element.
More
Accessibility: Use
h1for the main page title. There should typically be only oneh1per page.Creates an empty heading level 2 element.
More
Accessibility: Use
h2for major section headings underh1.Creates an empty heading level 3 element.
More
Accessibility: Use
h3for subsections underh2.Creates a heading level 3 element with text.
More
Accessibility: Use
h3for subsections underh2.Parameters: -
text: Heading textCreates an empty heading level 4 element.
Creates a heading level 4 element with text.
More
Parameters: -
text: Heading textCreates an empty heading level 5 element.
Creates a heading level 5 element with text.
More
Parameters: -
text: Heading textCreates an empty heading level 6 element.
Creates a heading level 6 element with text.
More
Parameters: -
text: Heading textCreates an empty generic inline container (span).
More
Accessibility: Prefer semantic elements like
strong,em,code, etc. when applicable.Creates an empty strong importance element.
More
Accessibility: Use
stronginstead ofbfor semantic meaning.Creates a strongly emphasized text element with text (strong importance).
More
Accessibility: Use
stronginstead ofbfor semantic meaning. Screen readers can convey the importance. Use for text that has strong importance, seriousness, or urgency.Parameters: -
text: Text to emphasizeCreates an empty emphasis element (stress emphasis).
More
Accessibility: Use
eminstead ofifor semantic meaning.Creates an emphasized text element with text (stress emphasis).
More
Accessibility: Use
eminstead ofifor semantic meaning. Screen readers can convey the emphasis. Use for text that has stress emphasis.Parameters: -
text: Text to emphasizeCreates an empty code element.
More
Accessibility: Represents a fragment of computer code.
Creates a code/computer code element with text.
More
Accessibility: Represents a fragment of computer code. Screen readers can identify this as code content.
Parameters: -
code: Code contentCreates an empty preformatted text element.
More
Accessibility: Preserves whitespace and line breaks.
Creates a preformatted text element with text.
More
Accessibility: Preserves whitespace and line breaks. Useful for code blocks or ASCII art. Screen readers will read the content as-is.
Parameters: -
text: Preformatted contentCreates an empty blockquote element.
More
Accessibility: Represents a section quoted from another source.
Creates a blockquote element with text.
More
Accessibility: Represents a section quoted from another source. Screen readers can identify quoted content. Consider adding a
citeattribute.Parameters: -
text: Quote contentCreates an empty citation element.
More
Accessibility: Represents a reference to a creative work.
Creates a citation element with text.
More
Accessibility: Represents a reference to a creative work. Screen readers can identify citations.
Parameters: -
text: Citation textCreates an empty abbreviation element.
More
Accessibility: Represents an abbreviation or acronym. Use with a
titleattribute to provide the full expansion for screen readers.Creates an abbreviation element with abbreviated text and a
titleexpansion.More
Accessibility: Represents an abbreviation or acronym. The
titleattribute provides the full expansion for screen readers.Parameters: -
abbr_text: Abbreviated text -title: Full expansionCreates an empty keyboard input element.
More
Accessibility: Represents keyboard input or key combinations.
Creates a keyboard input element with text.
More
Accessibility: Represents keyboard input or key combinations. Screen readers can identify keyboard instructions.
Parameters: -
text: Keyboard instructionCreates an empty sample output element.
More
Accessibility: Represents sample output from a program or computing system.
Creates a sample output element with text.
More
Accessibility: Represents sample output from a program or computing system.
Parameters: -
text: Sample textCreates an empty variable element.
More
Accessibility: Represents a variable in mathematical expressions or programming.
Creates a variable element with text.
More
Accessibility: Represents a variable in mathematical expressions or programming.
Parameters: -
text: Variable nameCreates an empty subscript element.
Creates a subscript element with text.
More
Accessibility: Screen readers may announce subscript formatting.
Parameters: -
text: Subscript contentCreates an empty superscript element.
Creates a superscript element with text.
More
Accessibility: Screen readers may announce superscript formatting.
Parameters: -
text: Superscript contentCreates an empty underline element.
Creates an underline text element with text.
More
Accessibility: Screen readers typically don't announce underline formatting. Use semantic elements when possible (e.g.,
<em>for emphasis).Creates an empty strikethrough element.
Creates a strikethrough text element with text.
More
Accessibility: Represents text that is no longer accurate or relevant. Consider using
<del>for deleted content with datetime attribute.Creates an empty mark element.
Creates a marked/highlighted text element with text.
More
Accessibility: Represents text marked for reference or notation purposes. Screen readers may announce this as "highlighted".
Creates an empty deleted text element.
Creates a deleted text element with text.
More
Accessibility: Represents deleted content in document edits. Use with
datetimeandciteattributes for edit tracking.Creates an empty inserted text element.
Creates an inserted text element with text.
More
Accessibility: Represents inserted content in document edits. Use with
datetimeandciteattributes for edit tracking.Creates an empty definition element.
Creates a definition element with text.
More
Accessibility: Represents the defining instance of a term. Often used within a definition list or with
<abbr>.Creates a time element.
More
Accessibility: Represents a specific time or date. Use
datetimeattribute for machine-readable format.Parameters: -
text: Human-readable time/date -datetime: Optional machine-readable datetimeCreates an empty bi-directional override element.
More
Accessibility: Overrides text direction. Use
dirattribute (ltr/rtl).Creates a bi-directional override element with text.
More
Accessibility: Overrides text direction. Use
dirattribute (ltr/rtl).Creates an anchor (hyperlink) with href, visible text, and accessibility information.
More
Use
create_a_no_a11yonly as a deliberate escape hatch (for example, image-only links whose accessible name comes from an<img alt>).Parameters: -
href: Link destination URL -text: Visible link text -aria: Accessibility information (expanded description, etc.)Creates an anchor/hyperlink element without accessibility information.
More
Prefer
create_aso that screen readers get a meaningful label.Parameters: -
href: Link destination URL -label: Link text (passNonefor image-only links with alt text)Creates a label element for form controls with accessibility information.
More
Use
create_label_no_a11yonly as a deliberate escape hatch.Parameters: -
for_id: ID of the associated form control -text: Label text -aria: Accessibility information (description, etc.)Creates a label element for form controls without accessibility information.
More
Prefer
create_labelso that screen readers get a descriptive label.Parameters: -
for_id: ID of the associated form control -text: Label textCreates an input element with type, name, and accessibility information.
More
Use
create_input_no_a11yonly as a deliberate escape hatch.Parameters: -
input_type: Input type (text, password, email, etc.) -name: Form field name -label: Accessibility label -aria: Accessibility information (description, etc.)Creates an input element without accessibility information.
More
Prefer
create_inputso that screen readers get a descriptive label beyond the HTMLaria-labelattribute.Parameters: -
input_type: Input type (text, password, email, etc.) -name: Form field name -label: Accessibility label (required)Creates a textarea element with name and accessibility information.
More
Use
create_textarea_no_a11yonly as a deliberate escape hatch.Parameters: -
name: Form field name -label: Accessibility label -aria: Accessibility information (description, etc.)Creates a textarea element without accessibility information.
More
Prefer
create_textareaso that screen readers get an accurate description of the control.Parameters: -
name: Form field name -label: Accessibility label (required)Creates a select dropdown with name and accessibility information.
More
Use
create_select_no_a11yonly as a deliberate escape hatch.Parameters: -
name: Form field name -label: Accessibility label -aria: Accessibility information (description, etc.)Creates a select dropdown without accessibility information.
More
Prefer
create_selectso that screen readers announce the control appropriately.Parameters: -
name: Form field name -label: Accessibility label (required)Creates an option element for select dropdowns with accessibility information.
More
Use
create_option_no_a11yonly as a deliberate escape hatch.Parameters: -
value: Option value -text: Display text -aria: Accessibility information (description, etc.)Creates an option element for select dropdowns without accessibility information.
More
Prefer
create_optionso that screen readers can announce a description.Parameters: -
value: Option value -text: Display textCreates an unordered list element.
More
Accessibility: Screen readers announce lists and item counts, helping users understand content structure.
Creates an ordered list element.
More
Accessibility: Screen readers announce lists and item counts, helping users understand content structure and numbering.
Creates a list item element.
More
Accessibility: Must be a child of
ul,ol, ormenu. Screen readers announce list item position (e.g., "2 of 5").Creates a table element with a caption and accessibility information.
More
Use
create_table_no_a11yonly as a deliberate escape hatch.Parameters: -
caption: Visible caption text for the table -aria: Accessibility information describing table purposeCreates a table element without accessibility information.
More
Prefer
create_tableso that screen readers can announce the table's purpose alongside its caption.Creates a table caption element.
More
Accessibility: Describes the purpose of the table. Screen readers announce this first.
Creates a table header element.
More
Accessibility: Groups header rows. Screen readers can navigate table structure.
Creates a table body element.
More
Accessibility: Groups body rows. Screen readers can navigate table structure.
Creates a table footer element.
More
Accessibility: Groups footer rows. Screen readers can navigate table structure.
Creates a table row element.
Creates a table header cell element.
More
Accessibility: Use
scopeattribute ("col" or "row") to associate headers with data cells. Screen readers use this to announce cell context.Creates a table data cell element.
Creates a form element with accessibility information.
More
Use
create_form_no_a11yonly as a deliberate escape hatch.Accessibility: Group related form controls with
fieldsetandlegend. Provide clear labels for all inputs. Consideraria-describedbyfor instructions.Creates a form element without accessibility information.
More
Prefer
create_formso that screen readers can announce the form's purpose.Creates a fieldset element with accessibility information.
More
Use
create_fieldset_no_a11yonly as a deliberate escape hatch.Accessibility: Groups related form controls. Always include a
legendas the first child to describe the group. Screen readers announce the legend when entering the fieldset.Creates a fieldset element for grouping form controls without accessibility info.
More
Prefer
create_fieldsetso that screen readers can announce the group's purpose.Creates a legend element with accessibility information.
More
Use
create_legend_no_a11yonly as a deliberate escape hatch.Accessibility: Describes the purpose of a fieldset. Must be the first child of a fieldset. Screen readers announce this when entering the fieldset.
Creates a legend element without accessibility information.
More
Prefer
create_legendso that the legend's accessible name is explicit.Creates a horizontal rule element.
More
Accessibility: Represents a thematic break. Screen readers may announce this as a separator. Consider using CSS borders for purely decorative lines.
Creates an address element.
More
Accessibility: Represents contact information. Screen readers identify this as address content.
Creates a definition list element.
More
Accessibility: Screen readers announce definition lists and their structure.
Creates a definition term element.
More
Accessibility: Must be a child of
dl. Represents the term being defined.Creates a definition description element.
More
Accessibility: Must be a child of
dl. Provides the definition for the term.Creates a table column group element.
Creates a table column element.
Creates an optgroup element for grouping select options with accessibility information.
More
Use
create_optgroup_no_a11yonly as a deliberate escape hatch.Parameters: -
label: Label for the option group (visible) -aria: Additional accessibility information (description, etc.)Creates an optgroup element for grouping select options without accessibility info.
More
Prefer
create_optgroupso that screen readers can announce the group's purpose.Parameters: -
label: Label for the option groupCreates a quotation element.
More
Accessibility: Represents an inline quotation.
Creates an empty acronym element.
More
Note: Deprecated in HTML5. Consider using
create_abbr()instead.Creates an acronym element with text.
More
Note: Deprecated in HTML5. Consider using
create_abbr_with_title()instead.Creates a menu element with accessibility information.
More
Use
create_menu_no_a11yonly as a deliberate escape hatch.Accessibility: Represents a list of commands. Similar to
<ul>but semantic for toolbars/menus.Creates a menu element without accessibility information.
More
Prefer
create_menuso that the menu's purpose is announced.Creates an empty menu item element with accessibility information.
More
Use
create_menuitem_no_a11yonly as a deliberate escape hatch.Accessibility: Represents a command in a menu. Use with appropriate role/aria attributes.
Creates an empty menu item element without accessibility information.
More
Prefer
create_menuitemso that the menu item's purpose is announced.Creates a menu item element with text and accessibility information.
More
Use
create_menuitem_with_text_no_a11yonly as a deliberate escape hatch.Accessibility: Represents a command in a menu. Use with appropriate role/aria attributes.
Creates a menu item element with text but without accessibility information.
More
Prefer
create_menuitem_with_textso that screen readers get a distinct accessible name.Creates an output element with accessibility information.
More
Use
create_output_no_a11yonly as a deliberate escape hatch.Accessibility: Represents the result of a calculation or user action. Use
forattribute to associate with input elements. Screen readers announce updates.Creates an output element without accessibility information.
More
Prefer
create_outputso that screen readers can announce the computed value's purpose.Creates a progress indicator element with accessibility information.
More
Use
create_progress_no_a11yonly as a deliberate escape hatch.Accessibility: Represents task progress. Screen readers announce progress percentage. The
ariavalue carries the label, current value, max, and an indeterminate flag for spinners with no known endpoint.Creates a progress indicator element without accessibility information.
More
Prefer
create_progressso that the task being measured is announced.Parameters: -
value: Current progress value -max: Maximum valueCreates a meter gauge element with accessibility information.
More
Use
create_meter_no_a11yonly as a deliberate escape hatch.Accessibility: Represents a scalar measurement within a known range. Screen readers announce the measurement. The
ariavalue carries the label plus value/min/max/low/high/optimum metadata.Creates a meter gauge element without accessibility information.
More
Prefer
create_meterso that the measurement's purpose is announced.Parameters: -
value: Current meter value -min: Minimum value -max: Maximum valueCreates a datalist element for input suggestions with accessibility information.
More
Use
create_datalist_no_a11yonly as a deliberate escape hatch.Accessibility: Provides autocomplete options for inputs. Associate with input using
listattribute. Screen readers announce available options.Creates a datalist element for input suggestions without accessibility information.
More
Prefer
create_datalistso that the suggestion list's purpose is announced.Creates a canvas element for graphics with accessibility information.
More
Use
create_canvas_no_a11yonly as a deliberate escape hatch.Accessibility: Canvas content is not accessible by default. Always provide fallback content as children and/or detailed aria-label. Consider using SVG for accessible graphics when possible.
Creates a canvas element for graphics without accessibility information.
More
Prefer
create_canvasso that the canvas's purpose is announced; canvas content is otherwise opaque to assistive technologies.Creates an object element for embedded content.
More
Accessibility: Provide fallback content as children. Use aria-label to describe content.
Creates a param element for object parameters.
More
Parameters: -
name: Parameter name -value: Parameter valueCreates an embed element.
More
Accessibility: Provide alternative content or link. Use aria-label to describe embedded content.
Creates an audio element with accessibility information.
More
Use
create_audio_no_a11yonly as a deliberate escape hatch.Accessibility: Always provide controls. Use
<track>for captions/subtitles. Provide fallback text for unsupported browsers.Creates an audio element without accessibility information.
More
Prefer
create_audioso that screen readers announce the audio's purpose.Creates a video element with accessibility information.
More
Use
create_video_no_a11yonly as a deliberate escape hatch.Accessibility: Always provide controls. Use
<track>for captions/subtitles/descriptions. Provide fallback text. Consider providing transcript.Creates a video element without accessibility information.
More
Prefer
create_videoso that screen readers announce the video's purpose.Creates a source element for media.
More
Parameters: -
src: Media source URL -media_type: MIME type (e.g., "video/mp4", "audio/ogg")Creates a track element for media captions/subtitles.
More
Accessibility: Essential for deaf/hard-of-hearing users and non-native speakers. Use
kind(subtitles/captions/descriptions),srclang, andlabelattributes.Parameters: -
src: Track file URL (WebVTT format) -kind: Track kind ("subtitles", "captions", "descriptions", "chapters", "metadata")Creates a map element for image maps.
More
Accessibility: Provide text alternatives. Ensure all areas have alt text.
Creates an area element for image map regions with accessibility information.
More
Use
create_area_no_a11yonly as a deliberate escape hatch.Accessibility: Always provide
alttext describing the region/link purpose. Keyboard users should be able to navigate areas.Creates an area element for image map regions without accessibility information.
More
Prefer
create_areaso that screen readers can announce the region's purpose.Creates an empty title element for document title.
More
Accessibility: Required for all pages. Screen readers announce this first.
Creates a title element for document title with text.
More
Accessibility: Required for all pages. Screen readers announce this first. Should be unique and descriptive. Keep under 60 characters.
Creates a meta element.
More
Accessibility: Use for charset, viewport, description. Crucial for proper text display.
Creates a link element for external resources.
More
Accessibility: Use for stylesheets, icons, alternate versions. Provide meaningful
titleattribute for alternate stylesheets.Creates a script element.
More
Accessibility: Ensure scripted content is accessible. Provide noscript fallbacks for critical functionality.
Creates an empty style element for embedded CSS.
More
Note: In Azul, use
.with_component_css()instead for styling. This creates a<style>HTML element for embedded stylesheets.Creates a style element for embedded CSS with the given stylesheet text.
More
Note: In Azul, use
.with_component_css()instead for styling. This creates a<style>HTML element for embedded stylesheets.Creates a base element for document base URL.
More
Parameters: -
href: Base URL for relative URLs in the documentCreates an empty bold element.
More
Accessibility: Prefer
<strong>for semantic emphasis.<b>is purely stylistic.Creates a bold element with text.
More
Accessibility: Prefer
<strong>for semantic emphasis.<b>is purely stylistic.Parameters: -
text: Bold text contentCreates an empty italic element.
More
Accessibility: Prefer
<em>for stress emphasis.<i>is purely stylistic.Creates an italic element with text.
More
Accessibility: Prefer
<em>for stress emphasis.<i>is purely stylistic.Parameters: -
text: Italic text contentCreates an empty small text element.
More
Accessibility: Represents side-comments and small print like copyright/legal text.
Creates a small text element with text.
More
Parameters: -
text: Small text contentCreates an empty
<big>element.More
Note: Deprecated in HTML5. Prefer CSS
font-size.Creates a
<big>element with text.More
Note: Deprecated in HTML5. Prefer CSS
font-size.Creates an empty bi-directional isolate element.
More
Accessibility: Used to isolate text whose direction is unknown, keeping it from affecting surrounding bidi layout.
Creates a bi-directional isolate element with text.
More
Accessibility: Used to isolate text whose direction is unknown, keeping it from affecting surrounding bidi layout.
Creates an empty word break opportunity element.
More
Note:
<wbr>is a self-closing element that suggests a line-break opportunity. It does not take text content.Creates an empty ruby annotation element.
More
Accessibility: Used for East Asian typography to provide pronunciation/translation annotations. Wraps
<rt>/<rp>children.Creates an empty ruby text element.
More
Accessibility: Pronunciation/translation annotation inside
<ruby>.Creates a ruby text element with text.
More
Parameters: -
text: Ruby annotation contentCreates an empty ruby text container element.
More
Accessibility: Container for ruby text annotations.
Creates an empty ruby fallback parenthesis element.
More
Accessibility: Provides parentheses around
<rt>for browsers without ruby support.Creates a ruby fallback parenthesis element with text.
More
Parameters: -
text: Parenthesis text (typically "(" or ")")Creates a
<data>element binding a machine-readable value to its content.More
Parameters: -
value: Machine-readable value for thevalueattribute.Creates a
<data>element with both a machine-readable value and visible text.More
Parameters: -
value: Machine-readable value for thevalueattribute. -text: Human-readable text content.Creates an empty directory list element.
More
Note: Deprecated in HTML5. Use
<ul>instead.Creates an empty SVG container element.
More
Accessibility: Provide
aria-labelor<title>child for assistive tech.Creates a table header cell with scope.
More
Parameters: -
scope: "col", "row", "colgroup", or "rowgroup" -text: Header textAccessibility: The scope attribute is crucial for associating headers with data cells.
Creates a table data cell with text.
More
Parameters: -
text: Cell contentCreates a table header cell with text.
More
Parameters: -
text: Header textCreates an invisible
NodeType::GeolocationProbenode that signals "this subtree needs the user's location". Lays out as zero-size and is skipped in the display list - the framework scans for it at end-of-layout and starts / stops the nativeCLLocationManager/LocationManager/geocluesubscription.47 methods
fn with_child:
fn with_css:
fn add_child:
&mut self
arg child: Dom
fn with_children:
fn with_callback:
self
arg event: EventFilter
arg data: RefAny
arg callback: CallbackType
-> Dom
fn with_id:
fn with_class:
fn set_css:
&mut self
arg style: String
self
arg prop: CssPropertyWithConditions
-> Dom
fn with_dataset:
self
arg data: OptionRefAny
-> Dom
fn add_callback:
&mut self
arg event: EventFilter
arg data: RefAny
arg callback: CallbackType
self
arg ids_and_classes: IdOrClassVec
-> Dom
fn set_dataset:
&mut self
arg data: OptionRefAny
fn with_marker:
self
arg marker: OptionString
-> Dom
fn set_marker:
&mut self
arg marker: OptionString
fn with_callbacks:
self
arg callbacks: CoreCallbackDataVec
-> Dom
fn set_children:
&mut self
arg children: DomVec
fn add_css_property:
&mut self
arg prop: CssPropertyWithConditions
fn with_clip_mask:
fn with_tab_index:
self
arg contenteditable: bool
-> Dom
self
arg accessibility_info: AccessibilityInfo
-> Dom
fn node_count:
&self
-> usize
&mut self
arg css: Css
&mut self
arg css: CssVec
&mut self
-> Dom
&mut self
-> Dom
fn with_attribute:
self
arg attr: AttributeType
-> Dom
fn with_attributes:
self
arg attributes: AttributeTypeVec
-> Dom
fn set_attributes:
&mut self
arg attributes: AttributeTypeVec
&mut self
-> usize
self
arg callback: DatasetMergeCallback
-> Dom
&mut self
arg callback: DatasetMergeCallback
fn with_css_props:
self
arg css_props: CssPropertyWithConditionsVec
-> Dom
fn with_node_type:
fn add_class:
&mut self
arg class: String
fn set_tab_index:
&mut self
arg tab_index: TabIndex
&mut self
arg contenteditable: bool
self
arg name: String
arg callback: ZombieAnimCallback
arg data: RefAny
-> Dom
self
arg patch: AccessibilityInfo
-> Dom
Builder method for
set_cssParse and set CSS styles with full selector support.
More
This is the unified API for setting inline CSS on a DOM node. It supports: - Simple properties:
color: red; font-size: 14px;- Pseudo-selectors::hover { background: blue; }- @-rules:@os linux { font-size: 14px; }- Nesting:@os linux { font-size: 14px; :hover { color: red; }}Examples
Builder method to add a CSS property with optional conditions (hover, focus, active, etc.) to the root node.
Setter form of
with_dataset.Stamp an app-chosen marker string on the root node, resolvable to a
(DomId, NodeId)viaCallbackInfo::get_node_id_by_marker- the clean way for one widget's callback to find another widget without knowing its internals. Unlike anIdattribute, a marker is invisible to CSS matching. PassNoneto remove a previously set marker.Setter form of
with_marker.Adds a CSS property with optional conditions (hover, focus, active, etc.) to the root node.
Sets the menu bar for the root node
Sets the context menu for the root node
Mutating form of
with_component_css. Pushes a stylesheet onto the subtree's component-level CSS list in place.Builder form of
add_component_css: attach a parsed stylesheet to this subtree and hand the Dom back, so a component builds in one expression.with_css(&str)is the same thing for a string that still needs parsing.Replace the subtree's entire component-level CSS list with the provided one. Use
add_component_css/with_component_cssfor stacking; this is the wholesale-replace form.Adds an attribute to this DOM element.
More
Example:
Adds multiple attributes to this DOM element.
Setter form of
with_attributes.Registers a callback to merge dataset state from the previous frame.
More
This is used for components that maintain heavy internal state (video players, WebGL contexts, network connections) that should not be destroyed and recreated on every render frame.
The callback receives both datasets as
RefAny(cheap shallow clones) and returns theRefAnythat should be used for the new node.Setter form of
with_merge_callback.Attach a presence-animation function to this node, resolvable by name from its -azul-animation-in / -azul-animation-out (after stylesheet @keyframes). The component-local replacement for the removed global registry.
Give this node an accessible name, keeping whatever else it already declares.
More
This is the override
with_accessibility_infocan't give you: a widget fills in what it knows (a slider's role and live value, a checkbox's checked state) but not what the control is called - only the app knows that. Replacing the whole struct to add a name would discard the role and value with it.Point this node at the node that already names it, keeping the rest of its declaration.
More
Preferred over copying the label text: a duplicated name drifts the moment someone edits the visible label and forgets the spoken one.
Overlay a partial accessibility declaration, keeping every field the patch does not set.
More
The general form of the two helpers around it, and the one to reach for when setting more than one thing at once:
See [
AccessibilityInfo::assign] for exactly which fields count as "set" -None, an empty vec andUnknownall mean "not specified".struct NodeData
has destructorRepresents all data associated with a single DOM node, such as its type, classes, IDs, callbacks, and inline styles.
6 fields
node_type: NodeType
callbacks: CoreCallbackDataVec
style: Css
flags: NodeFlags
accessibility: c_void
extra: c_void
22 constructors
constructor create_div:
-> NodeData
constructor create_body:
-> NodeData
constructor create_text_do_not_use_without_block_level_wrapper:
constructor create:
constructor create_br:
-> NodeData
constructor create_image:
constructor create_virtual_view:
arg data: RefAny
arg callback: VirtualViewCallback
-> NodeData
constructor create_node:
constructor create_button:
arg aria: SmallAriaInfo
-> NodeData
constructor create_button_no_a11y:
-> NodeData
constructor create_a:
arg href: String
arg aria: SmallAriaInfo
-> NodeData
constructor create_a_no_a11y:
constructor create_input:
arg input_type: String
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> NodeData
constructor create_input_no_a11y:
constructor create_textarea:
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> NodeData
constructor create_textarea_no_a11y:
constructor create_select:
arg name: String
arg label: String
arg aria: SmallAriaInfo
-> NodeData
constructor create_select_no_a11y:
constructor create_table:
arg aria: SmallAriaInfo
-> NodeData
constructor create_table_no_a11y:
-> NodeData
constructor create_label:
arg for_id: String
arg aria: SmallAriaInfo
-> NodeData
constructor create_label_no_a11y:
Shorthand for
NodeData::create_node(NodeType::Div).Shorthand for
NodeData::create_node(NodeType::Body).Creates a raw text node - only valid as the leaf inside a block-level wrapper (
p,div,h1, ...).More
Azul does not auto-wrap text in an anonymous block the way browsers do: a bare text node has no box, so every box-model property, callback,
tab_indexanddataseton it is inert. Prefercreate_*_with_text(create_p_with_text,create_div_with_text,create_span_with_text, ...) instead. The engine logs a warning after layout if it finds an unwrapped text node.Creates an new, empty
NodeDatastructShorthand for
NodeData::create_node(NodeType::Br).Shorthand for
NodeData::create_node(NodeType::Image(image_id)).Creates a new
NodeDatainstance from a givenNodeType.Creates a button
NodeDatawith accessibility information.Creates a button
NodeDatawithout accessibility information.Creates an anchor
NodeDatawith an href and accessibility information.Creates an anchor
NodeDatawith an href but no accessibility information.Creates an input
NodeDatawith accessibility information.Creates an input
NodeDatawithout accessibility information.Creates a textarea
NodeDatawith accessibility information.Creates a textarea
NodeDatawithout accessibility information.Creates a select
NodeDatawith accessibility information.Creates a select
NodeDatawithout accessibility information.Creates a table
NodeDatawith accessibility information.Creates a table
NodeDatawithout accessibility information.Creates a label
NodeDatawith an associated control ID and accessibility information.Creates a label
NodeDatawith an associated control ID but no accessibility information.32 methods
fn add_callback:
&mut self
arg event: EventFilter
arg data: RefAny
arg callback: CallbackType
fn set_dataset:
&mut self
arg data: OptionRefAny
&mut self
arg ids_and_classes: IdOrClassVec
fn with_marker:
self
arg marker: OptionString
-> NodeData
fn set_marker:
&mut self
arg marker: OptionString
fn set_callbacks:
&mut self
arg callbacks: CoreCallbackDataVec
fn set_clip_mask:
&mut self
arg clip_mask: ImageMask
fn set_tab_index:
&mut self
arg tab_index: TabIndex
&mut self
arg contenteditable: bool
&self
-> bool
self
arg contenteditable: bool
-> NodeData
&mut self
arg accessibility_info: AccessibilityInfo
fn is_text_node:
&self
-> bool
&self
-> bool
fn is_anonymous:
&self
-> bool
fn set_anonymous:
&mut self
arg is_anonymous: bool
fn add_id:
&mut self
arg s: String
fn add_class:
&mut self
arg s: String
fn add_css_property:
&mut self
arg p: CssPropertyWithConditions
fn is_focusable:
&self
-> bool
fn debug_print_end:
&self
-> String
&mut self
arg callback: DatasetMergeCallback
&self
self
arg callback: DatasetMergeCallback
-> NodeData
fn get_tab_index:
&self
fn has_id:
&self
arg id: String
-> bool
fn has_class:
&self
arg class: String
-> bool
&self
-> IdOrClassVec
&mut self
arg name: String
arg callback: ZombieAnimCallback
arg data: RefAny
Stamp an app-chosen marker string on this node, resolvable to a
(DomId, NodeId)viaCallbackInfo::get_node_id_by_marker- the clean way for one widget's callback to find another widget without knowing its internals. Unlike anIdattribute, a marker is invisible to CSS matching. PassNoneto remove a previously set marker.Setter form of
with_marker.Sets the contenteditable flag for this node, enabling inline text editing.
Returns whether this node is marked as contenteditable.
Builder method to set contenteditable and return self.
Returns whether this node is an anonymous box generated for table layout.
Marks this node as an anonymous box (generated for table layout).
Adds a CSS property with optional conditions (hover, focus, active, etc.).
Sets a dataset merge callback for this node.
More
The merge callback is invoked during reconciliation when a node from the previous frame is matched with a node in the new frame. It allows heavy resources (video decoders, GL textures, network connections) to be transferred from the old node to the new node instead of being destroyed.
Type Safety
The callback stores the
TypeIdofT. During execution, both the old and new datasets must match this type, otherwise the merge is skipped.Example
Gets the merge callback for this node, if set.
Registers a callback to merge dataset state from the previous frame.
More
This is used for components that maintain heavy internal state (video players, WebGL contexts, network connections) that should not be destroyed and recreated on every render frame.
The callback receives both datasets as
RefAny(cheap shallow clones) and returns theRefAnythat should be used for the new node.Example
Checks whether this node has the searched ID attached.
Checks whether this node has the searched class attached.
Returns IDs and classes as a computed
IdOrClassVec. Note: this allocates a new vec each time, preferhas_id()/has_class()for checks.Attach a presence-animation function to this node - see Dom::with_animation_callback.
union enum NodeType
has destructorList of core DOM node types built into
azul. This enum defines the building blocks of the UI, similar to HTML tags.184 variants
Html
Head
Body
Div
P
Article
Section
Aside
Header
Main
Figure
FigCaption
H1
H2
H3
H4
H5
H6
Br
Hr
Pre
BlockQuote
Address
Details
Summary
Dialog
Ul
Ol
Li
Dl
Dt
Dd
Menu
MenuItem
Dir
Table
Caption
THead
TBody
TFoot
Tr
Th
Td
ColGroup
Col
Form
FieldSet
Legend
Label
Input
Button
Select
OptGroup
SelectOption
TextArea
Output
Progress
Meter
DataList
Span
A
Em
Strong
B
I
U
S
Mark
Del
Ins
Code
Samp
Kbd
Var
Cite
Dfn
Abbr
Acronym
Q
Time
Sub
Sup
Small
Big
Bdo
Bdi
Wbr
Ruby
Rt
Rtc
Rp
Data
Canvas
Object
Param
Embed
Audio
Video
Source
Track
Map
Area
Svg
SvgG
SvgDefs
SvgSymbol
SvgUse
SvgSwitch
SvgPath
SvgCircle
SvgRect
SvgEllipse
SvgLine
SvgPolygon
SvgPolyline
SvgText(String)
SvgTspan
SvgTextPath
SvgLinearGradient
SvgRadialGradient
SvgStop
SvgPattern
SvgClipPathElement
SvgMask
SvgFilter
SvgFeBlend
SvgFeColorMatrix
SvgFeComponentTransfer
SvgFeComposite
SvgFeConvolveMatrix
SvgFeDiffuseLighting
SvgFeDisplacementMap
SvgFeDistantLight
SvgFeDropShadow
SvgFeFlood
SvgFeFuncR
SvgFeFuncG
SvgFeFuncB
SvgFeFuncA
SvgFeGaussianBlur
SvgFeImage
SvgFeMerge
SvgFeMergeNode
SvgFeMorphology
SvgFeOffset
SvgFePointLight
SvgFeSpecularLighting
SvgFeSpotLight
SvgFeTile
SvgFeTurbulence
SvgMarker
SvgImage(ImageRef)
SvgForeignObject
SvgTitle
SvgDesc
SvgMetadata
SvgA
SvgView
SvgStyle
SvgScript
SvgAnimate
SvgAnimateMotion
SvgAnimateTransform
SvgSet
SvgMpath
Title
Meta
Link
Script
Style
Base
Before
After
Marker
Placeholder
Text(BoxOrStaticString)
Image(BoxOrStaticImageRef)
VirtualView
TransientWindow(TransientWindowConfig)
Icon(BoxOrStaticString)
GeolocationProbe(GeolocationProbeConfig)
PageBreak
union enum AttributeType
has destructor44 variants
Id(String)
Class(String)
AriaLabel(String)
AriaLabelledBy(String)
AriaDescribedBy(String)
AriaRole(String)
AriaState(AttributeNameValue)
AriaProperty(AttributeNameValue)
Href(String)
Rel(String)
Target(String)
Src(String)
Alt(String)
Title(String)
Name(String)
Value(String)
InputType(String)
Placeholder(String)
Required
Disabled
Readonly
CheckedTrue
CheckedFalse
Selected
Max(String)
Min(String)
Step(String)
Pattern(String)
MinLength(i32)
MaxLength(i32)
Autocomplete(String)
Scope(String)
ColSpan(i32)
RowSpan(i32)
TabIndex(i32)
Focusable
Autofocus
Lang(String)
Dir(String)
ContentEditable(bool)
Draggable(bool)
Hidden
Data(AttributeNameValue)
Custom(AttributeNameValue)
struct Callback
2 fields
cb: CallbackType
ctx: OptionRefAny
1 constructor
constructor create:
arg cb: CallbackType
-> Callback
Create a new callback with just a function pointer (for native Rust code)
1 method
fn to_core:
self
-> CoreCallback
Converts this Callback to a CoreCallback for use with Dom::set_callback
struct SmallAriaInfo
has destructor3 fields
1 constructor
2 methods
fn with_role:
self
arg role: AccessibilityRole
fn with_description:
self
arg desc: String
Returns a copy with the given accessibility role.
Returns a copy with the given accessible description.
union enum TabIndex
Determines the behavior of an element in sequential focus navigation
3 variants
Automatic tab index, similar to simply setting
focusable = "true"ortabindex = 0(both have the effect of making the element focusable). Sidenote: See https://www.w3.org/TR/html5/editing.html#sequential-focus-navigation-and-the-tabindex-attribute for interesting notes on tabindex and accessibilityAuto
Set the tab index in relation to its parent element. I.e. if you have a list of elements, the focusing order is restricted to the current parent. Ex. a div might have: no_run,ignore div (Auto) |- element1 (OverrideInParent 0) <- current focus |- element2 (OverrideInParent 5) |- element3 (OverrideInParent 2) |- element4 (Global 5) ignore When pressing tab repeatedly, the focusing order will be "element3, element2, element4, div", since OverrideInParent elements take precedence among global order.
OverrideInParent(u32)
Elements can be focused in callbacks, but are not accessible via keyboard / tab navigation (-1).
NoKeyboardFocus
struct AccessibilityInfo
has destructorHolds information about a UI element for accessibility purposes (e.g., screen readers). This is a wrapper for platform-specific accessibility APIs like MSAA.
11 fields
accessibility_name: OptionString
accessibility_value: OptionString
description: OptionString
accelerator: OptionVirtualKeyCodeCombo
default_action: OptionString
states: AccessibilityStateVec
supported_actions: AccessibilityActionVec
labelled_by: OptionDomNodeId
described_by: OptionDomNodeId
role: AccessibilityRole
is_live_region: bool
1 constructor
constructor named:
arg name: String
arg role: AccessibilityRole
The common case: "this control is a X called Y".
More
Exists because the struct has eleven fields and, from a binding, there was no way to fill two of them without spelling out the other nine. A developer who has just been told by the engine's a11y lint to name a control should be one call away from doing it:
3 methods
fn with_value:
self
arg value: String
fn assign:
&mut self
arg patch: AccessibilityInfo
fn assigned:
self
arg patch: AccessibilityInfo
Attach a live value - a slider's position, a progress percentage.
Overlay
patchontoself, taking only the fieldspatchactually SETS - the accessibility equivalent of a struct assign/merge.More
The problem it solves: a widget declares what it knows (role, live value, checked state) and an application knows the one thing the widget cannot (what the control is CALLED). Replacing the struct to add a name throws away the role and value; adding a dedicated setter per field does not compose. This lets a caller hand over a partial declaration and keep everything else:
"Actually sets" is defined per field, and deliberately:
Noneand an EMPTY vec mean "not specified",AccessibilityRole::Unknownmeans "not specified" (which is exactly why Default uses it), andis_live_regionis only ever turned ON by a patch - afalsein a partial struct is indistinguishable from an unset field, so it must not clear atruethat the widget set on purpose.[
AccessibilityInfo::assign] as a builder: returns the merged value.struct KeyboardState
has destructor7 fields
current_virtual_keycode: OptionVirtualKeyCode
pressed_virtual_keycodes: VirtualKeyCodeVec
pressed_scancodes: ScanCodeVec
modifiers: KeyModifiers
locks: KeyLocks
is_repeat: bool
current_physical_key: OptionPhysicalKey
struct MouseState
9 fields
pointer_device_id: u64
cursor_position: CursorPosition
mouse_cursor_type: OptionMouseCursorType
pointer_source: PointerSource
is_cursor_locked: bool
left_down: bool
right_down: bool
middle_down: bool
other_down: u8
enum VirtualKeyCode
163 variants
Key1
Key2
Key3
Key4
Key5
Key6
Key7
Key8
Key9
Key0
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
Escape
F1
F2
F3
F4
F5
F6
F7
F8
F9
F10
F11
F12
F13
F14
F15
F16
F17
F18
F19
F20
F21
F22
F23
F24
Snapshot
Scroll
Pause
Insert
Home
Delete
End
PageDown
PageUp
Left
Up
Right
Down
Back
Return
Space
Compose
Caret
Numlock
Numpad0
Numpad1
Numpad2
Numpad3
Numpad4
Numpad5
Numpad6
Numpad7
Numpad8
Numpad9
NumpadAdd
NumpadDivide
NumpadDecimal
NumpadComma
NumpadEnter
NumpadEquals
NumpadMultiply
NumpadSubtract
AbntC1
AbntC2
Apostrophe
Apps
Asterisk
At
Ax
Backslash
Calculator
Capital
Colon
Comma
Convert
Equals
Grave
Kana
Kanji
LAlt
LBracket
LControl
LShift
LWin
Mail
MediaSelect
MediaStop
Minus
Mute
MyComputer
NextTrack
NoConvert
OEM102
Period
PlayPause
Plus
Power
PrevTrack
RAlt
RBracket
RControl
RShift
RWin
Semicolon
Slash
Sleep
Stop
Sysrq
Tab
Underline
Unlabeled
VolumeDown
VolumeUp
Wake
WebBack
WebFavorites
WebForward
WebHome
WebRefresh
WebSearch
WebStop
Yen
Copy
Paste
Cut
struct DomNodeId
A UUID for a DOM node within a
LayoutWindow.2 fields
The ID of the
Domthis node belongs to.dom: DomId
The hierarchical ID of the node within its
Dom.node: NodeHierarchyItemId
union enum FocusTarget
has destructor8 variants
struct DatasetMergeCallback
2 fields
callable: OptionRefAny
1 constructor
constructor from:
arg cb: DatasetMergeCallbackType
union enum VirtualViewCallbackReason
5 variants
struct NodeHierarchyItem
4 fields
parent: usize
previous_sibling: usize
next_sibling: usize
last_child: usize
struct DragData
has destructorDrag data (HTML5
DataTransfer): the MIME-keyed payload and the set of operations the source allows.2 fields
data: MimeTypeDataVec
effect_allowed: DragEffect
1 constructor
struct ClipboardContent
has destructor2 fields
plain_text: String
styled_runs: StyledTextRunVec
union enum Selection
2 variants
Cursor(TextCursor)
Range(SelectionRange)
struct SelectionRange
2 fields
start: TextCursor
end: TextCursor
struct DocumentSelectionSpan
A selected byte span
[start_byte, end_byte)ofnode's text content, always normalized (start_byte <= end_byte) and in logical order - drag direction and bidi visual order do not change it.3 fields
enum AccessibilityRole
Defines the element's purpose for accessibility APIs, informing assistive technologies like screen readers about the function of a UI element. Each variant corresponds to a standard control type or UI structure. For more details, see the [MSDN Role Constants page](https://docs.microsoft.com/en-us/windows/winauto/object-roles).
65 variants
Represents the title or caption bar of a window. - Purpose: To identify the title bar containing the window title and system commands. - When to use: This role is typically inserted by the operating system for standard windows. - Example: The bar at the top of an application window displaying its name and the minimize, maximize, and close buttons.
TitleBar
Represents a menu bar at the top of a window. - Purpose: To contain a set of top-level menus for an application. - When to use: For the main menu bar of an application, such as one containing "File," "Edit," and "View." - Example: The "File", "Edit", "View" menu bar at the top of a text editor.
MenuBar
Represents a vertical or horizontal scroll bar. - Purpose: To enable scrolling through content that is larger than the visible area. - When to use: For any scrollable region of content. - Example: The bar on the side of a web page that allows the user to scroll up and down.
ScrollBar
Represents a handle or grip used for moving or resizing. - Purpose: To provide a user interface element for manipulating another element's size or position. - When to use: For handles that allow resizing of windows, panes, or other objects. - Example: The small textured area in the bottom-right corner of a window that can be dragged to resize it.
Grip
Represents a system sound indicating an event. - Purpose: To associate a sound with a UI event, providing an auditory cue. - When to use: When a sound is the primary representation of an event. - Example: A system notification sound that plays when a new message arrives.
Sound
Represents the system's mouse pointer or other pointing device. - Purpose: To indicate the screen position of the user's pointing device. - When to use: This role is managed by the operating system. - Example: The arrow that moves on the screen as you move the mouse.
Cursor
Represents the text insertion point indicator. - Purpose: To show the current text entry or editing position. - When to use: This role is typically managed by the operating system for text input fields. - Example: The blinking vertical line in a text box that shows where the next character will be typed.
Caret
Represents an alert or notification. - Purpose: To convey an important, non-modal message to the user. - When to use: For non-intrusive notifications that do not require immediate user interaction. - Example: A small, temporary "toast" notification that appears to confirm an action, like "Email sent."
Alert
Represents a window frame. - Purpose: To serve as the container for other objects like a title bar and client area. - When to use: This is a fundamental role, typically managed by the windowing system. - Example: The main window of any application, which contains all other UI elements.
Window
Represents a window's client area, where the main content is displayed. - Purpose: To define the primary content area of a window. - When to use: For the main content region of a window. It's often the default role for a custom control container. - Example: The area of a web browser where the web page content is rendered.
Client
Represents a pop-up menu. - Purpose: To display a list of
MenuItemobjects that appears when a user performs an action. - When to use: For context menus (right-click menus) or drop-down menus. - Example: The menu that appears when you right-click on a file in a file explorer.MenuPopup
Represents an individual item within a menu. - Purpose: To represent a single command, option, or separator within a menu. - When to use: For individual options inside a
MenuBarorMenuPopup. - Example: The "Save" option within the "File" menu.MenuItem
Represents a small pop-up window that provides information. - Purpose: To offer brief, contextual help or information about a UI element. - When to use: For informational pop-ups that appear on mouse hover. - Example: The small box of text that appears when you hover over a button in a toolbar.
Tooltip
Represents the main window of an application. - Purpose: To identify the top-level window of an application. - When to use: For the primary window that represents the application itself. - Example: The main window of a calculator or notepad application.
Application
Represents a document window within an application. - Purpose: To represent a contained document, typically in a Multiple Document Interface (MDI) application. - When to use: For individual document windows inside a larger application shell. - Example: In a photo editor that allows multiple images to be open in separate windows, each image window would be a
Document.Document
Represents a pane or a distinct section of a window. - Purpose: To divide a window into visually and functionally distinct areas. - When to use: For sub-regions of a window, like a navigation pane, preview pane, or sidebar. - Example: The preview pane in an email client that shows the content of the selected email.
Pane
Represents a graphical chart or graph. - Purpose: To display data visually in a chart format. - When to use: For any type of chart, such as a bar chart, line chart, or pie chart. - Example: A bar chart displaying monthly sales figures.
Chart
Represents a dialog box or message box. - Purpose: To create a secondary window that requires user interaction before returning to the main application. - When to use: For modal or non-modal windows that prompt the user for information or a response. - Example: The "Open File" or "Print" dialog in most applications.
Dialog
Represents a window's border. - Purpose: To identify the border of a window, which is often used for resizing. - When to use: This role is typically managed by the windowing system. - Example: The decorative and functional frame around a window.
Border
Represents a group of related controls. - Purpose: To logically group other objects that share a common purpose. - When to use: For grouping controls like a set of radio buttons or a fieldset with a legend. - Example: A "Settings" group box in a dialog that contains several related checkboxes.
Grouping
Represents a visual separator. - Purpose: To visually divide a space or a group of controls. - When to use: For visual separators in menus, toolbars, or between panes. - Example: The horizontal line in a menu that separates groups of related menu items.
Separator
Represents a toolbar containing a group of controls. - Purpose: To group controls, typically buttons, for quick access to frequently used functions. - When to use: For a bar of buttons or other controls, usually at the top of a window or pane. - Example: The toolbar at the top of a word processor with buttons for "Bold," "Italic," and "Underline."
Toolbar
Represents a status bar for displaying information. - Purpose: To display status information about the current state of the application. - When to use: For a bar, typically at the bottom of a window, that displays messages. - Example: The bar at the bottom of a web browser that shows the loading status of a page.
StatusBar
Represents a data table. - Purpose: To present data in a two-dimensional grid of rows and columns. - When to use: For grid-like data presentation. - Example: A spreadsheet or a table of data in a database application.
Table
Represents a column header in a table. - Purpose: To provide a label for a column of data. - When to use: For the headers of columns in a
Table. - Example: The header row in a spreadsheet with labels like "Name," "Date," and "Amount."ColumnHeader
Represents a row header in a table. - Purpose: To provide a label for a row of data. - When to use: For the headers of rows in a
Table. - Example: The numbered rows on the left side of a spreadsheet.RowHeader
Represents a full column of cells in a table. - Purpose: To represent an entire column as a single accessible object. - When to use: When it is useful to interact with a column as a whole. - Example: The "Amount" column in a financial data table.
Column
Represents a full row of cells in a table. - Purpose: To represent an entire row as a single accessible object. - When to use: When it is useful to interact with a row as a whole. - Example: A row representing a single customer's information in a customer list.
Row
Represents a single cell within a table. - Purpose: To represent a single data point or control within a
Table. - When to use: For individual cells in a grid or table. - Example: A single cell in a spreadsheet containing a specific value.Cell
Represents a hyperlink to a resource. - Purpose: To provide a navigational link to another document or location. - When to use: For text or images that, when clicked, navigate to another resource. - Example: A clickable link on a web page.
Link
Represents a help balloon or pop-up. - Purpose: To provide more detailed help information than a standard tooltip. - When to use: For a pop-up that offers extended help text, often initiated by a help button. - Example: A pop-up balloon with a paragraph of help text that appears when a user clicks a help icon.
HelpBalloon
Represents an animated, character-like graphic object. - Purpose: To provide an animated agent for user assistance or entertainment. - When to use: For animated characters or avatars that provide help or guidance. - Example: An animated paperclip that offers tips in a word processor (e.g., Microsoft's Clippy).
Character
Represents a list of items. - Purpose: To contain a set of
ListItemobjects. - When to use: For list boxes or similar controls that present a list of selectable items. - Example: The list of files in a file selection dialog.List
Represents an individual item within a list. - Purpose: To represent a single, selectable item within a
List. - When to use: For each individual item in a list box or combo box. - Example: A single file name in a list of files.ListItem
Represents an outline or tree structure. - Purpose: To display a hierarchical view of data. - When to use: For tree-view controls that show nested items. - Example: A file explorer's folder tree view.
Outline
Represents an individual item within an outline or tree. - Purpose: To represent a single node (which can be a leaf or a branch) in an
Outline. - When to use: For each node in a tree view. - Example: A single folder in a file explorer's tree view.OutlineItem
Represents a single tab in a tabbed interface. - Purpose: To provide a control for switching between different
PropertyPageviews. - When to use: For the individual tabs that the user can click to switch pages. - Example: The "General" and "Security" tabs in a file properties dialog.PageTab
Represents the content of a page in a property sheet. - Purpose: To serve as a container for the controls displayed when a
PageTabis selected. - When to use: For the content area associated with a specific tab. - Example: The set of options displayed when the "Security" tab is active.PropertyPage
Represents a visual indicator, like a slider thumb. - Purpose: To visually indicate the current value or position of another control. - When to use: For a sub-element that indicates status, like the thumb of a scrollbar. - Example: The draggable thumb of a scrollbar that indicates the current scroll position.
Indicator
Represents a picture or graphical image. - Purpose: To display a non-interactive image. - When to use: For images and icons that are purely decorative or informational. - Example: A company logo displayed in an application's "About" dialog.
Graphic
Represents read-only text. - Purpose: To provide a non-editable text label for another control or for displaying information. - When to use: For text that the user cannot edit. - Example: The label "Username:" next to a text input field.
StaticText
Represents editable text or a text area. - Purpose: To allow for user text input or selection. - When to use: For text input fields where the user can type. - Example: A text box for entering a username or password.
Text
Represents a standard push button. - Purpose: To initiate an immediate action. - When to use: For standard buttons that perform an action when clicked. - Example: An "OK" or "Cancel" button in a dialog.
PushButton
Represents a check box control. - Purpose: To allow the user to make a binary choice (checked or unchecked). - When to use: For options that can be toggled on or off independently. - Example: A "Remember me" checkbox on a login form.
CheckButton
Represents a radio button. - Purpose: To allow the user to select one option from a mutually exclusive group. - When to use: For a choice where only one option from a
Groupingcan be selected. - Example: "Male" and "Female" radio buttons for selecting gender.RadioButton
Represents a combination of a text field and a drop-down list. - Purpose: To allow the user to either type a value or select one from a list. - When to use: For controls that offer a list of suggestions but also allow custom input. - Example: A font selector that allows you to type a font name or choose one from a list.
ComboBox
Represents a drop-down list box. - Purpose: To allow the user to select an item from a non-editable list that drops down. - When to use: For selecting a single item from a predefined list of options. - Example: A country selection drop-down menu.
DropList
Represents a progress bar. - Purpose: To indicate the progress of a lengthy operation. - When to use: To provide feedback for tasks like file downloads or installations. - Example: The bar that fills up to show the progress of a file copy operation.
ProgressBar
Represents a dial or knob. - Purpose: To allow selecting a value from a continuous or discrete range, often circularly. - When to use: For controls that resemble real-world dials, like a volume knob. - Example: A volume control knob in a media player application.
Dial
Represents a control for entering a keyboard shortcut. - Purpose: To capture a key combination from the user. - When to use: In settings where users can define their own keyboard shortcuts. - Example: A text field in a settings dialog where a user can press a key combination to assign it to a command.
HotkeyField
Represents a slider for selecting a value within a range. - Purpose: To allow the user to adjust a setting along a continuous or discrete range. - When to use: For adjusting values like volume, brightness, or zoom level. - Example: A slider to control the volume of a video.
Slider
Represents a spin button (up/down arrows) for incrementing or decrementing a value. - Purpose: To provide fine-tuned adjustment of a value, typically numeric. - When to use: For controls that allow stepping through a range of values. - Example: The up and down arrows next to a number input for setting the font size.
SpinButton
Represents a diagram or flowchart. - Purpose: To represent data or relationships in a schematic form. - When to use: For visual representations of structures that are not charts, like a database schema diagram. - Example: A flowchart illustrating a business process.
Diagram
Represents an animation control. - Purpose: To display a sequence of images or indicate an ongoing process. - When to use: For animations that show that an operation is in progress. - Example: The animation that plays while files are being copied.
Animation
Represents a mathematical equation. - Purpose: To display a mathematical formula in the correct format. - When to use: For displaying mathematical equations. - Example: A rendered mathematical equation in a scientific document editor.
Equation
Represents a button that drops down a list of items. - Purpose: To combine a default action button with a list of alternative actions. - When to use: For buttons that have a primary action and a secondary list of options. - Example: A "Send" button with a dropdown arrow that reveals "Send and Archive."
ButtonDropdown
Represents a button that drops down a full menu. - Purpose: To provide a button that opens a menu of choices rather than performing a single action. - When to use: When a button's primary purpose is to reveal a menu. - Example: A "Tools" button that opens a menu with various tool options.
ButtonMenu
Represents a button that drops down a grid for selection. - Purpose: To allow selection from a two-dimensional grid of options. - When to use: For buttons that open a grid-based selection UI. - Example: A color picker button that opens a grid of color swatches.
ButtonDropdownGrid
Represents blank space between other objects. - Purpose: To represent significant empty areas in a UI that are part of the layout. - When to use: Sparingly, to signify that a large area is intentionally blank. - Example: A large empty panel in a complex layout might use this role.
Whitespace
Represents the container for a set of tabs. - Purpose: To group a set of
PageTabelements. - When to use: To act as the parent container for a row or column of tabs. - Example: The entire row of tabs at the top of a properties dialog.PageTabList
Represents a clock control. - Purpose: To display the current time. - When to use: For any UI element that displays time. - Example: The clock in the system tray of the operating system.
Clock
Represents a button with two parts: a default action and a dropdown. - Purpose: To combine a frequently used action with a set of related, less-used actions. - When to use: When a button has a default action and other related actions available in a dropdown. - Example: A "Save" split button where the primary part saves, and the dropdown offers "Save As."
SplitButton
Represents a control for entering an IP address. - Purpose: To provide a specialized input field for IP addresses, often with formatting and validation. - When to use: For dedicated IP address input fields. - Example: A network configuration dialog with a field for entering a static IP address.
IpAddress
Represents an element with no specific role. - Purpose: To indicate an element that has no semantic meaning for accessibility. - When to use: Should be used sparingly for purely decorative elements that should be ignored by assistive technologies. - Example: A decorative graphical flourish that has no function or information to convey.
Nothing
Unknown or unspecified role. - Purpose: Default fallback when no specific role is assigned. - When to use: As a default value or when role information is unavailable.
Unknown
enum AccessibilityState
Defines the current state of an element for accessibility APIs (e.g., focused, checked). These states provide dynamic information to assistive technologies about the element's condition. See the [MSDN State Constants page](https://docs.microsoft.com/en-us/windows/win32/winauto/object-state-constants) for more details.
17 variants
Selected
Focused
CheckedTrue
CheckedFalse
Readonly
Default
Expanded
Collapsed
Busy
Offscreen
Focusable
Selectable
Linked
Traversed
Multiselectable
Protected
struct DragState
has destructor4 fields
drag_type: DragType
source_node: OptionDomNodeId
current_drop_target: OptionDomNodeId
file_path: OptionString
enum AttributeMatchOp
7 variants
Exists
Eq
Includes
DashMatch
Prefix
Suffix
Substring
struct NodeFlags
Packed representation of tab index + contenteditable flag as a u32.
1 field
inner: u32
struct DomId
A unique, runtime-generated identifier for a single
Dominstance.1 field
inner: usize
union enum AccessibilityAction
has destructor23 variants
Default
Focus
Blur
Collapse
Expand
ScrollIntoView
Increment
Decrement
ShowContextMenu
HideTooltip
ShowTooltip
ScrollUp
ScrollDown
ScrollLeft
ScrollRight
ReplaceSelectedText(String)
ScrollToPoint(LogicalPosition)
SetScrollOffset(LogicalPosition)
SetTextSelection(TextSelectionStartEnd)
SetValue(String)
SetNumericValue(FloatValue)
CustomAction(i32)
struct ListViewOnColumnClickCallback
2 fields
cb: ListViewOnColumnClickCallbackType
callable: OptionRefAny
struct TagIdToNodeIdMapping
3 fields
struct CoreCallback
2 fields
cb: CoreCallbackType
ctx: OptionRefAny
struct NodeHierarchyItemId
1 field
inner: usize
1 constructor
constructor from_raw:
arg value: usize
Creates an
NodeHierarchyItemIdfrom a raw 1-based encoded value.More
Warning
The value must use 1-based encoding (0 = None, n = NodeId(n-1)). Prefer using [
NodeHierarchyItemId::from_crate_internal] instead.1 method
fn into_raw:
&self
-> usize
Returns the raw 1-based encoded value.
More
Warning
The returned value uses 1-based encoding. Do NOT use as an array index!
struct CoreCallbackData
3 fields
struct ListViewOnRowClickCallback
2 fields
cb: ListViewOnRowClickCallbackType
callable: OptionRefAny
struct CoreMenuCallback
2 fields
refany: RefAny
callback: CoreCallback
struct CheckBoxOnToggleCallback
2 fields
cb: CheckBoxOnToggleCallbackType
callable: OptionRefAny
struct DropDownOnChoiceChangeCallback
2 fields
cb: DropDownOnChoiceChangeCallbackType
callable: OptionRefAny
struct TabOnClickCallback
2 fields
callable: OptionRefAny
struct ParentWithNodeDepth
2 fields
depth: usize
node_id: NodeHierarchyItemId
struct ListViewOnLazyLoadScrollCallback
2 fields
cb: ListViewOnLazyLoadScrollCallbackType
callable: OptionRefAny
struct ButtonOnClickCallback
2 fields
callable: OptionRefAny
struct XmlNode
has destructor3 fields
struct TagId
1 field
inner: u64
struct XmlAttributeMap
has destructorAttributes of an XML node, such as
["color" => "blue"]in<button color="blue" />.1 field
inner: StringPairVec
enum NodeTypeTag
184 variants
Html
Head
Body
Div
P
Article
Section
Aside
Header
Main
Figure
FigCaption
H1
H2
H3
H4
H5
H6
Br
Hr
Pre
BlockQuote
Address
Details
Summary
Dialog
Ul
Ol
Li
Dl
Dt
Dd
Menu
MenuItem
Dir
Table
Caption
THead
TBody
TFoot
Tr
Th
Td
ColGroup
Col
Form
FieldSet
Legend
Label
Input
Button
Select
OptGroup
SelectOption
TextArea
Output
Progress
Meter
DataList
Span
A
Em
Strong
B
I
U
S
Mark
Del
Ins
Code
Samp
Kbd
Var
Cite
Dfn
Abbr
Acronym
Q
Time
Sub
Sup
Small
Big
Bdo
Bdi
Wbr
Ruby
Rt
Rtc
Rp
Data
Canvas
Object
Param
Embed
Audio
Video
Source
Track
Map
Area
Svg
SvgPath
SvgCircle
SvgRect
SvgEllipse
SvgLine
SvgPolygon
SvgPolyline
SvgG
SvgDefs
SvgSymbol
SvgUse
SvgSwitch
SvgText
SvgTspan
SvgTextPath
SvgLinearGradient
SvgRadialGradient
SvgStop
SvgPattern
SvgClipPathElement
SvgMask
SvgFilter
SvgFeBlend
SvgFeColorMatrix
SvgFeComponentTransfer
SvgFeComposite
SvgFeConvolveMatrix
SvgFeDiffuseLighting
SvgFeDisplacementMap
SvgFeDistantLight
SvgFeDropShadow
SvgFeFlood
SvgFeFuncR
SvgFeFuncG
SvgFeFuncB
SvgFeFuncA
SvgFeGaussianBlur
SvgFeImage
SvgFeMerge
SvgFeMergeNode
SvgFeMorphology
SvgFeOffset
SvgFePointLight
SvgFeSpecularLighting
SvgFeSpotLight
SvgFeTile
SvgFeTurbulence
SvgMarker
SvgImage
SvgForeignObject
SvgTitle
SvgDesc
SvgMetadata
SvgA
SvgView
SvgStyle
SvgScript
SvgAnimate
SvgAnimateMotion
SvgAnimateTransform
SvgSet
SvgMpath
Title
Meta
Link
Script
Style
Base
Text
Img
VirtualView
TransientWindow
Icon
GeolocationProbe
Before
After
Marker
Placeholder
PageBreak
enum VertexAttributeType
5 variants
Float
Double
UnsignedByte
UnsignedShort
UnsignedInt
struct VertexAttribute
has destructor4 fields
struct InstantPtrCloneCallback
1 field
struct InstantPtrDestructorCallback
1 field
struct DebugState
28 fields
show_hit_test_areas: bool
profiler_dbg: bool
render_target_dbg: bool
texture_cache_dbg: bool
gpu_time_queries: bool
gpu_sample_queries: bool
disable_batching: bool
epochs: bool
echo_driver_messages: bool
show_overdraw: bool
gpu_cache_dbg: bool
texture_cache_dbg_clear_evicted: bool
picture_caching_dbg: bool
primitive_dbg: bool
zoom_dbg: bool
small_screen: bool
disable_opaque_pass: bool
disable_alpha_pass: bool
disable_clip_masks: bool
disable_text_prims: bool
disable_gradient_prims: bool
obscure_images: bool
glyph_flashing: bool
smart_profiler: bool
invalidation_dbg: bool
tile_cache_logging_dbg: bool
profiler_capture: bool
force_picture_invalidation: bool
struct TouchState
4 fields
num_touches: usize
touch_points: TouchPointVec
coalesced_points: TouchPointVec
predicted_points: TouchPointVec
struct GeolocationProbeConfig
4 fields
high_accuracy: bool
background: bool
max_accuracy_m: f32
min_interval_ms: u32
struct LocationFix
8 fields
latitude_deg: f64
longitude_deg: f64
accuracy_m: f32
altitude_m: f32
altitude_accuracy_m: f32
heading_deg: f32
speed_mps: f32
timestamp_ms: u64
struct CoreRenderImageCallback
2 fields
struct CoreImageCallback
2 fields
refany: RefAny
callback: CoreRenderImageCallback
union enum TextInputSelection
2 variants
All
FromTo(TextInputSelectionRange)
struct SelectionId
1 field
inner: u64
struct TextInputSelectionRange
2 fields
dir_from: usize
dir_to: usize
struct TextSelectionStartEnd
2 fields
selection_start: usize
selection_end: usize
struct VirtualKeyCodeCombo
has destructor1 field
keys: VirtualKeyCodeVec
struct SelectionColor
1 field
inner: ColorU
struct SelectionRadius
1 field
inner: PixelValue
struct TextInputOnVirtualKeyDown
2 fields
data: RefAny
callback: TextInputOnVirtualKeyDownCallback
struct TextInputOnVirtualKeyDownCallback
2 fields
cb: TextInputOnVirtualKeyDownCallbackType
callable: OptionRefAny
struct SelectionState
2 fields
selections: SelectionVec
node_id: DomNodeId
struct TextOpExtendSelection
3 fields
struct RenderImageCallback
Callback for rendering dynamic images
2 fields
ctx: OptionRefAny
1 constructor
constructor create:
arg cb: RenderImageCallbackType
Creates a new RenderImageCallback from a function pointer
1 method
fn to_core:
self
Converts this RenderImageCallback to a CoreRenderImageCallback for use with ImageRef::callback
enum SelectionDirection
2 variants
Forward
Backward
struct TextOpSetSelection
2 fields
old_range: OptionSelectionRange
new_range: SelectionRange
struct TextOpClearSelection
1 field
old_range: SelectionRange
struct NodeStateSnapshot
has destructor5 fields
node_id: NodeId
text_content: String
cursor_position: OptionTextCursor
selection_range: OptionSelectionRange
timestamp: Instant
enum DragType
2 variants
Node
File
struct ProgressAriaInfo
has destructorAccessibility information for a
<progress>indicator.5 fields
label: OptionString
current_value: OptionF32
max: OptionF32
indeterminate: bool
description: OptionString
1 constructor
4 methods
self
arg value: f32
fn with_max:
self
arg max: f32
self
arg indeterminate: bool
fn with_description:
self
arg desc: String
Returns a copy with the given current value.
Returns a copy with the given maximum value.
Returns a copy with the indeterminate flag set.
Returns a copy with the given description.
struct MeterAriaInfo
has destructorAccessibility information for a
<meter>gauge.8 fields
label: OptionString
current_value: f32
min: f32
max: f32
low: OptionF32
high: OptionF32
optimum: OptionF32
description: OptionString
1 constructor
4 methods
fn with_low:
self
arg low: f32
fn with_high:
self
arg high: f32
fn with_optimum:
self
arg optimum: f32
fn with_description:
self
arg desc: String
Returns a copy with the given low threshold.
Returns a copy with the given high threshold.
Returns a copy with the given optimum value.
Returns a copy with the given description.
struct NodeDataVecSlice
has destructor2 fields
struct VirtualKeyCodeVecSlice
2 fields
struct NodeHierarchyItemVecSlice
2 fields
struct DomIdVecSlice
2 fields
ptr: DomId
len: usize
struct TagIdToNodeIdMappingVecSlice
2 fields
struct VertexAttributeVecSlice
has destructor2 fields
struct AccessibilityStateVecSlice
2 fields
struct NodeHierarchyItemIdVecSlice
2 fields
ptr: NodeHierarchyItemId
len: usize
struct IdOrClassVecSlice
has destructor2 fields
struct SelectionRangeVecSlice
2 fields
struct SelectionVecSlice
2 fields
struct DomVecSlice
has destructor2 fields
struct AttributeTypeVecSlice
has destructor2 fields
struct AccessibilityActionVecSlice
has destructor2 fields
struct CoreCallbackDataVecSlice
2 fields
struct ScanCodeVecSlice
2 fields
struct ParentWithNodeDepthVecSlice
2 fields
struct XmlNodeChildVecSlice
has destructor2 fields
struct AccessibilitySettings
8 fields
text_scale_factor: f32
prefers_bold_text: bool
prefers_larger_text: bool
prefers_high_contrast: bool
prefers_reduced_motion: bool
prefers_reduced_transparency: bool
screen_reader_active: bool
differentiate_without_color: bool
struct InputMetrics
7 fields
double_click_time_ms: u32
double_click_distance_px: f32
drag_threshold_px: f32
caret_blink_rate_ms: u32
caret_width_px: f32
wheel_scroll_lines: u32
hover_time_ms: u32
struct FocusVisuals
3 fields
focus_ring_color: OptionColorU
focus_border_width: OptionPixelValue
focus_border_height: OptionPixelValue
enum FocusBehavior
2 variants
AlwaysVisible
KeyboardOnly
enum DropEffect
Drop effect - the outcome if the dragged data is dropped on the current target (HTML5
DataTransfer.dropEffect). Must be one ofNone,Copy,Link, orMove; defaults toNone.4 variants
None
Copy
Link
Move
enum DragEffect
Set of drag operations the drag source permits (HTML5
DataTransfer.effectAllowed). Superset ofDropEffectadding combined values (CopyLink,CopyMove,LinkMove,All) andUninitialized(the default).9 variants
Uninitialized
None
Copy
CopyLink
CopyMove
Link
LinkMove
Move
All
struct ParseFloatErrorWithInput
has destructor2 fields
error: ParseFloatError
input: String
enum ScrollIntoViewBehavior
3 variants
Auto
Instant
Smooth
struct RibbonOnTabClickCallback
2 fields
cb: RibbonOnTabClickCallbackType
callable: OptionRefAny
struct TreeViewOnNodeClickCallback
2 fields
cb: TreeViewOnNodeClickCallbackType
callable: OptionRefAny
struct CssAttributeSelector
has destructor3 fields
struct OnVideoFrameCallback
2 fields
callable: OptionRefAny
struct MapPinTapCallback
2 fields
callable: OptionRefAny
struct OnAudioFrameCallback
2 fields
callable: OptionRefAny
struct SwitchOnToggleCallback
2 fields
cb: SwitchOnToggleCallbackType
callable: OptionRefAny
struct SliderOnValueChangeCallback
2 fields
cb: SliderOnValueChangeCallbackType
callable: OptionRefAny
struct SegmentedOnChangeCallback
2 fields
cb: SegmentedOnChangeCallbackType
callable: OptionRefAny
struct RadioGroupOnChangeCallback
2 fields
cb: RadioGroupOnChangeCallbackType
callable: OptionRefAny
struct TextAreaOnFocusLostCallback
2 fields
cb: TextAreaOnFocusLostCallbackType
callable: OptionRefAny
struct AlertOnDismissCallback
2 fields
cb: AlertOnDismissCallbackType
callable: OptionRefAny
struct AccordionOnToggleCallback
2 fields
cb: AccordionOnToggleCallbackType
callable: OptionRefAny
struct ChipOnRemoveCallback
2 fields
callable: OptionRefAny
struct PopoverOnToggleCallback
2 fields
cb: PopoverOnToggleCallbackType
callable: OptionRefAny
struct ComboBoxOnSelectCallback
2 fields
cb: ComboBoxOnSelectCallbackType
callable: OptionRefAny
struct ModalOnCloseCallback
2 fields
callable: OptionRefAny
struct ToastOnDismissCallback
2 fields
cb: ToastOnDismissCallbackType
callable: OptionRefAny
struct PaginationOnChangeCallback
2 fields
cb: PaginationOnChangeCallbackType
callable: OptionRefAny
struct StepperOnStepChangeCallback
2 fields
cb: StepperOnStepChangeCallbackType
callable: OptionRefAny
struct SplitPaneOnResizeCallback
2 fields
cb: SplitPaneOnResizeCallbackType
callable: OptionRefAny
struct DatePickerOnChangeCallback
2 fields
cb: DatePickerOnChangeCallbackType
callable: OptionRefAny
struct TimePickerOnChangeCallback
2 fields
cb: TimePickerOnChangeCallbackType
callable: OptionRefAny
struct ChipOnClickCallback
2 fields
callable: OptionRefAny
struct TextAreaOnVirtualKeyDownCallback
2 fields
cb: TextAreaOnVirtualKeyDownCallbackType
callable: OptionRefAny
struct CardOnClickCallback
2 fields
callable: OptionRefAny
struct TextAreaOnVirtualKeyDown
2 fields
data: RefAny
callback: TextAreaOnVirtualKeyDownCallback
fnptr MeasureDomFn
signature
struct IdentifiedSelection
3 fields
struct IdentifiedSelectionVecSlice
2 fields
struct RibbonGalleryOnSelectCallback
2 fields
cb: RibbonGalleryOnSelectCallbackType
callable: OptionRefAny
struct SelectionTweenCallback
C-ABI wrapper over a
SelectionTweenCallbackType(user-settable selection tween math)2 fields
struct CaretTweenCallback
C-ABI wrapper over a
CaretTweenCallbackType(user-settable caret tween math)2 fields
ctx: OptionRefAny
struct SelectionTweenInfo
has destructorInputs for one selection-tween evaluation: the previously RENDERED selection band rectangles, the rectangles the current layout wants (display-list order, possibly spanning multiple lines and nodes), and the linear progress 0.0..=1.0.
3 fields
struct CustomE2eOpCallback
has destructorApplication handler for E2E ops, plus the schema describing them.
op_schemais DATA, not a second callback: discovery is a field read, needing no invocation and no debug HTTP server. It carries, per op, name / summary / description / the JSON type each argument expects / usage examples / example returns. Those examples and types are what a macro picker renders and what an agent reads instead of taking a screenshot. AzJson is the deliberate interim interface; typed structs come later.3 fields
struct ZombieAnimCallback
C-ABI wrapper over a
ZombieAnimCallbackType(native presence-animation frame function)1 field
cb: usize
struct UpdateCheckCallback
2 fields
ctx: OptionRefAny
struct OnConsumerFrameCallback
2 fields
cb: OnConsumerFrameCallbackType
callable: OptionRefAny
struct DomSplit
has destructor1 constructor
constructor at_path:
[
split_dom_at_path] for API consumers (the tuple return does not cross the ABI): splitdomat the root-to-node child-indexpath- the same paths [crate::solver3::paged_layout::StructuralBreak] carries andPaginationSnapshot::break_pathhands out.struct DocOpSplitNode
2 fields
node: DomNodeId
at: NodePosition
struct DocOpMergeNodes
3 fields
struct StatusBarOnViewSelectCallback
2 fields
cb: StatusBarOnViewSelectCallbackType
callable: OptionRefAny
struct KeyModifiers
4 fields
shift: bool
ctrl: bool
alt: bool
meta: bool
enum PointerSource
8 variants
Unknown
Mouse
Touchpad
Trackball
Trackpoint
Touchscreen
Pen
Eraser
struct ScrollNodeInfo
8 fields
current_offset: LogicalPosition
container_rect: LogicalRect
content_rect: LogicalRect
max_scroll_x: f32
max_scroll_y: f32
overscroll_behavior_x: OverscrollBehavior
overscroll_behavior_y: OverscrollBehavior
overflow_scrolling: OverflowScrolling
struct RawMotionEventData
3 fields
dx: f64
dy: f64
device_id: u64
struct DomNodeIdVecSlice
2 fields
struct SelectionOwner
2 fields
high: u64
low: u64
struct DocumentSelectionSpanVecSlice
2 fields
struct MapMountCallback
2 fields
callable: OptionRefAny
struct VideoMountCallback
2 fields
callable: OptionRefAny
mod app
9 typesApplication entry point, configuration, and lifecycle management.
struct App
2 fields
ptr: c_void
run_destructor: bool
7 methods
fn run:
&self
arg root_window: WindowCreateOptions
fn add_window:
&mut self
arg create_options: WindowCreateOptions
fn get_monitors:
&self
-> MonitorVec
fn set_tray:
&mut self
arg tray: TrayIconData
fn set_app_icon:
&mut self
arg spec: String
fn run_tray_only:
&self
&self
-> bool
Ask for a system-tray icon. Takes effect when
run()starts.More
Deferred rather than immediate because a tray cannot exist this early: macOS needs
NSApplication, and every backend needs the icon registry published so aTrayIconSource::Namedspec can resolve.This is best-effort by design. On a desktop with no tray - a vanilla GNOME has no
StatusNotifierWatcherat all - nothing appears and the app still runs; the failure is logged. Use [crate::desktop::tray::TrayIcon::is_available] beforehand if the app needs to know.Ask for an application icon - the macOS Dock tile, and elsewhere the process-wide default window icon. Takes effect when
run()starts.More
specis an icon-registry spec, exactly what an<icon>node takes: a bare name ("settings"), a pack-qualified name ("mypack:logo"), or a comma-separated fallback list. It renders through the SAME pipeline as a tray icon and an in-DOM<icon>, so all three can never disagree.Best-effort, and deliberately narrower than it looks: macOS documents
applicationIconImageas TEMPORARY (process-local, resets on next launch), and the Windows EXE icon cannot be changed at runtime at all.Run with a tray and NO window, for a menu-bar / system-tray utility that has no main window at all.
run()always creates one, so such an app previously had to open and then hide a window it never wanted.More
Requires
set_tray()to have been called: without a tray there is no way to interact with the app and nothing to keep it alive.macOS only for now. There it switches the process to Accessory activation (the runtime equivalent of
LSUIElement): no Dock tile and no application menu bar, which also means an icon set viaset_app_iconhas nowhere to appear.Whether anything on this system would DISPLAY a tray icon right now. Always true on Windows and macOS. On Linux this checks that org.kde.StatusNotifierWatcher is owned on the session bus AND that a host (a panel) has registered with it - a vanilla GNOME has neither. Lets an app be honest in its UI about whether the icon from
App::set_traycan appear.struct AppConfig
has destructor19 fields
log_level: AppLogLevel
natural_scroll: NaturalScroll
enable_visual_panic_hook: bool
enable_logging_on_panic: bool
synthesize_pinch_from_ctrl_wheel: bool
expose_system_media_controls: bool
termination_behavior: AppTerminationBehavior
icon_provider: IconProviderHandle
bundled_fonts: NamedFontVec
font_loading: FontLoadingConfig
mock_css_environment: OptionCssMockEnvironment
system_style: SystemStyle
component_libraries: ComponentLibraryVec
routes: RouteVec
system_animations: SystemAnimations
custom_e2e_op: CustomE2eOpCallback
updates: UpdateSettings
changelog_md: OptionString
report_problem: OptionEmailAddress
2 methods
&mut self
arg name: String
arg register_fn: RegisterComponentLibraryFnType
fn add_route:
&mut self
arg pattern: String
arg layout_callback: LayoutCallback
Register a component library under a vendor name.
More
Calls register_fn once to build the library, then stores it under name. Registering the same name twice replaces the earlier entry.
Register a route mapping a URL pattern to a layout callback.
More
The first route (or
/) is what the window starts on;CallbackInfo::switch_routeswaps the active one and triggers a relayout. Registering the same pattern twice replaces the earlier entry.C API
enum AppLogLevel
6 variants
Off
Error
Warn
Info
Debug
Trace
struct RendererOptions
3 fields
enum RendererType
2 variants
Hardware
Software
enum AppTerminationBehavior
3 variants
ReturnToMain
RunForever
EndProcess
struct MapPinTap
2 fields
data: RefAny
callback: MapPinTapCallback
struct AppliedEdit
has destructor3 fields
enum NaturalScroll
3 variants
Disabled
Enabled
System
mod callbacks
104 typesCallback type definitions + struct definitions of
CallbackInfosstruct RefAny
2 fields
sharing_info: RefCount
instance_id: u64
1 constructor
constructor new_c:
arg ptr: GlVoidPtrConst
arg len: usize
arg align: usize
arg type_id: u64
arg type_name: String
arg destructor: RefAnyDestructorType
arg serialize_fn: usize
arg deserialize_fn: usize
-> RefAny
Creates a new RefAny from a raw pointer wrapper, size, alignment, type_id, type_name, destructor, and optional JSON serialization function pointers
11 methods
fn is_type:
&self
arg type_id: u64
-> bool
fn get_data_ptr:
&self
-> *const c_void
fn get_type_id:
&self
-> u64
fn set_serialize_fn:
&mut self
arg serialize_fn: usize
&mut self
arg deserialize_fn: usize
fn replace_contents:
&mut self
arg new_value: RefAny
-> bool
fn can_serialize:
&self
-> bool
fn can_deserialize:
&self
-> bool
fn get_serialize_fn:
&self
-> usize
&self
-> usize
&self
-> OptionJson
Returns true if this RefAny is of the given type ID
Returns the internal data pointer. Used by AZ_REFLECT macros for downcasting.
Returns the type ID of this RefAny
Sets the serialization function pointer for JSON export
Sets the deserialization function pointer for JSON import
Replaces the contents of this RefAny with a new value. This properly destroys the old value and updates all metadata. Since all clones share the same internal data, this change is visible to ALL clones. Returns true if successful, false if there are active borrows.
Returns true if this RefAny has a serialization function set
Returns true if this RefAny has a deserialization function set
Returns the serialization function pointer (0 if not set)
Returns the deserialization function pointer (0 if not set)
Serialize this RefAny to JSON using its registered serialize function.
More
Returns Some(Json) on success, or None if serialization is not supported.
struct CallbackInfo
5 fields
ref_data: c_void
hit_dom_node: DomNodeId
cursor_relative_to_item: OptionLogicalPosition
cursor_in_viewport: OptionLogicalPosition
changes: c_void
356 methods
fn get_dataset:
&mut self
arg node_id: DomNodeId
-> OptionRefAny
fn get_hit_node:
&self
-> DomNodeId
fn prevent_default:
&mut self
fn stop_propagation:
&mut self
fn set_css_property:
&mut self
arg node_id: DomNodeId
arg property: CssProperty
fn change_node_text:
fn stop_immediate_propagation:
&mut self
fn add_timer:
fn get_current_keyboard_state:
&self
&self
-> MouseState
fn add_thread:
fn scroll_to:
&mut self
arg dom_id: DomId
arg node_id: NodeHierarchyItemId
arg position: LogicalPosition
&mut self
arg marker: String
&self
&self
fn get_focused_node:
&self
fn set_focus:
&mut self
arg target: FocusTarget
fn create_window:
&mut self
arg options: WindowCreateOptions
&mut self
arg state: FullWindowState
&self
&mut self
arg content: ClipboardContent
fn get_selection:
&self
arg dom_id: DomId
fn switch_route:
&mut self
arg pattern: String
arg params: StringPairVec
fn get_route_param:
fn get_node_rect:
&self
arg node_id: DomNodeId
fn get_gl_context:
&self
fn accept_drop:
&mut self
fn get_ctx:
&self
-> OptionRefAny
fn remove_timer:
&mut self
arg timer_id: TimerId
fn remove_thread:
&mut self
arg thread_id: ThreadId
fn close_window:
&mut self
&mut self
arg id: String
&mut self
fn show_tooltip:
&mut self
arg text: String
fn show_tooltip_at:
&mut self
arg text: String
arg position: LogicalPosition
fn hide_tooltip:
&mut self
&self
-> WindowFlags
fn get_cursor_relative_to_node:
&self
fn get_cursor_relative_to_viewport:
&self
fn get_cursor_position_screen:
&self
fn get_drag_delta:
&self
&self
fn get_drag_delta_screen_incremental:
&self
&mut self
fn get_monitors:
&self
-> MonitorVec
&self
fn get_current_time:
&self
-> Instant
fn is_dom_focused:
&self
arg dom_id: DomId
-> bool
&self
-> bool
fn is_pen_eraser:
&self
-> bool
fn is_pen_barrel_button_pressed:
&self
-> bool
fn focus_next:
&mut self
fn focus_previous:
&mut self
fn focus_first:
&mut self
fn focus_last:
&mut self
fn clear_focus:
&mut self
fn is_dragging:
&self
-> bool
fn is_drag_active:
&self
-> bool
&self
-> bool
&self
-> bool
fn has_sufficient_history_for_gestures:
&self
-> bool
fn update_all_image_callbacks:
&mut self
fn set_icon:
fn get_parent_node:
fn insert_text:
fn add_cursor:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg cursor: TextCursor
-> SelectionId
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg range: SelectionRange
-> SelectionId
&mut self
arg selection_id: SelectionId
-> bool
&self
arg dom_id: DomId
-> usize
fn get_node_size:
&self
arg node_id: DomNodeId
&self
arg node_id: DomNodeId
&self
fn get_timer:
&self
arg timer_id: TimerId
-> OptionTimer
fn get_timer_ids:
&self
-> TimerIdVec
fn get_thread:
&self
arg thread_id: ThreadId
-> OptionThread
fn get_thread_ids:
&self
-> ThreadIdVec
fn get_dom_ids:
&self
-> DomIdVec
fn get_parent:
&self
arg node_id: DomNodeId
&self
arg node_id: DomNodeId
fn get_next_sibling:
&self
arg node_id: DomNodeId
fn get_first_child:
&self
arg node_id: DomNodeId
fn get_last_child:
&self
arg node_id: DomNodeId
&self
arg node_id: DomNodeId
-> OptionString
fn has_selection:
&self
arg dom_id: DomId
-> bool
&self
arg dom_id: DomId
&self
arg dom_id: DomId
&self
&self
fn get_previous_keyboard_state:
&self
&self
&self
&self
&self
arg node_id: DomNodeId
arg property_type: CssPropertyType
&self
arg node_id: DomNodeId
&self
arg node_id: DomNodeId
&self
fn is_node_focused:
&self
arg node_id: DomNodeId
-> bool
fn get_pen_state:
&self
fn get_pen_pressure:
&self
-> OptionF32
fn get_pen_tilt:
&self
&self
-> OptionU64
fn has_focus:
&self
arg node_id: DomNodeId
-> bool
fn get_hovered_file:
&self
-> OptionString
fn get_dropped_file:
&self
-> OptionString
fn get_dragged_node:
&self
fn get_dragged_file:
&self
-> OptionString
fn get_drag_state:
&self
fn get_scroll_delta:
fn get_scroll_state:
fn inspect_paste_target_range:
&self
arg target: DomNodeId
fn inspect_select_all_changeset:
&self
arg target: DomNodeId
&self
arg target: DomNodeId
arg forward: bool
&self
arg target: DomNodeId
&self
arg target: DomNodeId
fn set_copy_content:
&mut self
arg target: DomNodeId
arg content: ClipboardContent
fn set_cut_content:
&mut self
arg target: DomNodeId
arg content: ClipboardContent
&mut self
arg target: DomNodeId
arg range: SelectionRange
&self
arg target: DomNodeId
-> OptionString
&self
arg target: DomNodeId
&self
arg target: DomNodeId
&self
arg target: DomNodeId
-> bool
&self
arg target: DomNodeId
-> OptionUsize
fn can_undo:
&self
arg node_id: NodeId
-> bool
fn can_redo:
&self
arg node_id: NodeId
-> bool
fn get_undo_text:
&self
arg node_id: NodeId
-> OptionString
fn get_redo_text:
&self
arg node_id: NodeId
-> OptionString
&self
arg node_id: NodeId
&self
arg node_id: NodeId
&self
arg target: DomNodeId
&self
arg target: DomNodeId
&self
arg target: DomNodeId
&self
arg target: DomNodeId
fn inspect_move_cursor_to_line_start:
&self
arg target: DomNodeId
fn inspect_move_cursor_to_line_end:
&self
arg target: DomNodeId
fn inspect_move_cursor_to_document_start:
&self
arg target: DomNodeId
fn inspect_move_cursor_to_document_end:
&self
arg target: DomNodeId
&self
arg target: DomNodeId
fn inspect_delete:
&self
arg target: DomNodeId
fn move_cursor_left:
&mut self
arg target: DomNodeId
arg extend_selection: bool
&mut self
arg target: DomNodeId
arg extend_selection: bool
fn move_cursor_up:
&mut self
arg target: DomNodeId
arg extend_selection: bool
fn move_cursor_down:
&mut self
arg target: DomNodeId
arg extend_selection: bool
&mut self
arg target: DomNodeId
arg extend_selection: bool
&mut self
arg target: DomNodeId
arg extend_selection: bool
fn move_cursor_to_document_start:
&mut self
arg target: DomNodeId
arg extend_selection: bool
fn move_cursor_to_document_end:
&mut self
arg target: DomNodeId
arg extend_selection: bool
fn delete_backward:
&mut self
arg target: DomNodeId
fn delete_forward:
&mut self
arg target: DomNodeId
&self
arg node_id: DomNodeId
-> OptionString
&self
arg node_id: DomNodeId
arg attr_name: String
-> OptionString
fn get_node_classes:
fn get_node_id:
&self
arg node_id: DomNodeId
-> OptionString
fn take_screenshot:
&self
arg dom_id: DomId
&self
arg node_id: DomNodeId
fn take_native_screenshot_bytes:
&self
fn take_native_screenshot_base64:
&self
&self
arg dom_id: DomId
&self
fn get_drag_types:
&self
-> StringVec
fn set_drag_data:
fn set_drop_effect:
&mut self
arg effect: DropEffect
&self
-> bool
&self
fn get_pinch:
&self
fn get_rotation:
&self
fn get_long_press:
&self
fn get_location_fix:
&self
&self
&self
&mut self
arg prompt: BiometricPrompt
fn keyring_store:
fn keyring_get:
&mut self
arg key: String
fn keyring_delete:
&mut self
arg key: String
&self
&self
arg kind: SensorKind
&self
arg id: GamepadId
&self
&self
fn get_loaded_fonts:
&self
&self
arg font_hash: u64
-> OptionU8Vec
fn measure_dom:
&self
arg dom: Dom
arg available: LogicalSize
-> LogicalSize
&self
arg dom: Dom
arg bound: LogicalSize
-> LogicalSize
&mut self
fn undo_app_state:
&mut self
fn redo_app_state:
&mut self
fn has_pending_relayout_change:
&self
-> bool
&self
-> String
fn set_route_param:
fn queue_window_state_sequence:
&mut self
arg states: FullWindowStateVec
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg image: ImageRef
arg update_type: UpdateImageType
fn trigger_all_virtual_view_rerender:
&mut self
fn change_node_css_properties:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg properties: CssPropertyVec
fn override_node_css_properties:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg properties: CssPropertyVec
&mut self
arg node_id: DomNodeId
arg property: CssProperty
&mut self
arg dom_id: DomId
arg node_id: NodeHierarchyItemId
arg position: LogicalPosition
&mut self
arg node_id: DomNodeId
arg options: ScrollIntoViewOptions
&mut self
arg changeset: PendingTextEdit
&mut self
arg text: String
&mut self
arg dom_id: DomId
arg parent_node_id: NodeId
arg node_type_str: String
arg position: OptionUsize
arg classes: StringVec
arg id: OptionString
fn delete_node:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg ids_and_classes: IdOrClassVec
&mut self
arg visible: bool
&mut self
&mut self
&mut self
fn scroll_active_cursor_into_view:
&mut self
fn move_cursor:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg cursor: TextCursor
fn set_selection:
fn get_multi_cursor_selections:
&self
arg dom_id: DomId
&self
arg dom_id: DomId
&self
arg node_id: DomNodeId
&self
fn get_system_style:
&self
-> SystemStyle
&self
fn format_integer:
fn format_decimal:
&self
arg locale: String
arg value: i64
fn pluralize:
fn format_list:
fn format_date:
&self
arg locale: String
arg date: IcuDate
arg length: FormatLength
-> IcuResult
fn format_time:
fn format_datetime:
&self
arg locale: String
arg datetime: IcuDateTime
arg length: FormatLength
-> IcuResult
fn compare_strings:
fn sort_strings:
&self
arg locale: String
arg strings: StringVec
-> IcuStringVec
fn strings_equal:
&mut self
arg gesture: NativeGestureEvent
&self
-> bool
&self
arg capability: Capability
&self
-> StringVec
&self
-> StringVec
&self
fn get_drag_data:
&self
arg mime_type: String
-> OptionU8Vec
&mut self
arg position: LogicalPosition
fn process_text_selection_click:
&mut self
arg position: LogicalPosition
arg time_ms: u64
&self
&self
&self
-> StyledDom
fn get_dom_subtree:
&mut self
arg node_id: DomNodeId
arg materialized: OptionLogicalRect
arg virtual_rect: OptionLogicalRect
&self
arg node_id: DomNodeId
&mut self
arg node_id: DomNodeId
arg velocity: LogicalPosition
&mut self
arg dialog: SysDialogType
&mut self
arg data: RefAny
arg callback: UpdateCheckCallback
arg options: UpdateOptions
-> ThreadId
fn record_counter:
&mut self
arg name: String
arg value: u64
arg labels: StringPairVec
fn record_histogram:
&mut self
arg name: String
arg value: f64
arg labels: StringPairVec
fn record_gauge:
&mut self
arg name: String
arg value: f64
arg labels: StringPairVec
&mut self
arg node_id: DomNodeId
arg states: AccessibilityStateVec
fn warn:
&mut self
arg message: String
fn log:
&mut self
arg message: String
&mut self
arg node: DomNodeId
arg open: bool
&mut self
arg node: DomNodeId
arg torn: bool
&self
arg node: DomNodeId
&mut self
&self
-> OptionColorU
fn capture_pointer:
&mut self
arg node: DomNodeId
&mut self
&self
&self
&mut self
arg revision: u64
fn get_document_text_revision:
&self
-> u64
&self
&self
&self
arg ancestor: DomNodeId
arg node: DomNodeId
-> OptionU32Vec
fn mark_document_edit_applied_with_inverse:
&mut self
arg id: u64
arg inverse: DocumentOperation
&self
fn set_pointer_lock:
&mut self
arg locked: bool
fn get_tablet_pad:
&self
&mut self
arg request: HapticRequest
&self
-> f32
fn is_composing:
&self
-> bool
&self
-> u64
&self
-> KeyModifiers
fn is_key_repeat:
&self
-> bool
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg target: LogicalPosition
&mut self
arg changeset: DocumentChangeset
fn mark_document_edit_applied:
&mut self
arg id: u64
&mut self
&mut self
fn play_haptic:
&mut self
arg pattern: HapticPattern
arg target: HapticTarget
&mut self
arg visible: bool
&self
-> OptionString
&self
fn get_dial_state:
&self
fn get_key_locks:
&self
-> KeyLocks
fn get_physical_key:
&self
&self
-> OptionF32
&self
&mut self
fn perform_accessibility_action:
&mut self
arg dom_id: DomId
arg node_id: NodeId
arg action: AccessibilityAction
fn get_hid_devices:
&self
-> HidDeviceVec
fn get_hid_reports:
&self
-> HidReportVec
&self
&self
&self
&self
fn set_now_playing:
&mut self
arg info: NowPlayingInfo
&self
&self
&self
arg node: DomNodeId
&self
-> DomNodeIdVec
fn get_hovered_nodes_frames_ago:
&self
arg frames_ago: usize
-> DomNodeIdVec
&mut self
arg owner: SelectionOwner
arg selections: SelectionVec
&mut self
arg owner: SelectionOwner
&mut self
arg owner: SelectionOwner
arg color: ColorU
fn clear_selection_owner_color:
&mut self
arg owner: SelectionOwner
&self
arg seat_id: u64
&self
fn get_proximity:
&self
&mut self
arg active: bool
&self
&self
-> bool
&self
-> bool
&self
-> bool
&self
-> bool
&mut self
arg seat_id: u64
arg target: FocusTarget
&mut self
arg seat_id: u64
&self
arg seat_id: u64
&self
arg seat_id: u64
arg node_id: DomNodeId
-> bool
fn query_pagination:
&self
arg styled_dom: *const StyledDom
arg page_size: LogicalSize
arg page_config: FakePageConfig
fn media_play:
&mut self
arg node: DomNodeId
fn media_pause:
&mut self
arg node: DomNodeId
fn media_toggle:
&mut self
arg node: DomNodeId
fn media_seek:
&mut self
arg node: DomNodeId
arg position_s: f32
fn media_set_volume:
&mut self
arg node: DomNodeId
arg volume: f32
fn media_set_muted:
&mut self
arg node: DomNodeId
arg muted: bool
&mut self
arg node: DomNodeId
arg duration_s: f32
fn media_advance:
&mut self
arg node: DomNodeId
arg dt_s: f32
&mut self
arg node: DomNodeId
fn get_media_state:
&self
arg node: DomNodeId
fn is_media_playing:
&self
arg node: DomNodeId
-> bool
&self
arg node: DomNodeId
-> f32
&self
arg node: DomNodeId
-> f32
fn get_media_volume:
&self
arg node: DomNodeId
-> f32
fn is_media_muted:
&self
arg node: DomNodeId
-> bool
Prevent the default text input from being applied
More
When called in a TextInput callback, prevents the typed text from being inserted. Useful for custom validation, filtering, or text transformation.
Example
Stop event propagation to other nodes (W3C stopPropagation).
More
Remaining handlers on the current node still fire, but handlers on parent/child nodes in subsequent phases are skipped. Applied after the callback returns.
Set a single CSS property on a node (convenience method for widgets)
More
This is a helper method that wraps
change_node_css_propertiesfor the common case of setting a single property. It uses the hit node's DOM ID automatically.# Arguments *
node_id- The node to set the property on (uses hit node's DOM ID) *property- The CSS property to setExample
Change the text content of a node (applied after callback returns)
More
This method was previously called
set_string_contentsin older API versions.# Arguments *
node_id- The text node to modify (DomNodeId containing both DOM and node IDs) *text- The new text contentExample
Stop event propagation immediately (W3C stopImmediatePropagation).
More
No further handlers fire, not even remaining handlers registered on the same node. Applied after the callback returns.
Add a timer to this window (applied after callback returns)
Get current keyboard state
Get current mouse state
Add a thread to this window (applied after callback returns)
Scroll a node to a specific position (applied after callback returns)
Resolve an app-chosen MARKER string (stamped on a node with
Dom::with_marker) to that node'sDomNodeId, searching every DOM of the current window.More
This is the address half of the inter-widget fast path: a callback on one node finds another widget's node without touching the app data model, then drives it through that widget's public API (for example
ProgressBar::update_progress). Unlike anIdattribute, a marker is invisible to CSS matching. ReturnsNonewhen no node carries the string; the FIRST match in DOM order wins.Get the current cursor position in logical coordinates relative to the window
Get the current scroll offset for the hit node (if it's scrollable)
More
Convenience method that uses the
hit_dom_nodefrom this callback. Useget_scroll_offset_for_nodeif you need to query a specific node.Get the currently focused node (if any)
More
Returns None if no node has focus.
Set keyboard focus target (applied after callback returns)
Create a new window (applied after callback returns)
Modify the window state (applied after callback returns)
Get clipboard content from system clipboard (available during paste operations)
More
This returns content that was read from the system clipboard when Ctrl+V was pressed. It's only available in On::Paste callbacks or similar clipboard-related callbacks.
Use this to inspect what will be pasted before allowing or modifying the paste operation.
Override clipboard content for copy/cut operations
More
This sets custom content that will be written to the system clipboard. Use this in On::Copy or On::Cut callbacks to modify what gets copied.
# Arguments *
content- The clipboard content to write to system clipboardExample
Get the current selection state for a DOM
Switch to a different route (applied after callback returns).
More
On desktop: swaps the layout callback and triggers
RefreshDom. On web: also callshistory.pushState().C API
Get a route parameter by key (e.g.
"id"from/user/:id).More
Returns empty string if the parameter doesn't exist or no route is active.
C API
Get the bounding rectangle of a node (position + size)
More
This is particularly useful for menu positioning, where you need to know where a UI element is to popup a menu relative to it.
Returns the OpenGL context if available
Accept the current drop operation on this node.
More
W3C equivalent: calling
event.preventDefault()in a DragOver handler. This signals that the current drop target can accept the dragged data. Must be called from a DragOver or DragEnter callback for the Drop event to fire on this node.Get the callable for FFI language bindings (Python, etc.)
More
Returns the cloned OptionRefAny if a callable was set, or None if this is a native Rust callback.
Remove a timer from this window (applied after callback returns)
Remove a thread from this window (applied after callback returns)
Close the current window (applied after callback returns)
Add an image to the image cache (applied after callback returns)
Remove an image from the image cache (applied after callback returns)
Reload system fonts (applied after callback returns)
More
Note: This is an expensive operation that rebuilds the entire font cache
Open a menu (context menu or dropdown)
More
The menu will be displayed either as a native menu or a fallback DOM-based menu depending on the window's
use_native_context_menusflag. Uses the position specified in the menu itself.# Arguments *
menu- The menu to displayOpen a menu at a specific position
More
# Arguments *
menu- The menu to display *position- The position where the menu should appear (overrides menu's position)Show a tooltip at the current cursor position
More
Displays a simple text tooltip near the mouse cursor. The tooltip will be shown using platform-specific native APIs where available.
Platform implementations: - Windows: Uses
TOOLTIPS_CLASSWin32 control - macOS: UsesNSPopoveror customNSWindowwith tooltip styling - X11: Creates transient window with_NET_WM_WINDOW_TYPE_TOOLTIP- Wayland: Useszwlr_layer_shell_v1with overlay layer# Arguments *
text- The tooltip text to displayExample
Show a tooltip at a specific position
More
# Arguments *
text- The tooltip text to display *position- The position where the tooltip should appear (in window coordinates)Example
Hide the currently displayed tooltip
More
Example
Open a menu positioned relative to the currently hit node
More
Convenience method for opening a menu at the element that triggered the callback. Equivalent to
open_menu_for_node(menu, info.get_hit_node()).# Arguments *
menu- The menu to display# Returns *
trueif the menu was queued for opening *falseif no node is currently hit or it has no layout informationGet current window flags
Get the current cursor position in screen (global/desktop) coordinates
Get the drag delta from drag start to current position, in window-local logical coordinates
Get the total drag delta in screen coordinates (from drag start to now)
Get the incremental screen drag delta since the last frame (robust against external position changes)
Begin an interactive window move (CSD titlebar drag). On Wayland this delegates to the compositor; on other platforms it is a no-op (use get_drag_delta instead).
Get all connected monitors (cached, no syscall). Returns the monitor list from the app-level cache. Updated automatically when monitors are added/removed.
Get the monitor the window is currently displayed on. Returns the full Monitor struct with DPI, size, position, etc. Returns None if monitor information is unavailable.
Check if any node in a specific DOM is focused
Check if pen is currently in contact with surface
Check if pen is in eraser mode
Check if pen barrel button is pressed
Set focus to a node matching a CSS path
Move focus to next focusable element in tab order
Move focus to previous focusable element in tab order
Move focus to first focusable element
Move focus to last focusable element
Remove focus from all elements
Check if a drag gesture is currently active
More
Convenience method that queries the gesture manager.
Check if a node or file drag is currently active
More
Returns true if either a node drag or file drag is in progress.
Check if a node drag is specifically active
Check if a file drag is specifically active
Check if there's sufficient mouse history for gesture detection (at least 2 frames)
Re-render an image callback (for resize/animation updates)
More
This triggers re-invocation of the RenderImageCallback associated with the node. Useful for: - Responding to window resize (image needs to match new size) - Animation frames (update OpenGL texture each frame) - Interactive content (user input changes rendering)
Example
Re-render ALL image callbacks across all DOMs (applied after callback returns)
More
This is the most efficient way to update animated GL textures from a timer. Triggers only texture re-rendering - no DOM rebuild or display list resubmission.
Example
Trigger re-rendering of a VirtualView (applied after callback returns)
More
This forces the VirtualView to call its layout callback with reason
DomRecreatedand submit a new display list to WebRender. The VirtualView's pipeline will be updated without affecting other parts of the window.Useful for: - Live preview panes (update when source code changes) - Dynamic content that needs manual refresh - Editor previews (re-parse and display new DOM)
Example
Swap the icon a Dom::create_icon_view node renders, without a full layout().
More
The counterpart of "change this node's text" for icons - and it cannot BE that, twice over. An icon is not one node (it resolves to a subtree), and by the time a callback runs the DOM it would edit has already been built, so rewriting the spec in the tree would change nothing until the next full rebuild. So the icon lives in a VirtualView: this rewrites the spec the view owns and queues a re-render of THAT view. One callback, one small nested DOM re-cascaded in place, damage the size of the icon. No layout(), no DOM diff.
node_id is the view node itself, typically found with get_node_id_by_marker. Returns false, changing nothing, when it does not name a live icon view: no layout result, no dataset, or a dataset belonging to another widget. Setting the spec the view already has also returns false and queues nothing.
Example
Find a node by ID attribute in the layout tree
More
Returns the NodeId of the first node with the given ID attribute, or None if not found.
Example
Get the parent node of the given node
More
Returns None if the node has no parent (i.e., it's the root node)
Get the next sibling of the given node
More
Returns None if the node has no next sibling
Get the previous sibling of the given node
More
Returns None if the node has no previous sibling
Get the first child of the given node
More
Returns None if the node has no children
Get the last child of the given node
More
Returns None if the node has no children
Change the image mask of a node (applied after callback returns)
Insert text at the current cursor position in a text node
More
This operation is transactional - the text will be inserted after the callback returns. If there's a selection, it will be replaced with the inserted text.
# Arguments *
dom_id- The DOM containing the text node *node_id- The node to insert text into *text- The text to insertExample
Add an additional cursor at the specified position (multi-cursor editing).
More
Returns the SelectionId of the new cursor.
Add an additional selection range (multi-cursor editing).
More
Returns the SelectionId of the new selection.
Remove a specific selection/cursor by its stable SelectionId.
Get the number of active cursors/selections in the MultiCursorState.
Open a menu positioned relative to a specific DOM node
More
This is useful for dropdowns, combo boxes, and context menus that should appear near a specific UI element. The menu will be positioned below the node by default.
# Arguments *
menu- The menu to display *node_id- The DOM node to position the menu relative to# Returns *
trueif the menu was queued for opening *falseif the node doesn't exist or has no layout informationGet the bounding rectangle of the hit node
More
Convenience method that combines get_hit_node() and get_node_rect(). Useful for menu positioning based on the clicked element.
Get a reference to a timer
Get all timer IDs
Get a reference to a thread
Get all thread IDs
Get all DOM IDs that have layout results
Check if a DOM has any selection
Get the primary cursor for a DOM (first in selection list)
Get all selection ranges (excludes plain cursors)
Get full current window state (immutable reference)
Get previous window flags
Get previous keyboard state
Get previous mouse state
Get the layout rectangle of the currently hit node (in logical coordinates)
Get the computed CSS property for a specific DOM node
More
This queries the CSS property cache and returns the resolved property value for the given node, taking into account: - User overrides (from callbacks) - Node state (:hover, :active, :focus) - CSS rules from stylesheets - Cascaded properties from parents - Inline styles
# Arguments *
node_id- The DOM node to query *property_type- The CSS property type to retrieve# Returns *
Some(CssProperty)if the property is set on this node *Noneif the property is not set (will use default value)Get the computed width of a node from CSS
More
Convenience method for getting the CSS width property.
Get the computed height of a node from CSS
More
Convenience method for getting the CSS height property.
Check if a specific node is currently focused
Get current pen/stylus state if a pen is active
Get current pen pressure (0.0 to 1.0) Returns None if no pen is active, Some(0.5) for mouse
Get current pen tilt angles (x_tilt, y_tilt) in degrees Returns None if no pen is active
Get the event ID of the current event
Set focus to a specific DOM node by ID
Check if a specific node has focus
Get the currently hovered file (if drag-drop is in progress)
More
Returns None if no file is being hovered over the window.
Get the currently dropped file (if a file was just dropped)
More
This is a one-shot value that is cleared after event processing. Returns None if no file was dropped this frame.
Get the node being dragged (if any)
Get the file path being dragged (if any)
Get the current drag/drop state (if any)
More
Returns None if no drag is active, or Some with drag details.
Get the current scroll offset for a specific node (if it's scrollable)
Get the scroll delta for a node in the current frame (for scroll event detection)
Get the scroll state (container rect, content rect, current offset) for a node
Inspect the current selection range that would be affected by paste
More
Returns the selection range that will be replaced when pasting. Returns None if no selection exists (paste will insert at cursor).
Inspect what text would be selected by Select All operation
More
Returns the full text content and the range that would be selected.
Inspect what would be deleted by a backspace/delete operation
More
Uses the pure functions from
text3::edit::inspect_delete()to determine what would be deleted without actually performing the deletion.Returns (range_to_delete, deleted_text). - forward=true: Delete key (delete character after cursor) - forward=false: Backspace key (delete character before cursor)
Example
Inspect a pending copy operation
More
Returns the clipboard content that would be copied from the current selection. Use this to validate or transform content before copying.
Inspect a pending cut operation
More
Returns the clipboard content that would be cut (copied + deleted). Use this to validate or transform content before cutting.
Set/modify the clipboard content before a copy operation
More
Use this to transform clipboard content before copying. The change is queued and will be applied after the callback returns, if preventDefault() was not called.
Example
Set/modify the clipboard content before a cut operation
More
Similar to set_copy_content but for cut operations. The change is queued and will be applied after the callback returns.
Override the selection range for select-all operation
More
Use this to limit what gets selected (e.g., only select visible text). The change is queued and will be applied after the callback returns.
Get the current text content of a node
More
Helper for inspecting text before operations.
Get the current cursor position in a node
More
Returns the text cursor position if the node is focused.
Get the current selection ranges in a node
More
Returns all active selection ranges for the specified DOM.
Check if a specific node has an active selection
More
This checks if the specific node (identified by DomNodeId) has a selection, as opposed to has_selection(DomId) which checks the entire DOM.
Get the length of text in a node
More
Useful for bounds checking in custom operations.
Check if undo is available for a specific node
More
Returns true if there is at least one undoable operation in the stack.
Check if redo is available for a specific node
More
Returns true if there is at least one redoable operation in the stack.
Get the text that would be restored by undo for a specific node
More
Returns the pre-state text content that would be restored if undo is performed. Returns None if no undo operation is available.
Get the text that would be restored by redo for a specific node
More
Returns the pre-state text content that would be restored if redo is performed. Returns None if no redo operation is available.
Inspect a pending undo operation
More
Returns the full UndoableOperation that would be undone. Use this to inspect the changeset and pre-state before allowing undo.
Inspect a pending redo operation
More
Returns the full UndoableOperation that would be redone. Use this to inspect the changeset and pre-state before allowing redo.
Inspect where the cursor would move when pressing left arrow
More
Returns the new cursor position that would result from moving left. Returns None if the cursor is already at the start of the document.
# Arguments *
target- The node containing the cursorExample
Inspect where the cursor would move when pressing right arrow
More
Returns the new cursor position that would result from moving right. Returns None if the cursor is already at the end of the document.
Inspect where the cursor would move when pressing up arrow
More
Returns the new cursor position that would result from moving up one line. Returns None if the cursor is already on the first line.
Inspect where the cursor would move when pressing down arrow
More
Returns the new cursor position that would result from moving down one line. Returns None if the cursor is already on the last line.
Inspect where the cursor would move when pressing Home key
More
Returns the cursor position at the start of the current line.
Inspect where the cursor would move when pressing End key
More
Returns the cursor position at the end of the current line.
Inspect where the cursor would move when pressing Ctrl+Home
More
Returns the cursor position at the start of the document.
Inspect where the cursor would move when pressing Ctrl+End
More
Returns the cursor position at the end of the document.
Inspect what text would be deleted by backspace (including Shift+Backspace)
More
Returns (range_to_delete, deleted_text). This is a convenience wrapper around inspect_delete_changeset(target, false).
Inspect what text would be deleted by delete key
More
Returns (range_to_delete, deleted_text). This is a convenience wrapper around inspect_delete_changeset(target, true).
Move cursor left (arrow left key)
More
# Arguments *
target- The node containing the cursor *extend_selection- If true, extends selection (Shift+Left); if false, moves cursorExample
Move cursor right (arrow right key)
Move cursor up (arrow up key)
Move cursor down (arrow down key)
Move cursor to line start (Home key)
Move cursor to line end (End key)
Move cursor to document start (Ctrl+Home)
Move cursor to document end (Ctrl+End)
Delete text backward (backspace or Shift+Backspace)
More
Queues a backspace operation to be applied after the callback. Use inspect_backspace() to see what would be deleted.
Delete text forward (delete key)
More
Queues a delete operation to be applied after the callback. Use inspect_delete() to see what would be deleted.
Get all direct children of a node
More
Returns a vector of NodeIds for all direct children of the specified node. Does not recurse into children of children (non-recursive).
Get the number of direct children of a node
More
Returns the count of direct children for the specified node. This is more efficient than get_all_children_nodes().len() when you only need the count.
Get the HTML tag name of a node
More
Returns the tag name (e.g., 'div', 'body', 'p', 'input') of the specified node. Returns None if the node doesn't exist.
Get a specific attribute value of a node
More
Returns the value of the specified attribute on the node. Supports standard HTML attributes like 'id', 'class', 'href', 'src', 'alt', etc. Also supports custom data-* attributes and aria-* attributes.
# Arguments *
node_id- The DOM node to query *attr_name- The attribute name to look up (e.g., 'id', 'class', 'href')# Returns *
Some(String)if the attribute exists *Noneif the attribute doesn't exist or the node doesn't existGet all CSS classes of a node
More
Returns a vector of all CSS class names applied to the node.
Get the ID attribute of a node
More
Convenience method for getting the 'id' attribute. Equivalent to get_node_attribute(node_id, 'id').
Take a CPU-rendered screenshot of a DOM
More
Renders the specified DOM to a PNG image using the CPU renderer. This captures only the DOM content without window decorations. Useful for visual regression testing (reftest) and documentation.
# Arguments *
dom_id- The DOM to screenshot# Returns *
Ok(Vec<u8>)- PNG-encoded image data *Err(String)- Error message if rendering failedTake a CPU-rendered screenshot of ONE NODE.
More
The window is rendered exactly as take_screenshot does - same compositor, same font/image caches, so the result is what the user sees - and the node's box is then cut out of it. Clipping, overlap and ancestor effects therefore stay correct; a node re-rendered in isolation would show none of them.
# Returns * Ok(Vec<u8>) - PNG-encoded image of the node * Err(String) - the DOM has no layout, the node has no bounds, or encoding failed
Take a native OS-level screenshot and return the PNG data as bytes
More
Same as take_native_screenshot but returns the PNG data directly instead of saving to a file.
# Returns *
Ok(Vec<u8>)- PNG-encoded image data *Err(String)- Error message if screenshot failedTake a native OS-level screenshot and return as a Base64 data URI
More
Returns the screenshot as a 'data:image/png;base64,...' string that can be directly used in HTML img tags or JSON responses.
# Returns *
Ok(String)- Base64 data URI string *Err(String)- Error message if screenshot failedTake a CPU-rendered screenshot and return as a Base64 data URI
More
Returns the screenshot as a 'data:image/png;base64,...' string. This is the software-rendered version without window decorations.
# Returns *
Ok(String)- Base64 data URI string *Err(String)- Error message if rendering failedGet the current text changeset being processed (if any)
More
This allows callbacks to inspect what text input is about to be applied. Returns None if no text input is currently being processed.
Use
set_text_changeset()to modify the text that will be inserted, andprevent_default()to block the text input entirely.Get the list of MIME types available on the current drag operation.
More
W3C equivalent:
dataTransfer.typesReturns an empty vec if no drag is active or no data is set.Set drag data for a MIME type on the active drag operation.
More
W3C equivalent:
dataTransfer.setData(type, data)Should be called from a DragStart callback to populate the drag data.Set the drop effect for the current drag operation.
More
W3C equivalent:
dataTransfer.dropEffect = "none" | "copy" | "link" | "move". Should be called from a DragOver or DragEnter callback on the drop target.True iff the gesture manager classified the current event sequence as a double-click / double-tap.
Returns the dominant direction of the current swipe gesture, if any. Detection uses the touch / pointer trajectory and a velocity threshold; on iOS / Android the platform backend may override the in-process detector with a native gesture-recognizer result.
Returns the active pinch gesture (scale + center + distances), if any.
Returns the active rotation gesture (radians + center), if any.
Returns the active long-press, if the user is currently holding a pointer in place beyond the configured threshold.
Get the most recent geolocation fix, or
Noneif noGeolocationProbeis mounted or no platform backend has delivered a fix yet. The fix is kept live by the platform backends (AndroidFusedLocationProvider, iOS/macOSCLLocationManager) via the async fix channel that the layout pass folds into the manager - so a callback can read the user's position to, e.g., place a "you are here" marker on a map.Get the most recent biometric-auth result, or
Noneif norequest_biometric_authhas completed yet. Kept live by the platform backends (iOS/macOSLAContext, AndroidBiometricPrompt, WindowsUserConsentVerifier) via the async result channel the layout pass folds into the manager - so a callback can unlock a vault / settings panel once the user authenticates.Get the device's biometric capability (sync probe):
Face,Fingerprint,Iris, orNotAvailable. Lets a callback decide whether to even offer a biometric unlock before requesting one (no OS prompt is shown - this just reads the cached probe).Request a biometric-auth prompt (Face ID / Touch ID / Android
BiometricPrompt/ Windows Hello). Returns immediately - the OS draws its own modal asynchronously; the outcome arrives on a later frame and is read via [CallbackInfo::get_biometric_result]. Call this from, e.g., an unlock button'son_click. Thepromptconfigures the reason text, cancel label, and whether the OS passcode fallback is allowed. (No platform backend reports a real outcome yet - the request currently resolves toBiometricResult::Unavailable; the iOS/macOS/Android backends land in a later tick.)Store
secretunderkeyin the OS keyring (Keychain / KeyStore / libsecret / CredentialLocker). Whenrequire_biometryis set, a laterkeyring_getof this key triggers the OS biometric prompt. Returns immediately; the outcome arrives viaget_keyring_result()on a later frame.Read the secret stored under
key. A biometry-bound item shows the OS prompt first; the secret (or a denial) arrives viaget_keyring_result()on a later frame.Remove the item stored under
keyfrom the OS keyring (no-op if absent). The outcome arrives viaget_keyring_result().Get the most recent keyring outcome, or
Noneuntil the first op completes. Read after akeyring_store/get/deleteto observe the result - e.g. the revealed secret from akeyring_get(KeyringResult::Retrieved).Get the latest motion-sensor reading for
kind(Accelerometer / Gyroscope / Magnetometer), orNoneif no platform backend has delivered one. Kept live by the sensor backends (iOS CoreMotion, AndroidSensorManager) via the async channel the layout pass folds into the manager - so a callback can drive tilt / shake / compass UI.Get the latest state of the gamepad
id(button bitset + analog axes), orNoneif no pad with that id has connected. Kept live by the controller backend (gilrs / iOSGCController/ AndroidInputDevice) via the async channel the layout pass folds into the manager - so a callback can drive movement / menu UI. For the common single-controller case, [CallbackInfo::get_primary_gamepad] skips the id bookkeeping.Get the first currently-connected gamepad, or
Noneif none is connected - the convenient single-controller accessor.The safe-area insets (notch / system-UI margins) for this window, in logical px - lay out interactive content within them so it isn't hidden by a notch / rounded corners / status bar. Zero where the platform or window has no inset. Set by the platform shell (macOS
NSScreennotch, iOSUIView.safeAreaInsets, AndroidWindowInsets).Enumerate every font the layout engine currently has loaded in its font cache.
More
Returns one [
LoadedFont](azul_core::resources::LoadedFont) descriptor per loaded face. Thefont_hashfield of each descriptor is identical to thefont_hashcarried byDisplayListItem::Textglyph runs, so a callback can correlate a loaded font with the text that uses it and then pull the raw bytes via [get_loaded_font_bytes](Self::get_loaded_font_bytes).The list includes fallback faces that were resolved during layout, not just the families named in the source CSS.
Retrieve the raw source bytes (TTF / OTF / TTC, etc.) for a loaded font, looked up by the
font_hashreturned from [get_loaded_fonts](Self::get_loaded_fonts) (or carried on aDisplayListItem::Textglyph run).More
Returns
Noneif no loaded font matchesfont_hash, or if the matching font did not retain its source bytes (e.g. a test-only font; production fonts loaded from disk retain an mmap-backed handle and always succeed). The returned bytes can be embedded directly into a generated document.Measure a DOM headlessly: style + lay it out against
availableconstraints (this window's fonts / system style) without touching the live layout. Returns the union of all node bounds - use a very tallavailable.height(e.g.1_000_000.0) to get a DOM's natural height at a given width. Primary use: sizingVirtualViewitems to compute the virtual scroll extent. A full cold layout pass per call - cache per item template.Measure a DOM headlessly at the size its CONTENT asks for: as wide as its max-content width (no wider than
bound), and as tall as that makes it. The natural-size counterpart ofmeasure_dom, whose block root stretches to whatever width it is given - so a label measured that way reports the box, not the text.More
This is what a content-sized view returns as its
materializedrect: a text label, a badge, a popup panel. Pass a generousbound(a few thousand pixels) for "unconstrained"; aVirtualViewwithwidth: autois then laid out at the size it reports. Two cold layout passes per call.Returns
LogicalSize::zero()when no measure hook was injected.Snapshot the current app state into the undo history (mini-git commit).
Undo the last committed app-state change; relayouts all windows.
Redo a previously undone app-state change; relayouts all windows.
Check if pending changes require relayout before the next step.
More
Returns true for
ModifyWindowState(resize) andScrollTo(scroll), which both need the event loop to re-run layout so that subsequent operations (liketake_screenshot) see updated content.Used by the E2E test runner to detect when it needs to yield.
Get the current active route pattern (e.g.
"/user/:id").More
Returns empty string if no route is active.
C API
Set a route parameter value and trigger re-render.
More
This modifies the active route's params in-place and triggers a DOM refresh. On web, this also updates the URL via
history.replaceState().C API
Queue multiple window state changes to be applied in sequence. Each state triggers a separate event processing cycle, which is needed for simulating clicks where mouse down and mouse up must be separate events.
Change the image of a node (applied after callback returns)
Re-render EVERY
VirtualViewon the existing DOM - no node id required.More
Use from a callback that mutated a dataset shared with a
VirtualView'srefany(the two are clones of oneRefAny, so they point at the same underlying data). The canonical case is a background thread writeback: e.g. theMapWidget's tile-fetch worker decodes a tile, writes it into the sharedMapTileCache, then calls this so the pureVirtualViewcontent callback re-reads the cache and rebuilds its child DOM in place - WITHOUT aRefreshDom(which would rebuild the DOM and orphan the worker's clone of the cache).Change CSS properties of a node (applied after callback returns)
Quickly override CSS properties on a node for animation or other transient visual changes. Writes go through
CssPropertyCache::user_overridden_properties, which is consulted at higher priority than the static cascade, so this does not invalidate the styled DOM's CSS rules. PassCssProperty::Initialfor a given property type to remove any prior override for that type.Convenience wrapper for
override_node_css_propertiesthat targets a single property on the hit node's DOM (typical for animation callbacks). # PanicsMore
Panics if
node_id.nodeis None; the target must reference a concrete node.Scroll a node to a specific position without clamping. Used by the scroll physics timer for rubber-banding/overscroll.
Scroll a node into view (W3C scrollIntoView API)
More
Scrolls the element into the visible area of its scroll container. This is the recommended way to programmatically scroll elements into view.
Arguments
*
node_id- The node to scroll into view *options- Scroll alignment and animation optionsNote
This uses the transactional change system - the scroll is queued and applied after the callback returns. The actual scroll adjustments are calculated during change processing.
Set/override the text changeset for the current text input operation
More
This allows you to modify what text will be inserted during text input events. Typically used in combination with
prevent_default()to transform user input.# Arguments *
changeset- The modified text changeset to applyCreate a synthetic text input event
More
This simulates receiving text input from the OS. Use this to programmatically insert text into contenteditable elements, for example from the debug server or from accessibility APIs.
The text input flow will: 1. Record the text in
TextInputManager(creating aPendingTextEdit) 2. Generate syntheticTextInputevents 3. Invoke user callbacks (which can intercept/reject via preventDefault) 4. Apply the changeset if not rejected 5. Mark dirty nodes for re-render# Arguments *
text- The text to insert at the current cursor positionInsert a new child node into the DOM tree (applied after callback returns)
More
Creates a new node with the given type string and appends it as a child of the specified parent node. The
node_type_strcan be: - A tag name: "div", "p", "span", "button", etc. - Text content: "text:Hello World"# Arguments *
dom_id- The DOM to modify *parent_node_id- The parent node to insert under *node_type_str- The node type (tag name or "text:content") *position- Optional child index (None = append at end) *classes- CSS classes for the new node *id- Optional ID for the new nodeDelete a node from the DOM tree (applied after callback returns)
More
Tombstones the node by setting it to an empty anonymous Div and unlinking it from the hierarchy. This preserves node ID stability (other node IDs don't shift).
# Arguments *
dom_id- The DOM containing the node *node_id- The node to deleteSet the IDs and classes on an existing node (applied after callback returns)
More
Replaces the current IDs and classes of a node with the given set.
# Arguments *
dom_id- The DOM containing the node *node_id- The node to modify *ids_and_classes- The new set of IDs and classesSet cursor visibility state
More
This is primarily used internally by the cursor blink timer callback. User code typically doesn't need to call this directly.
Reset cursor blink state on user input
More
This makes the cursor visible and records the current time, so the blink timer knows to keep the cursor solid for a while before blinking. Called automatically on keyboard input, but can be called manually.
Start the cursor blink timer
More
Called automatically when focus lands on a contenteditable element. The timer will toggle cursor visibility at ~530ms intervals.
Stop the cursor blink timer
More
Called automatically when focus leaves a contenteditable element.
Scroll the active cursor into view
More
This scrolls the focused text element's cursor into the visible area of any scrollable ancestor. Called automatically after text input.
Move the text cursor to a specific position
More
# Arguments *
dom_id- The DOM containing the text node *node_id- The node containing the cursor *cursor- The new cursor positionSet the text selection range
More
# Arguments *
dom_id- The DOM containing the text node *node_id- The node containing the selection *selection- The new selection (can be a cursor or range)Get all selections for the given DOM (read-only).
More
Returns a Vec of
IdentifiedSelectionfrom theMultiCursorState, or empty if no multi-cursor state exists.Get the primary (last-added) selection from the
MultiCursorState.Get the hit test bounds of a node from the display list
More
This is more reliable than
get_node_rectbecause the display list always contains the correct final rendered positions.Get full previous window state (immutable reference)
Get the system style (for menu rendering, CSD, etc.) This is useful for creating custom menus or other system-styled UI.
Get the ICU localizer cache for internationalized formatting.
More
The cache stores localizers for multiple locales. Each locale's formatter is lazily created on first use and cached for subsequent calls.
Format an integer with locale-appropriate grouping separators.
More
# Arguments *
locale- BCP 47 locale string (e.g., "en-US", "de-DE", "ja-JP") *value- The integer to formatExample
Format a decimal number with locale-appropriate separators.
More
# Arguments *
locale- BCP 47 locale string *integer_part- The full integer value (e.g., 123456 for 1234.56) *decimal_places- Number of decimal places (e.g., 2 for 1234.56)Example
Get the plural category for a number (cardinal: "1 item", "2 items").
More
# Arguments *
locale- BCP 47 locale string *value- The number to get the plural category forExample
Select the appropriate string based on plural rules.
More
# Arguments *
locale- BCP 47 locale string *value- The number to pluralize *zero,one,two,few,many,other- Strings for each categoryExample
Format a list of items with locale-appropriate conjunctions.
More
# Arguments *
locale- BCP 47 locale string *items- The items to format as a list *list_type- And, Or, or Unit list typeExample
Format a date according to the specified locale.
More
# Arguments *
locale- BCP 47 locale string *date- The date to format (use IcuDate::now() or IcuDate::new()) *length- Short, Medium, or Long formatExample
Format a time according to the specified locale.
More
# Arguments *
locale- BCP 47 locale string *time- The time to format (use IcuTime::now() or IcuTime::new()) *include_seconds- Whether to include seconds in the outputExample
Format a date and time according to the specified locale.
More
# Arguments *
locale- BCP 47 locale string *datetime- The date and time to format (use IcuDateTime::now()) *length- Short, Medium, or Long formatCompare two strings according to locale-specific collation rules.
More
Returns -1 if a < b, 0 if a == b, 1 if a > b. This is useful for locale-aware sorting where "A-umlaut" should sort with "A" in German.
# Arguments *
locale- BCP 47 locale string *a- First string to compare *b- Second string to compareExample
Sort a list of strings using locale-aware collation.
More
This properly handles accented characters, case sensitivity, and language-specific sorting rules.
# Arguments *
locale- BCP 47 locale string *strings- The strings to sortExample
Check if two strings are equal according to locale collation rules.
More
This may return
truefor strings that differ in case or accents, depending on the collation strength.# Arguments *
locale- BCP 47 locale string *a- First string to compare *b- Second string to compareQueue a platform-native gesture-recognizer result. Applied by the event-loop after the callback returns, via
CallbackChange::InjectNativeGesture->GestureAndDragManager::inject_native_gesture. Used by the iOS / Android / macOSplatform backends from their gesture-recognizer callbacks and by the e2e debug-server harness so JSON tests can drive every event filter end-to-end.Check if
multi_cursorhas any selection ranges.More
Replaces the removed
get_selection_manager().Read the most recently observed permission state for
capability(Camera / Microphone / Geolocation / Sensors / Notifications / ...) - e.g. so a callback can check a capability isGrantedbefore using it (show a camera preview only once granted). Kept live by the platform permission backend; a capability is subscribed by mounting its probe node (CameraProbe/GeolocationProbe/ ...) into the DOM.ALL files of the current drag hover (MWA-B7 - multi-file drags were previously truncated to the first path before they reached callbacks).
ALL files of this frame's drop (MWA-B7; one-shot).
Deepest node currently under the mouse pointer (MWA-B8). Anchor for drag auto-scroll when there is no focused node - node drags and OS file hovers scroll the container under the pointer, not the focused text field.
Get drag data for a specific MIME type.
More
W3C equivalent:
dataTransfer.getData(type)Returns None if no drag is active or the MIME type is not set.Find the closest scrollable ancestor of a node.
More
Walks up the node hierarchy to find a node registered in the
ScrollManager. Used by auto-scroll timer to find which container to scroll.Request a hit test update at a specific position
More
This is used by the Debug API to update the hover manager's hit test data after modifying the mouse position. This ensures that mouse event callbacks can find the correct nodes under the cursor.
The hit test is performed during the next frame update.
Process a text selection click at a specific position
More
This is used by the Debug API to trigger text selection directly, bypassing the normal event pipeline which generates
PreCallbackSystemEvent::TextClick.The selection processing is deferred until the
CallbackChangeis processed, at which point theLayoutWindowcan be mutably accessed.Snapshot of the app's registered images as an
ImageCacheSnapshothandle. Decoded pixels are shared (refcounted), never copied or re-decoded.Snapshot of the window's font resolution state as a
FontCacheSnapshothandle. Consumers resolve exactly the fonts the screen resolved - no re-parse.Clone of the CURRENT fully-styled root DOM - CSS cascade already applied, exactly what is on screen. The parity input for
Pdf.from_styled_dom_with_resources().Reconstruct a plain
Domfrom a subtree of the running UI (NodeData cloned, refcounted handles shared). The cascade's retained author CSS is re-attached to the returned root, so re-styling reproduces the on-screen cascade (for a non-root subtree, ancestor-dependent selectors are approximated - useget_styled_dom_clone()when exact parity matters).Reconfigure a VirtualView's ENTIRE geometry WITHOUT re-invoking its callback or re-laying-out its child DOM (see the virtual-views guide: scroll_size/scroll_offset describe the rendered content window, virtual_scroll_size is what the scrollbar represents, virtual_scroll_offset is usually zero). Each argument: Some = set, None = keep the current value. Intended for streaming corrections: a background exact-pagination writeback fixes the scrollbar's total extent live while the materialized window stays put.
Current animation MOMENTUM of a node: the velocity (logical px/s) of its in-flight presence/move animation, None while nothing animates it. Springs carry velocity across retargets by design; reversing a direction is set_animation_momentum with the negation.
Queue a momentum write for after this callback returns: kick the node's in-flight animation with velocity (logical px/s), or start an identity-anchored spring carrying it when nothing is animating.
Opens one of the built-in system dialogs (always CPU-rendered): ReportProblem captures a screenshot of this window and opens the problem-report dialog; UpdateVersion opens the update dialog and starts the async manifest check (install only after consent).
Checks for updates asynchronously on a background thread, reading AppConfig.updates (manifest URL, current version, mode). The callback runs on the main thread with the result; package-managed installs are clamped to notify-only. Returns the thread's id.
Records an app-defined COUNTER metric with free-form labels (pass an empty vec for none). Labels are sanitized and capped (6 keys, 64-char values); every distinct combination counts against the global series ceiling. No-op unless telemetry is compiled in and consented to.
Records an app-defined HISTOGRAM observation with free-form labels (same sanitization and caps as record_counter).
Sets an app-defined GAUGE with free-form labels (same sanitization and caps as record_counter).
Update a node's accessibility VALUE without rebuilding - a slider's position, a progress bar's percentage, a field's contents.
Update a node's accessibility STATE and/or VALUE without rebuilding.
More
Use it wherever a control changes what it announces but not its structure - a toggle flipping checked, a section expanding, a slider moving. Publishing only at build time leaves the accessibility tree describing a state the widget left behind, and a screen-reader user has no way to notice.
Emit a WARNING from inside a callback or a widget.
More
Goes to the same place every engine lint goes: the installed diagnostic sink (stderr by default, so it shows in a terminal), the in-process ring that
assert_stderrreads in e2e, and - oncetelemetry::install_diagnostics_bridge()is called - the OTLP pipeline behind Loki and Grafana, tagged with the running e2e scenario.Use it where a widget can SEE that it has been used wrongly and the engine cannot: a slider handed min > max, a list told to select an index it does not have, a control the app never named. One call, and the message reaches a developer's console, a test assertion, and a dashboard.
Emit an informational message. Same destinations as [
CallbackInfo::warn]; use it for things worth seeing in a trace but not worth alarming anyone.Open (or close) the
<transient-window>atnoderegardless of itsopenattribute. The popup appears after this callback's layout pass and stays open across rebuilds until closed here, by the attribute going false, or by a user dismissal (which also firesComponentEventFilter::Dismissedon the node).nodemust be in this window's dom.Tear the open
<transient-window>atnodeoff into a free toplevel (torn = true) or dock it back onto its anchor (false). Needstearoffon the node. The same thing the user's drag of the window's-azul-app-region: dragstrip does; firesComponentEventFilter::TornOff/Dockedon the node.The drop zone the
tearoff="zone:..."window atnodeis docked onto, if any: the node matching the zone selector the user last dropped it on.Nonewhile it sits in its own parent (or is torn off / not open). Informational: withdock="inline"the engine already lays the panel out inside that zone; read it in aDockedhandler to persist a workspace layout.Let the user pick a colour from the screen with the platform eyedropper: macOS's system sampler; elsewhere a screenshot shown in a fullscreen loupe window (Wayland asks the user's permission through the desktop portal first). Asynchronous: when the user picks or cancels, every callback in THIS window registered for
WindowEventFilter::ScreenColorPickedruns and reads the answer withget_picked_screen_color.The outcome of the most recent
pick_screen_colorin this window: the colour under the pointer when the user clicked, orNoneif they cancelled (or no pick has completed yet).Capture the pointer for
node: until the mouse button is released, every mouse move and the release are delivered tonodeeven when the pointer has left it (W3CsetPointerCapture). Released automatically on mouse-up.Release a pointer capture taken with
capture_pointerbefore the button goes up.The pending structural edit, if any (inspect in a callback before deciding to apply or
prevent_default).Every character-level edit the app has NOT yet folded into its own model: the node's effective text as the user now sees it, revision-stamped. Fold them in, then ack the highest revision with
mark_text_revision_synced- the character-path counterpart ofget_document_edit_clone.Ack the character-path sync: the app's model holds every text edit up to and including
revision. Monotonic; clamped engine-side.The current TEXT revision stamp;
0= no character edits yet.The current selection as byte spans over node text content (the same string
get_node_text_contentreturns). Normalizedstart <= end, logical order, grapheme-safe; one span per affected block for a cross-block selection; empty when only a caret exists.The primary caret in the same coordinates as
get_document_selection, orNonewhen no editing session is active.Child-index path from
ancestordown tonode- the same path vocabularyDocumentChangesetresume points speak. Empty whennode == ancestor;Nonewhennodeis not insideancestor(or in another dom).The handshake carrying the applier's INVERSE operation (from
document_edit::AppliedEdit::inverse) - makes the edit structurally undoable (Ctrl+Z re-records the inverse through the same loop).Enumerate the tablet input devices the platform backend found - name, vendor, USB ids, kind (stylus / eraser / pad / touch), capabilities, raw pressure range, physical size and device node where known. The
xinput listlevel of information: enough to tell the user WHICH tablet is in use or to configure per-device mappings. Empty when no tablet is attached (or the backend cannot enumerate).Lock the pointer to this window: confine it and hide it, so motion is reported as unbounded RELATIVE deltas instead of an absolute position that stops at the screen edge.
More
This is what
MouseState.is_cursor_lockedmeans, and whatRawMouseMotiondelivery is gated on. Passfalseto release.The request can be REFUSED: on X11 another client may already hold the pointer, and a platform with no pointer-lock concept cannot take one at all. Read
MouseState.is_cursor_lockedback to learn whether the lock is actually held; it stores what the platform granted, not what was asked for.Get the current Wacom tablet-pad state (
ExpressKeys+ touch-ring), orNoneif no pad backend has delivered one. (The pen's own wacom features - eraser / barrel button / barrel roll / tilt / pressure - are in [CallbackInfo::get_pen_state].) Kept live by the platform pad backend (Wintab / libwacom+libinput / macOS tabletNSEvents).Play a haptic pattern with an explicit strength and duration.
More
The long form of [
Self::play_haptic], for the two axes that only some actuators have:intensityscales Android's composition primitives and iOS'simpactOccurred(intensity:)and IS the amplitude for gamepad rumble, whileduration_msonly means anything for a continuous motor. Both are ignored by tap-style actuators such as a macOS trackpad, which has no strength axis at all.How much of the window the on-screen keyboard currently covers, in logical px from the bottom edge.
0.0when no keyboard is up.More
Separate from
get_safe_area_insets().bottom, which is the home indicator or navigation bar and does not move. A layout that needs to stay above the keyboard adds the two; one that wants to know why it shrank needs them apart.Whether an IME composition is currently open on the focused node.
Which physical pointing device is driving, or
0when the platform does not say.Which modifier keys are held right now.
Whether the key event being handled is an auto-repeat rather than a fresh press. A text field wants repeats; a jump button does not.
Get a read-only snapshot of a scroll node's bounds and position.
More
This is the recommended API for timer callbacks that need to compute scroll physics. Returns container/content rects and max scroll bounds.
Scroll a node toward a target offset with the critically-damped spring the scroll physics already uses for momentum and rubber-band (AZUL-STILL-TODO B8/I27): the position GLIDES to the target instead of jumping, and a retarget mid-flight keeps the current velocity. One mechanism shared by scroll-to-caret, scroll-to-page and find-result navigation.
More
The input lands in the shared scroll queue; the platform shell starts the physics timer when it sees pending input (the same path wheel momentum takes).
Record a structural document edit programmatically (the bold/italic toolbar path - keyboard defaults record through the default-action layer instead). Applied after the callback returns; azul never applies it to the
StyledDom.The commit handshake: confirm structural edit
idwas applied to the app's model (usually called for you bydocument_edit::apply_document_operationusers).Undo the newest structural edit: a NEW changeset (the inverse) is recorded for the app to apply - nothing mutates here.
Redo the newest undone structural edit.
Play a haptic pattern.
More
Queued rather than played synchronously: callbacks run on the layout thread and the platform actuator APIs want the event loop, the same reason clipboard writes and menu opens are deferred.
Repeated identical requests coalesce - a callback firing per frame during a drag would otherwise make the device buzz continuously instead of ticking once.
Ask the platform to show or hide the on-screen keyboard.
More
A REQUEST, not a setting: only the OS knows whether a keyboard is actually up - a hardware keyboard suppresses it, and the user can dismiss it at any time - so this records intent and the shell reconciles. Desktop shells ignore it.
Focusing a text field does NOT do this implicitly, because a field can be focused for reasons that should not raise a keyboard: restoring focus after a dialog closes, or a programmatic focus during startup.
The IME composition (preedit) text currently being composed on the focused node, if any.
More
Read this from a
CompositionStart/CompositionUpdate/CompositionEndcallback to render composition yourself - a code editor, a terminal, a chat box with inline candidates. OnCompositionEndthis is the COMMITTED string, matching W3Ccompositionend.data, not the (already discarded) preedit.The built-in text widgets do not need this: the engine applies the preedit to their text cache directly.
What kind of device produced the pointer event being handled - a mouse, a touchpad, a trackball, a pen.
Unknownwhen the platform does not classify, which is most of them today.More
Azul splits Mouse/Touch/Pen into separate FILTERS, so this is not how you tell a finger from a mouse. What it answers is the distinction WITHIN the pointer family that a filter cannot: whether a scroll came from a wheel detent or a continuous trackpad drag, and therefore whether a pinch gesture is even possible.
The most recent rotary-control rotation - a tablet pad dial, a Surface Dial, a Wear crown.
Noneuntil one reports.More
delta_radis rotation SINCE THE LAST FRAME, not an angle: a dial has no endstops, so there is no absolute position to read. Integrate it into whatever value the dial controls.Which lock keys are engaged - Caps, Num, Scroll.
More
Not derivable from the pressed-key set: a lock is a TOGGLE, so it stays on after the key is released and no key event describes it. This is what a password field reads to warn that Caps Lock is on.
The physical position of the currently pressed key, independent of layout -
KeyWis the key where W sits on US ANSI even when the user's layout produces Z there.More
Use this for anything positional (game movement bindings); use
get_current_keyboard_state().current_virtual_keycodefor anything the user reads as a letter.How far the pen is from the surface while hovering, normalized 0.0-1.0 against the tool's own sensing range.
Nonewhen no pen is active.More
The scale is the DEVICE's, not millimetres - Wayland reports a 16-bit fraction of maximum range and Win32 only reports in/out of range - so compare it against itself over time (a brush preview that grows as the pen approaches) rather than measuring with it. A touching pen reads
0.0, so check [Self::is_pen_in_contact] to tell "on the surface" from "not reported".Which tool of the tablet is in use - stylus, eraser, airbrush, lens and the rest of the
zwp_tablet_tool_v2vocabulary.Nonewhen no pen is active;Unknownwhen the platform does not classify, which is every backend except Wayland today.Declare the current scroll gesture finished, so
ScrollEndfires.More
Called by the scroll-physics timer when it runs dry. Routed as a
CallbackChangerather than touching the manager directly because a timer callback holds only its own downcast state - the change queue is the seam that reachesLayoutWindowfrom inside a callback.Perform an accessibility action on a node, exactly as if assistive technology had requested it.
More
Applied after the callback returns, via
CallbackChange::PerformAccessibilityAction->LayoutWindow::process_accessibility_action-> dispatch of the synthetic events the action maps to (e.g.AccessibilityAction::Defaulton a button becomes aMouseUpon that button, so itson_clickruns).This is the door the E2E
accessibility_actionop uses. Before it, nothing outside a real screen reader could reach that code path, so "activation invokes no callback" was unobservable from any test.The HID devices the platform enumerated.
More
Returns an owned vec rather than a borrowed slice because this crosses the C API, where a slice has no representation.
Input reports from HID devices azul does not model - flight sticks, wheels, 6-DOF mice, pedals, Stream Decks.
More
The bytes are exactly as the device sent them, because decoding needs that device's report descriptor and a framework guessing at it would be wrong more often than useful. This is the same trade WebHID makes.
Returns an owned vec rather than a borrowed slice because this crosses the C API, where a slice has no representation.
Intermediate touch samples the OS captured between this frame and the last, oldest first.
More
A digitizer samples much faster than the display refreshes - 120 or 240 Hz against 60 - and only the newest position is delivered per frame, which is what a button or a scroll view wants. A drawing app wants all of them: a fast stroke rendered from one point per frame is a polyline with visible corners, and the samples that would have rounded it were captured and thrown away.
Empty when the platform does not report them or nothing moved.
Where the OS predicts the touch is about to go, oldest first.
More
EXTRAPOLATIONS, not measurements - wrong whenever the user changes direction. They exist to hide latency: a stroke drawn through them appears to keep up with the finger, and the app discards and redraws them next frame when real samples arrive.
Never persist them. Committing a predicted point to a document means committing a guess.
Byte offsets of the composition caret/selection within the string from [
Self::get_composition_text], as(begin, end). Equal values mean a collapsed caret.Nonewhen no composition is active.More
Wayland reports these directly on
preedit_string; Win32 derives them fromGCS_CURSORPOSand macOS from theselectedRangehanded tosetMarkedText:selectedRange:replacementRange:.Raw pointer motion since the last frame, in DEVICE units, or
Nonewhen the pointer is not locked or nothing moved.More
This is not the difference between two cursor positions: those have already had the OS acceleration curve applied and are clamped to the screen, so differencing them gives accelerated motion that stops dead at the display edge. Raw deltas are pre-acceleration and unbounded, which is what a 3D orbit, a first-person camera or an infinite-drag scrubber needs.
Units are the device's own counts, whose size depends on its DPI - which is exactly why applications expose a sensitivity setting rather than treating them as pixels.
The scroll box
node_idLIVES IN - itself, if it is one.More
Drag-autoscroll wants this, not [
Self::find_scroll_parent]: the caret in aTextInputsits on the value<p>, which is simultaneously the IFC root and the horizontal scroll box, so a strict-ancestor search skipped straight past the field and scrolled the page instead. Returns the FFI node id, not the internalNodeId:NodeId's own docs nameNodeHierarchyItemIdas "the FFI wrapper type", andNodeId's field is private, so handing one to a binding would give it a value it cannot construct or inspect.Tell the system media session what this app is playing.
More
This is what puts a title, an artist and a play/pause button in the desktop's media widget: GNOME's and KDE's media applets, macOS's Control Center and Now Playing widget. It is the app-facing half of the media KEYS - on every platform the two are one object, and an app becomes eligible to receive
Play/Nextprecisely by declaring what it is playing.Azul does not derive this: it has no playback state machine, and an app playing audio through
rodio, a system framework, or the network knows what it is playing when the toolkit cannot see it.Call it as often as you like
A player is expected to call this every frame with an advancing
position_ms. That costs nothing: a change to the position ALONE is stored but not announced, because the MPRIS spec forbids announcingPositionand because 60 D-Bus broadcasts a second would wake every listening process on the desktop. Announcements happen when the track, the state or the duration actually change.It needs
AppConfig::expose_system_media_controlsRegistering an app as a media player is visible - it appears in the desktop's media controls - so it is opt-in, and publishing with the flag off does nothing. That is the same flag that makes the media keys arrive.
Platforms with no media-session API yet (Windows, iOS, Android) ignore this rather than failing, so one call site is correct everywhere.
The most recent input sample: where the pointer was, when, at what pressure and tilt, and the contact size.
More
This is the raw sample the gesture recogniser works from, one step below the events - useful for a drawing surface that wants every coalesced point, or for correlating a callback with the
event_idthat caused it.Noneoutside an input session, i.e. whenever no button or contact is down: samples are recorded per press, not continuously.Returns an OWNED sample rather than a borrow because this crosses the C API, where a reference into engine state has no representation and no lifetime to protect it - the same reason
get_hid_reportsreturns an owned vec.Why this control failed the last form validation.
More
The payload of an
Invalidevent: the event says WHICH control was rejected, and this says WHY.ValidityState::is_validfor a control that passed, or that nothing has validated yet - an untouched field is valid until a constraint check says otherwise, which is HTML's rule too.A SET rather than one reason, because one field can be both too short and out of range; read it with
ValidityState::has.Why this is not on the event
CallbackInfonever sees theSyntheticEvent- it carries the hit node and read-only access to the window - so anEventDatavariant carrying this would have been an ABI addition no application could observe. Parked in a manager and fetched here, like every other payload an app can actually read.[
Self::get_validity_state] for any control, not just this one.More
What a FORM-LEVEL handler needs: an
Invalidlistener on the form itself runs for each failing child, and an app that wants to paint all of them at once asks about each control by id rather than waiting to be called for it.Every node under the pointer, FRONT TO BACK (9g-ii-e).
More
The hit test itself is a
BTreeMapofDomIdto aHitTestthat is four more maps, which is whyget_current_hit_testabove cannot cross the C ABI - it would need five map types nothing else uses. No application wants that shape anyway; it wants the ANSWER, and this is it.Ordered by z-depth rather than by node id, which is a real difference: two overlapping absolutely-positioned nodes can have any id relationship, and the one on top is the one the backend reported at the lower depth.
Only the REGULAR hits - a scrollbar is not the content beneath it.
[
Self::get_hovered_nodes] for a PAST frame -0is the current one.More
The history is what a gesture recogniser written in application code needs, and it was unreachable for the same reason the current hit test was. Empty for a frame that has aged out; the buffer holds five.
Ask the platform to show or hide the on-screen keyboard.
More
A REQUEST, not a setting: only the OS knows whether a keyboard is actually up - a hardware keyboard suppresses it, and the user can dismiss it at any time - so this records intent and the shell reconciles. Desktop shells ignore it.
It OVERRIDES the focus default; it does not stand alone
This doc used to claim that focusing a text field does NOT raise the keyboard implicitly. THAT WAS NOT TRUE of the engine it described: focusing an editable raises it on the mobile shells and always has, which is why tapping a text field in an existing app works at all - no app calls this. The contract the comment stated would have left every mobile text field dead until each app opted in.
The real contract is an OVERRIDE. This and the focus-driven raise write ONE queue and the last writer wins, and a callback runs after the focus change that triggered it - so an app that wants a focused field WITHOUT a keyboard (restoring focus after a dialog closes, a programmatic focus during startup - the cases the old comment named) calls this with
falsefrom that callback and gets it. Publish a remote participant's cursors and selections (U1).The injection point for a SHARED EDITING SESSION: a peer's caret arrives over the network and this makes it the whole of what that peer has selected in the focused editable. Their caret is painted in their own colour - see [
Self::set_selection_owner_color] - so several people editing one document are visibly distinguishable.REPLACES rather than adds, because a remote participant's state is a SNAPSHOT: accumulating would leave a stale caret behind every time a message was missed.
Does nothing for
SelectionOwner::LOCAL, or when nothing is focused. The local caret is the engine's, and letting an app overwrite it here would put every text-editing invariant the engine maintains into the app's hands.Forget a participant - they left, or their connection dropped (U1).
What colour a participant's caret is painted in (U1).
More
Per OWNER, not per node, which is why this is an API rather than a CSS property:
caret-coloranswers "what colour is the caret in this field", and a shared session needs "what colour is Alice" - a different axis, and one no stylesheet can know because the participants are decided at runtime.An owner with no colour registered falls back to the node's
caret-color, which is what the LOCAL caret always does - so a single-user app is unaffected by any of this.Drop a participant's colour, so their caret falls back to the node's
caret-color(U1).The state of pointer seat
seat_id(9b-ii): a second, independent cursor on a multi-seat desktop (an X11 MPX master pointer).Nonefor a seat this window has never seen. [Self::get_current_mouse_state] is the PRIMARY seat by definition, so a callback handed a mouse event with a non-zero seat id reads that cursor's position and buttons here - the primary's would be a different cursor's.Raw pointer motion since the last frame, in DEVICE units, or
Nonewhen the pointer is not locked or nothing moved.More
This is not the difference between two cursor positions: those have already had the OS acceleration curve applied and are clamped to the screen, so differencing them gives accelerated motion that stops dead at the display edge. Raw deltas are pre-acceleration and unbounded, which is what a 3D orbit, a first-person camera or an infinite-drag scrubber needs.
Units are the device's own counts, whose size depends on its DPI - which is exactly why applications expose a sensitivity setting rather than treating them as pixels. What the platform's media controls asked for (9h-i-a-i-a, 9h-i-a-i-b) - the payload of a
MediaControlevent, or the last one delivered. A desktop scrubber, a lock-screen slider,playerctl positionand the desktop widget's volume slider all arrive here; the transport buttons arrive as media KEYS instead, because they carry no value.SeekRelativeis an offset in microseconds (negative = back),SeekAbsolutea position to jump to - MPRIS says to ignore it whentrack_idis not the current track -OpenUricarries theurito open and play, andSetVolumethevolumeto apply (0.0..1.0). The app reports the result throughset_now_playing: a position that is not the continuation of the last one is announced back to the desktop as a seek, and a changedvolumeas the newVolume.The proximity sensor's TYPED answer (8e-i-a-i, 8e-i-a-ii):
Near/Farfrom a binary sensor (iOS, Windows without ranging), aDistancein the sensor's native unit from a ranging one.Noneuntil a sensor has reported, or on a device without one. The raw centimetres, where a platform reports them, stay readable throughget_sensor_reading(SensorKind::Proximity).TAKE OVER THE SYSTEM AUDIO, or give it back (9h-i-a-i-d-i; USER RULING 2026-09-03: a runtime call around playback, not a config flag).
More
On iOS this activates the shared
AVAudioSessionwith the playback category, which is what makes the lock-screen and remote controls deliver anything - and what interrupts other apps' audio, which is why it is done when playback STARTS and undone (false, notifying others so their audio resumes) when it stops. On Android it requests audio focus for media. Desktop mixers share, so there the call is a no-op that reportsGranted.The answer, and every later change - a call interrupting, a prompt ducking, focus regained or lost for good - arrives as a
SystemAudioChangeevent (ApplicationEventFilter::SystemAudioChange) and stays readable throughget_system_audio_change.What the system last did with the audio the app took over (9h-i-a-i-d-i) - the payload of a
SystemAudioChangeevent, or the last one delivered.Nonebefore any takeover.Whether the app currently holds (asked for and was not told it lost) the system audio.
Lostclears it;InterruptedandDuckeddo not - the takeover is still the app's, only paused by the system.Whether the ENGINE flips scroll deltas (9b-ii-b-i-a):
AppConfig::natural_scroll == Enabled(or theAZ_NATURAL_SCROLLoverride). The platform's own preference isget_system_natural_scroll.The PLATFORM's natural-scrolling preference, if it reports one (9b-ii-b-i-a): macOS's setting, the Windows precision touchpad's, a Wayland compositor's
axis_relative_direction.falsealso when the platform says nothing -has_system_natural_scrolltells the two apart. WhatAppConfig::natural_scroll = Systemloads.Whether the platform reported a natural-scrolling preference at all.
Set the focus of pointer / keyboard SEAT
seat_id(9b-ii-a-i-d): a second seat has its own focused node, so two people can edit two fields of one window.Next/Previouswalk from that seat's current focus. Seat 0 is the primary and behaves asset_focus.Clear the focus of seat
seat_id(9b-ii-a-i-d).The node seat
seat_idfocuses (9b-ii-a-i-d); the primary's for seat 0.Nonewhen that seat focuses nothing.Whether seat
seat_idfocusesnode_id(9b-ii-a-i-d).#28: "what WOULD the page breaks be for this content at this page size?" - a SPECULATIVE pagination query answered from the window's live caches (shaping shared read-only, nothing committed, nothing polluted). The result is bbox-level only: break positions, page count, total content height. See [
LayoutWindow::query_pagination] for the cache-fork mechanics. Intended for app-side lazy pagination: lay out a monitor-height prefix eagerly, estimate the page count, then correct asynchronously with this query.Start playback on
node. RaisesPlayunless it was already playing.Pause playback on
node. RaisesPauseunless it was already paused.Play if paused, pause if playing. Raises whichever of the two applies.
Move the playback position to
position_sseconds, clamped into the known duration. RaisesTimeUpdatewhen the position actually moves.Set the output gain, clamped to
0.0..=1.0. RaisesVolumeChangeonly when the value actually changes.Mute or unmute without disturbing the volume level. Reported as
VolumeChange, which is how the web spells a mute change too.Tell azul how long the media is, once the app knows (metadata, or a decoder header parse).
0.0means unknown, and an unknown duration means playback can never reach an end, soEndednever fires.Advance the media clock by
dt_sseconds.More
The app owns the clock: nothing in azul decodes on a schedule, so there is no honest engine-side tick to drive playback from. Call this from a
Timeror from the decoder thread's write-back. Raises a throttledTimeUpdate(one per 250 ms of media time) and exactly oneEndedon reaching a known duration.Report that the app's media pipeline failed. Stops the transport and raises
MediaError.Everything about
node's playback in one call - the primary read API, so a callback handlingPlay/TimeUpdate/VolumeChangecan ask the engine what the state IS instead of shadowing every value it set. The six media events carry no payload; this is where the payload lives.More
Nonefor a node no transport call has ever named: "this is not a media node" is a real answer, and it is not the same as a default state.Whether
nodeis currently playing.falsefor a node no transport call has ever named. The scalar shortcut for [CallbackInfo::get_media_state].node's playback position in seconds,0.0if it has none.node's media length in seconds,0.0when it is unknown.node's output gain,1.0for a node with no state yet.Whether
nodeis muted (independently of its volume level).enum Update
3 variants
DoNothing
RefreshDom
RefreshDomAllWindows
struct LayoutCallbackInfo
6 fields
ref_data: c_void
window_size: WindowSize
theme: WindowTheme
relayout_reason: RelayoutReason
callable_ptr: c_void
_abi_mut: c_void
0 constructors
22 methods
fn get_window_width:
&self
-> f32
&self
-> f32
&self
arg px: f32
-> bool
fn get_dpi_factor:
&self
-> f32
fn relayout_reason:
&self
fn get_theme:
&self
-> WindowTheme
fn get_gl_context:
&self
fn get_system_style:
&self
-> SystemStyle
&self
arg dep: SystemStyleDependency
fn get_system_style_untracked:
&self
-> SystemStyle
fn get_ctx:
&self
-> OptionRefAny
&self
arg px: f32
-> bool
&self
arg min_px: f32
arg max_px: f32
-> bool
&self
arg px: f32
-> bool
fn window_height_greater_than:
&self
arg px: f32
-> bool
&self
arg min_px: f32
arg max_px: f32
-> bool
&self
-> String
fn get_route_param:
&self
arg width_px: f32
-> bool
fn get_monitors:
&self
-> MonitorVec
&self
&self
Returns the current window width in pixels
Returns the current window height in pixels
Returns true if the window width is less than the given pixel value
More
Example
Returns the current window DPI factor
Returns what triggered the current
layout()invocation.The window's light/dark polarity, declaring
SystemStyleDependency.Theme.More
The tracked way to read what the
themefield also holds. Use this and a change that leaves the polarity alone - a new accent colour, a different light scheme - will not rebuild the DOM.The window's system style (OS palette, fonts, metrics).
More
Declares
SystemStyleDependency.Everything: handing out the whole struct makes the read opaque, so the honest answer is that any part of it may have reached the DOM, and any system-style change rebuilds it. A callback that only wants the palette or the fonts should say so withdepends_on_system_style()and read throughget_system_style_untracked().Declare that the DOM this callback returns depends on
dep.More
THE seam between "the OS appearance changed" and "this app's DOM is now wrong". A theme switch, an accent-colour change and a UI-font resize all arrive as the same kind of event, and the engine has no way to see which of them can change what
layout()builds - only the callback knows.Declare narrowly and a change outside what you declared costs a RESTYLE (the cascade re-resolves
system-*colours and@themeconditions against the new style, warm layout caches intact) instead of a fullUpdate::RefreshDom(re-invokelayout(), rebuild the StyledDom, re-cascade, re-shape every run of text).Declarations UNION over the whole callback, widgets included, and the union is conservative. Declaring NOTHING is not "depends on nothing": an undeclared callback is rebuilt on every system-style change. Reading the
themefield directly declares nothing either - useget_theme().The system style WITHOUT declaring a dependency on all of it.
More
For a callback that has already declared what it actually reads with
depends_on_system_style(). Reading through this without declaring anything means the engine rebuilds the DOM on every system-style change, which is the conservative default.Get the callable for FFI language bindings (Python, etc.)
Returns true if the window width is greater than the given pixel value
Returns true if the window width is between min and max (inclusive)
Returns true if the window height is less than the given pixel value
Returns true if the window height is greater than the given pixel value
Returns true if the window height is between min and max (inclusive)
The pattern of the route this layout callback is rendering, e.g.
"/user/:id".More
"/"when the app configured no routes: an app without routing is on the default route, so a callback that branches on the pattern always has one string to branch on.C API
A route parameter by key (
"id"for/user/:id).More
Empty string when the parameter or the route is absent.
C API
Is the window's LOGICAL viewport wider than
width_px?More
The structural-breakpoint helper: branch on this in
layout()to return an entirely different DOM per form factor (ribbon.dom_desktop()vsribbon.dom_mobile()), instead of emitting both trees and toggling visibility with@mediarules.CONTRACT: the framework re-invokes
layout()on every window resize (RelayoutReason::Resize- the regenerate path never takes the layout-equivalence shortcut when the window size changed), so the answer cannot go stale: crossing the breakpoint in either direction re-runslayout()and the callback returns the other tree. If a future optimization ever skips DOM regeneration on resize, it must register the thresholds queried here and force a rebuild when one is crossed - grep for this comment.Snapshot of the system's monitors, taken right before this layout pass. Empty when the platform has not populated monitor info (headless, web, very early startup).
The LARGEST monitor size in physical px - the safe upper bound for how much content could possibly be visible at once. Use it to bound how much content the first layout() builds (e.g. at most monitor-height text lines, or monitor-width x monitor-height characters for one unbroken line), so opening a huge file never builds an unbounded DOM. None when no monitor info is available.
Safe-area insets in logical px: system bars, notch / cutout, and the on-screen keyboard.
More
The same values
CallbackInfo::get_safe_area_insetsreturns, made reachable fromlayout(). They were only available from EVENT callbacks, which is the wrong half: an app could read the notch from a click handler but not from the function that decides where to draw.keyboardis kept separate frombottomdeliberately. The bar is fixed and the keyboard moves, so a layout that must stay above the IME adds them, and one that only wants to avoid the home indicator does not.struct LayoutCallback
Wrapper around the layout callback function pointer. For FFI languages (Python, Java, etc.), the RefAny passed to the callback contains both the user data and the callback function object.
2 fields
ctx: OptionRefAny
1 constructor
constructor create:
arg cb: LayoutCallbackType
struct TimerCallbackInfo
7 fields
callback_info: CallbackInfo
node_id: OptionDomNodeId
frame_start: Instant
call_count: usize
is_about_to_finish: bool
_abi_ref: c_void
_abi_mut: c_void
1 constructor
constructor create:
arg callback_info: CallbackInfo
arg node_id: OptionDomNodeId
arg frame_start: Instant
arg call_count: usize
arg is_about_to_finish: bool
4 methods
&self
fn get_attached_node_position:
&self
fn update_all_image_callbacks:
&mut self
Re-render ALL image callbacks across all DOMs (applied after callback returns)
More
This is the most efficient way to update animated GL textures from a timer. Triggers only texture re-rendering - no DOM rebuild or display list resubmission.
Example
Trigger re-rendering of a VirtualView (applied after callback returns)
More
This forces the VirtualView to call its layout callback with reason
DomRecreatedand submit a new display list to WebRender.struct TimerCallbackReturn
2 fields
should_update: Update
should_terminate: TerminateTimer
5 constructors
constructor create:
arg should_update: Update
arg should_terminate: TerminateTimer
constructor continue_unchanged:
constructor continue_and_refresh_dom:
constructor terminate_unchanged:
constructor terminate_and_refresh_dom:
Creates a new TimerCallbackReturn with the given update and terminate flags.
Timer continues running, no DOM update needed.
Timer continues running and DOM should be refreshed.
Timer should stop, no DOM update needed.
Timer should stop and DOM should be refreshed.
struct TimerCallback
2 fields
ctx: OptionRefAny
struct RenderImageCallbackInfo
Information passed to image rendering callbacks
7 fields
callback_node_id: DomNodeId
bounds: HidpiAdjustedBounds
gl_context: c_void
image_cache: c_void
system_fonts: c_void
callable_ptr: c_void
_abi_mut: c_void
4 methods
fn get_bounds:
&self
&self
-> DomNodeId
fn get_gl_context:
&self
fn get_ctx:
&self
-> OptionRefAny
Returns the bounds of the laid-out node
Returns the DOM node ID that the callback is attached to
Returns the OpenGL context if available
Returns the context RefAny for FFI callbacks
struct WriteBackCallback
2 fields
ctx: OptionRefAny
struct ThreadCallback
2 fields
ctx: OptionRefAny
struct VirtualViewCallbackInfo
13 fields
reason: VirtualViewCallbackReason
system_fonts: c_void
image_cache: c_void
window_theme: WindowTheme
The window's CURRENT frame: normal, minimized, maximized, fullscreen.
More
Here for the same reason window_theme is: a view whose content depends on a window-level fact should READ that fact rather than be handed a copy at build time and then kept in sync. The window control that has to draw maximize-or-restore is the case - a seeded copy is wrong the moment the window manager maximizes the window itself (super+up, edge snap, a tiling rule), which never reaches the button's own callback.
window_frame: WindowFrame
bounds: HidpiAdjustedBounds
materialized: LogicalRect
virtual_rect: LogicalRect
scroll_offset: LogicalPosition
callable_ptr: c_void
measure_dom_fn: c_void
measure_dom_ctx: c_void
_abi_mut: c_void
0 constructors
4 methods
fn get_ctx:
&self
-> OptionRefAny
fn get_bounds:
&self
fn measure_dom:
&self
arg dom: Dom
arg available: LogicalSize
-> LogicalSize
&self
arg dom: Dom
arg bound: LogicalSize
-> LogicalSize
Get the callable for FFI language bindings (Python, etc.)
Measure a DOM headlessly: style + lay it out against
availableconstraints using the host window's fonts and system style, without touching the live layout. Returns the union of all node bounds.More
Use a very tall
available.height(e.g.1_000_000.0) to obtain a DOM's natural height at a fixed width - the building block for virtual-scroll sizing: measure one (or a few) item template(s), thenvirtual_scroll_size.height = item_height * item_countand render only the visible window of items. Each call is a full cold layout pass, so cache measured sizes per item template.Returns
LogicalSize::zero()when no measure hook was injected.Measure a DOM headlessly at the size its CONTENT asks for: as wide as its max-content width (no wider than
bound), and as tall as that makes it. The natural-size counterpart ofmeasure_dom, whose block root stretches to whatever width it is given - so a label measured that way reports the box, not the text.More
This is what a content-sized view returns as its
materializedrect: a text label, a badge, a popup panel. Pass a generousbound(a few thousand pixels) for "unconstrained"; aVirtualViewwithwidth: autois then laid out at the size it reports. Two cold layout passes per call.Returns
LogicalSize::zero()when no measure hook was injected.struct VirtualViewReturn
has destructorReturn value for a VirtualView rendering callback.
More
THREE RECTS, kept in sync by the engine: 1. the container (the VirtualView's on-screen box) - the engine owns this; 2.
materialized- what you just rendered, and WHERE it sits in the document; 3.virtual_rect- how big the document is (your best current estimate).Content is placed from
materializedand the live scroll offset only, so refiningvirtual_rectmoves the scrollbar and nothing else. The callback is re-invoked when the visible window comes near an edge ofmaterializedand the document extends past it.3 fields
The DOM with actual rendered content, or None to keep current DOM. -
OptionDom::Some(dom)- Replace current content with this new DOM -OptionDom::None- Keep using the previous DOM, only update scroll bounds ReturningNoneis an optimization when the callback determines that the current content is sufficient (e.g., already rendered ahead of scroll position).dom: OptionDom
WHAT THIS CALLBACK MATERIALIZED, in VIRTUAL space.
origin= where this window of content begins in the document;size= how much of the document it covers. One rect, not a loose offset + size: they are a single fact about a single window, and storing them apart is how the origin came to be dropped (content could not be placed, so a VirtualView could never actually scroll). The engine places content atcontainer.origin + (materialized.origin - current_scroll_offset). Example: a table showing rows 10-30 at 30px each reports origin.y = 300, size.height = 600.materialized: LogicalRect
THE WHOLE DOCUMENT, in VIRTUAL space - what the scrollbar represents.
originis normally zero;sizeis your current best estimate and MAY change as work completes (e.g. a background pagination pass refining a page count). Refining it is cheap and safe: ONLY the scrollbar reads this, so the thumb resizes and no content moves. Example: a 1000-row table reports size.height = 30000 even thoughmaterializedcovers 600px of it.virtual_rect: LogicalRect
2 constructors
constructor with_dom:
arg dom: Dom
arg materialized: LogicalRect
arg virtual_rect: LogicalRect
constructor keep_current:
arg materialized: LogicalRect
arg virtual_rect: LogicalRect
Creates a new VirtualViewReturn with updated DOM content.
More
Use this when the callback has rendered new content to display.
# Arguments -
dom- The new DOM to render -scroll_size- Size of the actual rendered content -scroll_offset- Position of rendered content in virtual space -virtual_scroll_size- Size for scrollbar representation -virtual_scroll_offset- UsuallyLogicalPosition::zero()Creates a return value that keeps the current DOM unchanged.
More
Use this when the callback determines that the existing content is sufficient (e.g., already rendered ahead of scroll position). This is an optimization to avoid rebuilding the DOM unnecessarily.
# Arguments -
scroll_size- Size of the current rendered content -scroll_offset- Position of current content in virtual space -virtual_scroll_size- Size for scrollbar representation -virtual_scroll_offset- UsuallyLogicalPosition::zero()struct ScrollState
1 field
scroll_position: LogicalPosition
struct RefCount
2 fields
ptr: c_void
run_destructor: bool
6 methods
fn increase_ref:
&self
fn decrease_ref:
&self
fn increase_refmut:
&self
fn decrease_refmut:
&self
Returns true if this RefCount can be shared (no mutable borrows active)
Returns true if this RefCount can be mutably shared (no borrows active)
Increases the shared reference count
Decreases the shared reference count
Increases the mutable reference count
Decreases the mutable reference count
enum EdgeType
4 variants
Top
Bottom
Left
Right
struct UpdateSettings
has destructorUpdate configuration (part of AppConfig): manifest URL, requested mode, the running version, and the state-directory app name.
8 fields
mode: UpdateMode
manifest_url: OptionString
current_version: String
app_name: String
build_date: String
build_tag: String
The release channel this binary follows: stable (the default when empty), beta, nightly, or whatever the publisher names. Compiled in, so a manifest cannot move a nightly build onto the stable track.
channel: String
Base64 minisign ROOT public key compiled in by the app. Non-empty arms the update signature chain (root-signed signing-key statement + artifact signature required); empty = digest verification only.
root_public_key: String
enum UpdateMode
3 variants
SelfUpdate
NotifyOnly
Disabled
fnptr CallbackType
Main callback type for UI event handling
signature
fnptr VirtualViewCallbackType
Type alias for extern "C" fn (&mut RefAny , &mut VirtualViewCallbackInfo) -> VirtualViewReturn
signature
fnptr NumberInputOnFocusLostCallbackType
signature
fnptr TextInputOnVirtualKeyDownCallbackType
signature
fnptr ButtonOnClickCallbackType
signature
fnptr CheckBoxOnToggleCallbackType
signature
fnptr DropDownOnChoiceChangeCallbackType
signature
fnptr NumberInputOnValueChangeCallbackType
signature
fnptr ListViewOnColumnClickCallbackType
signature
fnptr ListViewOnRowClickCallbackType
signature
fnptr ColorInputOnValueChangeCallbackType
signature
fnptr TextInputOnTextInputCallbackType
signature
fnptr FontRefDestructorCallbackType
signature
arg c_void
fnptr TextInputOnFocusLostCallbackType
signature
fnptr TabOnClickCallbackType
signature
fnptr ListViewOnLazyLoadScrollCallbackType
signature
fnptr FileInputOnPathChangeCallbackType
signature
fnptr InstantPtrCloneCallbackType
signature
arg *const InstantPtr
-> InstantPtr
fnptr InstantPtrDestructorCallbackType
signature
arg *mut InstantPtr
fnptr LayoutCallbackType
signature
fnptr ResumeCallbackType
The one callback shape every resumable API resumes into.
datais the RefAny you passed to the request function, returned untouched;resultis the per-operation result struct, type-erased into a RefAny - downcast it with<ResultStruct>::downcast(result)(FileOpenResult::downcast,HttpGetResult::downcast, ...). Never runs re-entrantly inside the requesting activation: on desktop it may run within the same frame, on web it always runs on a later task.signature
struct ResumeCallback
Function pointer + host context a request function stores until its result exists. See
ResumeCallbackType.2 fields
ctx: OptionRefAny
fnptr TimerCallbackType
signature
fnptr WriteBackCallbackType
signature
fnptr GetSystemTimeCallbackType
signature
-> Instant
fnptr ThreadCallbackType
signature
fnptr RefAnyDestructorType
Destructor callback for RefAny - called when the last reference is dropped
signature
arg c_void
fnptr RenderImageCallbackType
signature
struct PenState
13 fields
position: LogicalPosition
pressure: f32
tilt: PenTilt
in_contact: bool
is_eraser: bool
barrel_button_pressed: bool
device_id: u64
tangential_pressure: f32
barrel_roll_rad: f32
tool_id: u32
report_rate_hz: f32
hover_distance: f32
tool_kind: TabletToolKind
struct UndoableOperation
has destructor3 fields
struct GraphemeClusterId
2 fields
source_run: u32
start_byte_in_run: u32
struct PenTilt
2 fields
x_tilt: f32
y_tilt: f32
struct TextChangeset
has destructor4 fields
fnptr IconResolverCallbackType
signature
fnptr RibbonOnTabClickCallbackType
signature
fnptr TreeViewOnNodeClickCallbackType
signature
fnptr OnVideoFrameCallbackType
signature
fnptr MapViewportChangedCallbackType
signature
fnptr MapPinTapCallbackType
signature
fnptr OnAudioFrameCallbackType
signature
fnptr SwitchOnToggleCallbackType
signature
fnptr SliderOnValueChangeCallbackType
signature
fnptr SegmentedOnChangeCallbackType
signature
fnptr RadioGroupOnChangeCallbackType
signature
fnptr TextAreaOnFocusLostCallbackType
signature
fnptr TextAreaOnTextInputCallbackType
signature
fnptr AlertOnDismissCallbackType
signature
fnptr AccordionOnToggleCallbackType
signature
fnptr ChipOnRemoveCallbackType
signature
fnptr PopoverOnToggleCallbackType
signature
fnptr ComboBoxOnSelectCallbackType
signature
fnptr ModalOnCloseCallbackType
signature
fnptr ToastOnDismissCallbackType
signature
fnptr PaginationOnChangeCallbackType
signature
fnptr StepperOnStepChangeCallbackType
signature
fnptr SplitPaneOnResizeCallbackType
signature
fnptr DatePickerOnChangeCallbackType
signature
fnptr TimePickerOnChangeCallbackType
signature
fnptr ChipOnClickCallbackType
signature
fnptr TextAreaOnVirtualKeyDownCallbackType
signature
fnptr CardOnClickCallbackType
signature
enum UpdateImageType
2 variants
Background
Content
fnptr RibbonGalleryOnSelectCallbackType
signature
fnptr CustomE2eOpCallbackType
Handles an E2E op the engine does not implement. Args are the op name and its arguments as a JSON string, verbatim.
signature
fnptr SelectionTweenCallbackType
Returns the selection rectangles to render at progress
info.t. MUST return exactlyinfo.current.len()rectangles - a mismatched length makes the framework fall back toinfo.currentunanimated.signature
struct CaretTweenInfo
Inputs for one caret-tween evaluation: the previously RENDERED caret rect, the rect the current layout wants, and the linear time progress 0.0..=1.0. Easing / curves are the tween function's job.
3 fields
fnptr CaretTweenCallbackType
Returns the caret rectangle to render at progress
info.tsignature
fnptr UpdateCheckCallbackType
signature
struct UpdateOptions
Options for one update check.
download_automaticallySTAGES the artifact in the background; installing still requires consent.1 field
download_automatically: bool
struct UpdateCheckInfo
has destructorEverything one completed update check knows, delivered to the app's UpdateCheckCallback on the main thread.
4 fields
union enum UpdateCheckResult
has destructorWhat an update check concluded.
3 variants
fnptr OnConsumerFrameCallbackType
signature
struct DocumentChangeset
has destructor5 fields
1 constructor
constructor create:
arg target: DomNodeId
arg operation: DocumentOperation
arg resume: EditResumePoint
arg timestamp: Instant
Create a changeset with a fresh monotonic id.
2 methods
&self
-> bool
fn apply_to_dom:
Whether this operation restructures the node tree (vs inline-only wrap).
Apply this changeset to an app-model [
Dom](azul_core::dom::Dom) - the Path-2 helper [crate::document_edit::apply_document_operation] as a method, so API consumers reach it without free-function plumbing.More
host_pathis the root-to-host child-index path (empty = the model root hosts the blocks). On success the returned [AppliedEdit](crate::document_edit::AppliedEdit) carries the resume point and the INVERSE operation to hand back toCallbackInfo::mark_document_edit_applied_with_inverse.# Errors The tree is left unchanged on error (host/target not found).
fnptr StatusBarOnViewSelectCallbackType
signature
struct InputSample
8 fields
timestamp: Instant
event_id: u64
position: LogicalPosition
screen_position: LogicalPosition
tilt: PenTilt
touch_radius: LogicalSize
pressure: f32
button_state: u8
struct ValidityState
1 field
flags: u32
2 methods
fn has:
self
arg reason: ValidityReason
-> bool
fn is_valid:
self
-> bool
Did this control fail
reason?Did it pass everything?
enum ValidityReason
6 variants
ValueMissing
TooShort
TooLong
RangeUnderflow
RangeOverflow
PatternMismatch
fnptr DbMergeCallbackType
Computes the merged value for a
DbConflict. A pure function over the two versions, invoked synchronously while a sync is applied - it must not touch the UI, which is why it takes noCallbackInfo. ReturnDbValue::Nullto delete the key.signature
fnptr MapMountCallbackType
User hook fired when the map is mounted: receives the map's current
MapSetupand returns the one its tile fetches should use.signature
fnptr VideoMountCallbackType
User hook fired when the video widget is mounted: receives the widget's current
VideoSetupand returns the one its decode worker should use.signature
mod css
672 typesCssparsing modulestruct Css
has destructorCss stylesheet - contains a parsed CSS stylesheet as a flat list of
CssRuleBlocks. Layer separation (UA / system / author / inline / runtime) is encoded per-rule viaCssRuleBlock::priority.2 fields
All rule blocks, in source order. Sort by
(priority, specificity)viasort_by_specificityto put them in cascade order.rules: CssRuleBlockVec
All top-level
@keyframesblocks of the stylesheet, resolvable by name fromanimation/-azul-animation-in/-azul-animation-out.keyframes: KeyframesVec
3 constructors
constructor from_string:
constructor empty:
-> Css
constructor parse_inline:
Creates a new, empty CSS with no rules
Parse inline-style CSS (bare properties, pseudo blocks, @-rule blocks) and return a
Csswhose rules carryrule_priority::INLINE.More
Wraps the input in
* { ... }so the main CSS parser can handle bare properties at the top level. Pseudo and at-rule blocks like:hover { color: red; }or@os(linux) { font-size: 14px; }work directly via CSS nesting.2 methods
&mut self
fn is_empty:
&self
-> bool
union enum CssProperty
Represents one parsed CSS key-value pair, such as
"width: 20px"=>CssProperty::Width(LayoutWidth::px(20.0))191 variants
CaretColor(CaretColorValue)
CaretAnimationDuration(CaretAnimationDurationValue)
Animation(StyleAnimationVecValue)
AnimationIn(StyleAnimationVecValue)
AnimationOut(StyleAnimationVecValue)
CaretWidth(CaretWidthValue)
SelectionBackgroundColor(SelectionBackgroundColorValue)
SelectionColor(SelectionColorValue)
SelectionRadius(SelectionRadiusValue)
TextColor(StyleTextColorValue)
FontSize(StyleFontSizeValue)
FontFamily(StyleFontFamilyVecValue)
FontWeight(StyleFontWeightValue)
FontStyle(StyleFontStyleValue)
TextAlign(StyleTextAlignValue)
TextJustify(LayoutTextJustifyValue)
VerticalAlign(StyleVerticalAlignValue)
LetterSpacing(StyleLetterSpacingValue)
TextIndent(StyleTextIndentValue)
InitialLetter(StyleInitialLetterValue)
LineClamp(StyleLineClampValue)
HangingPunctuation(StyleHangingPunctuationValue)
TextCombineUpright(StyleTextCombineUprightValue)
UnicodeBidi(StyleUnicodeBidiValue)
TextBoxTrim(StyleTextBoxTrimValue)
TextBoxEdge(StyleTextBoxEdgeValue)
DominantBaseline(StyleDominantBaselineValue)
AlignmentBaseline(StyleAlignmentBaselineValue)
BaselineSource(StyleBaselineSourceValue)
LineFitEdge(StyleLineFitEdgeValue)
InitialLetterAlign(StyleInitialLetterAlignValue)
InitialLetterWrap(StyleInitialLetterWrapValue)
ScrollbarGutter(StyleScrollbarGutterValue)
OverflowClipMargin(StyleOverflowClipMarginValue)
Clip(StyleClipRectValue)
ExclusionMargin(StyleExclusionMarginValue)
HyphenationLanguage(StyleHyphenationLanguageValue)
LineHeight(StyleLineHeightValue)
WordSpacing(StyleWordSpacingValue)
TabSize(StyleTabSizeValue)
WhiteSpace(StyleWhiteSpaceValue)
Hyphens(StyleHyphensValue)
WordBreak(StyleWordBreakValue)
OverflowWrap(StyleOverflowWrapValue)
LineBreak(StyleLineBreakValue)
TextOverflow(StyleTextOverflowValue)
ObjectFit(StyleObjectFitValue)
ObjectPosition(StyleObjectPositionValue)
AspectRatio(StyleAspectRatioValue)
TextOrientation(StyleTextOrientationValue)
TextAlignLast(StyleTextAlignLastValue)
TextTransform(StyleTextTransformValue)
Direction(StyleDirectionValue)
UserSelect(StyleUserSelectValue)
TextDecoration(StyleTextDecorationValue)
Cursor(StyleCursorValue)
Display(LayoutDisplayValue)
Float(LayoutFloatValue)
BoxSizing(LayoutBoxSizingValue)
Width(LayoutWidthValue)
Height(LayoutHeightValue)
MinWidth(LayoutMinWidthValue)
MinHeight(LayoutMinHeightValue)
MaxWidth(LayoutMaxWidthValue)
MaxHeight(LayoutMaxHeightValue)
Position(LayoutPositionValue)
Top(LayoutTopValue)
Right(LayoutRightValue)
Left(LayoutLeftValue)
Bottom(LayoutInsetBottomValue)
ZIndex(LayoutZIndexValue)
FlexWrap(LayoutFlexWrapValue)
FlexDirection(LayoutFlexDirectionValue)
FlexGrow(LayoutFlexGrowValue)
FlexShrink(LayoutFlexShrinkValue)
FlexBasis(LayoutFlexBasisValue)
JustifyContent(LayoutJustifyContentValue)
AlignItems(LayoutAlignItemsValue)
AlignContent(LayoutAlignContentValue)
ColumnGap(LayoutColumnGapValue)
RowGap(LayoutRowGapValue)
GridTemplateColumns(LayoutGridTemplateColumnsValue)
GridTemplateRows(LayoutGridTemplateRowsValue)
GridAutoColumns(LayoutGridAutoColumnsValue)
GridAutoRows(LayoutGridAutoRowsValue)
GridColumn(LayoutGridColumnValue)
GridRow(LayoutGridRowValue)
GridTemplateAreas(LayoutGridTemplateAreasValue)
WritingMode(LayoutWritingModeValue)
Clear(LayoutClearValue)
BackgroundContent(StyleBackgroundContentVecValue)
BackgroundPosition(StyleBackgroundPositionVecValue)
BackgroundSize(StyleBackgroundSizeVecValue)
BackgroundRepeat(StyleBackgroundRepeatVecValue)
OverflowX(LayoutOverflowValue)
OverflowY(LayoutOverflowValue)
OverflowBlock(LayoutOverflowValue)
OverflowInline(LayoutOverflowValue)
GridAutoFlow(LayoutGridAutoFlowValue)
JustifySelf(LayoutJustifySelfValue)
JustifyItems(LayoutJustifyItemsValue)
Gap(LayoutGapValue)
GridGap(LayoutGapValue)
AlignSelf(LayoutAlignSelfValue)
Font(StyleFontValue)
PaddingTop(LayoutPaddingTopValue)
PaddingLeft(LayoutPaddingLeftValue)
PaddingRight(LayoutPaddingRightValue)
PaddingBottom(LayoutPaddingBottomValue)
PaddingInlineStart(LayoutPaddingInlineStartValue)
PaddingInlineEnd(LayoutPaddingInlineEndValue)
MarginTop(LayoutMarginTopValue)
MarginLeft(LayoutMarginLeftValue)
MarginRight(LayoutMarginRightValue)
MarginBottom(LayoutMarginBottomValue)
BorderTopLeftRadius(StyleBorderTopLeftRadiusValue)
BorderTopRightRadius(StyleBorderTopRightRadiusValue)
BorderBottomLeftRadius(StyleBorderBottomLeftRadiusValue)
BorderBottomRightRadius(StyleBorderBottomRightRadiusValue)
BorderTopColor(StyleBorderTopColorValue)
BorderRightColor(StyleBorderRightColorValue)
BorderLeftColor(StyleBorderLeftColorValue)
BorderBottomColor(StyleBorderBottomColorValue)
BorderTopStyle(StyleBorderTopStyleValue)
BorderRightStyle(StyleBorderRightStyleValue)
BorderLeftStyle(StyleBorderLeftStyleValue)
BorderBottomStyle(StyleBorderBottomStyleValue)
BorderTopWidth(LayoutBorderTopWidthValue)
BorderRightWidth(LayoutBorderRightWidthValue)
BorderLeftWidth(LayoutBorderLeftWidthValue)
BorderBottomWidth(LayoutBorderBottomWidthValue)
BoxShadowLeft(StyleBoxShadowValue)
BoxShadowRight(StyleBoxShadowValue)
BoxShadowTop(StyleBoxShadowValue)
BoxShadowBottom(StyleBoxShadowValue)
ScrollbarTrack(StyleBackgroundContentValue)
ScrollbarThumb(StyleBackgroundContentValue)
ScrollbarButton(StyleBackgroundContentValue)
ScrollbarCorner(StyleBackgroundContentValue)
ScrollbarResizer(StyleBackgroundContentValue)
ScrollbarWidth(LayoutScrollbarWidthValue)
OverscrollBehaviorX(OverscrollBehaviorValue)
OverscrollBehaviorY(OverscrollBehaviorValue)
ScrollbarColor(StyleScrollbarColorValue)
ScrollbarVisibility(ScrollbarVisibilityModeValue)
ScrollbarFadeDelay(ScrollbarFadeDelayValue)
ScrollbarFadeDuration(ScrollbarFadeDurationValue)
Opacity(StyleOpacityValue)
Visibility(StyleVisibilityValue)
Transform(StyleTransformVecValue)
TransformOrigin(StyleTransformOriginValue)
PerspectiveOrigin(StylePerspectiveOriginValue)
BackfaceVisibility(StyleBackfaceVisibilityValue)
AppRegion(StyleAppRegionValue)
MixBlendMode(StyleMixBlendModeValue)
Filter(StyleFilterVecValue)
BackdropFilter(StyleFilterVecValue)
TextShadow(StyleBoxShadowValue)
BreakBefore(PageBreakValue)
BreakAfter(PageBreakValue)
BreakInside(BreakInsideValue)
Orphans(OrphansValue)
Widows(WidowsValue)
BoxDecorationBreak(BoxDecorationBreakValue)
ColumnCount(ColumnCountValue)
ColumnWidth(ColumnWidthValue)
ColumnSpan(ColumnSpanValue)
ColumnFill(ColumnFillValue)
ColumnRuleWidth(ColumnRuleWidthValue)
ColumnRuleStyle(ColumnRuleStyleValue)
ColumnRuleColor(ColumnRuleColorValue)
FlowInto(FlowIntoValue)
FlowFrom(FlowFromValue)
ShapeOutside(ShapeOutsideValue)
ShapeInside(ShapeInsideValue)
ClipPath(ClipPathValue)
ShapeMargin(ShapeMarginValue)
ShapeImageThreshold(ShapeImageThresholdValue)
TableLayout(LayoutTableLayoutValue)
BorderCollapse(StyleBorderCollapseValue)
BorderSpacing(LayoutBorderSpacingValue)
CaptionSide(StyleCaptionSideValue)
EmptyCells(StyleEmptyCellsValue)
Content(ContentValue)
CounterReset(CounterResetValue)
CounterIncrement(CounterIncrementValue)
ListStyleType(StyleListStyleTypeValue)
ListStylePosition(StyleListStylePositionValue)
StringSet(StringSetValue)
229 constructors
constructor width:
arg input: LayoutWidth
-> CssProperty
constructor height:
arg input: LayoutHeight
-> CssProperty
constructor font_size:
arg input: StyleFontSize
-> CssProperty
constructor text_color:
arg input: StyleTextColor
-> CssProperty
constructor background_content:
arg input: StyleBackgroundContentVec
-> CssProperty
constructor display:
arg input: LayoutDisplay
-> CssProperty
constructor flex_direction:
arg input: LayoutFlexDirection
-> CssProperty
constructor flex_grow:
arg input: LayoutFlexGrow
-> CssProperty
constructor justify_content:
arg input: LayoutJustifyContent
-> CssProperty
constructor align_items:
arg input: LayoutAlignItems
-> CssProperty
constructor none:
arg prop_type: CssPropertyType
-> CssProperty
constructor auto:
arg prop_type: CssPropertyType
-> CssProperty
constructor initial:
arg prop_type: CssPropertyType
-> CssProperty
constructor inherit:
arg prop_type: CssPropertyType
-> CssProperty
constructor font_family:
arg input: StyleFontFamilyVec
-> CssProperty
constructor font_weight:
arg input: StyleFontWeight
-> CssProperty
constructor font_style:
arg input: StyleFontStyle
-> CssProperty
constructor text_align:
arg input: StyleTextAlign
-> CssProperty
constructor text_justify:
arg input: LayoutTextJustify
-> CssProperty
constructor vertical_align:
arg input: StyleVerticalAlign
-> CssProperty
constructor letter_spacing:
arg input: StyleLetterSpacing
-> CssProperty
constructor text_indent:
arg input: StyleTextIndent
-> CssProperty
constructor line_height:
arg input: StyleLineHeight
-> CssProperty
constructor word_spacing:
arg input: StyleWordSpacing
-> CssProperty
constructor tab_size:
arg input: StyleTabSize
-> CssProperty
constructor cursor:
arg input: StyleCursor
-> CssProperty
constructor user_select:
arg input: StyleUserSelect
-> CssProperty
constructor text_decoration:
arg input: StyleTextDecoration
-> CssProperty
constructor box_sizing:
arg input: LayoutBoxSizing
-> CssProperty
constructor min_width:
arg input: LayoutMinWidth
-> CssProperty
constructor caret_color:
arg input: CaretColor
-> CssProperty
constructor caret_animation_duration:
arg input: CaretAnimationDuration
-> CssProperty
constructor selection_background_color:
arg input: SelectionBackgroundColor
-> CssProperty
constructor selection_color:
arg input: SelectionColor
-> CssProperty
constructor min_height:
arg input: LayoutMinHeight
-> CssProperty
constructor max_width:
arg input: LayoutMaxWidth
-> CssProperty
constructor max_height:
arg input: LayoutMaxHeight
-> CssProperty
constructor position:
arg input: LayoutPosition
-> CssProperty
constructor top:
arg input: LayoutTop
-> CssProperty
constructor right:
arg input: LayoutRight
-> CssProperty
constructor left:
arg input: LayoutLeft
-> CssProperty
constructor bottom:
arg input: LayoutInsetBottom
-> CssProperty
constructor z_index:
arg input: LayoutZIndex
-> CssProperty
constructor flex_wrap:
arg input: LayoutFlexWrap
-> CssProperty
constructor flex_shrink:
arg input: LayoutFlexShrink
-> CssProperty
constructor grid_auto_flow:
arg input: LayoutGridAutoFlow
-> CssProperty
constructor justify_self:
arg input: LayoutJustifySelf
-> CssProperty
constructor justify_items:
arg input: LayoutJustifyItems
-> CssProperty
constructor gap:
arg input: LayoutGap
-> CssProperty
constructor grid_gap:
arg input: LayoutGap
-> CssProperty
constructor align_self:
arg input: LayoutAlignSelf
-> CssProperty
constructor font:
arg input: StyleFontFamilyVec
-> CssProperty
constructor align_content:
arg input: LayoutAlignContent
-> CssProperty
constructor background_position:
arg input: StyleBackgroundPositionVec
-> CssProperty
constructor background_size:
arg input: StyleBackgroundSizeVec
-> CssProperty
constructor background_repeat:
arg input: StyleBackgroundRepeatVec
-> CssProperty
constructor overflow_x:
arg input: LayoutOverflow
-> CssProperty
constructor overflow_y:
arg input: LayoutOverflow
-> CssProperty
constructor padding_top:
arg input: LayoutPaddingTop
-> CssProperty
constructor padding_left:
arg input: LayoutPaddingLeft
-> CssProperty
constructor padding_right:
arg input: LayoutPaddingRight
-> CssProperty
constructor padding_bottom:
arg input: LayoutPaddingBottom
-> CssProperty
constructor margin_top:
arg input: LayoutMarginTop
-> CssProperty
constructor margin_left:
arg input: LayoutMarginLeft
-> CssProperty
constructor margin_right:
arg input: LayoutMarginRight
-> CssProperty
constructor margin_bottom:
arg input: LayoutMarginBottom
-> CssProperty
constructor border_top_left_radius:
arg input: StyleBorderTopLeftRadius
-> CssProperty
constructor border_top_right_radius:
arg input: StyleBorderTopRightRadius
-> CssProperty
constructor border_bottom_left_radius:
arg input: StyleBorderBottomLeftRadius
-> CssProperty
constructor border_bottom_right_radius:
arg input: StyleBorderBottomRightRadius
-> CssProperty
constructor border_top_color:
arg input: StyleBorderTopColor
-> CssProperty
constructor border_right_color:
arg input: StyleBorderRightColor
-> CssProperty
constructor border_left_color:
arg input: StyleBorderLeftColor
-> CssProperty
constructor border_bottom_color:
arg input: StyleBorderBottomColor
-> CssProperty
constructor border_top_style:
arg input: StyleBorderTopStyle
-> CssProperty
constructor border_right_style:
arg input: StyleBorderRightStyle
-> CssProperty
constructor border_left_style:
arg input: StyleBorderLeftStyle
-> CssProperty
constructor border_bottom_style:
arg input: StyleBorderBottomStyle
-> CssProperty
constructor border_top_width:
arg input: LayoutBorderTopWidth
-> CssProperty
constructor border_right_width:
arg input: LayoutBorderRightWidth
-> CssProperty
constructor border_left_width:
arg input: LayoutBorderLeftWidth
-> CssProperty
constructor border_bottom_width:
arg input: LayoutBorderBottomWidth
-> CssProperty
constructor box_shadow_left:
arg input: StyleBoxShadow
-> CssProperty
constructor box_shadow_right:
arg input: StyleBoxShadow
-> CssProperty
constructor box_shadow_top:
arg input: StyleBoxShadow
-> CssProperty
constructor box_shadow_bottom:
arg input: StyleBoxShadow
-> CssProperty
constructor opacity:
arg input: StyleOpacity
-> CssProperty
constructor visibility:
arg input: StyleVisibility
-> CssProperty
constructor transform:
arg input: StyleTransformVec
-> CssProperty
constructor transform_origin:
arg input: StyleTransformOrigin
-> CssProperty
constructor perspective_origin:
arg input: StylePerspectiveOrigin
-> CssProperty
constructor backface_visibility:
arg input: StyleBackfaceVisibility
-> CssProperty
constructor break_before:
arg input: PageBreak
-> CssProperty
constructor break_after:
arg input: PageBreak
-> CssProperty
constructor break_inside:
arg input: BreakInside
-> CssProperty
constructor orphans:
arg input: Orphans
-> CssProperty
constructor widows:
arg input: Widows
-> CssProperty
constructor box_decoration_break:
arg input: BoxDecorationBreak
-> CssProperty
constructor column_count:
arg input: ColumnCount
-> CssProperty
constructor column_width:
arg input: ColumnWidth
-> CssProperty
constructor column_span:
arg input: ColumnSpan
-> CssProperty
constructor column_fill:
arg input: ColumnFill
-> CssProperty
constructor column_rule_width:
arg input: ColumnRuleWidth
-> CssProperty
constructor column_rule_style:
arg input: ColumnRuleStyle
-> CssProperty
constructor column_rule_color:
arg input: ColumnRuleColor
-> CssProperty
constructor flow_into:
arg input: FlowInto
-> CssProperty
constructor flow_from:
arg input: FlowFrom
-> CssProperty
constructor shape_outside:
arg input: ShapeOutside
-> CssProperty
constructor shape_inside:
arg input: ShapeInside
-> CssProperty
constructor clip_path:
arg input: ClipPath
-> CssProperty
constructor shape_margin:
arg input: ShapeMargin
-> CssProperty
constructor shape_image_threshold:
arg input: ShapeImageThreshold
-> CssProperty
constructor content:
arg input: Content
-> CssProperty
constructor counter_reset:
arg input: CounterReset
-> CssProperty
constructor counter_increment:
arg input: CounterIncrement
-> CssProperty
constructor list_style_type:
arg input: StyleListStyleType
-> CssProperty
constructor list_style_position:
arg input: StyleListStylePosition
-> CssProperty
constructor string_set:
arg input: StringSet
-> CssProperty
constructor table_layout:
arg input: LayoutTableLayout
-> CssProperty
constructor border_collapse:
arg input: StyleBorderCollapse
-> CssProperty
constructor border_spacing:
arg input: LayoutBorderSpacing
-> CssProperty
constructor caption_side:
arg input: StyleCaptionSide
-> CssProperty
constructor empty_cells:
arg input: StyleEmptyCells
-> CssProperty
constructor const_none:
arg prop_type: CssPropertyType
-> CssProperty
constructor const_auto:
arg prop_type: CssPropertyType
-> CssProperty
constructor const_initial:
arg prop_type: CssPropertyType
-> CssProperty
constructor const_inherit:
arg prop_type: CssPropertyType
-> CssProperty
constructor const_text_color:
arg input: StyleTextColor
-> CssProperty
constructor const_font_size:
arg input: StyleFontSize
-> CssProperty
constructor const_font_family:
arg input: StyleFontFamilyVec
-> CssProperty
constructor const_text_align:
arg input: StyleTextAlign
-> CssProperty
constructor const_vertical_align:
arg input: StyleVerticalAlign
-> CssProperty
constructor const_letter_spacing:
arg input: StyleLetterSpacing
-> CssProperty
constructor const_text_indent:
arg input: StyleTextIndent
-> CssProperty
constructor const_line_height:
arg input: StyleLineHeight
-> CssProperty
constructor const_word_spacing:
arg input: StyleWordSpacing
-> CssProperty
constructor const_tab_size:
arg input: StyleTabSize
-> CssProperty
constructor const_cursor:
arg input: StyleCursor
-> CssProperty
constructor const_display:
arg input: LayoutDisplay
-> CssProperty
constructor const_float:
arg input: LayoutFloat
-> CssProperty
constructor const_box_sizing:
arg input: LayoutBoxSizing
-> CssProperty
constructor const_width:
arg input: LayoutWidth
-> CssProperty
constructor const_height:
arg input: LayoutHeight
-> CssProperty
constructor const_min_width:
arg input: LayoutMinWidth
-> CssProperty
constructor const_min_height:
arg input: LayoutMinHeight
-> CssProperty
constructor const_max_width:
arg input: LayoutMaxWidth
-> CssProperty
constructor const_max_height:
arg input: LayoutMaxHeight
-> CssProperty
constructor const_position:
arg input: LayoutPosition
-> CssProperty
constructor const_top:
arg input: LayoutTop
-> CssProperty
constructor const_right:
arg input: LayoutRight
-> CssProperty
constructor const_left:
arg input: LayoutLeft
-> CssProperty
constructor const_bottom:
arg input: LayoutInsetBottom
-> CssProperty
constructor const_flex_wrap:
arg input: LayoutFlexWrap
-> CssProperty
constructor const_flex_direction:
arg input: LayoutFlexDirection
-> CssProperty
constructor const_flex_grow:
arg input: LayoutFlexGrow
-> CssProperty
constructor const_flex_shrink:
arg input: LayoutFlexShrink
-> CssProperty
constructor const_justify_content:
arg input: LayoutJustifyContent
-> CssProperty
constructor const_align_items:
arg input: LayoutAlignItems
-> CssProperty
constructor const_align_content:
arg input: LayoutAlignContent
-> CssProperty
constructor const_background_content:
arg input: StyleBackgroundContentVec
-> CssProperty
constructor const_background_position:
arg input: StyleBackgroundPositionVec
-> CssProperty
constructor const_background_size:
arg input: StyleBackgroundSizeVec
-> CssProperty
constructor const_background_repeat:
arg input: StyleBackgroundRepeatVec
-> CssProperty
constructor const_overflow_x:
arg input: LayoutOverflow
-> CssProperty
constructor const_overflow_y:
arg input: LayoutOverflow
-> CssProperty
constructor const_padding_top:
arg input: LayoutPaddingTop
-> CssProperty
constructor const_padding_left:
arg input: LayoutPaddingLeft
-> CssProperty
constructor const_padding_right:
arg input: LayoutPaddingRight
-> CssProperty
constructor const_padding_bottom:
arg input: LayoutPaddingBottom
-> CssProperty
constructor const_margin_top:
arg input: LayoutMarginTop
-> CssProperty
constructor const_margin_left:
arg input: LayoutMarginLeft
-> CssProperty
constructor const_margin_right:
arg input: LayoutMarginRight
-> CssProperty
constructor const_margin_bottom:
arg input: LayoutMarginBottom
-> CssProperty
constructor const_border_top_left_radius:
arg input: StyleBorderTopLeftRadius
-> CssProperty
constructor const_border_top_right_radius:
arg input: StyleBorderTopRightRadius
-> CssProperty
constructor const_border_bottom_left_radius:
arg input: StyleBorderBottomLeftRadius
-> CssProperty
constructor const_border_bottom_right_radius:
arg input: StyleBorderBottomRightRadius
-> CssProperty
constructor const_border_top_color:
arg input: StyleBorderTopColor
-> CssProperty
constructor const_border_right_color:
arg input: StyleBorderRightColor
-> CssProperty
constructor const_border_left_color:
arg input: StyleBorderLeftColor
-> CssProperty
constructor const_border_bottom_color:
arg input: StyleBorderBottomColor
-> CssProperty
constructor const_border_top_style:
arg input: StyleBorderTopStyle
-> CssProperty
constructor const_border_right_style:
arg input: StyleBorderRightStyle
-> CssProperty
constructor const_border_left_style:
arg input: StyleBorderLeftStyle
-> CssProperty
constructor const_border_bottom_style:
arg input: StyleBorderBottomStyle
-> CssProperty
constructor const_border_top_width:
arg input: LayoutBorderTopWidth
-> CssProperty
constructor const_border_right_width:
arg input: LayoutBorderRightWidth
-> CssProperty
constructor const_border_left_width:
arg input: LayoutBorderLeftWidth
-> CssProperty
constructor const_border_bottom_width:
arg input: LayoutBorderBottomWidth
-> CssProperty
constructor const_box_shadow_left:
arg input: StyleBoxShadow
-> CssProperty
constructor const_box_shadow_right:
arg input: StyleBoxShadow
-> CssProperty
constructor const_box_shadow_top:
arg input: StyleBoxShadow
-> CssProperty
constructor const_box_shadow_bottom:
arg input: StyleBoxShadow
-> CssProperty
constructor const_opacity:
arg input: StyleOpacity
-> CssProperty
constructor const_transform:
arg input: StyleTransformVec
-> CssProperty
constructor const_transform_origin:
arg input: StyleTransformOrigin
-> CssProperty
constructor const_perspective_origin:
arg input: StylePerspectiveOrigin
-> CssProperty
constructor const_backface_visibility:
arg input: StyleBackfaceVisibility
-> CssProperty
constructor const_break_before:
arg input: PageBreak
-> CssProperty
constructor const_break_after:
arg input: PageBreak
-> CssProperty
constructor const_break_inside:
arg input: BreakInside
-> CssProperty
constructor const_orphans:
arg input: Orphans
-> CssProperty
constructor const_widows:
arg input: Widows
-> CssProperty
constructor const_box_decoration_break:
arg input: BoxDecorationBreak
-> CssProperty
constructor const_column_count:
arg input: ColumnCount
-> CssProperty
constructor const_column_width:
arg input: ColumnWidth
-> CssProperty
constructor const_column_span:
arg input: ColumnSpan
-> CssProperty
constructor const_column_fill:
arg input: ColumnFill
-> CssProperty
constructor const_column_rule_width:
arg input: ColumnRuleWidth
-> CssProperty
constructor const_column_rule_style:
arg input: ColumnRuleStyle
-> CssProperty
constructor const_column_rule_color:
arg input: ColumnRuleColor
-> CssProperty
constructor const_flow_into:
arg input: FlowInto
-> CssProperty
constructor const_flow_from:
arg input: FlowFrom
-> CssProperty
constructor const_shape_outside:
arg input: ShapeOutside
-> CssProperty
constructor const_shape_inside:
arg input: ShapeInside
-> CssProperty
constructor const_clip_path:
arg input: ClipPath
-> CssProperty
constructor const_shape_margin:
arg input: ShapeMargin
-> CssProperty
constructor const_shape_image_threshold:
arg input: ShapeImageThreshold
-> CssProperty
constructor const_content:
arg input: Content
-> CssProperty
constructor const_counter_reset:
arg input: CounterReset
-> CssProperty
constructor const_counter_increment:
arg input: CounterIncrement
-> CssProperty
constructor const_list_style_type:
arg input: StyleListStyleType
-> CssProperty
constructor const_list_style_position:
arg input: StyleListStylePosition
-> CssProperty
constructor const_string_set:
arg input: StringSet
-> CssProperty
constructor const_table_layout:
arg input: LayoutTableLayout
-> CssProperty
constructor const_border_collapse:
arg input: StyleBorderCollapse
-> CssProperty
constructor const_border_spacing:
arg input: LayoutBorderSpacing
-> CssProperty
constructor const_caption_side:
arg input: StyleCaptionSide
-> CssProperty
constructor const_empty_cells:
arg input: StyleEmptyCells
-> CssProperty
3 methods
fn value:
&self
-> String
fn format_css:
&self
-> String
fn is_initial:
&self
-> bool
struct StyledDom
has destructor11 fields
root: NodeHierarchyItemId
node_hierarchy: NodeHierarchyItemVec
node_data: NodeDataVec
styled_nodes: StyledNodeVec
cascade_info: CascadeInfoVec
nodes_with_window_callbacks: NodeHierarchyItemIdVec
nodes_with_datasets: NodeHierarchyItemIdVec
tag_ids_to_node_ids: TagIdToNodeIdMappingVec
non_leaf_nodes: ParentWithNodeDepthVec
css_property_cache: CssPropertyCachePtr
dom_id: DomId
1 constructor
constructor create_from_dom:
Creates a
StyledDomfrom a recursive Dom tree with deferred CSS.More
This is the Phase 7.2 entry point: the layout callback returns a recursive
Domwithcss: Vec<Css>on each node. This function:1. Collects all CSS objects from the recursive tree 2. Flattens the Dom into contiguous arrays (
CompactDom) 3. Merges all CSS objects and runs a single cascade pass 4. Runsapply_ua_css->compute_inherited_values->build_compact_cache5. Generates anonymous table elements9 methods
fn with_child:
fn append_child:
&mut self
arg other: StyledDom
fn node_count:
&self
-> usize
fn get_rects_in_rendering_order:
&self
-> ContentGroup
&mut self
-> StyledDom
Same as
append_child(), but as a builder methodAppends another
StyledDomas a child to theself.rootwithout re-styling the DOM itselfReturns the total number of nodes in this StyledDom.
Sets the menu bar for the root node
Builder method for setting the menu bar
Sets the context menu for the root node
Builder method for setting the context menu
Returns nodes grouped by their rendering order (respects z-index and position).
Replaces this StyledDom with default and returns the old value.
union enum EventFilter
6 variants
Hover(HoverEventFilter)
Focus(FocusEventFilter)
Window(WindowEventFilter)
Component(ComponentEventFilter)
Application(ApplicationEventFilter)
External(ExternalEventFilter)
enum HoverEventFilter
78 variants
MouseOver
MouseDown
LeftMouseDown
RightMouseDown
MiddleMouseDown
Click
MouseUp
LeftMouseUp
RightMouseUp
MiddleMouseUp
MouseEnter
MouseLeave
Scroll
ScrollStart
ScrollEnd
TextInput
VirtualKeyDown
VirtualKeyUp
HoveredFile
DroppedFile
HoveredFileCancelled
TouchStart
TouchMove
TouchEnd
TouchCancel
PenDown
PenMove
PenUp
PenEnter
PenLeave
PenSqueeze
PenDoubleTap
PenHover
GeolocationFix
GeolocationError
SensorChanged
GamepadInput
DragStart
Drag
DragEnd
DragEnter
DragOver
DragLeave
Drop
DoubleClick
LongPress
SwipeLeft
SwipeRight
SwipeUp
SwipeDown
PinchIn
PinchOut
RotateClockwise
RotateCounterClockwise
MouseOut
FocusIn
FocusOut
CompositionStart
CompositionUpdate
CompositionEnd
SystemTextSingleClick
SystemTextDoubleClick
SystemTextTripleClick
PermissionChanged
BiometricResult
ScreenColorPicked
KeyringResult
BackMouseDown
BackMouseUp
ForwardMouseDown
ForwardMouseUp
Submit
Change
Reset
Invalid
DialRotate
DialClick
MouseMove
struct ColorU
u8-based color, range 0 to 255 (similar to webrenders ColorU)
4 fields
r: u8
g: u8
b: u8
a: u8
113 constructors
constructor from_str:
constructor rgba:
arg r: u8
arg g: u8
arg b: u8
arg a: u8
-> ColorU
constructor rgb:
arg r: u8
arg g: u8
arg b: u8
-> ColorU
constructor white:
-> ColorU
constructor black:
-> ColorU
constructor transparent:
-> ColorU
constructor create:
arg r: u8
arg g: u8
arg b: u8
arg a: u8
-> ColorU
constructor red:
-> ColorU
constructor green:
-> ColorU
constructor blue:
-> ColorU
constructor yellow:
-> ColorU
constructor cyan:
-> ColorU
constructor magenta:
-> ColorU
constructor orange:
-> ColorU
constructor pink:
-> ColorU
constructor purple:
-> ColorU
constructor brown:
-> ColorU
constructor gray:
-> ColorU
constructor light_gray:
-> ColorU
constructor dark_gray:
-> ColorU
constructor teal:
-> ColorU
constructor olive:
-> ColorU
constructor maroon:
-> ColorU
constructor lime:
-> ColorU
constructor aqua:
-> ColorU
constructor silver:
-> ColorU
constructor fuchsia:
-> ColorU
constructor indigo:
-> ColorU
constructor gold:
-> ColorU
constructor coral:
-> ColorU
constructor salmon:
-> ColorU
constructor turquoise:
-> ColorU
constructor violet:
-> ColorU
constructor crimson:
-> ColorU
constructor chocolate:
-> ColorU
constructor sky_blue:
-> ColorU
constructor forest_green:
-> ColorU
constructor sea_green:
-> ColorU
constructor slate_gray:
-> ColorU
constructor midnight_blue:
-> ColorU
constructor dark_red:
-> ColorU
constructor dark_green:
-> ColorU
constructor dark_blue:
-> ColorU
constructor light_blue:
-> ColorU
constructor light_green:
-> ColorU
constructor light_yellow:
-> ColorU
constructor light_pink:
-> ColorU
constructor create_rgb:
arg r: u8
arg g: u8
arg b: u8
-> ColorU
constructor strawberry:
arg shade: usize
-> ColorU
constructor palette_orange:
arg shade: usize
-> ColorU
constructor banana:
arg shade: usize
-> ColorU
constructor palette_lime:
arg shade: usize
-> ColorU
constructor mint:
arg shade: usize
-> ColorU
constructor blueberry:
arg shade: usize
-> ColorU
constructor grape:
arg shade: usize
-> ColorU
constructor bubblegum:
arg shade: usize
-> ColorU
constructor cocoa:
arg shade: usize
-> ColorU
constructor palette_silver:
arg shade: usize
-> ColorU
constructor slate:
arg shade: usize
-> ColorU
constructor dark:
arg shade: usize
-> ColorU
constructor apple_red:
-> ColorU
constructor apple_red_dark:
-> ColorU
constructor apple_orange:
-> ColorU
constructor apple_orange_dark:
-> ColorU
constructor apple_yellow:
-> ColorU
constructor apple_yellow_dark:
-> ColorU
constructor apple_green:
-> ColorU
constructor apple_green_dark:
-> ColorU
constructor apple_mint:
-> ColorU
constructor apple_mint_dark:
-> ColorU
constructor apple_teal:
-> ColorU
constructor apple_teal_dark:
-> ColorU
constructor apple_cyan:
-> ColorU
constructor apple_cyan_dark:
-> ColorU
constructor apple_blue:
-> ColorU
constructor apple_blue_dark:
-> ColorU
constructor apple_indigo:
-> ColorU
constructor apple_indigo_dark:
-> ColorU
constructor apple_purple:
-> ColorU
constructor apple_purple_dark:
-> ColorU
constructor apple_pink:
-> ColorU
constructor apple_pink_dark:
-> ColorU
constructor apple_brown:
-> ColorU
constructor apple_brown_dark:
-> ColorU
constructor apple_gray:
-> ColorU
constructor apple_gray_dark:
-> ColorU
constructor bootstrap_primary:
-> ColorU
constructor bootstrap_primary_hover:
-> ColorU
constructor bootstrap_primary_active:
-> ColorU
constructor bootstrap_secondary:
-> ColorU
constructor bootstrap_secondary_hover:
-> ColorU
constructor bootstrap_secondary_active:
-> ColorU
constructor bootstrap_success:
-> ColorU
constructor bootstrap_success_hover:
-> ColorU
constructor bootstrap_success_active:
-> ColorU
constructor bootstrap_danger:
-> ColorU
constructor bootstrap_danger_hover:
-> ColorU
constructor bootstrap_danger_active:
-> ColorU
constructor bootstrap_warning:
-> ColorU
constructor bootstrap_warning_hover:
-> ColorU
constructor bootstrap_warning_active:
-> ColorU
constructor bootstrap_info:
-> ColorU
constructor bootstrap_info_hover:
-> ColorU
constructor bootstrap_info_active:
-> ColorU
constructor bootstrap_light:
-> ColorU
constructor bootstrap_light_hover:
-> ColorU
constructor bootstrap_light_active:
-> ColorU
constructor bootstrap_dark:
-> ColorU
constructor bootstrap_dark_hover:
-> ColorU
constructor bootstrap_dark_active:
-> ColorU
constructor bootstrap_link:
-> ColorU
constructor bootstrap_link_hover:
-> ColorU
Creates a new color with RGBA values.
Creates a new color with RGB values (alpha = 255).
Alias for
rgb- kept for internal compatibility, not exposed in FFI.Strawberry color palette (shade: 100, 300, 500, 700, 900)
Orange color palette (shade: 100, 300, 500, 700, 900)
Banana color palette (shade: 100, 300, 500, 700, 900)
Lime color palette (shade: 100, 300, 500, 700, 900)
Mint color palette (shade: 100, 300, 500, 700, 900)
Blueberry color palette (shade: 100, 300, 500, 700, 900)
Grape color palette (shade: 100, 300, 500, 700, 900)
Bubblegum color palette (shade: 100, 300, 500, 700, 900)
Cocoa color palette (shade: 100, 300, 500, 700, 900)
Silver color palette (shade: 100, 300, 500, 700, 900)
Slate color palette (shade: 100, 300, 500, 700, 900)
Dark color palette (shade: 100, 300, 500, 700, 900)
Apple Red (light mode)
Apple Red (dark mode)
Apple Orange (light mode)
Apple Orange (dark mode)
Apple Yellow (light mode)
Apple Yellow (dark mode)
Apple Green (light mode)
Apple Green (dark mode)
Apple Mint (light mode)
Apple Mint (dark mode)
Apple Teal (light mode)
Apple Teal (dark mode)
Apple Cyan (light mode)
Apple Cyan (dark mode)
Apple Blue (light mode)
Apple Blue (dark mode)
Apple Indigo (light mode)
Apple Indigo (dark mode)
Apple Purple (light mode)
Apple Purple (dark mode)
Apple Pink (light mode)
Apple Pink (dark mode)
Apple Brown (light mode)
Apple Brown (dark mode)
Apple Gray (light mode)
Apple Gray (dark mode)
Primary button color (blue) - used for main actions
Primary button hover color
Primary button active/pressed color
Secondary button color (gray)
Success button color (green) - used for confirmations
Danger button color (red) - used for destructive actions
Warning button color (yellow) - uses BLACK text
Info button color (teal/cyan)
Light button color
Dark button color
Link button text color
27 methods
fn with_alpha:
&self
arg a: u8
-> ColorU
fn interpolate:
fn lighten:
&self
arg amount: f32
-> ColorU
fn to_hash:
&self
-> String
fn has_alpha:
&self
-> bool
fn darken:
&self
arg amount: f32
-> ColorU
fn mix:
fn hover_variant:
&self
-> ColorU
fn active_variant:
&self
-> ColorU
fn luminance:
&self
-> f32
&self
-> f32
fn contrast_text:
&self
-> ColorU
&self
-> ColorU
fn contrast_ratio:
&self
arg other: ColorU
-> f32
fn meets_wcag_aa:
&self
arg other: ColorU
-> bool
&self
arg other: ColorU
-> bool
fn meets_wcag_aaa:
&self
arg other: ColorU
-> bool
&self
arg other: ColorU
-> bool
fn apca_contrast:
&self
arg background: ColorU
-> f32
fn meets_apca_body:
&self
arg background: ColorU
-> bool
fn meets_apca_large:
&self
arg background: ColorU
-> bool
fn is_light:
&self
-> bool
fn is_dark:
&self
-> bool
fn ensure_contrast:
fn with_alpha_f32:
&self
arg a: f32
-> ColorU
fn invert:
&self
-> ColorU
fn to_grayscale:
&self
-> ColorU
Set the alpha channel while keeping RGB values.
Interpolate between two colors. t=0.0 returns self, t=1.0 returns other.
Lighten a color by a percentage (0.0 to 1.0). Returns a new color blended towards white.
Darken a color by a percentage (0.0 to 1.0). Returns a new color blended towards black.
Mix two colors together with a given ratio (0.0 = self, 1.0 = other).
Create a hover variant (slightly lighter for dark colors, darker for light colors). Useful for button hover states.
Create an active/pressed variant (darker than hover). Useful for button active states.
Calculate relative luminance (0.0 = black, 1.0 = white). Uses the sRGB luminance formula.
Calculate relative luminance per WCAG 2.1 specification. Uses sRGB to linear conversion for accurate results.
Returns white or black text color for best contrast on this background.
Suggest the best text color (black or white) for this background, ensuring WCAG AA compliance for normal text.
Calculate the contrast ratio between this color and another. Returns a value between 1.0 (no contrast) and 21.0 (max contrast).
More
WCAG 2.1 requirements: - AA normal text: >= 4.5:1 - AA large text: >= 3.0:1 - AAA normal text: >= 7.0:1 - AAA large text: >= 4.5:1
Check if the contrast ratio meets WCAG AA requirements for normal text (>= 4.5:1).
Check if the contrast ratio meets WCAG AA requirements for large text (>= 3.0:1). Large text is defined as 18pt+ or 14pt+ bold.
Check if the contrast ratio meets WCAG AAA requirements for normal text (>= 7.0:1).
Check if the contrast ratio meets WCAG AAA requirements for large text (>= 4.5:1).
Calculate the APCA (Accessible Perceptual Contrast Algorithm) contrast. This is a newer algorithm that may replace WCAG contrast in future standards. Returns a value between -108 (white on black) and 106 (black on white). For most purposes, use the absolute value.
Check if the APCA contrast meets the recommended minimum for body text (|Lc| >= 60).
Check if the APCA contrast meets the minimum for large text (|Lc| >= 45).
Returns true if this color is considered 'light' (luminance > 0.5).
Returns true if this color is considered 'dark' (luminance <= 0.5).
Adjust the color to ensure it meets the minimum contrast ratio against a background. Returns the original color if it already meets the requirement.
Set the alpha as a float (0.0 to 1.0).
Invert the color (keeping alpha).
Convert to grayscale using luminance weights.
union enum CssPropertyValue
Generic CSS property value that can be Auto, None, Initial, Inherit, or an exact value
7 variants
Auto
None
Initial
Inherit
Revert
Unset
Exact(T)
enum FocusEventFilter
58 variants
MouseOver
MouseDown
LeftMouseDown
RightMouseDown
MiddleMouseDown
MouseUp
LeftMouseUp
RightMouseUp
MiddleMouseUp
MouseEnter
MouseLeave
Scroll
ScrollStart
ScrollEnd
TextInput
VirtualKeyDown
VirtualKeyUp
FocusReceived
FocusLost
PenDown
PenMove
PenUp
DragStart
Drag
DragEnd
DragEnter
DragOver
DragLeave
Drop
DoubleClick
LongPress
SwipeLeft
SwipeRight
SwipeUp
SwipeDown
PinchIn
PinchOut
RotateClockwise
RotateCounterClockwise
FocusIn
FocusOut
CompositionStart
CompositionUpdate
CompositionEnd
Copy
Cut
Paste
DocumentEdit
TextChanged
BackMouseDown
BackMouseUp
ForwardMouseDown
ForwardMouseUp
Submit
Change
Reset
Invalid
MouseMove
struct PixelValue
2 fields
metric: SizeMetric
number: FloatValue
7 constructors
constructor zero:
-> PixelValue
constructor px:
arg value: f32
-> PixelValue
constructor em:
arg value: f32
-> PixelValue
constructor rem:
arg value: f32
-> PixelValue
constructor pt:
arg value: f32
-> PixelValue
constructor percent:
arg value: f32
-> PixelValue
constructor from_metric:
arg metric: SizeMetric
arg value: f32
-> PixelValue
Creates a zero pixel value.
Creates a pixel value in px units.
Creates a pixel value in em units.
Creates a pixel value in rem units.
Creates a pixel value in pt units.
Creates a pixel value in percent.
Creates a pixel value from a metric and value.
3 methods
fn is_absolute:
&self
-> bool
&self
-> OptionF32
fn to_pixels:
&self
arg percent_resolve: f32
arg em_resolve: f32
arg rem_resolve: f32
-> f32
Whether this value resolves to pixels with NO context.
More
True for
px,pt,in,cm,mm. False forem,rem,%and the viewport units, all of which need something the value itself does not carry.Resolve to pixels WITHOUT a context, or
Noneif this value needs one.More
The honest form for the many values that are absolute by construction - a safe-area inset, a scrollbar width, a border reported by the system theme.
CallbackInfo::get_safe_area_insets()hands backOptionPixelValue, and before this the only way out wasp.number.get(), which silently returns24for24emas readily as for24px: correct only because the caller happened to know the value was absolute.Returning
Nonerather than a number is the point. A relative unit has no pixel value until something supplies the reference, so answering with one would be inventing it - which is exactly howto_pixels_internalreports viewport units as0.0.Resolve to pixels, supplying the reference each relative unit needs.
More
-
percent_resolve- the 100% reference for%-em_resolve- the element's own font size, forem-rem_resolve- the root font size, forremAbsolute units ignore all three, so an absolute value can be resolved with zeroes - though [
Self::to_pixels_absolute] says that more clearly.Viewport units
vw/vh/vmin/vmaxresolve to0.0here, because this signature carries no viewport. That is a documented limitation of this entry point rather than a correct answer; the engine's own resolution path handles them.struct DynamicCssProperty
has destructorA
DynamicCssPropertyis a type of css property that can be changed on possibly every frame by the Rust code - for example to implement anOn::Hoverbehaviour. The syntax for such a property looks like this: no_run,ignore #my_div { padding: var(--my_dynamic_property_id, 400px); } Azul will register a dynamic property with the key "my_dynamic_property_id" and the default value of 400px. If the property gets overridden during one frame, the overridden property takes precedence. At runtime the style is immutable (which is a performance optimization - if we can assume that the property never changes at runtime), we can do some optimizations on it. Dynamic style properties can also be used for animations and conditional styles (i.e.hover,focus, etc.), thereby leading to cleaner code, since all of these special cases now use one single API.2 fields
The stringified ID of this property, i.e. the
"my_id"inwidth: var(--my_id, 500px).dynamic_id: String
Default values for this properties - one single value can control multiple properties!
default_value: CssProperty
struct LogicalSize
2 fields
width: f32
height: f32
2 constructors
constructor create:
arg width: f32
arg height: f32
-> LogicalSize
constructor zero:
-> LogicalSize
0 methods
enum ApplicationEventFilter
6 variants
DeviceConnected
DeviceDisconnected
MonitorConnected
MonitorDisconnected
MediaControl
SystemAudioChange
struct CssPropertyWithConditions
has destructorA CSS property with optional conditions for when it should be applied. Supports OS-specific, media query, container query, theme, and pseudo-state conditions.
2 fields
property: CssProperty
apply_if: DynamicSelectorVec
13 constructors
constructor simple:
arg property: CssProperty
constructor with_condition:
arg property: CssProperty
arg condition: DynamicSelector
constructor with_conditions:
arg property: CssProperty
arg conditions: DynamicSelectorVec
constructor on_hover:
arg property: CssProperty
constructor on_active:
arg property: CssProperty
constructor on_focus:
arg property: CssProperty
constructor when_disabled:
arg property: CssProperty
constructor on_os:
arg property: CssProperty
arg os: OsCondition
constructor dark_theme:
arg property: CssProperty
constructor light_theme:
arg property: CssProperty
constructor on_windows:
arg property: CssProperty
constructor on_macos:
arg property: CssProperty
constructor on_linux:
arg property: CssProperty
Create an unconditional property (always applies) - const version
Create a property with a single condition (non-const, allocates)
Create a property with multiple conditions (all must match)
Create a property that applies only on hover (const version)
Create a property that applies only when active (const version)
Create a property that applies only when focused (const version)
Create a property that applies only when disabled (const version)
Create a property that applies only on a specific OS (non-const, needs runtime value)
Create a property that applies only in dark theme (const version)
Create a property that applies only in light theme (const version)
Create a property for Windows only (const version)
Create a property for macOS only (const version)
Create a property for Linux only (const version)
3 methods
fn is_conditional:
&self
-> bool
&self
-> bool
&self
-> bool
Check if this property has any conditions
Check if this property is a pseudo-state conditional only (hover, active, focus, etc.)
Check if this property affects layout (width, height, margin, etc.) TODO: Implement when CssProperty has this method
struct LayoutRect
2 fields
origin: LayoutPoint
size: LayoutSize
2 constructors
constructor create:
arg origin: LayoutPoint
arg size: LayoutSize
-> LayoutRect
constructor zero:
-> LayoutRect
Creates a new LayoutRect with the given origin and size.
Creates a LayoutRect at the origin with zero size.
3 methods
fn contains_f32:
&self
arg x: f32
arg y: f32
-> bool
fn contains_rect:
&self
arg other: LayoutRect
-> bool
fn union:
arg rects: LayoutRectVecSlice
Returns whether this rectangle contains the given (x, y) point in f32 coordinates.
Returns whether
otheris fully contained inside this rectangle.Returns the bounding rectangle that covers every rectangle in the slice, or
OptionLayoutRect::Noneif the slice is empty.struct PercentageValue
Wrapper around FloatValue, represents a percentage instead of just being a regular floating-point value, i.e
5=5%1 field
number: FloatValue
struct FloatValue
Wrapper around an f32 value that is internally casted to an isize, in order to provide hash-ability (to avoid numerical instability).
1 field
number: isize
1 constructor
constructor create:
arg value: f32
-> FloatValue
Creates a new FloatValue from an f32.
1 method
fn get:
&self
-> f32
Gets the internal f32 value.
struct AngleValue
FloatValue, but associated with a certain metric (i.e. deg, rad, etc.)
2 fields
metric: AngleMetric
number: FloatValue
6 methods
fn zero:
-> AngleValue
fn deg:
arg value: f32
-> AngleValue
fn rad:
arg value: f32
-> AngleValue
fn grad:
arg value: f32
-> AngleValue
fn turn:
arg value: f32
-> AngleValue
fn get_degrees:
&self
-> f32
Creates an AngleValue of zero degrees.
Creates an AngleValue from degrees
Creates an AngleValue from radians
Creates an AngleValue from gradians
Creates an AngleValue from turns (1 turn = 360 degrees)
struct SystemStyle
has destructor24 fields
fonts: SystemFonts
metrics: SystemMetrics
linux: LinuxCustomization
platform: Platform
focus_visuals: FocusVisuals
language: String
app_specific_stylesheet: c_void
scrollbar: c_void
scroll_physics: ScrollPhysics
theme: Theme
os_version: OsVersion
prefers_reduced_motion: BoolCondition
prefers_high_contrast: BoolCondition
accessibility: AccessibilitySettings
handedness: Handedness
input: InputMetrics
text_rendering: TextRenderingHints
scrollbar_preferences: ScrollbarPreferences
visual_hints: VisualHints
animation: AnimationMetrics
colors: SystemColors
icon_style: IconStyleOptions
audio: AudioMetrics
run_destructor: bool
1 constructor
constructor detect:
-> SystemStyle
Discovers the system's UI style, and loads an optional app-specific stylesheet.
More
If the "io" feature is enabled, this function may be slow as it can involve running external commands and reading files.
If the "io" feature is disabled, this returns a hard-coded, deterministic style based on the target operating system.
1 method
&self
-> Css
Create a CSS stylesheet for CSD (Client-Side Decorations) titlebar
More
This generates CSS rules for the CSD titlebar using system colors, fonts, and metrics to match the native platform look.
struct SystemColors
21 fields
text: OptionColorU
secondary_text: OptionColorU
tertiary_text: OptionColorU
background: OptionColorU
accent: OptionColorU
accent_text: OptionColorU
button_face: OptionColorU
button_text: OptionColorU
disabled_text: OptionColorU
window_background: OptionColorU
under_page_background: OptionColorU
selection_background: OptionColorU
selection_text: OptionColorU
selection_background_inactive: OptionColorU
selection_text_inactive: OptionColorU
link: OptionColorU
separator: OptionColorU
grid: OptionColorU
find_highlight: OptionColorU
sidebar_background: OptionColorU
sidebar_selection: OptionColorU
enum SystemFontType
11 variants
Ui
UiBold
Monospace
MonospaceBold
MonospaceItalic
Title
TitleBold
Menu
Small
Serif
SerifBold
union enum StyleBackgroundContent
has destructor6 variants
LinearGradient(LinearGradient)
RadialGradient(RadialGradient)
ConicGradient(ConicGradient)
Image(String)
Color(ColorU)
SystemColor(SystemColorRef)
struct StyleBoxShadow
Represents a
box-shadowortext-shadowproperty.6 fields
offset_x: PixelValueNoPercent
offset_y: PixelValueNoPercent
blur_radius: PixelValueNoPercent
spread_radius: PixelValueNoPercent
clip_mode: BoxShadowClipMode
color: ColorU
enum BorderStyle
Style of a
border: solid, double, dash, ridge, etc.10 variants
None
Solid
Double
Dotted
Dashed
Hidden
Groove
Ridge
Inset
Outset
struct LinearGradient
has destructor3 fields
union enum StyleTransform
Represents one component of a
transformattribute21 variants
Matrix(StyleTransformMatrix2D)
Matrix3D(StyleTransformMatrix3D)
Translate(StyleTransformTranslate2D)
Translate3D(StyleTransformTranslate3D)
TranslateX(PixelValue)
TranslateY(PixelValue)
TranslateZ(PixelValue)
Rotate(AngleValue)
Rotate3D(StyleTransformRotate3D)
RotateX(AngleValue)
RotateY(AngleValue)
RotateZ(AngleValue)
Scale(StyleTransformScale2D)
Scale3D(StyleTransformScale3D)
ScaleX(PercentageValue)
ScaleY(PercentageValue)
ScaleZ(PercentageValue)
Skew(StyleTransformSkew2D)
SkewX(AngleValue)
SkewY(AngleValue)
Perspective(PixelValue)
struct DocumentPosition
A position in a node's TEXT CONTENT, app-facing:
text_byteindexes the flattened text ofnode- the exact stringget_node_text_content(node)returns. Resolved on grapheme-cluster boundaries, in LOGICAL byte order.2 fields
node: DomNodeId
text_byte: u32
struct StyleAnimation
has destructorOne entry of animation / -azul-animation-in / -azul-animation-out: <name> <duration> [<delay>] [<timing>] [infinite | <count>] [no-clip], e.g. flyOutLeft 1s, all 2s ease-out, spin 1s linear infinite, myFn 500ms cubic-bezier(0.4, 0, 0.2, 1) no-clip.
6 fields
name: String
duration: CssDuration
Wall-clock wait before the first iteration starts (staggered list entrances). Zero when omitted; the FIRST time value in the shorthand is the duration, the second is the delay.
delay: CssDuration
iterations: AnimationIterationCount
timing: AnimationTiming
Whether a presence EXIT driven by this animation is clipped to the node's retained rect. true when omitted; the CSS keyword no-clip clears it. Native functions may override per frame via ZombieFrame::clip_to_frozen_rect.
clip: bool
struct Keyframes
has destructorA named
@keyframesblock:@keyframes flyOutRight { from {..} to {..} }. Stops are sorted bypermilleascending at parse time.2 fields
name: String
stops: KeyframeStopVec
struct Content
has destructor1 field
inner: String
enum LayoutDisplay
Represents a
displayCSS property value23 variants
None
Block
Inline
InlineBlock
Flex
InlineFlex
Table
InlineTable
TableRowGroup
TableHeaderGroup
TableRow
TableColumnGroup
TableColumn
TableCell
TableCaption
FlowRoot
ListItem
RunIn
Marker
Grid
InlineGrid
Contents
union enum StyleFontFamily
has destructorRepresents a
font-familyattribute4 variants
struct StyleFontSize
Represents a
font-sizeattribute1 field
inner: PixelValue
1 constructor
constructor px:
arg value: f32
Creates a font size from a pixel value
struct CssRuleBlock
has destructorOne block of rules that applies a bunch of rules to a "path" in the style, i.e.
div#myid.myclass -> { ("justify-content", "center") }4 fields
The css path (full selector) of the style ruleset
path: CssPath
"justify-content: center"=>CssDeclaration::Static(CssProperty::JustifyContent(LayoutJustifyContent::Center))declarations: CssDeclarationVec
Conditions from enclosing @-rules (@media, @lang, etc.) that must ALL be satisfied for this rule block to apply. Empty = unconditional.
conditions: DynamicSelectorVec
Layer priority. 0 = UA / framework, 10 = system, 20 = author CSS (default), 30 = inline, 50 = runtime overrides. Combined with selector specificity in
Css::sort_by_specificityto put rules in cascade order.priority: u8
union enum CssNthChildSelector
4 variants
struct CssNthChildPattern
2 fields
pattern_repeat: u32
offset: u32
union enum CssDeclaration
has destructorContains one parsed
key: valuepair, static or dynamic2 variants
Static key-value pair, such as
width: 500pxStatic(CssProperty)
Dynamic key-value pair with default value, such as
width: [[ my_id | 500px ]]Dynamic(DynamicCssProperty)
enum SizeMetric
Enum representing the metric associated with a number (px, pt, em, etc.)
12 variants
Px
Pt
Em
Rem
In
Cm
Mm
Percent
Viewport width: 1vw = 1% of viewport width
Vw
Viewport height: 1vh = 1% of viewport height
Vh
Viewport minimum: 1vmin = 1% of smaller viewport dimension
Vmin
Viewport maximum: 1vmax = 1% of larger viewport dimension
Vmax
struct PixelValueSize
Two-dimensional size in PixelValue units (width, height) Used for background-size and similar properties
2 fields
width: PixelValue
height: PixelValue
union enum PixelValueOrSystem
A pixel value that can be either concrete or a system metric reference. System metrics are resolved at runtime based on user's system theme. CSS syntax: 10px, 1.5em, system:button-padding, etc.
2 variants
Value(PixelValue)
System(SystemMetricRef)
2 constructors
constructor value:
arg v: PixelValue
constructor system:
arg s: SystemMetricRef
Creates a PixelValueOrSystem from a concrete value.
Creates a PixelValueOrSystem from a system metric reference.
enum BoxShadowClipMode
What direction should a
box-shadowbe clipped in (inset or outset).2 variants
Outset
Inset
enum StyleMixBlendMode
Represents a
mix-blend-modeattribute, which determines how an element's content should blend with the content of the element's parent.16 variants
Normal
Multiply
Screen
Overlay
Darken
Lighten
ColorDodge
ColorBurn
HardLight
SoftLight
Difference
Exclusion
Hue
Saturation
Color
Luminosity
union enum StyleFilter
16 variants
Blend(StyleMixBlendMode)
Flood(ColorU)
Blur(StyleBlur)
Opacity(PercentageValue)
ColorMatrix(StyleColorMatrix)
DropShadow(StyleBoxShadow)
ComponentTransfer
Offset(StyleFilterOffset)
Composite(StyleCompositeFilter)
Brightness(PercentageValue)
Contrast(PercentageValue)
Grayscale(PercentageValue)
HueRotate(AngleValue)
Invert(PercentageValue)
Saturate(PercentageValue)
Sepia(PercentageValue)
struct StyleBlur
2 fields
width: PixelValue
height: PixelValue
struct StyleColorMatrix
20 fields
m0: FloatValue
m1: FloatValue
m2: FloatValue
m3: FloatValue
m4: FloatValue
m5: FloatValue
m6: FloatValue
m7: FloatValue
m8: FloatValue
m9: FloatValue
m10: FloatValue
m11: FloatValue
m12: FloatValue
m13: FloatValue
m14: FloatValue
m15: FloatValue
m16: FloatValue
m17: FloatValue
m18: FloatValue
m19: FloatValue
struct StyleFilterOffset
2 fields
x: PixelValue
y: PixelValue
union enum StyleCompositeFilter
7 variants
enum LayoutAlignContent
Represents an
align-contentattribute, which aligns a flex container's lines within it when there is extra space in the cross-axis. Default:Stretch6 variants
Stretch
Center
Start
End
SpaceBetween
SpaceAround
enum LayoutAlignItems
Represents an
align-itemsattribute, which defines the default behavior for how flex items are laid out along the cross axis on the current line. Default:Stretch5 variants
Stretch
Center
Start
End
Baseline
enum LayoutBoxSizing
Represents a
box-sizingattribute2 variants
ContentBox
BorderBox
enum LayoutFlexDirection
Represents a
flex-directionattribute, which establishes the main-axis, thus defining the direction flex items are placed in the flex container. Default:Row4 variants
Row
RowReverse
Column
ColumnReverse
2 methods
fn get_axis:
&self
-> LayoutAxis
fn is_reverse:
&self
-> bool
Returns the
LayoutAxis(Horizontal or Vertical) that this flex-direction lays items along.Returns
trueif this flex-direction is a reversed variant (RowReverseorColumnReverse).enum LayoutAxis
Represents the main or cross axis of a flex container.
2 variants
Horizontal
Vertical
struct LayoutFlexGrow
Represents a
flex-growattribute, which dictates what proportion of the remaining space in the flex container should be assigned to the item. Default: 01 field
inner: FloatValue
1 constructor
constructor create:
arg value: f32
Creates a flex-grow value
struct LayoutFlexShrink
Represents a
flex-shrinkattribute, which dictates what proportion of the negative space in the flex container should be removed from the item. Default: 11 field
inner: FloatValue
enum LayoutFloat
Represents a
floatattribute3 variants
Left
Right
None
union enum LayoutHeight
6 variants
enum LayoutJustifyContent
Represents a
justify-contentattribute, which defines the alignment along the main axis. Default:Start(flex-start)8 variants
FlexStart
FlexEnd
Start
End
Center
SpaceBetween
SpaceAround
SpaceEvenly
struct LayoutLeft
1 field
inner: PixelValue
struct LayoutMaxHeight
1 field
inner: PixelValue
struct LayoutMaxWidth
1 field
inner: PixelValue
struct LayoutMinHeight
1 field
inner: PixelValue
struct LayoutMinWidth
1 field
inner: PixelValue
struct LayoutPaddingLeft
1 field
inner: PixelValue
enum LayoutPosition
Represents a
positionattribute - default:Static5 variants
Static
Relative
Absolute
Fixed
Sticky
struct LayoutRight
1 field
inner: PixelValue
struct LayoutTop
1 field
inner: PixelValue
union enum LayoutWidth
6 variants
enum LayoutFlexWrap
Represents a
flex-wrapattribute, which determines whether flex items are forced onto one line or can wrap onto multiple lines. Default:NoWrap3 variants
Wrap
NoWrap
WrapReverse
enum LayoutOverflow
Represents an
overflow-xoroverflow-yproperty. Determines what to do when content overflows an element's box.5 variants
Always shows a scroll bar, overflows on scroll.
Scroll
Shows a scroll bar only when content overflows. This is the default.
Auto
Clips overflowing content. The rest of the content will be invisible.
Hidden
Content is not clipped and renders outside the element's box.
Visible
Similar to
hidden, clips the content at the box's edge.Clip
enum AngleMetric
Enum representing the metric associated with an angle (deg, rad, etc.)
5 variants
Degree
Radians
Grad
Turn
Percent
struct NormalizedLinearColorStop
2 fields
offset: PercentageValue
color: ColorOrSystem
struct NormalizedRadialColorStop
2 fields
angle: AngleValue
color: ColorOrSystem
enum DirectionCorner
8 variants
Right
Left
Top
Bottom
TopRight
TopLeft
BottomRight
BottomLeft
1 method
fn opposite:
&self
Returns the corner opposite to this one (e.g.
TopLeft->BottomRight).struct DirectionCorners
2 fields
dir_from: DirectionCorner
dir_to: DirectionCorner
union enum Direction
CSS direction (necessary for gradients). Can either be a fixed angle or a direction ("to right" / "to left", etc.).
2 variants
Angle(AngleValue)
FromTo(DirectionCorners)
enum Shape
2 variants
Ellipse
Circle
enum RadialGradientSize
4 variants
ClosestSide
ClosestCorner
FarthestSide
FarthestCorner
struct RadialGradient
has destructor5 fields
shape: Shape
size: RadialGradientSize
position: StyleBackgroundPosition
extend_mode: ExtendMode
stops: NormalizedLinearColorStopVec
struct ConicGradient
has destructor4 fields
extend_mode: ExtendMode
center: StyleBackgroundPosition
angle: AngleValue
stops: NormalizedRadialColorStopVec
union enum BackgroundPositionHorizontal
4 variants
union enum BackgroundPositionVertical
4 variants
struct StyleBackgroundPosition
2 fields
horizontal: BackgroundPositionHorizontal
vertical: BackgroundPositionVertical
enum StyleBackgroundRepeat
4 variants
NoRepeat
PatternRepeat
RepeatX
RepeatY
union enum StyleBackgroundSize
3 variants
struct StyleBorderBottomColor
1 field
inner: ColorU
struct StyleBorderBottomLeftRadius
1 field
inner: PixelValue
struct StyleBorderBottomRightRadius
1 field
inner: PixelValue
struct StyleBorderBottomStyle
1 field
inner: BorderStyle
struct LayoutBorderBottomWidth
1 field
inner: PixelValue
struct StyleBorderLeftColor
1 field
inner: ColorU
struct StyleBorderLeftStyle
1 field
inner: BorderStyle
struct LayoutBorderLeftWidth
1 field
inner: PixelValue
struct StyleBorderRightColor
1 field
inner: ColorU
struct StyleBorderRightStyle
1 field
inner: BorderStyle
struct LayoutBorderRightWidth
1 field
inner: PixelValue
struct StyleBorderTopColor
1 field
inner: ColorU
struct StyleBorderTopLeftRadius
1 field
inner: PixelValue
struct StyleBorderTopRightRadius
1 field
inner: PixelValue
struct StyleBorderTopStyle
1 field
inner: BorderStyle
struct LayoutBorderTopWidth
1 field
inner: PixelValue
struct StyleOpacity
Represents an
opacityattribute, a value from 0.0 to 1.0.1 field
inner: PercentageValue
struct StyleTransformOrigin
Represents a
transform-originattribute2 fields
x: PixelValue
y: PixelValue
enum StyleBackfaceVisibility
Represents a
backface-visibilityattribute2 variants
Visible
Hidden
struct StyleTransformMatrix2D
6 fields
struct StyleTransformMatrix3D
16 fields
m11: FloatValue
m12: FloatValue
m13: FloatValue
m14: FloatValue
m21: FloatValue
m22: FloatValue
m23: FloatValue
m24: FloatValue
m31: FloatValue
m32: FloatValue
m33: FloatValue
m34: FloatValue
m41: FloatValue
m42: FloatValue
m43: FloatValue
m44: FloatValue
struct StyleTransformTranslate2D
2 fields
x: PixelValue
y: PixelValue
struct StyleTransformTranslate3D
3 fields
struct StyleTransformRotate3D
4 fields
struct StyleTransformScale2D
2 fields
x: FloatValue
y: FloatValue
struct StyleTransformScale3D
3 fields
struct StyleTransformSkew2D
2 fields
x: AngleValue
y: AngleValue
enum StyleTextAlign
Horizontal text alignment enum (left, center, right) - default:
Left6 variants
Left
Center
Right
Justify
Start
End
struct CounterReset
has destructor2 fields
counter_name: String
value: i32
union enum GridLine
has destructorRepresents a grid line position (start or end)
4 variants
struct StylePerspectiveOrigin
Represents a
perspective-originattribute2 fields
x: PixelValue
y: PixelValue
union enum LayoutZIndex
Represents a
z-indexattribute - controls stacking order of positioned elements2 variants
Auto
Integer(i32)
enum LayoutJustifyItems
Represents
justify-itemsfor grid containers4 variants
Start
End
Center
Stretch
struct SelectionBackgroundColor
1 field
inner: ColorU
struct ColumnRuleColor
1 field
inner: ColorU
enum ColumnSpan
2 variants
None
All
enum LayoutClear
Represents a
clearattribute4 variants
None
Left
Right
Both
enum StyleWhiteSpace
How to handle white space inside an element.
6 variants
Normal
Pre
Nowrap
PreWrap
PreLine
BreakSpaces
enum BreakInside
Represents a
break-insideCSS property value.4 variants
Auto
Avoid
AvoidPage
AvoidColumn
enum LayoutAlignSelf
Represents an
align-selfattribute, which allows the default alignment (or the one specified by align-items) to be overridden for individual flex items. Default:Auto6 variants
Auto
Stretch
Center
Start
End
Baseline
struct CaretAnimationDuration
1 field
inner: CssDuration
struct ColumnRuleStyle
1 field
inner: BorderStyle
union enum ShapeOutside
has destructorCSS shape-outside property for wrapping text around shapes
2 variants
None
Shape(CssShape)
union enum ColumnCount
2 variants
Auto
Integer(u32)
enum LayoutWritingMode
Represents a
writing-modeattribute3 variants
HorizontalTb
VerticalRl
VerticalLr
enum StyleUserSelect
Controls whether the user can select text. Used to prevent accidental text selection on UI controls like buttons.
4 variants
Browser determines selectability (default)
Auto
Text is selectable
Text
Text is not selectable
None
User can select all text with a single action
All
struct GridTemplate
has destructorRepresents
grid-template-columnsorgrid-template-rows1 field
tracks: GridTrackSizingVec
enum LayoutJustifySelf
Represents
justify-selffor grid items5 variants
Auto
Start
End
Center
Stretch
enum StyleHyphens
Hyphenation rules.
3 variants
None
Manual
Auto
struct LayoutGap
1 field
inner: PixelValue
enum StyleDirection
Text direction.
2 variants
Ltr
Rtl
struct ShapeMargin
1 field
inner: PixelValue
enum LayoutTextJustify
5 variants
Auto
None
InterWord
InterCharacter
Distribute
union enum ColumnWidth
2 variants
Auto
Length(PixelValue)
struct CounterIncrement
has destructor2 fields
counter_name: String
value: i32
enum BoxDecorationBreak
Represents a
box-decoration-breakCSS property value.2 variants
Slice
Clone
enum StyleVisibility
Represents a
visibilityattribute, controlling element visibility.3 variants
Visible
Hidden
Collapse
struct ShapeImageThreshold
1 field
inner: FloatValue
enum LayoutGridAutoFlow
Represents the
grid-auto-flowproperty4 variants
Row
Column
RowDense
ColumnDense
struct ColumnRuleWidth
1 field
inner: PixelValue
enum StyleTextDecoration
Text decoration (underline, overline, line-through).
4 variants
No decoration
None
Underline
Underline
Line above text
Overline
Strike-through line
LineThrough
struct CaretColor
1 field
inner: ColorU
struct LayoutSize
Only used for calculations: Size (width, height) in layout space.
2 fields
width: isize
height: isize
2 constructors
constructor create:
arg width: isize
arg height: isize
-> LayoutSize
constructor zero:
-> LayoutSize
Creates a new LayoutSize with the given width and height.
Creates a LayoutSize with zero dimensions.
0 methods
enum ColumnFill
2 variants
Auto
Balance
struct GridAutoTracks
has destructorRepresents grid-auto-columns or grid-auto-rows Structurally identical to GridTemplate but semantically different
1 field
tracks: GridTrackSizingVec
enum PageBreak
Represents a
break-beforeorbreak-afterCSS property value.12 variants
Auto
Avoid
Always
All
Page
AvoidPage
Left
Right
Recto
Verso
Column
AvoidColumn
enum LayoutScrollbarWidth
Represents the standard
scrollbar-widthproperty.3 variants
Auto
Thin
None
union enum StyleScrollbarColor
Represents the standard
scrollbar-colorproperty.2 variants
Auto
Custom(ScrollbarColorCustom)
union enum StyleVerticalAlign
Vertical text alignment enum (baseline, top, middle, bottom, sub, super, text-top, text-bottom) - default:
Baseline10 variants
struct StyleLineClamp
line-clamp property for limiting visible lines
1 field
max_lines: usize
union enum ShapeInside
has destructorCSS shape-inside property for flowing text within shapes
2 variants
None
Shape(CssShape)
struct Orphans
1 field
inner: u32
struct StyleTextIndent
Represents a
text-indentattribute (indentation of first line in a block).3 fields
inner: PixelValue
each-line keyword: indent first line of each block container AND each line after a forced line break (but not after soft wrap).
each_line: bool
hanging keyword: inverts which lines are affected by the indent.
hanging: bool
struct LayoutBorderSpacing
Sets the distance between the borders of adjacent cells. The
border-spacingproperty is only applicable whenborder-collapseis set toseparate. It can have one or two values: - One value: Sets both horizontal and vertical spacing - Two values: First is horizontal, second is vertical This struct represents a single spacing value (either horizontal or vertical).2 fields
Horizontal spacing between cell borders
horizontal: PixelValue
Vertical spacing between cell borders
vertical: PixelValue
struct LayoutPaddingInlineStart
1 field
inner: PixelValue
enum StyleFontWeight
Represents the
font-weightproperty.11 variants
Lighter
W100
W200
W300
Normal
W500
W600
Bold
W800
W900
Bolder
struct StyleExclusionMargin
-azul-exclusion-marginproperty: defines margin around shape exclusions This property controls the spacing between text and shapes that text flows around. It's similar toshape-marginbut specifically for exclusions (text wrapping). # Example ss .element { -azul-exclusion-margin: 10.5; }1 field
inner: FloatValue
struct Widows
1 field
inner: u32
struct LayoutColumnGap
1 field
inner: PixelValue
struct LayoutPaddingInlineEnd
1 field
inner: PixelValue
enum StyleListStyleType
12 variants
None
Disc
Circle
Square
Decimal
DecimalLeadingZero
LowerRoman
UpperRoman
LowerGreek
UpperGreek
LowerAlpha
UpperAlpha
union enum ClipPath
has destructorCSS clip-path property for clipping element rendering
2 variants
None
Shape(CssShape)
struct StyleHyphenationLanguage
has destructor-azul-hyphenation-languageproperty: specifies language for hyphenation This property defines the language code (BCP 47 format) used for automatic hyphenation. Examples: "en-US", "de-DE", "fr-FR" # Example ss .element { -azul-hyphenation-language: "en-US"; }1 field
inner: String
enum StyleListStylePosition
2 variants
Inside
Outside
enum StyleBorderCollapse
Specifies whether cell borders are collapsed into a single border or separated. The
border-collapseproperty determines the border rendering model: - separate: Each cell has its own border (default, uses border-spacing) - collapse: Adjacent cells share borders (ignores border-spacing)2 variants
Borders are separated (default). Each cell has its own border. The
border-spacingproperty defines the distance between borders.Separate
Borders are collapsed. Adjacent cells share a single border. Border conflict resolution rules apply when borders differ.
Collapse
enum StyleCaptionSide
Specifies the placement of a table caption. The
caption-sideproperty positions the caption either above or below the table.2 variants
Caption is placed above the table (default)
Top
Caption is placed below the table
Bottom
struct LayoutRowGap
1 field
inner: PixelValue
struct StyleHangingPunctuation
hanging-punctuation property for hanging punctuation marks
4 fields
first: bool
force_end: bool
allow_end: bool
last: bool
enum LayoutTableLayout
Controls the algorithm used to lay out table cells, rows, and columns. The
table-layoutproperty determines whether the browser should use: - auto: Column widths are determined by the content (slower but flexible) - fixed: Column widths are determined by the first row (faster and predictable)2 variants
Use automatic table layout algorithm (content-based, default). Column width is set by the widest unbreakable content in the cells.
Auto
Use fixed table layout algorithm (first-row-based). Column width is set by the width property of the column or first-row cell. Renders faster than auto.
Fixed
enum StyleEmptyCells
Specifies whether or not to display borders and background on empty cells. The
empty-cellsproperty only applies whenborder-collapseis set toseparate. A cell is considered empty if it contains no visible content.2 variants
Show borders and background on empty cells (default)
Show
Hide borders and background on empty cells
Hide
enum StyleFontStyle
Represents the
font-styleproperty.3 variants
Normal
Italic
Oblique
union enum StyleTextCombineUpright
text-combine-upright property for combining horizontal text in vertical layout
3 variants
None
All
Digits(u8)
union enum GridTrackSizing
7 variants
struct PhysicalSizeU32
Physical size with u32 dimensions
2 fields
width: u32
height: u32
enum ShapeRendering
3 variants
OptimizeSpeed
CrispEdges
GeometricPrecision
struct XmlTextPos
2 fields
row: u32
col: u32
struct StyledNodeState
12 fields
hover: bool
active: bool
focused: bool
disabled: bool
checked: bool
focus_within: bool
visited: bool
backdrop: bool
dragging: bool
drag_over: bool
placeholder: bool
seat_focused: bool
struct CssPropertyCachePtr
2 fields
ptr: c_void
run_destructor: bool
struct SvgRenderTransform
6 fields
sx: f32
kx: f32
ky: f32
sy: f32
tx: f32
ty: f32
enum TextRendering
3 variants
OptimizeSpeed
OptimizeLegibility
GeometricPrecision
struct PhysicalSize
2 fields
width: T
height: T
struct VertexLayout
has destructor1 field
fields: VertexAttributeVec
struct GridMinMax
3 fields
min: c_void
max: c_void
run_destructor: bool
struct ShapeInset
5 fields
union enum CssShape
has destructor5 variants
struct ShapePath
has destructor1 field
data: String
struct ShapeEllipse
3 fields
struct ShapePoint
2 fields
x: f32
y: f32
enum WindowBackgroundMaterial
7 variants
Opaque
Transparent
Sidebar
Menu
HUD
Titlebar
MicaAlt
struct LayoutRectVecSlice
2 fields
union enum WindowPosition
3 variants
struct LayoutPoint
2 fields
x: isize
y: isize
2 constructors
constructor create:
arg x: isize
arg y: isize
-> LayoutPoint
constructor zero:
-> LayoutPoint
Creates a new LayoutPoint with the given x and y coordinates.
Creates a LayoutPoint at the origin (0, 0).
0 methods
union enum CursorPosition
3 variants
union enum ImePosition
2 variants
Uninitialized
Initialized(LogicalRect)
enum WindowDecorations
5 variants
Normal
NoTitle
NoTitleAutoInject
NoControls
None
struct PhysicalPosition
2 fields
x: T
y: T
struct LinuxDecorationsState
4 fields
is_dragging_titlebar: bool
close_button_hover: bool
maximize_button_hover: bool
minimize_button_hover: bool
enum Srgb
3 variants
Enabled
Disabled
DontCare
struct LayoutInsetBottom
1 field
inner: PixelValue
struct ContentGroup
2 fields
root: NodeHierarchyItemId
children: ContentGroupVec
enum CssPropertyType
191 variants
CaretColor
CaretAnimationDuration
Animation
AnimationIn
AnimationOut
CaretWidth
SelectionBackgroundColor
SelectionColor
SelectionRadius
TextColor
FontSize
FontFamily
FontWeight
FontStyle
TextAlign
TextJustify
VerticalAlign
LetterSpacing
TextIndent
InitialLetter
LineClamp
HangingPunctuation
TextCombineUpright
UnicodeBidi
TextBoxTrim
TextBoxEdge
DominantBaseline
AlignmentBaseline
BaselineSource
LineFitEdge
InitialLetterAlign
InitialLetterWrap
ScrollbarGutter
OverflowClipMargin
Clip
ExclusionMargin
HyphenationLanguage
LineHeight
WordSpacing
TabSize
WhiteSpace
Hyphens
WordBreak
OverflowWrap
LineBreak
TextOverflow
ObjectFit
ObjectPosition
AspectRatio
TextOrientation
TextAlignLast
TextTransform
Direction
UserSelect
TextDecoration
Cursor
Display
Float
BoxSizing
Width
Height
MinWidth
MinHeight
MaxWidth
MaxHeight
Position
Top
Right
Left
Bottom
ZIndex
FlexWrap
FlexDirection
FlexGrow
FlexShrink
FlexBasis
JustifyContent
AlignItems
AlignContent
ColumnGap
RowGap
GridTemplateColumns
GridTemplateRows
GridAutoColumns
GridAutoRows
GridColumn
GridRow
GridTemplateAreas
GridAutoFlow
JustifySelf
JustifyItems
Gap
GridGap
AlignSelf
Font
WritingMode
Clear
BackgroundContent
BackgroundPosition
BackgroundSize
BackgroundRepeat
OverflowX
OverflowY
OverflowBlock
OverflowInline
PaddingTop
PaddingLeft
PaddingRight
PaddingBottom
PaddingInlineStart
PaddingInlineEnd
MarginTop
MarginLeft
MarginRight
MarginBottom
BorderTopLeftRadius
BorderTopRightRadius
BorderBottomLeftRadius
BorderBottomRightRadius
BorderTopColor
BorderRightColor
BorderLeftColor
BorderBottomColor
BorderTopStyle
BorderRightStyle
BorderLeftStyle
BorderBottomStyle
BorderTopWidth
BorderRightWidth
BorderLeftWidth
BorderBottomWidth
BoxShadowLeft
BoxShadowRight
BoxShadowTop
BoxShadowBottom
ScrollbarTrack
ScrollbarThumb
ScrollbarButton
ScrollbarCorner
ScrollbarResizer
ScrollbarWidth
OverscrollBehaviorX
OverscrollBehaviorY
ScrollbarColor
ScrollbarVisibility
ScrollbarFadeDelay
ScrollbarFadeDuration
Opacity
Visibility
Transform
TransformOrigin
PerspectiveOrigin
BackfaceVisibility
AppRegion
MixBlendMode
Filter
BackdropFilter
TextShadow
BreakBefore
BreakAfter
BreakInside
Orphans
Widows
BoxDecorationBreak
ColumnCount
ColumnWidth
ColumnSpan
ColumnFill
ColumnRuleWidth
ColumnRuleStyle
ColumnRuleColor
FlowInto
FlowFrom
ShapeOutside
ShapeInside
ClipPath
ShapeMargin
ShapeImageThreshold
TableLayout
BorderCollapse
BorderSpacing
CaptionSide
EmptyCells
Content
CounterReset
CounterIncrement
ListStyleType
ListStylePosition
StringSet
struct StyledNode
1 field
styled_node_state: StyledNodeState
struct StyledTextRun
has destructor6 fields
struct TextOpReplaceText
has destructor4 fields
union enum TextOperation
has destructor11 variants
InsertText(TextOpInsertText)
DeleteText(TextOpDeleteText)
ReplaceText(TextOpReplaceText)
SetSelection(TextOpSetSelection)
ExtendSelection(TextOpExtendSelection)
ClearSelection(TextOpClearSelection)
MoveCursor(TextOpMoveCursor)
Copy(TextOpCopy)
Cut(TextOpCut)
Paste(TextOpPaste)
SelectAll(TextOpSelectAll)
struct TextOpCopy
has destructor2 fields
range: SelectionRange
content: ClipboardContent
struct TextOpDeleteText
has destructor3 fields
struct TextOpSelectAll
2 fields
old_range: OptionSelectionRange
new_range: SelectionRange
struct TextOpInsertText
has destructor3 fields
struct TextOpPaste
has destructor3 fields
struct TextOpCut
has destructor3 fields
enum ExtendMode
2 variants
Clamp
Repeat
union enum FlowFrom
has destructor2 variants
None
Named(String)
union enum FlowInto
has destructor2 variants
None
Named(String)
struct ArithmeticCoefficients
4 fields
struct CascadeInfo
Has all the necessary information about the style CSS path
2 fields
index_in_parent: u32
is_last_child: bool
enum LinuxDesktopEnv
Linux desktop environment for DE-specific styling
7 variants
Gnome
KDE
XFCE
Unity
Cinnamon
MATE
Other
struct SystemFonts
has destructor11 fields
ui_font: OptionString
ui_font_size: OptionF32
monospace_font: OptionString
monospace_font_size: OptionF32
ui_font_bold: OptionString
title_font: OptionString
title_font_size: OptionF32
small_font: OptionString
small_font_size: OptionF32
union enum DesktopEnvironment
has destructor3 variants
enum ScrollLogicalPosition
4 variants
Start
Center
End
Nearest
struct CaretWidth
1 field
inner: PixelValue
struct StyleTabSize
1 field
inner: PixelValue
struct GridTrackSizingVecSlice
2 fields
struct ContentGroupVecSlice
2 fields
struct StyledTextRunVecSlice
has destructor2 fields
struct CssRuleBlockVecSlice
has destructor2 fields
struct CascadeInfoVecSlice
2 fields
ptr: CascadeInfo
len: usize
struct NormalizedRadialColorStopVecSlice
2 fields
struct StyleFontFamilyVecSlice
has destructor2 fields
struct StyleFilterVecSlice
2 fields
struct StyleBackgroundSizeVecSlice
2 fields
struct StyleBackgroundContentVecSlice
has destructor2 fields
len: usize
struct CssDeclarationVecSlice
has destructor2 fields
ptr: CssDeclaration
len: usize
struct StyleBackgroundPositionVecSlice
2 fields
struct NormalizedLinearColorStopVecSlice
2 fields
ptr: NormalizedLinearColorStop
len: usize
struct CssPropertyWithConditionsVecSlice
has destructor2 fields
struct CssVecSlice
has destructor2 fields
struct StyleTransformVecSlice
2 fields
ptr: StyleTransform
len: usize
struct StyledNodeVecSlice
2 fields
struct ShapePointVecSlice
2 fields
struct StyleBackgroundRepeatVecSlice
2 fields
struct CssMockEnvironment
has destructor9 fields
theme: OptionThemeCondition
language: OptionString
os_version: OptionOsVersion
desktop_env: OptionLinuxDesktopEnv
viewport_width: OptionF32
viewport_height: OptionF32
prefers_reduced_motion: OptionBool
prefers_high_contrast: OptionBool
union enum ColorOrSystem
2 variants
Color(ColorU)
System(SystemColorRef)
enum SystemColorRef
9 variants
Text
Background
Accent
AccentText
ButtonFace
ButtonText
WindowBackground
SelectionBackground
SelectionText
struct SafeAreaInsets
Safe area insets for devices with notches, rounded corners, or sensor housings.
5 fields
top: OptionPixelValue
bottom: OptionPixelValue
left: OptionPixelValue
right: OptionPixelValue
keyboard: OptionPixelValue
enum ScrollbarTrackClick
2 variants
JumpToPosition
PageUpDown
enum SubpixelType
5 variants
None
Rgb
Bgr
VRgb
VBgr
struct ScrollbarPreferences
2 fields
visibility: ScrollbarVisibility
track_click: ScrollbarTrackClick
enum ScrollbarVisibility
3 variants
Always
WhenScrolling
Automatic
struct TextRenderingHints
4 fields
subpixel_type: SubpixelType
font_smoothing_gamma: u32
font_smoothing_enabled: bool
increased_contrast: bool
enum ToolbarStyle
4 variants
IconsOnly
TextOnly
TextBesideIcon
TextBelowIcon
struct AnimationMetrics
3 fields
struct GridAreaDefinition
has destructor5 fields
struct GridTemplateAreas
has destructor1 field
areas: GridAreaDefinitionVec
struct GridAreaDefinitionVecSlice
has destructor2 fields
union enum CssColorParseErrorOwned
has destructor13 variants
InvalidColor(String)
InvalidFunctionName(String)
InvalidColorComponent(u8)
IntValueParseErr(ParseIntError)
FloatValueParseErr(ParseFloatError)
FloatValueOutOfRange(f32)
MissingColorComponent(CssColorComponent)
ExtraArguments(String)
UnclosedColor(String)
EmptyInput
DirectionParseError(CssDirectionParseErrorOwned)
UnsupportedDirection(String)
InvalidPercentage(PercentageParseError)
union enum CssPixelValueParseErrorOwned
has destructor4 variants
EmptyString
NoValueGiven(PixelNoValueGivenError)
ValueParseErr(ParseFloatErrorWithInput)
InvalidPixelValue(String)
union enum CssBorderStyleParseErrorOwned
has destructor1 variant
InvalidStyle(String)
union enum StyleExclusionMarginParseErrorOwned
has destructor1 variant
FloatValue(String)
union enum JustifyContentParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum LayoutMarginParseErrorOwned
has destructor3 variants
union enum StyleTextColorParseErrorOwned
has destructor1 variant
ColorParseError(CssColorParseErrorOwned)
union enum AlignItemsParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum AlignContentParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleTabSizeParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutDisplayParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum AlignSelfParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct PercentageParseErrorWithInput
has destructor2 fields
error: PercentageParseError
input: String
union enum CssStylePerspectiveOriginParseErrorOwned
has destructor2 variants
WrongNumberOfComponents(WrongComponentCountError)
PixelValueParseError(CssPixelValueParseErrorOwned)
union enum TextJustifyParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum CssBackgroundParseErrorOwned
has destructor11 variants
Error(String)
InvalidBackground(ParenthesisParseErrorOwned)
UnclosedGradient(String)
NoDirection(String)
TooFewGradientStops(String)
DirectionParseError(CssDirectionParseErrorOwned)
GradientParseError(CssGradientStopParseErrorOwned)
ConicGradient(CssConicGradientParseErrorOwned)
ShapeParseError(CssShapeParseErrorOwned)
ImageParseError(CssImageParseErrorOwned)
ColorParseError(CssColorParseErrorOwned)
union enum JustifySelfParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleVisibilityParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum LayoutBoxSizingParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleTextIndentParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutClearParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleLetterSpacingParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum CssStyleFilterParseErrorOwned
has destructor14 variants
InvalidFilter(String)
InvalidParenthesis(ParenthesisParseErrorOwned)
Shadow(CssShadowParseErrorOwned)
BlendMode(InvalidValueErrOwned)
Color(CssColorParseErrorOwned)
Opacity(PercentageParseError)
Brightness(PercentageParseError)
Contrast(PercentageParseError)
Saturate(PercentageParseError)
Blur(CssStyleBlurParseErrorOwned)
ColorMatrix(CssStyleColorMatrixParseErrorOwned)
Offset(CssStyleFilterOffsetParseErrorOwned)
Composite(CssStyleCompositeFilterParseErrorOwned)
Angle(CssAngleValueParseErrorOwned)
union enum OpacityParseErrorOwned
has destructor2 variants
ParsePercentage(PercentageParseErrorWithInput)
OutOfRange(String)
union enum CssStyleTransformParseErrorOwned
has destructor7 variants
InvalidTransform(String)
InvalidParenthesis(ParenthesisParseErrorOwned)
WrongNumberOfComponents(WrongComponentCountError)
NumberParseError(ParseFloatError)
PixelValueParseError(CssPixelValueParseErrorOwned)
AngleValueParseError(CssAngleValueParseErrorOwned)
PercentageValueParseError(PercentageParseError)
union enum CssConicGradientParseErrorOwned
has destructor3 variants
union enum StyleTextDecorationParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum LayoutZIndexParseErrorOwned
has destructor2 variants
InvalidValue(String)
ParseInt(ParseIntErrorWithInput)
union enum StyleWhiteSpaceParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleDirectionParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleVerticalAlignParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum CssStyleCompositeFilterParseErrorOwned
has destructor3 variants
Invalid(InvalidValueErrOwned)
Float(ParseFloatError)
WrongNumberOfComponents(WrongComponentCountError)
union enum CssShapeParseErrorOwned
has destructor1 variant
ShapeErr(InvalidValueErrOwned)
union enum PercentageParseErrorOwned
has destructor3 variants
union enum LayoutPositionParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleHyphensParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum CssAngleValueParseErrorOwned
has destructor4 variants
EmptyString
NoValueGiven(AngleNoValueGivenError)
ValueParseErr(ParseFloatErrorWithInput)
InvalidAngle(String)
union enum LayoutFloatParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum ColumnRuleColorParseErrorOwned
has destructor1 variant
Color(CssColorParseErrorOwned)
union enum CssBorderSideParseErrorOwned
has destructor4 variants
InvalidDeclaration(String)
Width(CssPixelValueParseErrorOwned)
Style(CssBorderStyleParseErrorOwned)
Color(CssColorParseErrorOwned)
union enum FlexDirectionParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum CssStyleFontSizeParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum MixBlendModeParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum CssStyleFilterOffsetParseErrorOwned
has destructor2 variants
Pixel(CssPixelValueParseErrorOwned)
WrongNumberOfComponents(WrongComponentCountError)
union enum CssBackfaceVisibilityParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleHyphenationLanguageParseErrorOwned
has destructor1 variant
InvalidString(String)
union enum ColumnWidthParseErrorOwned
has destructor2 variants
InvalidValue(String)
PixelValue(CssPixelValueParseErrorOwned)
enum CombinedCssPropertyType
28 variants
BorderRadius
Overflow
OverscrollBehavior
Margin
Border
BorderLeft
BorderRight
BorderTop
BorderBottom
BorderColor
BorderStyle
BorderWidth
Padding
BoxShadow
BackgroundColor
BackgroundImage
Background
Flex
Grid
Gap
GridGap
Font
Columns
ColumnRule
GridArea
TextBox
InsetBlock
InsetInline
union enum StyleListStyleTypeParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum ColumnRuleWidthParseErrorOwned
has destructor1 variant
Pixel(CssPixelValueParseErrorOwned)
union enum CssGradientStopParseErrorOwned
has destructor4 variants
Error(String)
Percentage(PercentageParseErrorOwned)
Angle(CssAngleValueParseErrorOwned)
ColorParseError(CssColorParseErrorOwned)
union enum ColumnRuleStyleParseErrorOwned
has destructor1 variant
union enum CssFontStyleParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum LayoutWritingModeParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleWordSpacingParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum StyleUserSelectParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum CssShadowParseErrorOwned
has destructor3 variants
TooManyOrTooFewComponents(String)
ValueParseErr(CssPixelValueParseErrorOwned)
ColorParseError(CssColorParseErrorOwned)
union enum LayoutHeightParseErrorOwned
has destructor2 variants
PixelValue(CssPixelValueParseErrorOwned)
InvalidKeyword(String)
union enum JustifyItemsParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum BoxDecorationBreakParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum PageBreakParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleScrollbarColorParseErrorOwned
has destructor2 variants
InvalidValue(String)
Color(CssColorParseErrorOwned)
union enum StyleLineClampParseErrorOwned
has destructor2 variants
InvalidValue(String)
ZeroValue
union enum CssDirectionParseErrorOwned
has destructor5 variants
Error(String)
InvalidArguments(String)
ParseFloat(ParseFloatError)
CornerError(CssDirectionCornerParseErrorOwned)
AngleError(CssAngleValueParseErrorOwned)
union enum LayoutPaddingParseErrorOwned
has destructor3 variants
union enum BreakInsideParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleTextAlignParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum LayoutScrollbarWidthParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum CssStyleBlurParseErrorOwned
has destructor2 variants
Pixel(CssPixelValueParseErrorOwned)
TooManyComponents(String)
union enum LayoutOverflowParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum CssDirectionCornerParseErrorOwned
has destructor1 variant
InvalidDirection(String)
union enum LayoutWidthParseErrorOwned
has destructor2 variants
PixelValue(CssPixelValueParseErrorOwned)
InvalidKeyword(String)
union enum CssStyleColorMatrixParseErrorOwned
has destructor2 variants
Float(ParseFloatError)
WrongNumberOfComponents(WrongComponentCountError)
union enum CssBorderRadiusParseErrorOwned
has destructor2 variants
TooManyValues(String)
PixelValue(CssPixelValueParseErrorOwned)
union enum StyleHangingPunctuationParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum CssStyleTransformOriginParseErrorOwned
has destructor2 variants
WrongNumberOfComponents(WrongComponentCountError)
PixelValueParseError(CssPixelValueParseErrorOwned)
union enum CssBackgroundPositionParseErrorOwned
has destructor4 variants
NoPosition(String)
TooManyComponents(String)
FirstComponentWrong(CssPixelValueParseErrorOwned)
SecondComponentWrong(CssPixelValueParseErrorOwned)
union enum StyleListStylePositionParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct CssSyntaxInvalidAdvance
3 fields
struct CssStyleBorderRadiusParseErrorOwned
has destructor1 field
struct CssBorderParseErrorOwned
has destructor1 field
inner: CssBorderSideParseErrorOwned
union enum StyleBorderBottomRightRadiusParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum ColumnFillParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleBorderBottomLeftRadiusParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum ColumnSpanParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum LayoutMaxWidthParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum StyleBorderTopLeftRadiusParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutMinHeightParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutMinWidthParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum OrphansParseErrorOwned
has destructor2 variants
ParseInt(ParseIntErrorWithInput)
NegativeValue(String)
union enum LayoutMaxHeightParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum WidowsParseErrorOwned
has destructor2 variants
ParseInt(ParseIntErrorWithInput)
NegativeValue(String)
union enum StyleBorderTopRightRadiusParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
struct SvgTransform
6 fields
sx: f32
kx: f32
ky: f32
sy: f32
tx: f32
ty: f32
struct SvgFillStyle
7 fields
line_join: SvgLineJoin
miter_limit: f32
tolerance: f32
fill_rule: SvgFillRule
transform: SvgTransform
anti_alias: bool
high_quality_aa: bool
union enum ScrollbarVisibilityModeParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum ScrollbarFadeDurationParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum ScrollbarFadeDelayParseErrorOwned
has destructor1 variant
InvalidValue(String)
enum ScrollbarVisibilityMode
3 variants
Always
WhenScrolling
Auto
struct ScrollbarFadeDuration
1 field
ms: u32
struct ScrollbarFadeDelay
1 field
ms: u32
union enum StyleTextAlignLastParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleWordBreakParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleOverflowWrapParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleLineBreakParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
enum StyleLineBreak
5 variants
Auto
Loose
Normal
Strict
Anywhere
enum StyleTextAlignLast
7 variants
Auto
Start
End
Left
Right
Center
Justify
enum StyleOverflowWrap
3 variants
Normal
Anywhere
BreakWord
enum StyleWordBreak
4 variants
Normal
BreakAll
KeepAll
BreakWord
union enum StyleTextOrientationParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleObjectFitParseErrorOwned
has destructor1 variant
InvalidValue(String)
enum StyleTextOrientation
3 variants
Mixed
Upright
Sideways
enum StyleObjectFit
5 variants
Fill
Contain
Cover
None
ScaleDown
union enum StyleAspectRatioParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleObjectPositionParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct StyleObjectPosition
2 fields
horizontal: BackgroundPositionHorizontal
vertical: BackgroundPositionVertical
union enum StyleAspectRatio
2 variants
Auto
Ratio(AspectRatioValue)
union enum StyleAlignmentBaselineParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleUnicodeBidiParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleTextBoxEdgeParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleScrollbarGutterParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleTextBoxTrimParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleOverflowClipMarginParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum StyleDominantBaselineParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleInitialLetterWrapParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleInitialLetterAlignParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
enum StyleInitialLetterWrap
4 variants
None
First
All
Grid
struct StyleOverflowClipMargin
2 fields
clip_edge: VisualBox
inner: PixelValue
enum VisualBox
3 variants
ContentBox
PaddingBox
BorderBox
enum StyleInitialLetterAlign
4 variants
Auto
Alphabetic
Hanging
Ideographic
enum TextBoxEdgeOver
6 variants
Auto
Text
Cap
Ex
Ideographic
IdeographicInk
enum TextBoxEdgeUnder
5 variants
Auto
Text
Alphabetic
Ideographic
IdeographicInk
struct StyleTextBoxEdge
2 fields
over: TextBoxEdgeOver
under: TextBoxEdgeUnder
enum StyleAlignmentBaseline
8 variants
Baseline
TextBottom
Alphabetic
Ideographic
Middle
Central
Mathematical
TextTop
enum StyleDominantBaseline
9 variants
Auto
TextBottom
Alphabetic
Ideographic
Middle
Central
Mathematical
Hanging
TextTop
enum StyleTextBoxTrim
4 variants
None
TrimStart
TrimEnd
TrimBoth
enum StyleScrollbarGutter
3 variants
Auto
Stable
StableBothEdges
enum StyleUnicodeBidi
6 variants
Normal
Embed
Isolate
BidiOverride
IsolateOverride
Plaintext
enum MediaType
Media type for @media queries
3 variants
Screen
Print
All
enum OrientationType
Orientation type for responsive styling
2 variants
Portrait
Landscape
union enum CalcAstItem
7 variants
union enum OsVersionCondition
OS version condition for version-specific styling
7 variants
Min(OsVersion)
Max(OsVersion)
Exact(OsVersion)
DesktopEnvironment(LinuxDesktopEnv)
DesktopEnvMin(DesktopEnvVersion)
DesktopEnvMax(DesktopEnvVersion)
DesktopEnvExact(DesktopEnvVersion)
struct U16VecSlice
2 fields
Pointer to the slice data
ptr: u16
Number of elements in the slice
len: usize
struct AudioMetrics
2 fields
event_sounds_enabled: bool
input_feedback_sounds_enabled: bool
struct ScrollPhysics
Scroll physics configuration for momentum scrolling. Controls how scrolling feels - the 'weight' and 'friction' of the scroll.
11 fields
smooth_scroll_duration_ms: u32
deceleration_rate: f32
min_velocity_threshold: f32
max_velocity: f32
wheel_multiplier: f32
invert_direction: bool
overscroll_elasticity: f32
max_overscroll_distance: f32
bounce_back_duration_ms: u32
timer_interval_ms: u32
Spring duration (ms) for target-seeking scrolls that originate from a physical mouse wheel: each wheel click extends an absolute target and the scroll glides there with a short critically-damped spring (hard stop, no momentum tail). Other origins (programmatic scroll_to_animated, rubber-band) use bounce_back_duration_ms.
wheel_animate_bounce_ms: u32
struct TitlebarMetrics
has destructorMetrics for titlebar layout and window chrome. Provides information needed to correctly position custom titlebar content when using WindowDecorations::NoTitle (expanded title mode).
15 fields
Which side the window control buttons are on
button_side: TitlebarButtonSide
Which buttons are available
buttons: TitlebarButtons
Height of the titlebar in pixels
height: OptionPixelValue
Width reserved for window control buttons (close/min/max)
button_area_width: OptionPixelValue
Horizontal padding inside the titlebar
padding_horizontal: OptionPixelValue
Safe area insets for notched/rounded displays
safe_area: SafeAreaInsets
Title text font
title_font: OptionString
Title text font size
title_font_size: OptionF32
Title text font weight (400 = normal, 600 = semibold, 700 = bold)
title_font_weight: OptionU16
The titlebar's own background while the window HAS focus.
background_active: OptionColorU
The titlebar's background while the window does NOT have focus.
background_inactive: OptionColorU
Title text colour while focused.
text_active: OptionColorU
Title text colour while unfocused.
text_inactive: OptionColorU
Background a window-control button takes on hover.
button_hover_background: OptionColorU
Background the CLOSE button takes on hover - its own colour on every platform.
close_button_hover_background: OptionColorU
5 constructors
constructor windows:
constructor macos:
constructor linux_gnome:
constructor ios:
constructor android:
Windows-style titlebar (buttons on right)
macOS-style titlebar (buttons on left, traffic lights)
Linux GNOME-style titlebar
iOS-style safe area (for notched devices)
Android-style titlebar (action bar)
struct OsVersion
2 fields
os: OsFamily
version_id: u32
union enum DynamicSelector
has destructorDynamic selector for runtime CSS evaluation based on OS, media, container, theme, and pseudo-state
15 variants
Os(OsCondition)
OsVersion(OsVersionCondition)
Media(MediaType)
ViewportWidth(MinMaxRange)
ViewportHeight(MinMaxRange)
ContainerWidth(MinMaxRange)
ContainerHeight(MinMaxRange)
ContainerName(String)
Theme(ThemeCondition)
AspectRatio(MinMaxRange)
Orientation(OrientationType)
PrefersReducedMotion(BoolCondition)
PrefersHighContrast(BoolCondition)
PseudoState(PseudoStateType)
Language(LanguageCondition)
enum SystemMetricRef
Reference to a specific system metric value. These are resolved at runtime based on the user's system preferences. CSS syntax: system:button-padding, system:button-radius, etc.
11 variants
Button corner radius (system:button-radius)
ButtonRadius
Button horizontal padding (system:button-padding-horizontal)
ButtonPaddingHorizontal
Button vertical padding (system:button-padding-vertical)
ButtonPaddingVertical
Button border width (system:button-border-width)
ButtonBorderWidth
Titlebar height (system:titlebar-height)
TitlebarHeight
Titlebar button area width (system:titlebar-button-width)
TitlebarButtonWidth
Titlebar horizontal padding (system:titlebar-padding)
TitlebarPadding
Safe area top inset for notched devices (system:safe-area-top)
SafeAreaTop
Safe area bottom inset (system:safe-area-bottom)
SafeAreaBottom
Safe area left inset (system:safe-area-left)
SafeAreaLeft
Safe area right inset (system:safe-area-right)
SafeAreaRight
struct InvalidValueErrOwned
has destructor1 field
value: String
enum PseudoStateType
Pseudo-state type for element state conditions
14 variants
Normal
Hover
Active
Focus
SeatFocus
Disabled
CheckedTrue
CheckedFalse
FocusWithin
Visited
Backdrop
Dragging
DragOver
Placeholder
enum OsCondition
Operating system condition for OS-specific styling
8 variants
Any
Apple
MacOS
IOS
Linux
Windows
Android
Web
struct CalcAstItemVecSlice
2 fields
struct MinMaxRange
Min/Max range for numeric conditions (NaN = no limit)
2 fields
min: f32
max: f32
struct AspectRatioValue
2 fields
width: u32
height: u32
struct SystemMetrics
has destructor5 fields
corner_radius: OptionPixelValue
border_width: OptionPixelValue
The horizontal (left/right) padding for buttons and similar controls.
button_padding_horizontal: OptionPixelValue
The vertical (top/bottom) padding for buttons and similar controls.
button_padding_vertical: OptionPixelValue
Titlebar layout information (button positions, safe areas, etc.)
titlebar: TitlebarMetrics
struct F32VecSlice
2 fields
Pointer to the slice data
ptr: f32
Number of elements in the slice
len: usize
struct EmptyStruct
1 field
_reserved: u8
1 constructor
constructor create:
-> EmptyStruct
Create a new EmptyStruct value (FFI-safe replacement for
())struct U32VecSlice
2 fields
Pointer to the slice data
ptr: u32
Number of elements in the slice
len: usize
union enum BoxOrStatic
Enum that stores either a heap-allocated Box<T> or a *const T pointer to static data. Used to optimize CSS property values by storing compile-time constants as static pointers instead of heap allocations. Size: 16 bytes on 64-bit (1 tag + 7 padding + 8 pointer).
2 variants
Boxed(T)
Static(T)
struct VisualHints
5 fields
enum OsFamily
5 variants
Windows
MacOS
IOS
Linux
Android
enum BoolCondition
Boolean condition for accessibility preferences
2 variants
False
True
struct DynamicSelectorVecSlice
has destructor2 fields
struct U8VecSlice
2 fields
Pointer to the slice data
ptr: u8
Number of elements in the slice
len: usize
struct LinuxCustomization
has destructor5 fields
gtk_theme: OptionString
icon_theme: OptionString
cursor_theme: OptionString
cursor_size: u32
titlebar_button_layout: OptionString
union enum StyleClipRectParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum LayoutLeftParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutTopParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutInsetBottomParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
union enum LayoutRightParseErrorOwned
has destructor1 variant
PixelValue(CssPixelValueParseErrorOwned)
enum RelayoutReason
What triggered the current
layout()invocation.More
The framework re-invokes the layout callback for any change that may produce a structurally different DOM (resize across a CSS breakpoint, theme toggle, route switch, callback returning Update::RefreshDom). Read via
LayoutCallbackInfo.relayout_reason()so the callback can branch - for example, skip expensive analytics onResizecalls.6 variants
Initial
RefreshDom
Resize
ThemeChange
RouteChange
Other
enum SystemStyleDependency
Which facet of the OS style a
layout()callback read.More
An "appearance change" is never one event. The light/dark polarity flips, or the accent colour moves, or the UI font grows, or the icon theme is swapped, and each of those reaches a different app differently. Whether the change can alter what
layout()RETURNS depends entirely on what that callback read, and only the callback knows.LayoutCallbackInfo.depends_on_system_style()is how it says so; this enum is the vocabulary.Declare narrowly and a change outside what you declared costs a restyle instead of a full
Update::RefreshDom. Declaring nothing is read conservatively: the DOM is rebuilt on every system-style change.7 variants
The light/dark polarity alone (
LayoutCallbackInfo.get_theme()).Theme
The colour palette: text, background, accent, button, selection.
Colors
The UI fonts - family, size, weight.
Fonts
Sizing and spacing metrics: control sizes, scrollbar geometry, titlebar layout, input timings, focus ring.
Metrics
The icon theme and the icon styling options.
Icons
Accessibility and motion preferences - reduced motion, high contrast, animation speed.
Accessibility
Everything: the callback took the whole SystemStyle and the engine cannot see which parts of it were read. The conservative answer.
Everything
struct DesktopEnvVersion
2 fields
env: LinuxDesktopEnv
version_id: u32
enum GestureDirection
Dominant direction of a swipe gesture, used by
CallbackInfo::get_swipe_direction().4 variants
Up
Down
Left
Right
struct CssScopeRange
2 fields
start: usize
end: usize
union enum StyleTextTransformParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
enum StyleTextTransform
5 variants
None
Capitalize
Uppercase
Lowercase
FullWidth
enum ListType
3 variants
And
Or
Unit
struct CssPropertyVecSlice
2 fields
union enum StyleTextOverflowParseErrorOwned
has destructor1 variant
InvalidValue(String)
enum StyleTextOverflow
2 variants
Clip
Ellipsis
union enum StyleBaselineSourceParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
union enum StyleLineFitEdgeParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
enum StyleBaselineSource
3 variants
Auto
First
Last
enum StyleLineFitEdge
7 variants
Leading
Text
Cap
Ex
Ideographic
IdeographicInk
Alphabetic
enum Handedness
2 variants
RightHanded
LeftHanded
struct SystemAnimations
Configuration of the SYSTEM-driven animations: physics-based scrolling and the caret / selection tweens. Lives on
AppConfigso a platform or application can tune the feel without rebuilding azul. The scroll physics override is applied ON TOP of the platform-discoveredSystemStyleatApp::createtime (Nonekeeps the per-platform preset). Tween durations of 0 disable that tween (caret / selection jumps, the classic behavior). While a tween runs, caret blinking is suppressed (the caret stays solid while it moves).9 fields
caret_tween: CaretTweenCallback
selection_tween: SelectionTweenCallback
caret_tween_data: RefAny
selection_tween_data: RefAny
scroll_physics: OptionScrollPhysics
caret_tween_duration_ms: u32
selection_tween_duration_ms: u32
Focus-ring glide duration in ms. 0 (the DEFAULT) disables the ring entirely - zero visual change for existing apps. Opted-in apps get a focus outline that GLIDES between focused elements via the caret_tween interpolator; suppressed while a text-editing session owns focus.
focus_ring_duration_ms: u32
Whether scroll-caret-into-view glides via the scroll-physics spring (true, the Word feel) or jumps instantly (false; SystemAnimations::disabled() sets this for deterministic e2e screenshots).
caret_scroll_glide: bool
union enum AnimationTiming
Timing for animation / -azul-animation-in / -azul-animation-out: the CSS keywords, the engine's spring presets, and a custom cubic-bezier(...) point list (permille-encoded so the type stays Eq-capable). Native animation functions receive the DECLARED timing plus raw linear progress and own the math - AnimationTiming::evaluate is the one-call way to honour it.
9 variants
1 method
fn evaluate:
self
arg t: f32
-> f32
Eased progress for raw linear t - how a native animation function honours the CSS-requested timing.
struct KeyframeStop
One stop of a
@keyframesblock (from= 0,to= 1000,12.5%= 125). Permille rather than a float percentage so the type stays Eq-capable.2 fields
permille: u16
props: CssPropertyVec
struct AnimationFunction
has destructorA COMPONENT-ATTACHED native animation function: lives on the node's own NodeData (Dom::with_animation_callback / NodeData::add_animation_callback) - a sidebar widget ships its fly-out next to its own DOM, not in app-global state. Resolvable by NAME from that node's -azul-animation-in / -azul-animation-out, AFTER stylesheet @keyframes (the web mechanism stays the only default name source; there are no engine builtins).
3 fields
union enum AnimationIterationCount
How many times an animation plays.
Infiniteis what makes a CSS spinner expressible; presence EXITS clamp it to one run (an infinite exit would never reap its zombie).2 variants
Count(u16)
Infinite
struct AnimationTimingBezier
cubic-bezier(x1, y1, x2, y2) control points in PERMILLE (Eq-safe; CSS clamps x to [0,1] = 0..=1000, y may overshoot and is signed).
4 fields
x1: u16
y1: i16
x2: u16
y2: i16
struct StyleAnimationVecSlice
has destructor2 fields
union enum StyleAnimationParseErrorOwned
has destructor2 variants
Empty(String)
Duration(DurationParseErrorOwned)
enum StyleAppRegion
2 variants
NoDrag
Drag
struct NodePosition
2 fields
child_index: u32
text_byte: OptionU32
2 constructors
constructor before_child:
arg child_index: u32
-> NodePosition
constructor in_text_child:
arg child_index: u32
arg text_byte: u32
-> NodePosition
A pure structural boundary before child
child_index.A position inside the text child at
child_index.struct DocOpWrapRange
has destructor4 fields
struct DocOpUnwrapRange
2 fields
node: DomNodeId
at: NodePosition
union enum DocumentOperation
has destructor7 variants
SplitNode(DocOpSplitNode)
MergeNodes(DocOpMergeNodes)
InsertChildren(DocOpInsertChildren)
RemoveChildren(DocOpRemoveChildren)
ReplaceChildren(DocOpReplaceChildren)
WrapRange(DocOpWrapRange)
UnwrapRange(DocOpUnwrapRange)
enum OverscrollBehavior
3 variants
Auto
Contain
None
enum FocusDirection
4 variants
Up
Down
Left
Right
enum OverflowScrolling
2 variants
Auto
Touch
struct CompositionCursor
2 fields
begin: usize
end: usize
enum ExternalEventFilter
6 variants
Play
Pause
Ended
TimeUpdate
VolumeChange
MediaError
struct DocumentTextEditVecSlice
has destructor2 fields
mod widgets
209 typesDefault, built-in widgets (button, label, textinput, etc.)
struct Button
has destructor13 fields
label: String
image: OptionImageRef
icon: String
icon_dom: OptionDom
trailing_icon: String
button_type: ButtonType
container_style: OptionCssPropertyWithConditionsVec
label_style: OptionCssPropertyWithConditionsVec
image_style: OptionCssPropertyWithConditionsVec
icon_style: OptionCssPropertyWithConditionsVec
trailing_icon_style: OptionCssPropertyWithConditionsVec
on_click: OptionButtonOnClick
theme: OptionUiTheme
2 constructors
13 methods
fn dom:
self
-> Dom
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
-> Button
fn with_button_type:
self
arg button_type: ButtonType
-> Button
fn set_button_type:
&mut self
arg button_type: ButtonType
&mut self
-> Button
fn set_image:
&mut self
arg image: ImageRef
fn set_icon:
&mut self
arg icon: String
fn with_icon:
&mut self
arg icon: String
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Builder method to set the button type
Set the button type and update styling accordingly
Sets the leading icon name (empty string clears it).
Builder method to set the leading icon name.
Sets the trailing icon name (empty string clears it).
Builder method to set the trailing icon name.
Pick the widget theme. Unset (
None), the widget renders in the default theme (crate::widgets::themes::UiTheme::default()).[
Self::set_theme] for the builder chain.enum ButtonType
The semantic type/role of a button. Each type has distinct styling to indicate its purpose to the user.
8 variants
Default
Primary
Secondary
Success
Danger
Warning
Info
Link
struct TextInput
has destructor5 fields
text_input_state: TextInputStateWrapper
container_style: OptionCssPropertyWithConditionsVec
label_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
theme: OptionUiTheme
19 methods
fn dom:
self
-> Dom
fn with_placeholder:
fn with_text:
self
arg refany: RefAny
arg callback: TextInputOnTextInputCallback
-> TextInput
fn set_text:
&mut self
arg text: String
self
arg refany: RefAny
arg callback: TextInputOnFocusLostCallback
-> TextInput
fn set_placeholder:
&mut self
arg placeholder: String
&mut self
arg refany: RefAny
arg callback: TextInputOnTextInputCallback
&mut self
arg refany: RefAny
arg callback: TextInputOnVirtualKeyDownCallback
self
arg refany: RefAny
arg callback: TextInputOnVirtualKeyDownCallback
-> TextInput
&mut self
arg refany: RefAny
arg callback: TextInputOnFocusLostCallback
&mut self
arg style: CssPropertyWithConditionsVec
self
arg style: CssPropertyWithConditionsVec
-> TextInput
fn set_label_style:
&mut self
arg style: CssPropertyWithConditionsVec
fn with_label_style:
self
arg style: CssPropertyWithConditionsVec
-> TextInput
&mut self
-> TextInput
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Name this control for assistive technology.
Pick the widget theme. Unset (
None), the widget renders in the default theme (crate::widgets::themes::UiTheme::default()).[
Self::set_theme] for the builder chain.struct NumberInput
has destructor4 fields
number_input_state: NumberInputStateWrapper
text_input: TextInput
style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
constructor create:
arg input: f32
-> NumberInput
Creates a new
NumberInputwith the given initial value.15 methods
fn dom:
self
-> Dom
self
arg refany: RefAny
arg callback: NumberInputOnValueChangeCallback
-> NumberInput
self
arg refany: RefAny
arg callback: NumberInputOnFocusLostCallback
-> NumberInput
&mut self
arg refany: RefAny
arg callback: TextInputOnTextInputCallback
self
arg refany: RefAny
arg callback: TextInputOnTextInputCallback
-> NumberInput
&mut self
arg refany: RefAny
arg callback: TextInputOnVirtualKeyDownCallback
self
arg refany: RefAny
arg callback: TextInputOnVirtualKeyDownCallback
-> NumberInput
&mut self
arg refany: RefAny
arg callback: NumberInputOnFocusLostCallback
&mut self
arg refany: RefAny
arg callback: NumberInputOnValueChangeCallback
&mut self
arg style: CssPropertyWithConditionsVec
self
arg style: CssPropertyWithConditionsVec
-> NumberInput
fn set_label_style:
&mut self
arg style: CssPropertyWithConditionsVec
fn with_label_style:
self
arg style: CssPropertyWithConditionsVec
-> NumberInput
&mut self
-> NumberInput
self
arg name: String
-> NumberInput
Creates a new
NumberInputwith the given initial value. Name this control for assistive technology.struct CheckBox
has destructor5 fields
check_box_state: CheckBoxStateWrapper
theme: OptionUiTheme
container_style: OptionCssPropertyWithConditionsVec
content_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
7 methods
fn dom:
self
-> Dom
fn with_on_toggle:
self
arg data: RefAny
arg on_toggle: CheckBoxOnToggleCallback
-> CheckBox
fn set_on_toggle:
&mut self
arg data: RefAny
arg on_toggle: CheckBoxOnToggleCallback
&mut self
-> CheckBox
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Name this control for assistive technology.
Pick the widget theme. Unset (
None), the widget renders in the default theme (UiTheme::default()).[
Self::set_theme] for the builder chain.struct DropDown
has destructor8 fields
choices: StringVec
selected: usize
on_choice_change: OptionDropDownOnChoiceChange
wrapper_style: OptionCssPropertyWithConditionsVec
label_style: OptionCssPropertyWithConditionsVec
arrow_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
theme: OptionUiTheme
1 constructor
9 methods
fn dom:
self
-> Dom
self
arg data: RefAny
arg callback: DropDownOnChoiceChangeCallback
-> DropDown
&mut self
arg data: RefAny
arg callback: DropDownOnChoiceChangeCallback
&mut self
-> DropDown
fn with_selected:
self
arg index: usize
-> DropDown
fn set_selected:
&mut self
arg index: usize
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Builds the DOM tree for this drop-down widget.
Builder variant of [
Self::set_on_choice_change].Sets the callback invoked when the user selects a different choice.
Replaces
selfwith the default value and returns the original.Creates a new
DropDownwith the given choices and no callback. Name this control for assistive technology.Builder variant of [
Self::set_selected].Selects the choice at
index- what the trigger DISPLAYS.More
A drop-down is rebuilt from the host's state on every layout, so the host must write the index its
on_choice_changecallback was handed back here; otherwise the trigger keeps showing choice 0 no matter what the user picks (there was no setter at all, so this was the only possible outcome). An out-of-range index displays the empty string rather than panicking, the same as an empty choice list.Pick the widget theme. Unset (
None), the widget renders in the default theme (crate::widgets::themes::UiTheme::default()).[
Self::set_theme] for the builder chain.struct ColorInput
has destructor3 fields
color_input_state: ColorInputStateWrapper
style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
constructor create:
arg color: ColorU
-> ColorInput
Creates a new
ColorInputdisplaying the given color.5 methods
fn dom:
self
-> Dom
self
arg data: RefAny
arg callback: ColorInputOnValueChangeCallback
-> ColorInput
&mut self
arg data: RefAny
arg callback: ColorInputOnValueChangeCallback
&mut self
-> ColorInput
self
arg name: String
-> ColorInput
Converts this
ColorInputinto a styled [Dom] node with a click callback.Builder-style method to set the value-change callback.
Sets the callback invoked when the color value changes.
Replaces
selfwith a defaultColorInputand returns the previous value.Creates a new
ColorInputdisplaying the given color. Name this control for assistive technology.struct FileInput
has destructor6 fields
file_input_state: FileInputStateWrapper
default_text: String
image: OptionImageRef
container_style: OptionCssPropertyWithConditionsVec
label_style: OptionCssPropertyWithConditionsVec
image_style: OptionCssPropertyWithConditionsVec
1 constructor
constructor create:
arg path: OptionString
-> FileInput
6 methods
fn set_default_text:
&mut self
arg default_text: String
&mut self
arg refany: RefAny
arg callback: FileInputOnPathChangeCallback
self
arg refany: RefAny
arg callback: FileInputOnPathChangeCallback
-> FileInput
fn dom:
self
-> Dom
&mut self
-> FileInput
struct ProgressBar
has destructor5 fields
progressbar_state: ProgressBarState
height: PixelValue
bar_background: StyleBackgroundContentVec
container_background: StyleBackgroundContentVec
theme: OptionUiTheme
1 constructor
constructor create:
arg percent_done: f32
-> ProgressBar
Creates a new progress bar with the given completion percentage (0.0 to 100.0).
13 methods
fn dom:
self
-> Dom
fn update_progress:
arg callback_info: CallbackInfo
arg node_id: DomNodeId
arg percent_done: f32
-> bool
fn set_height:
&mut self
arg height: PixelValue
fn with_height:
self
arg height: PixelValue
-> ProgressBar
&mut self
arg background: StyleBackgroundContentVec
self
arg background: StyleBackgroundContentVec
-> ProgressBar
&mut self
arg background: StyleBackgroundContentVec
self
arg background: StyleBackgroundContentVec
-> ProgressBar
fn render_bar:
self
-> Dom
&mut self
-> ProgressBar
self
arg background: StyleBackgroundContentVec
-> ProgressBar
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
self
arg theme: UiTheme
-> ProgressBar
Build the widget: a
VirtualViewnode whose callback renders the bar (container div + filled bar + remaining space) into the node's bounds.More
The node carries the widget's private dataset, so
update_progresscan move the bar later WITHOUT a relayout - stamp a marker on the returnedDom(with_marker) to be able to find the node again from any callback.Update the percentage of the progress bar at
node_idwithout a relayout - the widget half of the inter-widget fast path.More
node_idis the widget's root node, typically resolved viaCallbackInfo::get_node_id_by_markerfrom a marker the app stamped onProgressBar::dom()during layout. The widget's PRIVATE dataset is updated and only this node'sVirtualViewis re-rendered in place (damage rect of just the bar; no full layout, no DOM diff, no app-data-model round trip).Returns
false(and changes nothing) whennode_iddoes not name a live progress bar. The value is clamped to 0..=100 when the bar renders.Renders the BARE progress bar (container div with the filled bar and the remaining empty space) - the tree the
VirtualViewcallback insidedom()returns on every re-render. Use it directly only when embedding the bar in a context that manages its own updates;dom()is the normal entry point.Replaces
selfwith a default (0%) progress bar, returning the previous value.Build the widget: a
VirtualViewnode (explicitly sized to [height](Self::height)) whose callback renders [render_bar] (Self::render_bar) into the node's bounds. The node carries the widget's private dataset so [update_progress](Self::update_progress) can find and mutate it later - see the module docs for the fast path.struct TextArea
has destructor5 fields
text_area_state: TextAreaStateWrapper
container_style: OptionCssPropertyWithConditionsVec
label_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
theme: OptionUiTheme
17 methods
fn dom:
self
-> Dom
fn with_placeholder:
fn with_text:
self
arg refany: RefAny
arg callback: TextAreaOnTextInputCallback
-> TextArea
fn set_text:
&mut self
arg text: String
fn set_placeholder:
&mut self
arg placeholder: String
&mut self
arg refany: RefAny
arg callback: TextAreaOnTextInputCallback
&mut self
arg refany: RefAny
arg callback: TextAreaOnFocusLostCallback
self
arg refany: RefAny
arg callback: TextAreaOnFocusLostCallback
-> TextArea
&mut self
arg style: CssPropertyWithConditionsVec
self
arg style: CssPropertyWithConditionsVec
-> TextArea
&mut self
-> TextArea
&mut self
arg refany: RefAny
arg callback: TextAreaOnVirtualKeyDownCallback
self
arg refany: RefAny
arg callback: TextAreaOnVirtualKeyDownCallback
-> TextArea
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Sets the (multi-line) text. Newlines in
textare preserved.Name this control for assistive technology.
Pick the widget theme. Unset (
None), the widget renders in the default theme (crate::widgets::themes::UiTheme::default()).[
Self::set_theme] for the builder chain.struct Frame
has destructor1 constructor
4 methods
fn dom:
self
-> Dom
fn set_flex_grow:
&mut self
arg flex_grow: f32
fn with_flex_grow:
self
arg flex_grow: f32
-> Frame
&mut self
-> Frame
Sets the flex-grow factor for the content area.
Builder-style setter for the flex-grow factor.
Replaces
selfwith a default frame and returns the original.struct Titlebar
has destructor11 fields
title: String
height: f32
font_size: f32
padding_left: f32
padding_right: f32
title_color: ColorU
The titlebar's own background; None = the caller styles it.
background_color: OptionColorU
The titlebar's background while the window is unfocused.
background_inactive: OptionColorU
Title text colour while the window is unfocused.
title_color_inactive: OptionColorU
Background a window-control button takes on hover.
button_hover_color: OptionColorU
Background the CLOSE button takes on hover.
close_hover_color: OptionColorU
4 constructors
constructor create:
constructor with_height:
constructor from_system_style:
arg title: String
arg system_style: SystemStyle
-> Titlebar
constructor from_system_style_csd:
arg title: String
arg system_style: SystemStyle
-> Titlebar
Create a titlebar with compile-time platform defaults.
More
Use [
Titlebar::from_system_style] when you have aSystemStyleavailable for pixel-perfect metrics.Create a titlebar with a custom height.
Create from a live [
SystemStyle] (for title-only mode, padding reserves space for OS-drawn buttons).Create from [
SystemStyle] for full CSD mode (no padding - the buttons are rendered as DOM children).5 methods
fn dom:
self
-> Dom
fn set_height:
&mut self
arg height: f32
fn set_title:
&mut self
arg title: String
&mut self
-> Titlebar
fn dom_with_buttons:
self
arg buttons: TitlebarButtons
arg button_side: TitlebarButtonSide
-> Dom
Title-only DOM (for
NoTitleAutoInject).More
The OS draws the native window-control buttons; this just renders a centred title with drag support.
Set the titlebar height.
Set the title text.
Swap this titlebar with a default instance, returning the old value.
Full-CSD DOM with close / minimize / maximize buttons.
More
Each button is a div with a
MouseDowncallback that callsmodify_window_state()- no special hooks needed.struct TabHeader
has destructor3 fields
6 methods
fn dom:
self
-> Dom
fn with_active_tab:
self
arg active_tab: usize
-> TabHeader
fn with_on_click:
self
arg refany: RefAny
arg on_click: TabOnClickCallback
-> TabHeader
fn set_active_tab:
&mut self
arg active_tab: usize
fn set_on_click:
&mut self
arg refany: RefAny
arg on_click: TabOnClickCallback
&mut self
-> TabHeader
struct ListView
has destructorList view, optionally able to lazy-load data
9 fields
Column names
columns: StringVec
Currently rendered rows. Note that the ListView does not have to render all rows at once, usually you'd only render the top 100 rows
rows: ListViewRowVec
Which column is the list view sorted by (default = None)?
sorted_by: OptionUsize
Offset to add to the rows used when layouting row positions during lazy-loaded scrolling. Also affects the scroll position
scroll_offset: PixelValueNoPercent
Height of the content, if not all rows are loaded
content_height: OptionPixelValueNoPercent
Context menu for the columns (usually opens a context menu to select which columns to show)
Indicates that this ListView is being lazily loaded, allows control over what happens when the user scrolls the ListView.
on_lazy_load_scroll: OptionListViewOnLazyLoadScroll
What to do when the user left-clicks the column (usually used for storing which column to sort by)
on_column_click: OptionListViewOnColumnClick
What to do when the user left-clicks a row (usually used for selecting the row depending on the state)
on_row_click: OptionListViewOnRowClick
18 methods
fn dom:
self
-> Dom
fn with_rows:
self
arg rows: ListViewRowVec
-> ListView
fn with_columns:
self
arg refany: RefAny
arg on_row_click: ListViewOnRowClickCallback
-> ListView
&mut self
-> ListView
fn set_columns:
&mut self
arg columns: StringVec
fn set_rows:
&mut self
arg rows: ListViewRowVec
fn with_sorted_by:
self
arg sorted_by: OptionUsize
-> ListView
fn set_sorted_by:
&mut self
arg sorted_by: OptionUsize
self
arg scroll_offset: PixelValueNoPercent
-> ListView
&mut self
arg scroll_offset: PixelValueNoPercent
self
arg content_height: PixelValueNoPercent
-> ListView
&mut self
arg content_height: PixelValueNoPercent
self
arg refany: RefAny
arg on_column_click: ListViewOnColumnClickCallback
-> ListView
&mut self
arg refany: RefAny
arg on_column_click: ListViewOnColumnClickCallback
fn set_on_row_click:
&mut self
arg refany: RefAny
arg on_row_click: ListViewOnRowClickCallback
struct TreeView
has destructor2 fields
root: TreeViewNode
on_node_click: OptionTreeViewOnNodeClick
1 constructor
constructor create:
arg root: TreeViewNode
-> TreeView
3 methods
fn dom:
self
-> Dom
self
arg data: RefAny
arg callback: TreeViewOnNodeClickCallback
-> TreeView
&mut self
arg data: RefAny
arg callback: TreeViewOnNodeClickCallback
struct TextInputState
has destructor5 fields
text: U32Vec
placeholder: OptionString
max_len: usize
selection: OptionTextInputSelection
cursor_pos: usize
struct Ribbon
has destructor6 fields
app_button: OptionRibbonAppButton
tabs: RibbonTabVec
active_tab: usize
on_tab_click: OptionRibbonOnTabClick
style: RibbonStyle
behavior: RibbonBehavior
1 constructor
constructor create:
arg tabs: RibbonTabVec
-> Ribbon
Creates a new ribbon with the given tabs, the first tab active and the Word 2013 default style.
13 methods
fn dom:
self
-> Dom
fn with_active_tab:
self
arg index: usize
-> Ribbon
self
arg data: RefAny
arg cb: RibbonOnTabClickCallback
-> Ribbon
fn set_active_tab:
&mut self
arg index: usize
fn set_on_tab_click:
&mut self
arg data: RefAny
arg cb: RibbonOnTabClickCallback
fn set_app_button:
&mut self
arg app_button: RibbonAppButton
fn with_app_button:
self
arg app_button: RibbonAppButton
-> Ribbon
fn set_style:
&mut self
arg style: RibbonStyle
fn with_style:
self
arg style: RibbonStyle
-> Ribbon
fn set_behavior:
&mut self
arg behavior: RibbonBehavior
fn with_behavior:
self
arg behavior: RibbonBehavior
-> Ribbon
fn dom_desktop:
self
-> Dom
fn dom_mobile:
self
-> Dom
Builds the ribbon DOM: the tab strip and the active tab's groups.
Builder method: sets the active tab (clamped) and returns
self.Builder method: registers a tab-click callback and returns
self.Sets the active tab by index, clamping to the last valid tab.
Registers a callback invoked when a tab is clicked.
Sets the application button ("FILE").
Builder method: sets the application button and returns
self.Replaces the whole style bundle.
Builder method: replaces the style bundle and returns
self.Replaces the self-driven behavior set (collapse, peek, gallery).
Builder method: replaces the behavior set and returns
self.Builds ONLY the desktop chrome (tab strip + content band), with no mobile nodes and no viewport conditions. Pair with [
Self::dom_mobile] by branching onLayoutCallbackInfo::viewport_bigger_thaninlayout()- the framework re-invokeslayout()on every resize, so crossing the breakpoint swaps the structure.Builds ONLY the touch chrome: the full-width active-tab button (tap opens the fullscreen tab picker, double-tap collapses the band), the scrollable group list on the dominant-hand side, and ONE visible group at a time (tapping a list entry swaps it in with no app relayout). See [
Self::dom_desktop] for the pairing contract.struct NumberInputState
4 fields
previous: f32
number: f32
min: f32
max: f32
struct Modal
has destructor5 fields
modal_state: ModalStateWrapper
title: String
content: Dom
show_close_button: bool
backdrop_style: OptionCssPropertyWithConditionsVec
1 constructor
12 methods
fn dom:
self
-> Dom
fn with_title:
fn with_content:
fn with_open:
self
arg open: bool
-> Modal
fn with_on_close:
self
arg data: RefAny
arg on_close: ModalOnCloseCallback
-> Modal
fn set_title:
&mut self
arg title: String
fn set_content:
&mut self
arg content: Dom
fn set_open:
&mut self
arg open: bool
fn set_close_button:
&mut self
arg show: bool
self
arg show: bool
-> Modal
fn set_on_close:
&mut self
arg data: RefAny
arg on_close: ModalOnCloseCallback
&mut self
-> Modal
Renders the modal into a [
Dom] subtree with the__azul-native-modalclass (the backdrop).Builder-style setter for the title.
Builder-style setter for the content.
Builder-style setter for the initial open state.
Builder-style setter for the close callback.
Sets the dialog title (empty = no title).
Replaces the content shown inside the panel.
Sets whether the dialog is currently open, recomputing the backdrop style.
Sets whether the "x" close button is shown.
Builder-style setter for the close-button flag.
Sets the close callback (invoked with the new state when "x" is clicked).
Replaces
selfwith a default (empty, closed) modal and returns the original.struct ComboBox
has destructor9 fields
combo_state: ComboBoxStateWrapper
placeholder: String
wrapper_style: OptionCssPropertyWithConditionsVec
field_style: OptionCssPropertyWithConditionsVec
text_style: OptionCssPropertyWithConditionsVec
arrow_style: OptionCssPropertyWithConditionsVec
option_style: OptionCssPropertyWithConditionsVec
list_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
2 constructors
constructor create_with_items:
constructor create:
-> ComboBox
Creates a new combobox with the given options (no callback, nothing typed).
Creates an empty combobox.
12 methods
fn dom:
self
-> Dom
fn with_on_select:
self
arg data: RefAny
arg on_select: ComboBoxOnSelectCallback
-> ComboBox
fn with_placeholder:
fn set_selected:
&mut self
arg selected: usize
fn with_selected:
self
arg selected: usize
-> ComboBox
fn set_text:
&mut self
arg text: String
fn with_text:
fn set_placeholder:
&mut self
arg placeholder: String
fn set_on_select:
&mut self
arg data: RefAny
arg on_select: ComboBoxOnSelectCallback
&mut self
-> ComboBox
&self
Renders the combobox into a [
Dom] subtree with the__azul-native-comboboxclass.Builder-style setter for the select callback.
Builder-style setter for the placeholder.
Sets the initially-selected option index.
Builder-style setter for the initially-selected index.
Sets the initial (editable) field text.
Builder-style setter for the initial field text.
Sets the greyed placeholder shown when the field is empty.
Sets the callback invoked when an option is selected.
Replaces
selfwith a default (empty) combobox and returns the original.Creates a new combobox with the given options (no callback, nothing typed). Name this control for assistive technology.
The field-text CSS this combobox renders with.
struct Slider
has destructor5 fields
theme: OptionUiTheme
slider_state: SliderStateWrapper
track_style: OptionCssPropertyWithConditionsVec
thumb_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
9 methods
fn dom:
self
-> Dom
self
arg data: RefAny
arg on_value_change: SliderOnValueChangeCallback
-> Slider
fn set_value:
&mut self
arg value: f32
fn with_value:
self
arg value: f32
-> Slider
&mut self
-> Slider
&mut self
arg data: RefAny
arg on_value_change: SliderOnValueChangeCallback
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Sets the current value (clamped to the range), recomputing the thumb position.
Builder-style setter for the current value.
Creates a slider with the given current value and
[min, max]range. Name this slider for assistive technology.More
Prefer this over patching the finished
Dom: the widget forwards it into the accessibility declaration it builds anyway, alongside the role and the live value, and knowing the name at build time is what lets the widget tell you when it is missing without crying wolf.Pick the widget theme. Unset (
None), the widget renders in the default theme (crate::widgets::themes::UiTheme::default()).struct Switch
has destructor5 fields
switch_state: SwitchStateWrapper
theme: OptionUiTheme
track_style: OptionCssPropertyWithConditionsVec
knob_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
7 methods
fn dom:
self
-> Dom
fn with_on_toggle:
self
arg data: RefAny
arg on_toggle: SwitchOnToggleCallback
-> Switch
&mut self
-> Switch
fn set_on_toggle:
&mut self
arg data: RefAny
arg on_toggle: SwitchOnToggleCallback
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Creates a new switch in the given on/off state with default styling. Name this control for assistive technology.
Pick the widget theme. Unset (
None), the widget renders in the default theme (UiTheme::default()).[
Self::set_theme] for the builder chain.struct RadioGroup
has destructor4 fields
radio_group_state: RadioGroupStateWrapper
options: StringVec
container_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
constructor create:
arg options: StringVec
-> RadioGroup
Creates a radio group from the given options, with the first one selected.
9 methods
&mut self
arg selected_index: usize
self
arg selected_index: usize
-> RadioGroup
fn set_horizontal:
&mut self
arg horizontal: bool
fn with_horizontal:
self
arg horizontal: bool
-> RadioGroup
&mut self
-> RadioGroup
fn set_on_change:
&mut self
arg data: RefAny
arg on_change: RadioGroupOnChangeCallback
fn with_on_change:
self
arg data: RefAny
arg on_change: RadioGroupOnChangeCallback
-> RadioGroup
fn dom:
self
-> Dom
self
arg name: String
-> RadioGroup
Sets the currently selected option index.
Builder-style setter for the selected option index.
Lays the options out horizontally (default is vertical).
Builder-style setter for the horizontal layout flag.
Creates a radio group from the given options, with the first one selected. Name this control for assistive technology.
struct Segmented
has destructor3 fields
segmented_state: SegmentedStateWrapper
labels: StringVec
container_style: OptionCssPropertyWithConditionsVec
1 constructor
6 methods
&mut self
arg selected_index: usize
self
arg selected_index: usize
-> Segmented
&mut self
-> Segmented
fn set_on_change:
&mut self
arg data: RefAny
arg on_change: SegmentedOnChangeCallback
fn with_on_change:
self
arg data: RefAny
arg on_change: SegmentedOnChangeCallback
-> Segmented
fn dom:
self
-> Dom
Sets the currently selected segment index.
Builder-style setter for the selected segment index.
struct Tooltip
has destructor4 fields
anchor: Dom
text: String
wrapper_style: OptionCssPropertyWithConditionsVec
tip_style: OptionCssPropertyWithConditionsVec
1 constructor
6 methods
fn set_text:
&mut self
arg text: String
fn with_text:
fn set_tip_style:
&mut self
arg style: CssPropertyWithConditionsVec
fn with_tip_style:
self
arg style: CssPropertyWithConditionsVec
-> Tooltip
&mut self
-> Tooltip
fn dom:
self
-> Dom
Sets the tip text.
Builder-style setter for the tip text.
Overrides the tip popup style.
Builder-style setter for the tip popup style.
struct Card
has destructor3 fields
1 constructor
8 methods
fn dom:
self
-> Dom
fn with_content:
fn with_on_click:
self
arg data: RefAny
arg on_click: CardOnClickCallback
-> Card
&mut self
-> Card
fn set_content:
&mut self
arg content: Dom
fn set_flex_grow:
&mut self
arg flex_grow: f32
fn with_flex_grow:
self
arg flex_grow: f32
-> Card
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: CardOnClickCallback
Builder-style setter for the body content.
Builder-style setter for the click callback.
Replaces
selfwith an empty default card and returns the original.Sets the body content.
Sets the flex-grow factor for the card container.
Builder-style setter for the flex-grow factor.
Sets the click callback, invoked when the card container is clicked.
struct Alert
has destructor5 fields
alert_state: AlertStateWrapper
message: String
kind: AlertKind
dismissible: bool
container_style: OptionCssPropertyWithConditionsVec
2 constructors
8 methods
fn dom:
self
-> Dom
fn with_dismissible:
self
arg dismissible: bool
-> Alert
fn with_on_dismiss:
self
arg data: RefAny
arg on_dismiss: AlertOnDismissCallback
-> Alert
fn set_kind:
&mut self
arg kind: AlertKind
fn with_alert_kind:
fn set_dismissible:
&mut self
arg dismissible: bool
fn set_on_dismiss:
&mut self
arg data: RefAny
arg on_dismiss: AlertOnDismissCallback
&mut self
-> Alert
Converts this alert into a DOM subtree with the
__azul-native-alertclass.Builder-style setter for the dismissible flag.
Builder-style setter for the dismiss callback (implies dismissible).
Sets the colour variant, recomputing the container style.
Builder-style setter for the colour variant.
Sets whether the alert shows a "x" close button.
Sets the dismiss callback. Implies
dismissible = trueso the close button is rendered.Replaces
selfwith a default (empty info) alert and returns the original.struct Accordion
has destructor2 fields
sections: AccordionSectionVec
on_toggle: OptionAccordionOnToggle
2 constructors
constructor create_with_sections:
arg sections: AccordionSectionVec
-> Accordion
constructor create:
-> Accordion
Creates a new accordion from the given sections, with no toggle callback.
Creates an empty accordion.
4 methods
fn set_on_toggle:
&mut self
arg data: RefAny
arg callback: AccordionOnToggleCallback
fn with_on_toggle:
self
arg data: RefAny
arg callback: AccordionOnToggleCallback
-> Accordion
&mut self
-> Accordion
fn dom:
self
-> Dom
Sets the callback invoked when any section header is toggled.
Builder method: sets the toggle callback.
Replaces
selfwith an empty default accordion and returns the original.Renders the accordion into a [
Dom] subtree.struct Chip
has destructor5 fields
chip_state: ChipStateWrapper
label: String
kind: ChipKind
removable: bool
container_style: OptionCssPropertyWithConditionsVec
2 constructors
10 methods
fn set_kind:
&mut self
arg kind: ChipKind
fn with_chip_kind:
fn set_removable:
&mut self
arg removable: bool
fn with_removable:
self
arg removable: bool
-> Chip
fn set_on_remove:
&mut self
arg data: RefAny
arg on_remove: ChipOnRemoveCallback
fn with_on_remove:
self
arg data: RefAny
arg on_remove: ChipOnRemoveCallback
-> Chip
&mut self
-> Chip
fn dom:
self
-> Dom
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ChipOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ChipOnClickCallback
-> Chip
Sets the colour variant, recomputing the container style.
Builder-style setter for the colour variant.
Sets whether the chip shows a "x" remove affordance.
Builder-style setter for the removable flag.
Sets the remove callback. Implies
removable = trueso the "x" is rendered.Builder-style setter for the remove callback (implies removable).
Replaces
selfwith an empty default chip and returns the original.Converts this chip into a DOM subtree with the
__azul-native-chipclass.Sets the click callback, invoked when the chip's label area is clicked.
Builder-style setter for the click callback.
struct MapWidget
has destructorMap widget - MVT tile + MapCSS -> SVG -> DOM (AzulMaps goal app, SUPER_PLAN_2 P3). Tile cache lives in a
RefAnydataset owned by aDatasetMergeCallbackso in-flight fetches and decoded SVG bytes survive relayout. Visible-tile grid is computed by an innerVirtualViewcallback running Web Mercator math.6 fields
layer: MapTileLayer
viewport: MapViewport
container_style: OptionCssPropertyWithConditionsVec
on_viewport_changed: OptionMapViewportChanged
on_pin_tap: OptionMapPinTap
on_mount: OptionMapMount
1 constructor
constructor create:
arg layer: MapTileLayer
-> MapWidget
15 methods
fn dom:
self
-> Dom
fn with_viewport:
self
arg viewport: MapViewport
-> MapWidget
fn with_on_pin_tap:
self
arg data: RefAny
arg callback: MapPinTapCallback
-> MapWidget
fn set_viewport:
&mut self
arg viewport: MapViewport
self
arg css: CssPropertyWithConditionsVec
-> MapWidget
self
arg data: RefAny
arg callback: MapViewportChangedCallback
-> MapWidget
&mut self
arg data: RefAny
arg callback: MapViewportChangedCallback
fn latlon_at_px:
arg viewport: MapViewport
arg px: LogicalPosition
arg container: LogicalSize
-> MapLatLon
fn px_at_latlon:
arg viewport: MapViewport
arg coord: MapLatLon
arg container: LogicalSize
fn set_on_pin_tap:
&mut self
arg data: RefAny
arg callback: MapPinTapCallback
fn with_theme:
fn with_pitch:
self
arg pitch_deg: f32
-> MapWidget
fn with_bearing:
self
arg bearing_deg: f32
-> MapWidget
fn with_on_mount:
self
arg data: RefAny
arg callback: MapMountCallback
-> MapWidget
fn set_on_mount:
&mut self
arg data: RefAny
arg callback: MapMountCallback
Construct the rendered
Dom. The returnedDomis a single<div>with: - AMapTileCacheRefAnydataset (initialised from this widget'sviewport+layer). - ADatasetMergeCallbackso the cache survives relayout. - AVirtualViewchild that re-renders the visible-tile grid on bounds change. - Mouse-down / mouse-move / mouse-up callbacks that pan the viewport while a drag is active (the widget owns the pan state viaMapTileCache::drag_anchor, so user code doesn't have to wire anything). - Pinch callbacks that zoom in / out.More
Tiles are fetched by the framework's built-in worker, which the map installs when it mounts. Without a registered worker the grid renders placeholders. Pools and limits for those fetches come from the
on_mounthook, never from here: building theDomonly describes the UI.Builder form of [
set_on_pin_tap](Self::set_on_pin_tap).Mutator: replace the viewport in place.
Builder form of [
set_on_viewport_changed](Self::set_on_viewport_changed).Set a hook fired when the user pans / zooms the map. The map owns its own pan/pinch state; this lets your app observe or persist the resulting
MapViewport.Project a screen pixel
px(relative to the map node's top-left, in a node of sizecontainer) to a lat/lon on the map atviewport. Small- angle Mercator (accurate at city zooms). Inverse of [px_at_latlon](Self::px_at_latlon). Exposed so apps don't reimplement the projection (e.g. to drop a pin where the user tapped).Inverse of [
latlon_at_px](Self::latlon_at_px): wherecoordlands in container pixels atviewport.Set a hook fired when the user taps the map (a press + release at ~the same point, no drag), with the tapped lat/lon.
Pick a look for the tile layer (see [
MapTheme]);Systemfollows the window's light / dark theme.Tilt the camera: 0 looks straight down, [
MAX_PITCH_DEG] is the steepest 3D view (clamped). Rendered as a perspective transform on the tile canvas; right-drag vertically changes it at runtime.Rotate the map (clockwise degrees, normalised to
-180..180). Right-drag horizontally or a rotate gesture changes it at runtime.Builder form of [
set_on_mount](Self::set_on_mount).Set a hook fired when the map is mounted. It receives the map's current [
MapSetup] and returns the one to use: this is where an app hands the map a sharedHttpClientorThreadPool. Without a hook every tile opens its own connection on its own thread.More
Runs again if the map is mounted again, e.g. after moving to another parent, so return the setup unchanged when there is nothing to change.
struct TreeViewNode
has destructor4 fields
1 constructor
constructor create:
arg label: String
-> TreeViewNode
4 methods
fn with_child:
self
arg child: TreeViewNode
-> TreeViewNode
fn with_expanded:
self
arg expanded: bool
-> TreeViewNode
fn add_child:
&mut self
arg child: TreeViewNode
fn with_selected:
self
arg selected: bool
-> TreeViewNode
struct CameraWidget
4 fields
config: CameraConfig
on_frame: OptionOnVideoFrame
consumers: FrameConsumerVec
on_consumer_frame: OptionOnConsumerFrame
1 constructor
constructor create:
arg config: CameraConfig
-> CameraWidget
Create a camera widget for the given capture config.
7 methods
fn dom:
self
-> Dom
fn with_on_frame:
self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
-> CameraWidget
fn set_on_frame:
&mut self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
fn add_consumer:
&mut self
arg consumer: FrameConsumer
fn with_consumer:
self
arg consumer: FrameConsumer
-> CameraWidget
&mut self
arg data: RefAny
arg on_consumer_frame: OnConsumerFrameCallback
self
arg data: RefAny
arg on_consumer_frame: OnConsumerFrameCallback
-> CameraWidget
Build the widget's DOM: a single
<img>node, fed by a background capture thread started on mount.Builder form of [
set_on_frame](Self::set_on_frame).Set a hook invoked with every captured frame - for live effects, saving frames into your data model, or sending them over the network (azul-meet). The backreference DI pattern (see
architecture.md).Register a consumer of the captured frames: every frame is cut to
consumer's size (off the main thread) and handed to theon_consumer_framehook withconsumer.id. The camera is opened at the smallest size covering every consumer and the tile, so "client Bob wants 500x200 while the local preview is 100x200" captures ONE 500x200 frame and samples it twice - nothing larger is captured, and nothing larger than asked is sent. A consumer with a zero size or the reserved preview id 0 is ignored.Builder form of [
add_consumer](Self::add_consumer).Set the hook that receives every consumer's cut of every captured frame (route on
frame.consumer.id; send Bob his, record the other).Builder form of [
set_on_consumer_frame](Self::set_on_consumer_frame).struct MicrophoneWidget
2 fields
config: AudioConfig
on_frame: OptionOnAudioFrame
1 constructor
constructor create:
arg config: AudioConfig
Create a microphone widget for the given capture config.
3 methods
fn with_on_frame:
self
arg data: RefAny
arg on_frame: OnAudioFrameCallback
fn set_on_frame:
&mut self
arg data: RefAny
arg on_frame: OnAudioFrameCallback
fn dom:
self
-> Dom
Builder form of [
set_on_frame](Self::set_on_frame).Set a hook invoked with every captured audio chunk - for saving, effects, or sending over the network (azul-meet). The backreference DI pattern (see
architecture.md).Build the widget's DOM: a single invisible node, fed by a background capture thread started on mount. Place it anywhere in your tree - the capture lives as long as the node is mounted (unmount stops it).
struct MapTileId
3 fields
z: u8
x: u32
y: u32
struct MapTileLayer
has destructor6 fields
2 methods
fn with_theme:
self
arg theme: MapTheme
-> MapTileLayer
&self
arg window_theme: WindowTheme
-> String
Pick a theme. Appends the licence credit of both its halves (where a design has one) to the attribution, so an app that shows
attributioncomplies with CC BY whichever way the window is themed.The MapCSS the tiles are decoded with under
window_theme: a non-emptystyle_cssalways wins; else the theme's sheet for that half; else the built-in palette (empty).struct MapViewport
5 fields
centre_lat_deg: f64
centre_lon_deg: f64
zoom: f32
bearing_deg: f32
pitch_deg: f32
struct ButtonOnClick
2 fields
data: RefAny
callback: ButtonOnClickCallback
struct FileInputStateWrapper
has destructor4 fields
inner: FileInputState
on_path_change: OptionFileInputOnPathChange
file_dialog_title: String
default_dir: OptionString
struct FileInputState
has destructor1 field
path: OptionString
struct FileInputOnPathChange
2 fields
data: RefAny
callback: FileInputOnPathChangeCallback
struct FileInputOnPathChangeCallback
2 fields
cb: FileInputOnPathChangeCallbackType
callable: OptionRefAny
struct CheckBoxStateWrapper
2 fields
Content (image or text) of this CheckBox, centered by default
inner: CheckBoxState
Optional: Function to call when the CheckBox is toggled
on_toggle: OptionCheckBoxOnToggle
struct CheckBoxOnToggle
2 fields
data: RefAny
callback: CheckBoxOnToggleCallback
struct CheckBoxState
1 field
checked: bool
struct DropDownOnChoiceChange
2 fields
data: RefAny
callback: DropDownOnChoiceChangeCallback
struct ColorInputStateWrapper
has destructor3 fields
struct ColorInputState
1 field
color: ColorU
struct ColorInputOnValueChange
2 fields
data: RefAny
callback: ColorInputOnValueChangeCallback
struct ColorInputOnValueChangeCallback
2 fields
cb: ColorInputOnValueChangeCallbackType
callable: OptionRefAny
struct TextInputStateWrapper
has destructor7 fields
inner: TextInputState
on_text_input: OptionTextInputOnTextInput
on_virtual_key_down: OptionTextInputOnVirtualKeyDown
on_focus_lost: OptionTextInputOnFocusLost
update_text_input_before_calling_focus_lost_fn: bool
update_text_input_before_calling_vk_down_fn: bool
cursor_animation: OptionTimerId
struct TextInputOnTextInput
2 fields
data: RefAny
callback: TextInputOnTextInputCallback
struct TextInputOnTextInputCallback
2 fields
cb: TextInputOnTextInputCallbackType
callable: OptionRefAny
struct TextInputOnFocusLost
2 fields
data: RefAny
callback: TextInputOnFocusLostCallback
struct TextInputOnFocusLostCallback
2 fields
cb: TextInputOnFocusLostCallbackType
callable: OptionRefAny
struct OnTextInputReturn
2 fields
update: Update
valid: TextInputValid
enum TextInputValid
2 variants
Yes
No
struct NumberInputStateWrapper
3 fields
inner: NumberInputState
on_value_change: OptionNumberInputOnValueChange
on_focus_lost: OptionNumberInputOnFocusLost
struct NumberInputOnValueChange
2 fields
data: RefAny
callback: NumberInputOnValueChangeCallback
struct NumberInputOnValueChangeCallback
2 fields
cb: NumberInputOnValueChangeCallbackType
callable: OptionRefAny
struct NumberInputOnFocusLost
2 fields
data: RefAny
callback: NumberInputOnFocusLostCallback
struct NumberInputOnFocusLostCallback
2 fields
cb: NumberInputOnFocusLostCallbackType
callable: OptionRefAny
struct ProgressBarState
2 fields
percent_done: f32
display_percentage: bool
struct TabOnClick
2 fields
data: RefAny
callback: TabOnClickCallback
struct ListViewRow
has destructorRow of the ListView
2 fields
Each cell is an opaque Dom object
cells: DomVec
Height of the row, if known beforehand
height: OptionPixelValueNoPercent
struct ListViewOnLazyLoadScroll
2 fields
data: RefAny
callback: ListViewOnLazyLoadScrollCallback
struct ListViewOnColumnClick
2 fields
data: RefAny
callback: ListViewOnColumnClickCallback
struct ListViewOnRowClick
2 fields
data: RefAny
callback: ListViewOnRowClickCallback
struct ListViewState
has destructor6 fields
columns: StringVec
sorted_by: OptionUsize
current_row_count: usize
scroll_offset: PixelValueNoPercent
current_scroll_position: LogicalPosition
current_content_height: LogicalSize
struct TabHeaderState
1 field
active_tab: usize
struct ListViewRowVecSlice
has destructor2 fields
struct TitlebarButtons
Which window control buttons are available in the titlebar.
4 fields
Close button is available
has_close: bool
Minimize button is available
has_minimize: bool
Maximize/zoom button is available
has_maximize: bool
Fullscreen button is available (macOS green button behavior)
has_fullscreen: bool
enum TitlebarButtonSide
Which side of the titlebar the window control buttons are on.
2 variants
Buttons are on the left (macOS default)
Left
Buttons are on the right (Windows, most Linux DEs)
Right
struct RibbonTab
has destructor3 fields
1 constructor
4 methods
fn add_group:
&mut self
arg group: RibbonGroup
fn with_group:
self
arg group: RibbonGroup
-> RibbonTab
fn set_style:
&mut self
arg style: CssPropertyWithConditionsVec
fn with_style:
self
arg style: CssPropertyWithConditionsVec
-> RibbonTab
Appends a group to this tab.
Builder method: appends a group and returns
self.Appends per-tab style properties to this tab's header, after the shared tab style (see
RibbonTab::style).Builder method: sets the per-tab header style and returns
self.struct RibbonOnTabClick
2 fields
data: RefAny
callback: RibbonOnTabClickCallback
struct TreeViewOnNodeClick
2 fields
data: RefAny
callback: TreeViewOnNodeClickCallback
struct RibbonTabVecSlice
has destructor2 fields
struct TreeViewNodeVecSlice
has destructor2 fields
struct ScreenCaptureWidget
4 fields
config: ScreenCaptureConfig
on_frame: OptionOnVideoFrame
consumers: FrameConsumerVec
on_consumer_frame: OptionOnConsumerFrame
1 constructor
constructor create:
arg config: ScreenCaptureConfig
Create a screencap widget for the given config.
7 methods
fn dom:
self
-> Dom
fn with_on_frame:
self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
fn set_on_frame:
&mut self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
fn add_consumer:
&mut self
arg consumer: FrameConsumer
fn with_consumer:
self
arg consumer: FrameConsumer
&mut self
arg data: RefAny
arg on_consumer_frame: OnConsumerFrameCallback
self
arg data: RefAny
arg on_consumer_frame: OnConsumerFrameCallback
Build the widget's DOM: a single
<img>node, fed by a background capture thread started on mount.Builder form of [
set_on_frame](Self::set_on_frame).Set a hook invoked with every captured frame - for live effects, saving frames into your data model, or sending them over the network (azul-meet). The backreference DI pattern (see
architecture.md).Register a consumer of the captured frames (see
CameraWidget::add_consumer- identical semantics: one capture at the covering size, one cut per consumer, same-id replaces).Builder form of [
add_consumer](Self::add_consumer).Set the hook that receives every consumer's cut of every captured frame (route on
frame.consumer.id).Builder form of [
set_on_consumer_frame](Self::set_on_consumer_frame).struct VideoWidget
has destructor4 fields
1 constructor
constructor create:
arg config: VideoConfig
-> VideoWidget
Create a video widget for the given config.
6 methods
fn dom:
self
-> Dom
fn with_on_frame:
self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
-> VideoWidget
fn with_frames:
self
arg frames: RefAny
-> VideoWidget
fn set_on_frame:
&mut self
arg data: RefAny
arg on_frame: OnVideoFrameCallback
fn with_on_mount:
self
arg data: RefAny
arg callback: VideoMountCallback
-> VideoWidget
fn set_on_mount:
&mut self
arg data: RefAny
arg callback: VideoMountCallback
Build the widget's DOM: an
<img>a background thread keeps fed.More
Replays pre-decoded
with_framesif given. Otherwise the widget streamsconfig.sourcethrough the runtime's decode worker, installed when the widget mounts; without one it shows the built-in test pattern. Pools for the decoder come from theon_mounthook, never from here: building theDomonly describes the UI.Builder form of [
set_on_frame](Self::set_on_frame).Replay a list of already-decoded frames instead of the built-in test pattern:
framesis a [RefAny] holding aVec<VideoFrame>. The background worker cycles them through the shared GL presenter (the samepresent_framepath the camera/screencap widgets use), so callers that decode a clip up front (e.g.decode_mp4_h264_bytes) get real pixels on screen. TheRefAnymust carry aVec<VideoFrame>, else playback is skipped and the test pattern shows instead.Set a hook invoked with every decoded frame - for live effects, saving frames into your data model, or sending them over the network (azul-meet). The backreference DI pattern (see
architecture.md).Builder form of [
set_on_mount](Self::set_on_mount).Set a hook fired when the widget is mounted. It receives the widget's current [
VideoSetup] and returns the one to use: this is where an app hands the decoder a sharedHttpClientorThreadPool. Without a hook the decoder downloads over its own connection on its own thread.More
The decoder runs for as long as the video plays, so a pool keeps one worker busy per playing video.
struct OnVideoFrame
2 fields
data: RefAny
callback: OnVideoFrameCallback
struct MapViewportChangedCallback
2 fields
cb: MapViewportChangedCallbackType
callable: OptionRefAny
struct MapViewportChanged
2 fields
data: RefAny
callback: MapViewportChangedCallback
struct MapLatLon
2 fields
lat_deg: f64
lon_deg: f64
struct OnAudioFrame
2 fields
data: RefAny
callback: OnAudioFrameCallback
struct SwitchState
1 field
checked: bool
struct SwitchOnToggle
2 fields
data: RefAny
callback: SwitchOnToggleCallback
struct SwitchStateWrapper
2 fields
inner: SwitchState
on_toggle: OptionSwitchOnToggle
struct Divider
has destructor2 fields
orientation: DividerOrientation
divider_style: OptionCssPropertyWithConditionsVec
2 constructors
constructor create:
-> Divider
constructor create_with_orientation:
arg orientation: DividerOrientation
-> Divider
Creates a new horizontal divider with default styling.
Creates a new divider with the given orientation and default styling.
4 methods
fn set_orientation:
&mut self
arg orientation: DividerOrientation
fn with_orientation:
self
arg orientation: DividerOrientation
-> Divider
&mut self
-> Divider
fn dom:
self
-> Dom
Sets the orientation, resetting the style to the matching default.
Builder-style setter for the orientation.
Replaces
selfwith a default horizontal divider and returns the original.Converts this divider into a DOM node with the
__azul-native-dividerclass.enum DividerOrientation
2 variants
Horizontal
Vertical
struct Badge
has destructor3 fields
2 constructors
4 methods
fn set_kind:
&mut self
arg kind: BadgeKind
fn with_badge_kind:
&mut self
-> Badge
fn dom:
self
-> Dom
Sets the colour variant, recomputing the style.
Builder-style setter for the colour variant.
Replaces
selfwith an empty default badge and returns the original.Converts this badge into a DOM text node with the
__azul-native-badgeclass.enum BadgeKind
6 variants
Default
Primary
Success
Danger
Warning
Info
struct SliderOnValueChange
2 fields
data: RefAny
callback: SliderOnValueChangeCallback
struct SliderState
3 fields
value: f32
min: f32
max: f32
struct SliderStateWrapper
3 fields
struct SegmentedState
1 field
selected_index: usize
struct SegmentedOnChange
2 fields
data: RefAny
callback: SegmentedOnChangeCallback
struct SegmentedStateWrapper
2 fields
inner: SegmentedState
on_change: OptionSegmentedOnChange
struct RadioGroupStateWrapper
3 fields
struct RadioGroupState
1 field
selected_index: usize
struct RadioGroupOnChange
2 fields
data: RefAny
callback: RadioGroupOnChangeCallback
struct TextAreaState
has destructor4 fields
struct TextAreaOnTextInput
2 fields
data: RefAny
callback: TextAreaOnTextInputCallback
struct TextAreaStateWrapper
has destructor5 fields
inner: TextAreaState
on_text_input: OptionTextAreaOnTextInput
on_focus_lost: OptionTextAreaOnFocusLost
update_text_area_before_calling_focus_lost_fn: bool
on_virtual_key_down: OptionTextAreaOnVirtualKeyDown
struct TextAreaOnFocusLost
2 fields
data: RefAny
callback: TextAreaOnFocusLostCallback
struct AlertOnDismiss
2 fields
data: RefAny
callback: AlertOnDismissCallback
enum AlertKind
4 variants
Info
Success
Warning
Danger
struct AlertStateWrapper
2 fields
inner: AlertState
on_dismiss: OptionAlertOnDismiss
struct AlertState
1 field
visible: bool
struct AccordionOnToggle
2 fields
data: RefAny
callback: AccordionOnToggleCallback
struct Avatar
has destructor5 fields
image: OptionImageRef
initials: String
size: AvatarSize
theme: OptionUiTheme
avatar_style: OptionCssPropertyWithConditionsVec
2 constructors
8 methods
fn set_image:
&mut self
arg image: ImageRef
fn with_image:
fn set_size:
&mut self
arg size: AvatarSize
fn with_size:
self
arg size: AvatarSize
-> Avatar
&mut self
-> Avatar
fn dom:
self
-> Dom
fn set_theme:
&mut self
arg theme: UiTheme
fn with_theme:
Sets the avatar image (shown instead of the initials).
Builder-style setter for the avatar image.
Sets the size variant, recomputing the style.
Builder-style setter for the size variant.
Replaces
selfwith a default (empty medium) avatar and returns the original.Converts this avatar into a DOM subtree with the
__azul-native-avatarclass.Sets the theme this avatar renders with.
enum AvatarSize
3 variants
Small
Medium
Large
struct ChipState
1 field
visible: bool
struct ChipStateWrapper
3 fields
enum ChipKind
6 variants
Default
Primary
Success
Danger
Warning
Info
struct ChipOnRemove
2 fields
data: RefAny
callback: ChipOnRemoveCallback
struct Spinner
has destructor4 fields
2 constructors
8 methods
fn set_size:
&mut self
arg size: isize
self
arg size: isize
-> Spinner
fn set_color:
&mut self
arg color: ColorU
fn with_color:
fn set_track_color:
&mut self
arg track_color: ColorU
fn with_track_color:
&mut self
-> Spinner
fn dom:
self
-> Dom
Sets the ring diameter (logical px), recomputing the style.
Builder-style setter for the ring diameter.
Sets the active-arc colour, recomputing the style.
Builder-style setter for the active-arc colour.
Sets the inactive "track" colour, recomputing the style.
Builder-style setter for the inactive "track" colour.
Replaces
selfwith a default spinner and returns the original.Converts this spinner into a single DOM node with the
__azul-native-spinnerclass.struct Popover
has destructor5 fields
popover_state: PopoverStateWrapper
anchor: Dom
content: Dom
wrapper_style: OptionCssPropertyWithConditionsVec
content_style: OptionCssPropertyWithConditionsVec
1 constructor
6 methods
fn set_open:
&mut self
arg open: bool
fn with_open:
self
arg open: bool
-> Popover
fn set_on_toggle:
&mut self
arg data: RefAny
arg on_toggle: PopoverOnToggleCallback
fn with_on_toggle:
self
arg data: RefAny
arg on_toggle: PopoverOnToggleCallback
-> Popover
&mut self
-> Popover
fn dom:
self
-> Dom
Sets whether the panel starts open, recomputing the panel style.
Builder-style setter for the initial open state.
Sets the toggle callback (invoked with the new state on every toggle).
Builder-style setter for the toggle callback.
Replaces
selfwith a default (empty) popover and returns the original.Renders the popover into a [
Dom] subtree with the__azul-native-popoverclass.struct PopoverOnToggle
2 fields
data: RefAny
callback: PopoverOnToggleCallback
struct PopoverState
1 field
open: bool
struct PopoverStateWrapper
2 fields
inner: PopoverState
on_toggle: OptionPopoverOnToggle
struct ComboBoxStateWrapper
has destructor3 fields
struct ComboBoxState
has destructor3 fields
struct ComboBoxOnSelect
2 fields
data: RefAny
callback: ComboBoxOnSelectCallback
struct ModalOnClose
2 fields
data: RefAny
callback: ModalOnCloseCallback
struct ModalState
1 field
open: bool
struct ModalStateWrapper
2 fields
inner: ModalState
on_close: OptionModalOnClose
struct ToastOnDismiss
2 fields
data: RefAny
callback: ToastOnDismissCallback
enum ToastKind
4 variants
Info
Success
Warning
Danger
struct Toast
has destructor5 fields
toast_state: ToastStateWrapper
message: String
kind: ToastKind
dismissible: bool
container_style: OptionCssPropertyWithConditionsVec
2 constructors
8 methods
fn dom:
self
-> Dom
fn with_dismissible:
self
arg dismissible: bool
-> Toast
fn with_on_dismiss:
self
arg data: RefAny
arg on_dismiss: ToastOnDismissCallback
-> Toast
fn set_kind:
&mut self
arg kind: ToastKind
fn with_toast_kind:
fn set_dismissible:
&mut self
arg dismissible: bool
fn set_on_dismiss:
&mut self
arg data: RefAny
arg on_dismiss: ToastOnDismissCallback
&mut self
-> Toast
Converts this toast into a DOM subtree with the
__azul-native-toastclass.Builder-style setter for the dismissible flag.
Builder-style setter for the dismiss callback (implies dismissible).
Sets the colour variant, recomputing the container style.
Builder-style setter for the colour variant.
Sets whether the toast shows a "x" close button.
Sets the dismiss callback. Implies
dismissible = trueso the close button is rendered.Replaces
selfwith a default (empty info) toast and returns the original.struct ToastStateWrapper
2 fields
inner: ToastState
on_dismiss: OptionToastOnDismiss
struct ToastState
1 field
visible: bool
struct BreadcrumbStateWrapper
2 fields
inner: BreadcrumbState
struct BreadcrumbState
1 field
selected_index: usize
struct Breadcrumb
has destructor3 fields
breadcrumb_state: BreadcrumbStateWrapper
labels: StringVec
container_style: OptionCssPropertyWithConditionsVec
1 constructor
constructor create:
arg labels: StringVec
-> Breadcrumb
Creates a breadcrumb from the given labels (the last is the current page).
4 methods
&mut self
-> Breadcrumb
fn dom:
self
-> Dom
struct Pagination
has destructor2 fields
pagination_state: PaginationStateWrapper
container_style: OptionCssPropertyWithConditionsVec
1 constructor
constructor create:
arg current_page: usize
arg total_pages: usize
-> Pagination
Creates a pager for
total_pagespages withcurrent_page(1-based) selected.current_pageis clamped into[1, total_pages.max(1)].6 methods
fn set_current_page:
&mut self
arg current_page: usize
self
arg current_page: usize
-> Pagination
&mut self
-> Pagination
fn set_on_change:
&mut self
arg data: RefAny
arg on_change: PaginationOnChangeCallback
fn with_on_change:
self
arg data: RefAny
arg on_change: PaginationOnChangeCallback
-> Pagination
fn dom:
self
-> Dom
Sets the current (1-based) page, clamped into
[1, total_pages].Builder-style setter for the current page.
struct PaginationOnChange
2 fields
data: RefAny
callback: PaginationOnChangeCallback
struct PaginationState
2 fields
current_page: usize
total_pages: usize
struct PaginationStateWrapper
2 fields
inner: PaginationState
on_change: OptionPaginationOnChange
struct StepperState
2 fields
current_step: usize
total_steps: usize
struct StepperOnStepChange
2 fields
data: RefAny
callback: StepperOnStepChangeCallback
struct StepperStateWrapper
2 fields
inner: StepperState
on_step_change: OptionStepperOnStepChange
struct Stepper
has destructor3 fields
stepper_state: StepperStateWrapper
labels: StringVec
container_style: OptionCssPropertyWithConditionsVec
1 constructor
6 methods
fn set_current_step:
&mut self
arg current_step: usize
self
arg current_step: usize
-> Stepper
&mut self
-> Stepper
&mut self
arg data: RefAny
arg on_step_change: StepperOnStepChangeCallback
self
arg data: RefAny
arg on_step_change: StepperOnStepChangeCallback
-> Stepper
fn dom:
self
-> Dom
Sets the current (zero-based) step, clamped into
[0, total_steps - 1].Builder-style setter for the current step.
struct SplitPane
has destructor4 fields
split_pane_state: SplitPaneStateWrapper
first: Dom
second: Dom
container_style: OptionCssPropertyWithConditionsVec
1 constructor
constructor create:
arg direction: SplitDirection
arg first: Dom
arg second: Dom
-> SplitPane
Creates a split pane with the two child
Doms, split 50/50.9 methods
fn set_ratio:
&mut self
arg ratio: f32
fn with_ratio:
self
arg ratio: f32
-> SplitPane
fn set_direction:
&mut self
arg direction: SplitDirection
fn with_direction:
self
arg direction: SplitDirection
-> SplitPane
self
arg css: CssPropertyWithConditionsVec
-> SplitPane
&mut self
-> SplitPane
fn set_on_resize:
&mut self
arg data: RefAny
arg on_resize: SplitPaneOnResizeCallback
fn with_on_resize:
self
arg data: RefAny
arg on_resize: SplitPaneOnResizeCallback
-> SplitPane
fn dom:
self
-> Dom
Sets the first-pane fraction, clamped into
[MIN_RATIO, MAX_RATIO].Builder-style setter for the first-pane fraction.
Sets the orientation (also refreshes the default container style).
Builder-style setter for the orientation.
Replaces the default container style.
enum SplitDirection
2 variants
Horizontal
Vertical
struct SplitPaneStateWrapper
5 fields
inner: SplitPaneState
on_resize: OptionSplitPaneOnResize
is_dragging: bool
drag_start_px: f32
ratio_at_drag_start: f32
struct SplitPaneOnResize
2 fields
data: RefAny
callback: SplitPaneOnResizeCallback
struct SplitPaneState
2 fields
direction: SplitDirection
ratio: f32
struct DatePicker
has destructor3 fields
state: DatePickerStateWrapper
container_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
constructor create:
arg year: u32
arg month: u32
arg day: u32
-> DatePicker
Creates a new
DatePickershowingyear/monthwithdayselected.monthis clamped to1..=12anddayto1..=days_in_month.5 methods
fn set_on_change:
&mut self
arg data: RefAny
arg callback: DatePickerOnChangeCallback
fn with_on_change:
self
arg data: RefAny
arg callback: DatePickerOnChangeCallback
-> DatePicker
&mut self
-> DatePicker
fn dom:
self
-> Dom
self
arg name: String
-> DatePicker
Sets the callback invoked when the selection or month changes.
Builder variant of [
Self::set_on_change].Replaces
selfwith the default value and returns the original.Creates a new
DatePickershowingyear/monthwithdayselected.monthis clamped to1..=12anddayto1..=days_in_month. Name this control for assistive technology.struct DatePickerStateWrapper
2 fields
inner: DatePickerState
on_change: OptionDatePickerOnChange
struct DatePickerState
3 fields
year: u32
month: u32
day: u32
struct DatePickerOnChange
2 fields
data: RefAny
callback: DatePickerOnChangeCallback
struct TimePicker
has destructor3 fields
state: TimePickerStateWrapper
container_style: OptionCssPropertyWithConditionsVec
accessibility_name: OptionString
1 constructor
constructor create:
arg hour: u32
arg minute: u32
-> TimePicker
Creates a new 24-hour
TimePickerwith the given initial hour (0..=23) and minute (0..=59), both clamped into range.9 methods
fn set_24h:
&mut self
arg is_24h: bool
fn with_24h:
self
arg is_24h: bool
-> TimePicker
fn set_pm:
&mut self
arg is_pm: bool
fn with_pm:
self
arg is_pm: bool
-> TimePicker
fn set_on_change:
&mut self
arg data: RefAny
arg callback: TimePickerOnChangeCallback
fn with_on_change:
self
arg data: RefAny
arg callback: TimePickerOnChangeCallback
-> TimePicker
&mut self
-> TimePicker
fn dom:
self
-> Dom
self
arg name: String
-> TimePicker
Switches between 24-hour (no AM/PM) and 12-hour (with AM/PM) display, re-clamping the hour into the new range.
Builder variant of [
Self::set_24h].Sets the AM/PM flag (only meaningful in 12-hour mode).
Builder variant of [
Self::set_pm].Sets the callback invoked when any value changes.
Builder variant of [
Self::set_on_change].Replaces
selfwith the default value and returns the original.Creates a new 24-hour
TimePickerwith the given initial hour (0..=23) and minute (0..=59), both clamped into range. Name this control for assistive technology.struct TimePickerOnChange
2 fields
data: RefAny
callback: TimePickerOnChangeCallback
struct TimePickerState
4 fields
hour: u32
minute: u32
is_pm: bool
is_24h: bool
struct TimePickerStateWrapper
2 fields
inner: TimePickerState
on_change: OptionTimePickerOnChange
struct TextAreaOnTextInputCallback
2 fields
cb: TextAreaOnTextInputCallbackType
callable: OptionRefAny
struct AccordionSectionVecSlice
has destructor2 fields
struct ChipOnClick
2 fields
data: RefAny
callback: ChipOnClickCallback
struct CardOnClick
2 fields
data: RefAny
callback: CardOnClickCallback
struct RibbonGalleryOnSelect
2 fields
data: RefAny
callback: RibbonGalleryOnSelectCallback
enum RibbonArrow
3 variants
None
Menu
Split
struct RibbonGallery
has destructor3 fields
1 constructor
constructor create:
arg cells: RibbonGalleryCellVec
Creates a gallery from its cells; cell 0 is selected.
3 methods
fn with_selected:
self
arg selected: usize
fn set_on_select:
&mut self
arg data: RefAny
arg on_select: RibbonGalleryOnSelectCallback
fn with_on_select:
self
arg data: RefAny
arg on_select: RibbonGalleryOnSelectCallback
Builder method: sets the selected cell index and returns
self.Sets the cell-click callback.
Builder method: sets the cell-click callback and returns
self.struct RibbonRow
has destructor1 field
items: RibbonItemVec
2 methods
fn add_item:
&mut self
arg item: RibbonItem
fn with_item:
self
arg item: RibbonItem
-> RibbonRow
Appends an item to this row.
Builder method: appends an item and returns
self.struct RibbonColumn
has destructor1 field
items: RibbonItemVec
1 constructor
constructor create:
-> RibbonColumn
Creates an empty column.
2 methods
fn add_item:
&mut self
arg item: RibbonItem
fn with_item:
self
arg item: RibbonItem
-> RibbonColumn
Appends an item to this column.
Builder method: appends an item and returns
self.union enum RibbonItem
has destructor10 variants
LargeButton(RibbonButton)
SmallButton(RibbonButton)
Column(RibbonColumn)
Row(RibbonRow)
Combo(ComboBox)
Drop(DropDown)
Check(CheckBox)
Gallery(RibbonGallery)
Separator
Custom(Dom)
struct RibbonGroup
has destructor4 fields
1 constructor
constructor create:
arg label: String
-> RibbonGroup
Creates a new group with the given caption and no items.
5 methods
fn with_fills_space:
self
arg fills_space: bool
-> RibbonGroup
fn add_item:
&mut self
arg item: RibbonItem
fn with_item:
self
arg item: RibbonItem
-> RibbonGroup
fn set_launcher:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_launcher:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
-> RibbonGroup
Builder method: makes this group absorb the remaining ribbon width.
Appends an item to this group.
Builder method: appends an item and returns
self.Sets the dialog-box-launcher callback (renders the launcher button).
Builder method: sets the launcher callback and returns
self.struct RibbonButton
has destructor5 fields
1 constructor
constructor create:
arg icon: String
arg label: String
-> RibbonButton
Creates a plain button with an icon and a label (both may be empty).
4 methods
fn with_arrow:
self
arg arrow: RibbonArrow
-> RibbonButton
fn with_toggled:
self
arg toggled: bool
-> RibbonButton
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
-> RibbonButton
Builder method: sets the arrow decoration and returns
self.Builder method: sets the toggled state and returns
self.Sets the click callback.
Builder method: sets the click callback and returns
self.struct RibbonStyle
has destructor45 fields
theme: RibbonTheme
handedness: Handedness
container_style: OptionCssPropertyWithConditionsVec
tab_bar_style: OptionCssPropertyWithConditionsVec
app_button_style: OptionCssPropertyWithConditionsVec
tab_style: OptionCssPropertyWithConditionsVec
tab_active_style: OptionCssPropertyWithConditionsVec
tab_filler_style: OptionCssPropertyWithConditionsVec
content_style: OptionCssPropertyWithConditionsVec
group_style: OptionCssPropertyWithConditionsVec
group_items_style: OptionCssPropertyWithConditionsVec
group_label_style: OptionCssPropertyWithConditionsVec
launcher_button_style: OptionCssPropertyWithConditionsVec
launcher_icon_style: OptionCssPropertyWithConditionsVec
column_style: OptionCssPropertyWithConditionsVec
row_style: OptionCssPropertyWithConditionsVec
separator_style: OptionCssPropertyWithConditionsVec
large_button_style: OptionCssPropertyWithConditionsVec
large_icon_style: OptionCssPropertyWithConditionsVec
large_label_style: OptionCssPropertyWithConditionsVec
small_button_style: OptionCssPropertyWithConditionsVec
small_icon_style: OptionCssPropertyWithConditionsVec
small_label_style: OptionCssPropertyWithConditionsVec
arrow_icon_style: OptionCssPropertyWithConditionsVec
checked_style: OptionCssPropertyWithConditionsVec
gallery_frame_style: OptionCssPropertyWithConditionsVec
gallery_strip_style: OptionCssPropertyWithConditionsVec
gallery_cell_style: OptionCssPropertyWithConditionsVec
gallery_cell_selected_style: OptionCssPropertyWithConditionsVec
gallery_cell_label_style: OptionCssPropertyWithConditionsVec
gallery_spinner_style: OptionCssPropertyWithConditionsVec
gallery_wrapper_style: OptionCssPropertyWithConditionsVec
gallery_panel_style: OptionCssPropertyWithConditionsVec
mobile_tab_button_style: OptionCssPropertyWithConditionsVec
mobile_tab_label_style: OptionCssPropertyWithConditionsVec
mobile_tab_arrow_style: OptionCssPropertyWithConditionsVec
mobile_tab_overlay_style: OptionCssPropertyWithConditionsVec
mobile_tab_overlay_item_style: OptionCssPropertyWithConditionsVec
mobile_group_list_style: OptionCssPropertyWithConditionsVec
mobile_group_list_item_style: OptionCssPropertyWithConditionsVec
mobile_group_list_item_selected_style: OptionCssPropertyWithConditionsVec
gallery_spinner_button_style: OptionCssPropertyWithConditionsVec
gallery_spinner_icon_style: OptionCssPropertyWithConditionsVec
4 constructors
constructor office_2013:
-> RibbonStyle
constructor from_theme:
arg theme: RibbonTheme
-> RibbonStyle
constructor from_system:
arg style: SystemStyle
-> RibbonStyle
constructor from_theme_handed:
arg theme: RibbonTheme
arg handedness: Handedness
-> RibbonStyle
The Word 2013 look (white chrome, #2B579A accents) - the default.
Derives every part style from the given palette. This is the styling override API: build a [
RibbonTheme] (or start from a preset), then replace individual*_stylefields for finer control.Derives the ribbon style from the OS theme (see [
RibbonTheme::from_system]). PassSystemStyle::detect()for the live system look, e.g. to render a "system native" ribbon.[
Self::from_theme] with an explicit hand: the mobile group list sits on the dominant-hand side so the thumb reaches it. Independent of text direction - see [Handedness].2 methods
fn styled_combo_box:
&self
Returns a [
ComboBox] with this ribbon's field look injected through the combobox's public style fields (flat 1px #ABABAB border, 22px field, 12px text - the Word 2013 font-name/font-size pickers).widthis the total field width in px. Demonstrates (and exercises) the widget style-injection API; tweak the returned combobox further by replacing any of its*_stylefields.The
container_stylethis bundle renders with: the caller's override if there is one, else derived from [Self::theme].struct RibbonAppButton
has destructor2 fields
label: String
on_click: OptionButtonOnClick
1 constructor
2 methods
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
Sets the click callback.
Builder method: sets the click callback and returns
self.struct RibbonItemVecSlice
has destructor2 fields
struct RibbonGalleryCellVecSlice
has destructor2 fields
struct RibbonGroupVecSlice
has destructor2 fields
struct RibbonTheme
16 fields
Chrome background: the ribbon's own surfaces (root, tab bar, tabs) and the control fills that match them.
chrome_bg: ColorU
The tab-content band behind the groups, separately from chrome_bg so an app can paint the two differently: a window whose background is a gradient wants the chrome TRANSPARENT, so the gradient runs unbroken from the title bar down, and the content band as a translucent overlay on it rather than an opaque slab that cuts it.
More
Defaults to chrome_bg in every constructor, so a theme that says nothing looks exactly as it did.
content_bg: ColorU
accent: ColorU
accent_hover: ColorU
accent_text: ColorU
text: ColorU
label: ColorU
icon: ColorU
border: ColorU
separator: ColorU
hover_bg: ColorU
hover_border: ColorU
pressed_bg: ColorU
checked_bg: ColorU
selected_bg: ColorU
field_border: ColorU
2 constructors
constructor office_2013:
-> RibbonTheme
constructor from_system:
arg style: SystemStyle
-> RibbonTheme
The Word 2013 palette: white chrome, #2B579A accents, #CDE6F7 hovers.
Extracts a ribbon palette from the OS theme (accent color, selection colors, separators). Colors the platform does not report fall back to the Word 2013 palette. Pass
SystemStyle::detect()for the live system theme, or a presetSystemStylefor platform mockups.struct RibbonBehavior
5 fields
collapsible: bool
peek_on_hover: bool
auto_select_gallery: bool
expandable_gallery: bool
mobile_tab_overlay: bool
2 constructors
constructor office_2013:
constructor inert:
All Word behaviors enabled - the default.
Every self-driven behavior off: the ribbon only forwards events to the application callbacks and never patches its own chrome.
struct ZombieFrame
One frame of a native presence animation. Absolute values, not deltas: translation in logical px about the node's origin, opacity (0.0 skips the node), an optional absolute painted width (left-anchored narrowing for exits) and whether to clip the exit to its frozen rect.
5 fields
struct KeyframeStopVecSlice
2 fields
struct KeyframesVecSlice
has destructor2 fields
struct ConsumerFrame
has destructor2 fields
consumer: FrameConsumer
frame: VideoFrame
1 constructor
constructor create:
arg consumer: FrameConsumer
arg frame: VideoFrame
Pair a cut frame with the consumer it was cut for.
struct OnConsumerFrame
2 fields
data: RefAny
callback: OnConsumerFrameCallback
struct FrameConsumerVecSlice
2 fields
struct QuickAccessTheme
7 fields
1 constructor
constructor from_system:
arg style: SystemStyle
Extracts a band palette from the OS theme.
More
The quick-access band IS the window's titlebar in an app that draws its own chrome, so it reads the OS TITLEBAR colours first (
SystemMetrics.titlebar, which every desktop keeps separately from the window background) and falls back to the general palette, then to that field's own Office-2013 value. One system colour per field, no colour arithmetic.struct QuickAccessBar
has destructor13 fields
style: QuickAccessStyle
leading: OptionDom
on_minimize: OptionButtonOnClick
on_maximize: OptionButtonOnClick
on_close: OptionButtonOnClick
title: String
actions: QuickAccessActionVec
trailing_actions: QuickAccessActionVec
show_minimize: bool
show_maximize: bool
show_close: bool
top_inset: f32
2 constructors
constructor create:
arg title: String
constructor office_2013:
arg title: String
Creates a band with the given title, no actions and all three window buttons, in the the Office-2013-era look style.
The the Office-2013-era look band: save / undo / redo quick-access actions (inert until callbacks are set), the customize chevron, and help before the window buttons.
6 methods
fn with_leading:
self
arg leading: Dom
fn with_actions:
self
arg actions: QuickAccessActionVec
self
arg trailing_actions: QuickAccessActionVec
fn with_style:
self
arg style: QuickAccessStyle
fn dom:
self
-> Dom
fn with_top_inset:
self
arg top_inset: f32
Builder method: sets the leading content.
Builder method: replaces the quick-access actions.
Builder method: replaces the trailing actions.
Builder method: replaces the style bundle.
Renders the band.
Sets the safe-area inset above the band - see [
Self::top_inset].struct QuickAccessAction
has destructor2 fields
icon: String
on_click: OptionButtonOnClick
2 methods
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
Sets the click callback.
Builder method: sets the click callback and returns
self.struct QuickAccessStyle
has destructor10 fields
theme: QuickAccessTheme
bar_style: OptionCssPropertyWithConditionsVec
leading_style: OptionCssPropertyWithConditionsVec
action_button_style: OptionCssPropertyWithConditionsVec
action_icon_style: OptionCssPropertyWithConditionsVec
title_style: OptionCssPropertyWithConditionsVec
window_button_style: OptionCssPropertyWithConditionsVec
window_icon_style: OptionCssPropertyWithConditionsVec
close_button_style: OptionCssPropertyWithConditionsVec
2 constructors
constructor from_system:
arg style: SystemStyle
constructor from_theme:
arg theme: QuickAccessTheme
Every part style, derived from the OS theme - see
QuickAccessTheme.from_system.Derives every part style from the given palette. Pair with
QuickAccessTheme.from_systemto take the desktop's neutrals and then re-assert an app's own brand colours.1 method
&self
The
bar_stylethis bundle renders with: the caller's override if there is one, else derived from [Self::theme].struct StatusBarViewSwitcher
has destructor3 fields
2 constructors
constructor create:
arg views: StatusBarViewVec
constructor office_2013:
Creates a view switcher with the given views; view 0 is active.
The the Office-2013-era look trio: read mode, print layout (active), web layout.
3 methods
fn with_active_view:
self
arg active_view: usize
fn set_on_select:
&mut self
arg data: RefAny
arg on_select: StatusBarOnViewSelectCallback
fn with_on_select:
self
arg data: RefAny
arg on_select: StatusBarOnViewSelectCallback
Builder method: sets the active view index.
Sets the view-select callback.
Builder method: sets the view-select callback and returns
self.struct StatusBarView
has destructor1 field
icon: String
struct StatusBar
has destructor4 fields
segments: StatusBarSegmentVec
views: OptionStatusBarViewSwitcher
zoom: OptionStatusBarZoom
style: StatusBarStyle
1 constructor
constructor create:
arg segments: StatusBarSegmentVec
-> StatusBar
Creates a status bar with the given left segments, no view switcher and no zoom cluster, in the the Office-2013-era look style.
7 methods
arg callback_info: CallbackInfo
arg node_id: DomNodeId
arg label: String
-> bool
fn set_views:
&mut self
arg views: StatusBarViewSwitcher
fn with_views:
self
arg views: StatusBarViewSwitcher
-> StatusBar
fn set_zoom:
&mut self
arg zoom: StatusBarZoom
fn with_zoom:
self
arg zoom: StatusBarZoom
-> StatusBar
fn with_style:
self
arg style: StatusBarStyle
-> StatusBar
fn dom:
self
-> Dom
Rewrites the text of a MARKED segment in place, from any callback - the widget half of the inter-widget fast path (see
ProgressBar::update_progress).More
node_idis the segment label'sVirtualViewnode - the one that carries the marker given toStatusBarSegment::with_marker, found withCallbackInfo::get_node_id_by_marker. The label's PRIVATE dataset is updated and only this node's view is re-rendered, at the size the new text measures to, so the bar re-flows around it and nothing else in the window is touched. NoRefreshDom, no DOM diff, no app-data-model round trip: this is how a word count keeps up with typing (read the committed text from anOn::TextChangedcallback and land it here).Returns
false(and changes nothing) whennode_iddoes not name a live marked segment. Returnstruewithout re-rendering when the text is unchanged, so calling it on every keystroke is free when nothing moved.Sets the view-switcher cluster.
Builder method: sets the view-switcher cluster and returns
self.Sets the zoom cluster.
Builder method: sets the zoom cluster and returns
self.Builder method: replaces the style bundle.
Renders the status bar.
struct StatusBarZoom
7 fields
on_zoom_out: OptionButtonOnClick
on_zoom_in: OptionButtonOnClick
on_slider_change: OptionSliderOnValueChange
percent: f32
min: f32
max: f32
show_label: bool
1 constructor
constructor office_2013:
100% zoom over the the Office-2013-era look
[10, 190]window, label shown.1 method
fn with_percent:
self
arg percent: f32
Builder method: sets the zoom percent.
struct StatusBarStyle
has destructor19 fields
theme: StatusBarTheme
bar_style: OptionCssPropertyWithConditionsVec
segment_style: OptionCssPropertyWithConditionsVec
segment_icon_style: OptionCssPropertyWithConditionsVec
segment_label_style: OptionCssPropertyWithConditionsVec
filler_style: OptionCssPropertyWithConditionsVec
views_style: OptionCssPropertyWithConditionsVec
view_button_style: OptionCssPropertyWithConditionsVec
view_button_active_style: OptionCssPropertyWithConditionsVec
view_icon_style: OptionCssPropertyWithConditionsVec
zoom_style: OptionCssPropertyWithConditionsVec
zoom_button_style: OptionCssPropertyWithConditionsVec
zoom_icon_style: OptionCssPropertyWithConditionsVec
zoom_track_host_style: OptionCssPropertyWithConditionsVec
zoom_rail_style: OptionCssPropertyWithConditionsVec
zoom_tick_style: OptionCssPropertyWithConditionsVec
slider_track_style: OptionCssPropertyWithConditionsVec
slider_thumb_style: OptionCssPropertyWithConditionsVec
zoom_label_style: OptionCssPropertyWithConditionsVec
2 constructors
constructor from_system:
arg style: SystemStyle
constructor from_theme:
arg theme: StatusBarTheme
Every part style, derived from the OS theme - see
StatusBarTheme.from_system.Derives every part style from the given palette. Pair with
StatusBarTheme.from_systemto take the desktop's neutrals and then re-assert an app's own brand colours.1 method
&self
The
bar_stylethis bundle renders with: the caller's override if there is one, else derived from [Self::theme].struct StatusBarTheme
8 fields
1 constructor
constructor from_system:
arg style: SystemStyle
Extracts a bar palette from the OS theme.
More
The status bar is an ACCENT-FILLED strip, so the accent colour and the colour the platform says goes on top of it drive the whole palette, not the window background. A colour the platform does not report falls back to that field's own Office-2013 value, never to another derived value.
struct StatusBarSegment
has destructor4 fields
icon: String
label: String
on_click: OptionButtonOnClick
Optional marker (
Dom::with_marker) that makes an INERT text segment live-updatable: the label becomes aVirtualViewwhose node carries this marker, so a callback anywhere can find it byCallbackInfo::get_node_id_by_markerand rewrite the text withStatusBar::update_segment_label- without aRefreshDom, a DOM diff, or a round trip through the app's data model. Empty = plain static text. Ignored for icon / clickable segments (those are buttons).marker: String
4 methods
fn with_icon:
self
arg icon: String
fn with_marker:
self
arg marker: String
fn set_on_click:
&mut self
arg data: RefAny
arg on_click: ButtonOnClickCallback
fn with_on_click:
self
arg data: RefAny
arg on_click: ButtonOnClickCallback
Builder method: sets the leading icon name.
Builder method: marks the segment for live label updates (see the
markerfield). Use a unique string - aUuid::short()the app keeps in its state is the intended shape - so two bars never collide.Sets the click callback.
Builder method: sets the click callback and returns
self.struct StatusBarOnViewSelect
2 fields
data: RefAny
callback: StatusBarOnViewSelectCallback
struct BackstageStyle
has destructor10 fields
theme: BackstageTheme
root_style: OptionCssPropertyWithConditionsVec
back_button_style: OptionCssPropertyWithConditionsVec
back_icon_style: OptionCssPropertyWithConditionsVec
right_style: OptionCssPropertyWithConditionsVec
content_style: OptionCssPropertyWithConditionsVec
2 constructors
constructor from_system:
arg style: SystemStyle
constructor from_theme:
arg theme: BackstageTheme
Every part style, derived from the OS theme - see
BackstageTheme.from_system.Derives every part style from the given palette. Pair with
BackstageTheme.from_systemto take the desktop's neutrals and then re-assert an app's own brand colours.1 method
&self
The
root_stylethis bundle renders with: the caller's override if there is one, else derived from [Self::theme].struct BackstageBehavior
1 field
close_on_escape: bool
struct Backstage
has destructor8 fields
active_item: usize
on_back: OptionButtonOnClick
title_strip: OptionDom
content: OptionDom
behavior: BackstageBehavior
style: BackstageStyle
2 constructors
constructor create:
arg nav_items: BackstageNavItemVec
-> Backstage
constructor office_2013:
-> Backstage
Creates a backstage with the given nav items, item 0 active, no callbacks and no content, in the the Office-2013-era look style.
The the Office-2013-era look nav: Info / New / Open / Save / Save As / Print / Share / Export / Close, then a gap, then Account / Options.
13 methods
fn set_active_item:
&mut self
arg active_item: usize
fn with_active_item:
self
arg active_item: usize
-> Backstage
fn set_content:
&mut self
arg content: Dom
fn with_content:
fn set_title_strip:
&mut self
arg title_strip: Dom
fn with_title_strip:
fn set_on_back:
&mut self
arg data: RefAny
arg on_back: ButtonOnClickCallback
fn with_on_back:
self
arg data: RefAny
arg on_back: ButtonOnClickCallback
-> Backstage
fn with_behavior:
self
arg behavior: BackstageBehavior
-> Backstage
fn with_style:
self
arg style: BackstageStyle
-> Backstage
fn dom:
self
-> Dom
Sets the active nav item.
Builder method: sets the active nav item and returns
self.Sets the pane content for the active item.
Builder method: sets the pane content and returns
self.Sets the title strip rendered above the content.
Builder method: sets the title strip and returns
self.Sets the nav-select callback.
Builder method: sets the nav-select callback and returns
self.Sets the back callback (back button + Escape).
Builder method: sets the back callback and returns
self.Builder method: replaces the behavior set.
Builder method: replaces the style bundle.
Renders the backstage.
struct BackstageTheme
1 constructor
constructor from_system:
arg style: SystemStyle
Extracts a backstage palette from the OS theme.
More
The nav column is an ACCENT-FILLED band and the pane behind it is the window surface, so those two system colours carry the whole screen. A colour the platform does not report falls back to that field's own Office-2013 value, never to another derived value.
struct StatusBarViewVecSlice
has destructor2 fields
struct StatusBarSegmentVecSlice
has destructor2 fields
struct QuickAccessActionVecSlice
has destructor2 fields
struct MapSetup
What a map's tile fetches run on. Handed to the
on_mounthook, which returns the setup the map uses from then on.More
The default shares nothing: each tile opens its own connection on its own thread, which is also what a map without an
on_mounthook does.3 fields
3 methods
fn with_http_client:
self
arg client: HttpClient
-> MapSetup
fn with_thread_pool:
self
arg pool: ThreadPool
-> MapSetup
self
arg max_in_flight: u32
-> MapSetup
Download tiles through a shared connection pool
Run tile downloads on a shared thread pool
Limit how many tiles download at once (0 = no limit)
struct MapMount
2 fields
data: RefAny
callback: MapMountCallback
struct VideoSetup
What a video's decode worker runs on. Handed to the
on_mounthook, which returns the setup the widget uses from then on.More
The default shares nothing: the worker downloads over its own connection on its own thread, which is also what a widget without an
on_mounthook does.2 fields
http_client: OptionHttpClient
thread_pool: OptionThreadPool
1 constructor
constructor create:
-> VideoSetup
A setup that shares nothing
2 methods
fn with_http_client:
self
arg client: HttpClient
-> VideoSetup
fn with_thread_pool:
self
arg pool: ThreadPool
-> VideoSetup
Download the video through a shared connection pool
Run the decoder on a shared thread pool
struct VideoMount
2 fields
data: RefAny
callback: VideoMountCallback
mod window
72 typesWindow creation / startup configuration
struct WindowCreateOptions
has destructor9 fields
window_state: FullWindowState
create_callback: OptionCallback
parent_window_id: u64
renderer: OptionRendererOptions
theme: OptionWindowTheme
background_color_light: OptionColorU
background_color_dark: OptionColorU
size_to_content: bool
hot_reload: bool
1 constructor
constructor create:
arg layout_callback: LayoutCallbackType
Create a new WindowCreateOptions with a layout callback
enum WindowEventFilter
85 variants
MouseOver
MouseDown
LeftMouseDown
RightMouseDown
MiddleMouseDown
MouseUp
LeftMouseUp
RightMouseUp
MiddleMouseUp
MouseEnter
MouseLeave
Scroll
ScrollStart
ScrollEnd
TextInput
VirtualKeyDown
VirtualKeyUp
HoveredFile
DroppedFile
HoveredFileCancelled
Resized
Moved
FrameChanged
TouchStart
TouchMove
TouchEnd
TouchCancel
FocusReceived
FocusLost
CloseRequested
ThemeChanged
WindowFocusReceived
WindowFocusLost
PenDown
PenMove
PenUp
PenEnter
PenLeave
PenSqueeze
PenDoubleTap
PenHover
GeolocationFix
GeolocationError
SensorChanged
GamepadInput
DragStart
Drag
DragEnd
DragEnter
DragOver
DragLeave
Drop
DoubleClick
LongPress
SwipeLeft
SwipeRight
SwipeUp
SwipeDown
PinchIn
PinchOut
RotateClockwise
RotateCounterClockwise
DpiChanged
MonitorChanged
PermissionChanged
BiometricResult
ScreenColorPicked
KeyringResult
BackMouseDown
BackMouseUp
ForwardMouseDown
ForwardMouseUp
RawMouseMotion
ModifiersChanged
HidReport
DialRotate
DialClick
MouseMove
PointerLockChange
Play
Pause
Ended
TimeUpdate
VolumeChange
MediaError
struct FullWindowState
has destructor21 fields
platform_specific_options: PlatformSpecificOptions
keyboard_state: KeyboardState
window_id: String
title: String
close_callback: OptionCallback
layout_callback: LayoutCallback
position: WindowPosition
touch_state: TouchState
size: WindowSize
flags: WindowFlags
mouse_state: MouseState
theme: WindowTheme
ime_position: ImePosition
renderer_options: RendererOptions
monitor_id: OptionU32
debug_state: DebugState
background_color: OptionColorU
window_focused: bool
active_route: OptionRouteMatch
pointer_seats: PointerSeatVec
keyboard_seats: KeyboardSeatVec
struct WindowFlags
18 fields
frame: WindowFrame
decorations: WindowDecorations
background_material: WindowBackgroundMaterial
window_type: WindowType
close_requested: bool
is_visible: bool
is_always_on_top: bool
is_resizable: bool
has_focus: bool
smooth_scroll_enabled: bool
autotab_enabled: bool
has_decorations: bool
is_top_level: bool
prevent_system_sleep: bool
fullscreen_mode: FullScreenMode
extend_into_safe_area: bool
struct WindowSize
4 fields
struct Monitor
has destructor8 fields
monitor_id: MonitorId
monitor_name: OptionString
size: LayoutSize
position: LayoutPoint
scale_factor: f64
work_area: LayoutRect
video_modes: VideoModeVec
is_primary_monitor: bool
enum WindowFrame
4 variants
Normal
Minimized
Maximized
Fullscreen
enum WindowType
4 variants
Normal
Menu
Tooltip
Dialog
enum WindowTheme
2 variants
DarkMode
LightMode
union enum Platform
has destructor6 variants
enum StyleCursor
30 variants
Alias
AllScroll
Cell
ColResize
ContextMenu
Copy
Crosshair
Default
EResize
EwResize
Grab
Grabbing
Help
Move
NResize
NsResize
NeswResize
NwseResize
Pointer
Progress
RowResize
SResize
SeResize
Text
Unset
VerticalText
WResize
Wait
ZoomIn
ZoomOut
enum MouseCursorType
35 variants
Default
Crosshair
Hand
Arrow
Move
Text
Wait
Help
Progress
NotAllowed
ContextMenu
Cell
VerticalText
Alias
Copy
NoDrop
Grab
Grabbing
AllScroll
ZoomIn
ZoomOut
EResize
NResize
NeResize
NwResize
SResize
SeResize
SwResize
WResize
EwResize
NsResize
NeswResize
NwseResize
ColResize
RowResize
enum FullScreenMode
4 variants
SlowFullScreen
FastFullScreen
SlowWindowed
FastWindowed
struct HidpiAdjustedBounds
2 fields
logical_size: LogicalSize
hidpi_factor: DpiScaleFactor
1 constructor
constructor from_bounds:
arg bounds: LayoutSize
arg hidpi_factor: DpiScaleFactor
3 methods
&self
fn get_logical_size:
&self
-> LogicalSize
fn get_hidpi_factor:
&self
struct IconProviderHandle
2 fields
inner: c_void
run_destructor: bool
2 constructors
constructor create:
constructor with_resolver:
arg resolver: IconResolverCallbackType
Create a new empty icon provider with the default resolver
Create with a custom resolver callback
11 methods
fn set_resolver:
&mut self
arg resolver: IconResolverCallbackType
fn register_icon:
fn unregister_icon:
fn unregister_pack:
&mut self
arg pack_name: String
fn lookup:
&self
arg icon_name: String
-> OptionRefAny
fn has_icon:
&self
arg icon_name: String
-> bool
fn debug_lookup:
Register a font icon in a pack
Register an arbitrary
Domas an icon, in a pack.More
The general case: an icon is just a DOM, and image / font icons are special cases of it. Whatever you register is spliced in wherever that icon name is used - an
<icon>node, a tray icon, an app icon - and it keeps its own styling, because the DOM carries both inline properties and its own stylesheets.That is how an icon gets a colour without any call site passing a tint: the icon says what it looks like, the call site says how big.
Register an image icon in a pack.
More
The bitmap's own size becomes the icon's NATURAL size - the size it occupies in layout. That is right for a 1:1 bitmap; an OVERSAMPLED one (an SVG rasterised at 2x so it stays crisp on a HiDPI display) must state its natural size with
register_image_icon_sized, or it lays out at twice the size it is drawn at.Set the resolver callback
Register a single icon in a pack (creates pack if needed)
Unregister a single icon from a pack
Unregister an entire icon pack
Look up an icon across all packs (first match wins)
Check if an icon exists in any pack
Register an image icon whose NATURAL SIZE differs from its bitmap's.
More
width/heightare the logical px the icon occupies in layout; the bitmap may be larger (an SVG rasterised at 2x or 3x so it stays crisp when the display or the zoom scales it up). Only the caller that rasterised it knows this: a freedesktop theme states it in the directory the file came from (actions/16,actions/22, ...).A non-finite or non-positive size is ignored in favour of the bitmap's own - a zero-sized icon is invisible, which is a worse failure than a wrong-sized one.
Debug lookup: returns detailed info about an icon's RefAny contents. Useful for debugging to verify icons are registered correctly.
struct DpiScaleFactor
1 field
inner: FloatValue
struct LinuxWindowOptions
has destructor13 fields
wayland_theme: OptionWaylandTheme
window_icon: OptionWindowIcon
x11_gtk_theme_variant: OptionString
wayland_app_id: OptionString
x11_wm_classes: StringPairVec
x11_window_types: XWindowTypeVec
x11_visual: OptionX11Visual
x11_resize_increments: OptionLogicalSize
x11_base_size: OptionLogicalSize
x11_screen: OptionI32
request_user_attention: UserAttentionType
x11_decorations_state: OptionLinuxDecorationsState
x11_override_redirect: bool
struct WaylandTheme
has destructor44 fields
title_bar_active_background_color: ColorU
title_bar_active_separator_color: ColorU
title_bar_active_text_color: ColorU
title_bar_inactive_background_color: ColorU
title_bar_inactive_separator_color: ColorU
title_bar_inactive_text_color: ColorU
maximize_idle_foreground_inactive_color: ColorU
minimize_idle_foreground_inactive_color: ColorU
close_idle_foreground_inactive_color: ColorU
maximize_hovered_foreground_inactive_color: ColorU
minimize_hovered_foreground_inactive_color: ColorU
close_hovered_foreground_inactive_color: ColorU
maximize_disabled_foreground_inactive_color: ColorU
minimize_disabled_foreground_inactive_color: ColorU
close_disabled_foreground_inactive_color: ColorU
maximize_idle_background_inactive_color: ColorU
minimize_idle_background_inactive_color: ColorU
close_idle_background_inactive_color: ColorU
maximize_hovered_background_inactive_color: ColorU
minimize_hovered_background_inactive_color: ColorU
close_hovered_background_inactive_color: ColorU
maximize_disabled_background_inactive_color: ColorU
minimize_disabled_background_inactive_color: ColorU
close_disabled_background_inactive_color: ColorU
maximize_idle_foreground_active_color: ColorU
minimize_idle_foreground_active_color: ColorU
close_idle_foreground_active_color: ColorU
maximize_hovered_foreground_active_color: ColorU
minimize_hovered_foreground_active_color: ColorU
close_hovered_foreground_active_color: ColorU
maximize_disabled_foreground_active_color: ColorU
minimize_disabled_foreground_active_color: ColorU
close_disabled_foreground_active_color: ColorU
maximize_idle_background_active_color: ColorU
minimize_idle_background_active_color: ColorU
close_idle_background_active_color: ColorU
maximize_hovered_background_active_color: ColorU
minimize_hovered_background_active_color: ColorU
close_hovered_background_active_color: ColorU
maximize_disabled_background_active_color: ColorU
minimize_disabled_background_active_color: ColorU
close_disabled_background_active_color: ColorU
title_bar_font: String
title_bar_font_size: f32
enum UserAttentionType
3 variants
None
Critical
Informational
struct MonitorId
2 fields
index: usize
hash: u64
struct WasmWindowOptions
1 field
_reserved: u8
struct IconKey
1 field
icon_id: usize
enum HwAcceleration
3 variants
Enabled
Disabled
DontCare
struct MacWindowOptions
1 field
_reserved: u8
enum Vsync
3 variants
Enabled
Disabled
DontCare
struct VideoMode
3 fields
enum XWindowType
14 variants
Desktop
Dock
Toolbar
Menu
Utility
Splash
Dialog
DropdownMenu
PopupMenu
Tooltip
Notification
Combo
Dnd
Normal
struct PlatformSpecificOptions
has destructor4 fields
windows_options: WindowsWindowOptions
linux_options: LinuxWindowOptions
mac_options: MacWindowOptions
wasm_options: WasmWindowOptions
union enum WindowIcon
has destructor2 variants
Small(SmallWindowIconBytes)
Large(LargeWindowIconBytes)
struct WindowsWindowOptions
has destructor4 fields
allow_drag_and_drop: bool
no_redirection_bitmap: bool
window_icon: OptionWindowIcon
taskbar_icon: OptionTaskBarIcon
struct IOSHandle
3 fields
ui_window: c_void
ui_view: c_void
ui_view_controller: c_void
union enum RawWindowHandle
9 variants
IOS(IOSHandle)
MacOS(MacOSHandle)
Xlib(XlibHandle)
Xcb(XcbHandle)
Wayland(WaylandHandle)
Windows(WindowsHandle)
Web(WebHandle)
Android(AndroidHandle)
Unsupported
struct MacOSHandle
2 fields
ns_window: c_void
ns_view: c_void
struct XcbHandle
2 fields
window: u32
connection: c_void
struct TextCursor
2 fields
cluster_id: GraphemeClusterId
affinity: CursorAffinity
struct XlibHandle
2 fields
window: u64
display: c_void
struct WaylandHandle
2 fields
surface: c_void
display: c_void
struct WindowsHandle
2 fields
hwnd: c_void
hinstance: c_void
struct WebHandle
1 field
id: u32
struct AndroidHandle
1 field
a_native_window: c_void
enum CursorAffinity
2 variants
Leading
Trailing
enum CursorMovement
11 variants
Left
Right
Up
Down
WordLeft
WordRight
LineStart
LineEnd
DocumentStart
DocumentEnd
Absolute
struct TextOpMoveCursor
3 fields
union enum ThemeCondition
has destructorTheme condition for light/dark mode styling
4 variants
enum Theme
2 variants
Light
Dark
struct MimeTypeHint
has destructor1 field
inner: String
struct VideoModeVecSlice
2 fields
struct MonitorVecSlice
has destructor2 fields
ptr: Monitor
len: usize
struct XWindowTypeVecSlice
2 fields
union enum CursorParseErrorOwned
has destructor1 variant
InvalidValue(InvalidValueErrOwned)
struct MimeTypeDataVecSlice
has destructor2 fields
struct TouchPoint
Single touch point (finger, stylus, etc.)
8 fields
id: u64
seat_id: u64
position: LogicalPosition
force: f32
major: f32
minor: f32
orientation_rad: f32
tool_type: TouchToolType
struct TouchPointVecSlice
2 fields
struct DetectedPinch
Result of pinch gesture detection (scale + center + travel distances + duration).
5 fields
Scale factor (< 1.0 for pinch in, > 1.0 for pinch out)
scale: f32
Center point of the pinch gesture
center: LogicalPosition
Distance between touch points when the pinch started, in logical px
initial_distance: f32
Current distance between touch points, in logical px
current_distance: f32
Duration of the pinch so far, in milliseconds
duration_ms: u64
struct PlatformCapability
has destructor19 constructors
constructor webtransport:
constructor iroh:
constructor thread:
constructor file_system:
constructor dialogs:
constructor http:
constructor multi_window:
constructor sql:
constructor sync:
constructor camera:
constructor screen_capture:
constructor microphone:
constructor audio_output:
constructor sensors:
constructor gamepad:
constructor geolocation:
constructor keyring:
constructor biometric:
constructor video_codec:
Probe the WebTransport client (native: in-process QUIC; web: the browser's WebTransport API).
Probe peer-to-peer QUIC (
IrohEndpoint). Native: the in-process iroh engine when theirohfeature is compiled in. Web: not yet, until iroh runs over WebTransport.Probe user background threads (
Thread::create).falseon web until a worker mode exists.Probe the file system (
FilePath::*): the OS file system natively, a virtual origin-private one plus picked files on web.Probe native dialogs (
FileDialog,ColorPickerDialog,MsgBox); on web the browser pickers, gated on a user gesture.Probe the HTTP client (
HttpRequestConfig::*): ureq + rustls natively when built withhttp,fetch()(subject to CORS) on web.Probe multi-window support (
CallbackInfo::create_window): desktop only; mobile and web have one window andcreate_windowis a no-op.Probe raw SQL access. Never available through the API:
Dbis a key/value + index store and its engine is an internal detail.Probe
Dbbackup sync (DbConfig::with_backup_sync_url), which needs the HTTP client on every target.Probe camera capture availability + backend (non-destructive).
Probe screen-capture availability + backend (portal+PipeWire on Linux, ScreenCaptureKit on macOS 12.3+).
Probe microphone capture availability + backend.
Probe audio output (
AudioSink) availability + backend.Probe motion-sensor availability + backend (false on a device with no sensor, never panics).
Probe gamepad backend (does not initialise gilrs; a pad is detected on poll).
Probe geolocation availability + backend (currently a stub on all platforms).
Probe the OS secret keyring backend.
Probe biometric auth (uses the real sync availability check - reflects device/enrolment state).
Probe the hardware video codec (currently a stub on all platforms).
struct FullWindowStateVecSlice
has destructor2 fields
enum MapTheme
7 variants
System
Positron
Bright
Liberty
Google
Apple
Custom
2 methods
fn stylesheet:
self
arg window_theme: WindowTheme
-> String
fn credit:
self
arg window_theme: WindowTheme
-> String
The MapCSS sheet this theme renders with under
window_theme; empty forCustom(the layer'sstyle_cssis the sheet then).The credit line the design rendered under
window_themeasks for (CC BY 4.0 for the OpenFreeMap designs, Apache-2.0 for Google's night sample); empty for the authored looks andCustom. Both halves are appended to the layer's attribution by [MapTileLayer::with_theme].struct TransientWindowConfig
8 fields
size: OptionLogicalSize
anchor: TransientAnchor
dismiss: TransientDismiss
tearoff: TransientTearoff
dock: TransientDock
material: WindowBackgroundMaterial
open: bool
torn: bool
2 constructors
8 methods
fn with_anchor:
self
arg anchor: TransientAnchor
fn with_dismiss:
self
arg dismiss: TransientDismiss
fn with_size:
self
arg size: LogicalSize
fn with_tearoff:
self
arg tearoff: TransientTearoff
fn with_torn:
self
arg torn: bool
fn with_material:
self
arg material: WindowBackgroundMaterial
fn with_dock:
self
arg dock: TransientDock
fn apply_attr:
Apply one XML/HTML attribute. Returns
trueif the key was one of ours.More
size="WxH"in logical px; anything else for a known key degrades to the default rather than erroring - a typo must not make a popup refuse to open. Unknown keys returnfalseso the caller can treat them as ordinary attributes (id, class, ...).enum PhysicalKey
127 variants
Unidentified
KeyA
KeyB
KeyC
KeyD
KeyE
KeyF
KeyG
KeyH
KeyI
KeyJ
KeyK
KeyL
KeyM
KeyN
KeyO
KeyP
KeyQ
KeyR
KeyS
KeyT
KeyU
KeyV
KeyW
KeyX
KeyY
KeyZ
Digit0
Digit1
Digit2
Digit3
Digit4
Digit5
Digit6
Digit7
Digit8
Digit9
Backquote
Minus
Equal
BracketLeft
BracketRight
Backslash
Semicolon
Quote
Comma
Period
Slash
Enter
Tab
Space
Backspace
Escape
CapsLock
ShiftLeft
ShiftRight
ControlLeft
ControlRight
AltLeft
AltRight
MetaLeft
MetaRight
ContextMenu
Insert
Delete
Home
End
PageUp
PageDown
ArrowUp
ArrowDown
ArrowLeft
ArrowRight
F1
F2
F3
F4
F5
F6
F7
F8
F9
F10
F11
F12
F13
F14
F15
F16
F17
F18
F19
F20
F21
F22
F23
F24
PrintScreen
ScrollLock
Pause
NumLock
NumpadDivide
NumpadMultiply
NumpadSubtract
NumpadAdd
NumpadEnter
NumpadDecimal
NumpadComma
NumpadEqual
Numpad0
Numpad1
Numpad2
Numpad3
Numpad4
Numpad5
Numpad6
Numpad7
Numpad8
Numpad9
IntlBackslash
IntlRo
IntlYen
Lang1
Lang2
Convert
NonConvert
KanaMode
struct KeyLocks
3 fields
caps_lock: bool
num_lock: bool
scroll_lock: bool
enum TouchToolType
6 variants
Unknown
Finger
Stylus
Eraser
Palm
Mouse
struct PointerSeat
2 fields
seat_id: u64
state: MouseState
struct PointerSeatVecSlice
2 fields
struct KeyboardSeat
has destructor2 fields
seat_id: u64
state: KeyboardState
struct KeyboardSeatVecSlice
has destructor2 fields
enum UiTheme
2 variants
Flat
Flora
mod str
7 typesDefinition of azuls internal
Stringwrappersstruct String
has destructor1 field
vec: U8Vec
2 constructors
constructor copy_from_bytes:
arg ptr: *const u8
arg start: usize
arg len: usize
-> String
constructor from_c_str:
arg ptr: *const i8
-> String
Creates a new String from a null-terminated C string (const char*). This copies the string data into a new allocation.
5 methods
fn from_utf8:
arg ptr: *const u8
arg len: usize
-> String
fn from_utf8_lossy:
arg ptr: *const u8
arg len: usize
-> String
fn to_c_str:
&self
-> U8Vec
fn from_utf16_le:
arg ptr: *const u8
arg len: usize
-> String
fn from_utf16_be:
arg ptr: *const u8
arg len: usize
-> String
Creates a new String from UTF-8 bytes. Returns an empty string if the input is not valid UTF-8.
Creates a new String from UTF-8 bytes with lossy conversion. Invalid UTF-8 sequences are replaced with the Unicode replacement character (U+FFFD).
Creates a null-terminated copy of the string for C FFI usage. Returns a new U8Vec that contains the string data followed by a null byte. The caller is responsible for freeing this memory.
Creates a new String from UTF-16 encoded bytes (little-endian). Returns an empty string if the input is invalid UTF-16 or has odd length.
Creates a new String from UTF-16 encoded bytes (big-endian). Returns an empty string if the input is invalid UTF-16 or has odd length.
struct StringSet
has destructor1 field
inner: String
struct StringPairVecSlice
has destructor2 fields
struct StringVecSlice
has destructor2 fields
struct IcuStringVecSlice
has destructor2 fields
mod image
23 typesStruct definitions for image loading
struct ImageRef
has destructor4 fields
data: c_void
copies: c_void
id: u64
run_destructor: bool
6 constructors
constructor create_rawimage:
arg image_data: RawImage
constructor gl_texture:
constructor callback:
arg callback: CoreRenderImageCallback
arg data: RefAny
-> ImageRef
constructor null_image:
arg width: usize
arg height: usize
arg format: RawImageFormat
arg tag: U8VecRef
-> ImageRef
constructor raw_image:
arg data: RawImage
constructor create_gltexture:
Creates an image reference from an OpenGL texture
Creates an image reference from a CPU-backed buffer
14 methods
fn get_size:
&self
-> LogicalSize
fn get_bytes:
&self
fn is_invalid:
&self
-> bool
fn is_gl_texture:
&self
-> bool
fn is_raw_image:
&self
-> bool
fn is_callback:
&self
-> bool
fn get_raw_image:
&self
fn is_null_image:
&self
-> bool
fn get_rawimage:
&self
fn get_hash:
&self
-> ImageRefHash
&self
&mut self
fn deep_copy:
&self
-> ImageRef
fn get_bytes_ptr:
&self
-> *const u8
NOTE: returns (0, 0) for a Callback
Get raw bytes from the image as a slice Returns None if this is not a Raw image or if it's an External image
Returns whether the image is a null (invalid) image
If the image is a RawImage, returns a COPY of the internal image bytes (useful for encoding the RawImage / exporting the ImageRef to a file)
In difference to the default shallow copy, creates a new image ref
Get a pointer to the raw bytes for debugging/profiling purposes Returns a unique pointer for this ImageRef's data
struct RawImage
has destructor6 fields
pixels: RawImageData
width: usize
height: usize
premultiplied_alpha: bool
data_format: RawImageFormat
tag: U8Vec
4 constructors
constructor decode_image_bytes_any:
arg bytes: U8VecRef
constructor empty:
-> RawImage
constructor allocate_clip_mask:
arg size: LayoutSize
-> RawImage
constructor decode_image_bytes:
arg bytes: U8Vec
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
Decodes a RawImage from any supported image format - automatically guesses the format based on the magic header. Pure compute: works on every target, but on web the resumable
decode_image_bytesuses the browser's hardware decoder and is the faster choice for large images. Decoded pixels may differ per backend.Returns a zero-sized image
Allocates a width * height, single-channel image with zeroed bytes
Decode
bytes(any supported format, guessed from the magic header) and resumeon_resultwith anImageDecodeResult. This is the fast path on web, where the browser's hardware decoders do the work;decode_image_bytes_anyis the pure synchronous decoder that works everywhere. Decoded pixels may differ per backend (premultiplication, ICC handling). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched.9 methods
fn encode_png:
&self
fn encode_bmp:
&self
fn encode_jpeg:
&self
arg quality: u8
fn encode_tga:
&self
fn encode_pnm:
&self
fn encode_gif:
&self
fn encode_tiff:
&self
fn paint_dot:
&mut self
arg cx: f32
arg cy: f32
arg brush: Brush
fn paint_stroke:
&mut self
arg x0: f32
arg y0: f32
arg x1: f32
arg y1: f32
arg brush: Brush
Encodes the RawImage in the PNG image format
Encodes the RawImage in the BMP image format
Encodes the RawImage in the JPG image format. Quality is a value from 0 to 100.
Encodes the RawImage in the TGA image format
Encodes the RawImage in the PNM image format
Encodes the RawImage in the GIF image format
Encodes the RawImage in the TIFF image format
CPU painting: stamp one brush dab centered at (
cx,cy) in pixel coordinates, alpha-over compositing a radial-falloff disc. Only 8-bitRGBA8/BGRA8images are painted (other formats are left untouched). This is the CPU mirror of the GPU brush shader.CPU painting: stamp a stroke by spacing dabs along the segment (
x0,y0)->(x1,y1). Call once per pointer move with the previous and current positions for a continuous line.enum RawImageFormat
12 variants
R8
RG8
RGB8
RGBA8
R16
RG16
RGB16
RGBA16
BGR8
BGRA8
RGBF32
RGBAF32
struct Route
has destructor2 fields
pattern: String
layout_callback: LayoutCallback
struct ImageMask
has destructor3 fields
struct RouteMatch
has destructor2 fields
pattern: String
params: StringPairVec
struct ImageDescriptor
6 fields
format: RawImageFormat
width: usize
height: usize
stride: OptionI32
offset: i32
flags: ImageDescriptorFlags
struct VideoEncoder
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor open:
arg width: u32
arg height: u32
arg h265: bool
arg bitrate_kbps: u32
-> VideoEncoder
Open an encoder for
widthxheight, H.265 ifh265else H.264, atbitrate_kbps. Uses the platform-native backend ([backend_name]). Returns an invalid handle (is_open()false) where no backend exists.6 methods
fn backend_name:
-> String
fn is_open:
&self
-> bool
fn encode:
&self
arg frame: VideoFrame
arg force_keyframe: bool
-> bool
fn frames_encoded:
&self
-> u64
fn close:
&mut self
fn recv_packet:
&mut self
-> OptionU8Vec
The native codec backend selected for this platform ("VideoToolbox", "MediaCodec", "gpu-video", or "none").
Whether the encoder opened (a backend exists for this platform).
Submit one
VideoFrame(RGBA) for encoding;force_keyframerequests an IDR. Returnstrueif the frame was accepted (the encoder is open). The encoded chunks (Annex-B for H.264/H.265) come out ofrecv_packet, possibly several per frame and possibly later: hardware and browser (WebCodecs) encoders are output-callback shaped, so submit and poll are separate steps on every target.Frames submitted to [
encode](Self::encode) so far (stub progress).Release the encoder. (Drop does this too.)
Pull the next encoded chunk, or
Nonewhen nothing is ready yet. Drain in a loop after eachencode(or from a timer).struct VideoDecoder
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor open:
arg h265: bool
-> VideoDecoder
Open a decoder (H.265 if
h265else H.264) using the platform-native backend. Invalid handle where no backend exists.4 methods
fn is_open:
&self
-> bool
fn decode:
&self
arg data: U8Vec
-> bool
fn close:
&mut self
fn recv_frame:
&mut self
Whether the decoder opened.
Submit one encoded chunk (Annex-B H.264). Returns
trueif the chunk was accepted (the decoder is open). Decoded frames come out ofrecv_frame: decode is pipelined and B-frame reordered, so one chunk can yield zero or several frames, possibly later - the same output-callback shape as WebCodecs.Release the decoder. (Drop does this too.)
Pull the next decoded frame, or
Nonewhen nothing is ready yet. Drain in a loop after eachdecode(or from a timer).enum ImageRendering
2 variants
OptimizeQuality
OptimizeSpeed
struct ImageDescriptorFlags
2 fields
is_opaque: bool
allow_mipmaps: bool
struct ImageRefHash
1 field
inner: u64
union enum CssImageParseErrorOwned
has destructor1 variant
UnclosedQuotes(String)
struct RouteVecSlice
has destructor2 fields
struct DecodedVideo
has destructor5 fields
1 method
fn decode_mp4_h264:
arg bytes: U8Vec
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
Demux + decode an in-memory MP4 (H.264) and resume
on_resultwith aVideoDecodeResult(videoisNoneon any error). Decoding a whole clip is inherently asynchronous on web (WebCodecs), so the answer is delivered as a resume on every target. On a box with no hardware decoder the demux still runs andframesis empty (seeaccess_units_fed). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched.struct VideoEncodeCheck
has destructor1 constructor
constructor run:
Probe hardware + software H.264 encode (call once at startup). Inspection only. Warns when only software (x264) encoding is available on this machine.
struct ImageCacheSnapshot
Boxed snapshot of the app's registered images (css id -> ImageRef). Obtain via
CallbackInfo.get_image_cache_clone(). ImageRefs are refcounted - decoded pixels are shared, never re-decoded. Valid after the callback returns (off-thread ok).2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor empty:
An empty handle.
struct ZombieAnimInfo
9 fields
styled_dom: c_void
node_id: u64
rect: LogicalRect
viewport: LogicalRect
dpi_factor: f32
t: f32
timing: AnimationTiming
velocity_x: f32
velocity_y: f32
struct EmailAddress
has destructorAn email address, e.g. a support mailbox problem reports go to.
1 field
address: String
1 constructor
constructor create:
arg address: String
-> EmailAddress
struct ImageDecodeResult
has destructorResult of
RawImage::decode_image_bytes.1 field
result: ResultRawImageDecodeImageError
struct VideoDecodeResult
has destructorResult of
DecodedVideo::decode_mp4_h264.1 field
video: OptionDecodedVideo
mod task
14 typesTimer, thread, and async task management.
struct Timer
9 fields
refany: RefAny
node_id: OptionDomNodeId
created: Instant
last_run: OptionInstant
run_count: usize
delay: OptionDuration
interval: OptionDuration
timeout: OptionDuration
callback: TimerCallback
1 constructor
constructor create:
arg refany: RefAny
arg callback: TimerCallback
arg get_system_time_fn: GetSystemTimeCallback
-> Timer
7 methods
fn with_interval:
fn with_delay:
fn with_timeout:
fn tick_millis:
&self
-> u64
&self
-> Instant
&self
arg instant_now: Instant
-> bool
fn invoke:
&mut self
arg callback_info: CallbackInfo
arg get_system_time_fn: GetSystemTimeCallback
Invoke the timer callback and update internal state
struct Thread
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor create:
arg thread_initialize_data: RefAny
arg writeback_data: RefAny
arg callback: ThreadCallback
-> Thread
Creates a new thread that will execute the given callback function.
More
# Arguments *
thread_initialize_data- Data passed to the callback when the thread starts *writeback_data- Data that will be passed back when writeback messages are received *callback- The function to execute in the background threadenum TerminateTimer
2 variants
Terminate
Continue
struct ThreadSender
3 fields
1 method
fn send:
&mut self
arg msg: ThreadReceiveMsg
-> bool
Sends a message from the background thread to the main thread
struct ThreadReceiver
3 fields
1 method
fn recv:
&mut self
Receives a message from the main thread, if available
union enum ThreadSendMsg
3 variants
union enum ThreadReceiveMsg
2 variants
WriteBack(ThreadWriteBackMsg)
Update(Update)
struct RequestId
Identifies one in-flight request created by a resumable API function. Every request function (
FileDialog::open_file,FilePath::read_bytes,HttpRequestConfig::http_get, ...) returns one immediately and resumes the caller later through itsResumeCallback.invalid()is the never-matching sentinel to initialise state with; ids are process-unique and never reused.1 field
id: u64
1 constructor
1 method
fn is_valid:
&self
-> bool
truefor every id a request function returned,falseonly forinvalid().struct ThreadWriteBackMsg
2 fields
refany: RefAny
callback: WriteBackCallback
1 constructor
constructor create:
arg callback: WriteBackCallback
arg data: RefAny
Creates a new ThreadWriteBackMsg with the given callback and data
struct TimerIdVecSlice
2 fields
ptr: TimerId
len: usize
struct ThreadIdVecSlice
2 fields
struct ThreadPool
A fixed set of worker threads that runs
Threadbodies, created by the application and shared by whoever it hands a clone to.More
Thread::createstarts one OS thread per call. A widget that starts many short jobs (a map fetching tiles) can instead be given a pool: at mostthreadsjobs then run at once and the rest wait in the pool's queue. Cloning is cheap and shares the same workers; the workers exit once the last handle is dropped and the queue is empty.2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor create:
arg threads: usize
-> ThreadPool
Start a pool of
threadsworkers (at least one).2 methods
fn thread_count:
&self
-> usize
fn create_thread:
&self
arg thread_initialize_data: RefAny
arg writeback_data: RefAny
arg callback: ThreadCallback
-> Thread
How many workers are running (0 where the target cannot start threads).
Like [
Thread::create], but the body runs on one of this pool's workers instead of a new OS thread. Hand the result toCallbackInfo::add_threadexactly like any otherThread.
mod time
11 typesRust wrappers for
Instant/Durationclassesunion enum Instant
2 variants
System(InstantPtr)
Tick(SystemTick)
1 constructor
3 methods
fn duration_since:
&self
arg earlier: Instant
fn add_duration:
Linearly interpolates between [start, end] if the
selfInstant lies between start and end. Returns values between 0.0 and 1.0Returns the duration since and earlier instant or None if the earlier instant is later than self
Adds a duration to the current time instant, returning the new
Instantunion enum Duration
2 variants
System(SystemTimeDiff)
Tick(SystemTickDiff)
4 methods
fn div:
&self
arg other: Duration
-> f32
fn min:
fn greater_than:
&self
arg other: Duration
-> bool
fn smaller_than:
&self
arg other: Duration
-> bool
Divides this duration by another, returning the ratio as an f32. Returns 0.0 if the variants differ (mixing System with Tick).
Returns the smaller of two durations.
Returns true if self > other. Panics if the variants differ (System vs. Tick).
Returns true if self < other. Panics if the variants differ (System vs. Tick).
struct CssDuration
A CSS time duration: a magnitude plus the unit it is counted in.
inneris NOT unconditionally milliseconds - read it together withunit.2 fields
inner: u32
unit: CssDurationUnit
struct SystemTimeDiff
2 fields
secs: u64
nanos: u32
3 constructors
constructor from_secs:
arg secs: u64
constructor from_millis:
arg millis: u64
constructor from_nanos:
arg nanos: u64
Creates a duration from whole seconds.
Creates a duration from milliseconds.
Creates a duration from nanoseconds.
2 methods
fn millis:
&self
-> u64
fn div:
&self
arg other: SystemTimeDiff
-> f64
Returns the total duration in milliseconds.
Divides this duration by another, returning the ratio as an f64. Returns Inf or NaN if other is zero.
struct SystemTick
1 field
tick_counter: u64
struct SystemTickDiff
1 field
tick_diff: u64
1 method
fn div:
&self
arg other: SystemTickDiff
-> f64
Divides this tick-difference by another, returning the ratio as an f64. Returns Inf or NaN if other is zero.
struct InstantPtr
4 fields
ptr: c_void
clone_fn: InstantPtrCloneCallback
destructor: InstantPtrDestructorCallback
run_destructor: bool
enum CssDurationUnit
The unit a
CssDurationmagnitude is counted in: wall-clock milliseconds (ms/s) or engine ticks / frames (t).2 variants
Milliseconds
Ticks
struct GetSystemTimeCallback
1 field
struct IcuTime
3 fields
hour: u8
minute: u8
second: u8
mod svg
29 typesSVG parsing and rendering functions
struct Svg
has destructor2 fields
tree: c_void
run_destructor: bool
2 constructors
constructor from_string:
arg svg_string: String
arg parse_options: SvgParseOptions
constructor from_bytes:
arg svg_bytes: U8VecRef
arg parse_options: SvgParseOptions
struct SvgPath
1 field
items: SvgPathElementVec
1 constructor
constructor create:
arg items: SvgPathElementVec
-> SvgPath
Creates a new SvgPath from a vector of path elements
struct SvgMultiPolygon
1 field
rings: SvgPathVec
1 constructor
constructor create:
arg rings: SvgPathVec
Creates a new SvgMultiPolygon from a vector of paths (rings) NOTE: If a ring represents a hole, simply reverse the order of points
3 methods
fn tessellate_fill:
&self
arg fill_style: SvgFillStyle
&self
arg stroke_style: SvgStrokeStyle
fn get_bounds:
&self
-> SvgRect
union enum SvgPathElement
3 variants
3 constructors
constructor line:
arg l: SvgLine
constructor cubic_curve:
arg cc: SvgCubicCurve
constructor quadratic_curve:
arg qc: SvgQuadraticCurve
Creates a line path element from a SvgLine
Creates a cubic curve path element from a SvgCubicCurve
Creates a quadratic curve path element from a SvgQuadraticCurve
11 methods
fn set_last:
&mut self
arg point: SvgPoint
fn set_first:
&mut self
arg point: SvgPoint
fn reverse:
&mut self
fn get_start:
&self
-> SvgPoint
fn get_end:
&self
-> SvgPoint
fn get_bounds:
&self
-> SvgRect
fn get_length:
&self
-> f64
fn get_t_at_offset:
&self
arg offset: f64
-> f64
&self
arg t: f64
-> SvgVector
fn get_x_at_t:
&self
arg t: f64
-> f64
fn get_y_at_t:
&self
arg t: f64
-> f64
struct SvgRect
8 fields
width: f32
height: f32
x: f32
y: f32
radius_top_left: f32
radius_top_right: f32
radius_bottom_left: f32
radius_bottom_right: f32
2 methods
fn expand:
&self
arg padding_top: f32
arg padding_bottom: f32
arg padding_left: f32
arg padding_right: f32
-> SvgRect
fn get_center:
&self
-> SvgPoint
Expands the rect with a certain amount of padding
Returns the center point of the rect
struct TessellatedSvgNode
has destructor2 fields
vertices: SvgVertexVec
indices: U32Vec
2 constructors
constructor empty:
constructor from_nodes:
arg nodes: TessellatedSvgNodeVecRef
Creates a new TessellatedSvgNode by joining all the given nodes together into one array and inserting a
GL_RESTART_INDEX(u32::MAX) into the indices (so that the resulting buffer can be drawn in one draw call).struct SvgStrokeStyle
11 fields
dash_pattern: OptionSvgDashPattern
transform: SvgTransform
start_cap: SvgLineCap
end_cap: SvgLineCap
line_join: SvgLineJoin
line_width: f32
miter_limit: f32
tolerance: f32
apply_line_width: bool
anti_alias: bool
high_quality_aa: bool
enum SvgFillRule
2 variants
Winding
EvenOdd
enum SvgLineJoin
4 variants
Miter
MiterClip
Round
Bevel
struct LogicalRect
2 fields
origin: LogicalPosition
size: LogicalSize
2 constructors
constructor create:
arg origin: LogicalPosition
arg size: LogicalSize
-> LogicalRect
constructor zero:
-> LogicalRect
6 methods
fn max_x:
&self
-> f32
fn min_x:
&self
-> f32
fn max_y:
&self
-> f32
fn min_y:
&self
-> f32
fn contains:
&self
arg point: LogicalPosition
-> bool
fn intersects:
&self
arg other: LogicalRect
-> bool
Returns whether this rectangle contains the given point
Returns whether this rectangle intersects with another rectangle
union enum SvgFitTo
4 variants
Original
Width(u32)
Height(u32)
Zoom(f32)
union enum CssPathPseudoSelector
has destructor13 variants
First
Last
NthChild(CssNthChildSelector)
Hover
Active
Focus
SeatFocus
Lang(String)
Backdrop
Dragging
DragOver
Root
Placeholder
union enum CssPathSelector
has destructor11 variants
Global
Root(CssScopeRange)
Type(NodeTypeTag)
Class(String)
Id(String)
PseudoSelector(CssPathPseudoSelector)
Attribute(CssAttributeSelector)
DirectChildren
Children
AdjacentSibling
GeneralSibling
struct CssPath
has destructor1 field
selectors: CssPathSelectorVec
struct ShapeCircle
2 fields
center: ShapePoint
radius: f32
struct ShapePolygon
1 field
points: ShapePointVec
struct TessellatedGPUSvgNode
has destructor1 field
vertex_index_buffer: VertexBuffer
1 constructor
constructor create:
arg node: TessellatedSvgNode
arg gl: GlContextPtr
Uploads the tesselated SVG node to GPU memory
1 method
fn draw:
&self
arg texture: *mut Texture
arg target_size: PhysicalSizeU32
arg color: ColorU
arg transforms: StyleTransformVec
-> bool
Draw the vertex buffer to the texture with the given color and transform
struct TessellatedColoredGPUSvgNode
has destructor1 field
vertex_index_buffer: VertexBuffer
struct CssPathSelectorVecSlice
has destructor2 fields
ptr: CssPathSelector
len: usize
struct SvgDashPattern
7 fields
offset: f32
length_1: f32
gap_1: f32
length_2: f32
gap_2: f32
length_3: f32
gap_3: f32
enum SvgLineCap
3 variants
Butt
Square
Round
struct SvgVector
2 fields
x: f64
y: f64
2 methods
fn angle_degrees:
&self
-> f64
fn rotate_90deg_ccw:
&self
-> SvgVector
Returns the angle of the vector in degrees
Rotate the vector 90 degrees counter-clockwise
struct SvgPoint
2 fields
x: f32
y: f32
struct SvgPathVecSlice
2 fields
ptr: SvgPath
len: usize
struct SvgPathElementVecSlice
2 fields
ptr: SvgPathElement
len: usize
struct LogicalRectVecSlice
2 fields
mod dialog
14 typesNative OS dialog wrappers (message boxes, file open/save, color picker) built on
tfd.struct MsgBox
Static-method namespace for
tfd-backed message-box dialogs.1 field
_reserved: u8
1 constructor
4 methods
fn info:
arg content: String
fn yes_no:
arg title: String
arg message: String
arg icon: MsgBoxIcon
arg default: YesNo
-> YesNo
fn ok:
arg title: String
arg message: String
arg icon: MsgBoxIcon
fn ok_cancel:
arg title: String
arg message: String
arg icon: MsgBoxIcon
arg default: OkCancel
-> OkCancel
Convenience: Ok-only message box titled "Info" with an info icon.
Show a Yes/No message box and return which button the user pressed.
Show an Ok-only message box. Quotes are stripped from the message to avoid
tfdshell-escape issues on some platforms.Show an Ok/Cancel message box and return which button the user pressed.
struct FileDialog
Static-method namespace for
tfd-backed file dialogs.1 field
_reserved: u8
1 constructor
constructor create:
-> FileDialog
Returns a zero-initialised handle. The struct only exists so the FFI layer can hang static methods off it.
5 methods
fn open_file:
arg title: String
arg default_path: OptionString
arg filter_list: OptionFileTypeList
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn save_file:
arg title: String
arg suggested_name: String
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn open_directory:
arg title: String
arg default_path: OptionString
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
arg title: String
arg default_path: OptionString
arg filter_list: OptionFileTypeList
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn save_bytes:
Open a single file and resume
on_resultwith aFileOpenResult(pathisNoneif the user cancelled). Downcast withFileOpenResult::downcast(result). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched. Browsers only open a picker from a user gesture: a request issued outside one (from a timer, for example) resolves withpath: None.Save-file dialog: resumes
on_resultwith aSaveTargetResultwhosetarget(Noneif cancelled) is WHERE TO WRITE, not a string path - seeSaveTarget.suggested_nameis the file name the dialog proposes, not a path. Decision tree: an app that only ever exports a blob of bytes (a PDF, an image) should callsave_bytesand never see a target; usesave_filewhen the app needs to write the same file again later. On web the real-path form exists only on Chromium; Firefox and Safari resolve with aDownloadtarget whoseas_pathisNone. Same contract asopen_file.Open a directory and resume
on_resultwith aFileOpenResultwhosepathis the chosen directory (Noneif cancelled). Same contract asopen_file. On web only Chromium has a directory picker; the portable fallback yields a read-only snapshot of the chosen tree mounted at the returned virtual path.Open multiple files and resume
on_resultwith aFileOpenMultiResult(pathsis empty if the user cancelled). Same contract asopen_file.Hand the user a file:
bytesundersuggested_name(a file name, not a path) with the given MIME type. Fire-and-forget:truemeans the export was performed (desktop: the user picked a location in the native save dialog and the file was written) or scheduled (web: a download was triggered);falsemeans cancelled or failed. This is the portable "export a document" primitive - it works from any event-driven callback chain on every target and needs no write target and no path. Compose it withCallbackInfo::take_screenshotorPdf::save_to_bytes.struct ColorPickerDialog
Static-method namespace for the
tfd-backed color picker dialog.1 field
_reserved: u8
1 constructor
constructor create:
Returns a zero-initialised handle. The struct only exists so the FFI layer can hang static methods off it.
1 method
fn open:
arg title: String
arg default_value: OptionColorU
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
Open the system color picker and resume
on_resultwith aColorPickResult(colorisNoneif the user cancelled). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched. Browsers only open the picker from a user gesture, and<input type=color>has no cancel event everywhere, so a blur without a change resolves asNone.enum MsgBoxIcon
Icon to display in the message box.
4 variants
Info
Warning
Error
Question
enum OkCancel
Result of an Ok/Cancel message box.
2 variants
Ok
Cancel
enum YesNo
Result of a Yes/No message box.
2 variants
Yes
No
struct DialogAriaInfo
has destructorAccessibility information for a
<dialog>element.5 fields
label: OptionString
described_by: OptionString
description: OptionString
role: AccessibilityRole
modal: bool
1 constructor
4 methods
fn with_modal:
self
arg modal: bool
self
arg described_by: String
fn with_role:
self
arg role: AccessibilityRole
fn with_description:
self
arg desc: String
Returns a copy with the given modality flag.
Returns a copy with
aria-describedbypointing at the given node ID.Returns a copy with the given accessibility role.
Returns a copy with the given inline description.
enum SysDialogType
A built-in system dialog the engine presents on the app's behalf (always CPU-rendered).
4 variants
ReportProblem
UpdateVersion
TelemetryConsent
GpuCheck
struct FileOpenResult
has destructorResult of
FileDialog::open_file/open_directory.pathisNoneif cancelled.1 field
path: OptionFilePath
struct FileOpenMultiResult
has destructorResult of
FileDialog::open_multiple_files.pathsis empty if cancelled.1 field
paths: FilePathVec
struct ColorPickResult
Result of
ColorPickerDialog::open.colorisNoneif cancelled.1 field
color: OptionColorU
enum SaveTargetKind
What kind of write target a
SaveTargetis.3 variants
A real filesystem path (
as_pathisSome) - desktop and mobile.Path
A browser File-System-Access handle (Chromium);
as_pathisNone.WebHandle
The portable browser fallback:
write_bytestriggers a download;as_pathisNone.Download
struct SaveTarget
has destructorAn opaque write target obtained from
FileDialog::save_file. Desktop: a real path. Web: a File-System-Access handle (Chromium) or aDownloadsentinel (Firefox / Safari, which will not ship the handle API), whereas_pathreturnsNone. Apps that only ever export bytes should callFileDialog::save_bytesinstead and never touch this type.3 fields
kind: SaveTargetKind
path: OptionFilePath
Identifies the browser-side handle for
WebHandletargets;0otherwise.handle_id: u64
2 methods
fn write_bytes:
&self
arg bytes: U8Vec
-> bool
fn as_path:
&self
Write
bytesto the target. Fire-and-forget:truemeans the write was performed (desktop) or scheduled (web); durability is not implied.The real path behind the target, or
Noneon the browser fallbacks.struct SaveTargetResult
has destructorResult of
FileDialog::save_file.targetisNoneif cancelled.1 field
target: OptionSaveTarget
mod xml
25 typesXML parsing / decoding module
struct Xml
has destructor1 field
root: XmlNodeChildVec
1 constructor
1 method
&self
Scan the XML/HTML document for external resource URLs.
More
This function traverses the entire document tree and extracts URLs from: -
<img src="...">- Images -<link href="...">- Stylesheets, icons, fonts -<script src="...">- Scripts -<video src="...">,<source src="...">- Video -<audio src="...">- Audio -<a href="...">- Links (classified as Unknown) - CSSurl()in style attributes -<style>blocks with @import or url()struct ParsedSvg
has destructor2 fields
svg_data: U8Vec
run_destructor: bool
2 constructors
constructor from_string:
arg svg_string: String
arg parse_options: SvgParseOptions
constructor from_bytes:
arg svg_bytes: U8VecRef
arg parse_options: SvgParseOptions
Parses an SVG from a string
Parses an SVG from bytes
1 method
fn render:
&self
arg options: SvgRenderOptions
Renders the SVG to a raw image
struct ExternalResource
has destructor5 fields
url: String
kind: ExternalResourceKind
mime_type: OptionMimeTypeHint
source_element: String
source_attribute: String
union enum CssFontWeightParseErrorOwned
has destructor2 variants
InvalidValue(InvalidValueErrOwned)
InvalidNumber(ParseIntError)
union enum GridAutoFlowParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct CssParseErrorOwned
has destructor3 fields
union enum FlexGrowParseErrorOwned
has destructor2 variants
ParseFloat(ParseFloatErrorWithInput)
NegativeValue(String)
union enum CssParseErrorInnerOwned
has destructor8 variants
ParseError(CssSyntaxError)
UnclosedBlock
MalformedCss
DynamicCssParseError(DynamicCssParseErrorOwned)
PseudoSelectorParseError(CssPseudoSelectorParseErrorOwned)
NodeTypeTag(NodeTypeTagParseErrorOwned)
UnknownPropertyKey(UnknownPropertyKeyError)
VarOnShorthandProperty(VarOnShorthandPropertyError)
union enum ParenthesisParseErrorOwned
has destructor5 variants
union enum NodeTypeTagParseErrorOwned
has destructor1 variant
Invalid(String)
union enum CssPseudoSelectorParseErrorOwned
has destructor4 variants
EmptyNthChild
UnknownSelector(UnknownSelectorError)
InvalidNthChildPattern(String)
InvalidNthChild(ParseIntError)
union enum FlexWrapParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum GridParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum FlexBasisParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum FlexShrinkParseErrorOwned
has destructor2 variants
ParseFloat(ParseFloatErrorWithInput)
NegativeValue(String)
union enum DynamicCssParseErrorOwned
has destructor2 variants
InvalidBraceContents(String)
UnexpectedValue(CssParsingErrorOwned)
union enum FlowIntoParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum FlowFromParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct ExternalResourceVecSlice
has destructor2 fields
enum ExternalResourceKind
8 variants
Image
Font
Stylesheet
Script
Icon
Video
Audio
Unknown
union enum CssAppRegionParseErrorOwned
has destructor1 variant
InvalidValue(String)
union enum OverscrollBehaviorParseErrorOwned
has destructor1 variant
InvalidValue(String)
struct XmlTagName
has destructorTag of an XML node, such as the "button" in
<button>Hello</button>.1 field
inner: String
mod font
11 typesFont decoding / parsing module
struct FontRef
has destructorFontRef is a reference-counted pointer to a parsed font. It holds a *const c_void that points to the actual parsed font data (typically a ParsedFont from the layout crate). The parsed data is managed via atomic reference counting, allowing safe sharing across threads without duplicating the font data.
5 fields
parsed: c_void
copies: c_void
id: u64
run_destructor: bool
parsed_destructor: FontRefDestructorCallbackType
2 constructors
constructor parse:
arg source: LoadedFontSource
constructor create:
arg parsed: *const c_void
arg destructor: FontRefDestructorCallbackType
-> FontRef
Parses a new font from bytes. Returns
Noneif the font could not be parsed correctly.Create a new FontRef from parsed font data
More
# Arguments *
parsed- Pointer to parsed font data (e.g., Arc::into_raw(Arc::new(ParsedFont))) *destructor- Function to clean up the parsed data3 methods
fn get_bytes:
&self
-> U8Vec
fn get_font_metrics:
&self
-> FontMetrics
fn get_hash:
&self
-> u64
Returns the font bytes of the underlying font source
Returns the font metrics of the parsed font
Returns the hash of the FontRef (fast)
struct FontMetrics
Font metrics structure containing all font-related measurements from the font file tables (head, hhea, and os/2 tables).
55 fields
ul_code_page_range1: OptionU32
ul_code_page_range2: OptionU32
ul_unicode_range1: u32
ul_unicode_range2: u32
ul_unicode_range3: u32
ul_unicode_range4: u32
ach_vend_id: u32
s_typo_ascender: OptionI16
s_typo_descender: OptionI16
s_typo_line_gap: OptionI16
us_win_ascent: OptionU16
us_win_descent: OptionU16
sx_height: OptionI16
s_cap_height: OptionI16
us_default_char: OptionU16
us_break_char: OptionU16
us_max_context: OptionU16
us_lower_optical_point_size: OptionU16
us_upper_optical_point_size: OptionU16
units_per_em: u16
font_flags: u16
x_min: i16
y_min: i16
x_max: i16
y_max: i16
ascender: i16
descender: i16
line_gap: i16
advance_width_max: u16
min_left_side_bearing: i16
min_right_side_bearing: i16
x_max_extent: i16
caret_slope_rise: i16
caret_slope_run: i16
caret_offset: i16
num_h_metrics: u16
x_avg_char_width: i16
us_weight_class: u16
us_width_class: u16
fs_type: u16
y_subscript_x_size: i16
y_subscript_y_size: i16
y_subscript_x_offset: i16
y_subscript_y_offset: i16
y_superscript_x_size: i16
y_superscript_y_size: i16
y_superscript_x_offset: i16
y_superscript_y_offset: i16
y_strikeout_size: i16
y_strikeout_position: i16
s_family_class: i16
fs_selection: u16
us_first_char_index: u16
us_last_char_index: u16
panose: Panose
1 constructor
constructor zero:
-> FontMetrics
Returns a FontMetrics struct with all fields set to 0
21 methods
fn use_typo_metrics:
&self
-> bool
fn get_ascender:
&self
-> i16
fn get_descender:
&self
-> i16
fn get_line_gap:
&self
-> i16
fn get_x_min:
&self
-> i16
fn get_y_min:
&self
-> i16
fn get_x_max:
&self
-> i16
fn get_y_max:
&self
-> i16
&self
-> u16
&self
-> i16
fn get_min_right_side_bearing:
&self
-> i16
fn get_x_max_extent:
&self
-> i16
&self
-> i16
&self
-> i16
&self
-> i16
&self
-> i16
&self
-> i16
&self
-> i16
&self
-> i16
fn get_y_superscript_x_offset:
&self
-> i16
fn get_y_superscript_y_offset:
&self
-> i16
Returns whether typographic metrics should be used (from fs_selection flag)
Returns the ascender value from the hhea table
Returns the descender value from the hhea table
Returns the line gap value from the hhea table
Returns the x_min value from the head table
Returns the y_min value from the head table
Returns the x_max value from the head table
Returns the y_max value from the head table
Returns the maximum advance width from the hhea table
Returns the minimum left side bearing from the hhea table
Returns the minimum right side bearing from the hhea table
Returns the maximum extent in the x direction from the hhea table
Returns the average character width from the os/2 table
Returns the subscript x size from the os/2 table
Returns the subscript y size from the os/2 table
Returns the subscript x offset from the os/2 table
Returns the subscript y offset from the os/2 table
Returns the superscript x size from the os/2 table
Returns the superscript y size from the os/2 table
Returns the superscript x offset from the os/2 table
Returns the superscript y offset from the os/2 table
struct LoadedFont
has destructor4 fields
1 constructor
constructor create:
arg font_hash: u64
arg family_name: String
arg num_glyphs: u32
arg has_bytes: bool
-> LoadedFont
struct LoadedFontSource
has destructorSource data of a font file (bytes)
3 fields
struct Panose
10 fields
family_type: u8
serif_style: u8
weight: u8
proportion: u8
contrast: u8
stroke_variation: u8
arm_style: u8
letterform: u8
midline: u8
x_height: u8
struct LoadedFontVecSlice
has destructor2 fields
struct FontCacheSnapshot
Boxed snapshot of a window's font resolution state (shared parsed-font pool, resolved fallback chains, embedded fonts). Obtain via
CallbackInfo.get_font_cache_clone(); hand toPdf.from_styled_dom_with_resources(). Cloning shares the pool (cheap); valid after the callback returns (off-thread ok).2 fields
ptr: c_void
run_destructor: bool
2 constructors
constructor from_layout_info:
arg info: *const LayoutCallbackInfo
constructor empty:
Wrap a font manager into an ABI handle. Snapshot for use inside a LAYOUT callback: builds family resolution + fallback chains over the system font cache the callback exposes. No per-window embedded fonts exist yet at layout time, so nothing is lost versus
CallbackInfo::get_font_cache_clone- this is the off-thread-pagination input an app can hand toPdf::compute_paginationwithout ever seeing the internal manager.An empty handle (also what the non-
text_layoutbuild returns).struct NamedFontVecSlice
has destructor2 fields
union enum FontLoadingConfig
has destructorConfiguration for how fonts should be loaded at app startup.
3 variants
struct NamedFont
has destructorA named font bundled with the application (name + raw bytes). The name is used to reference the font in CSS (e.g. font-family: "MyFont").
2 fields
enum FontDatabase
2 variants
Empty
System
mod gl
28 typesOpenGl helper types (
Texture,Gl, etc.)struct Texture
has destructorOpenGL texture, use
ReadOnlyWindow::create_textureto create a texture8 fields
gl_context: GlContextPtr
texture_id: GLuint
refcount: c_void
size: PhysicalSizeU32
format: RawImageFormat
background_color: ColorU
flags: TextureFlags
run_destructor: bool
3 constructors
constructor allocate_rgba8:
arg gl_context: GlContextPtr
arg size: PhysicalSizeU32
arg background: ColorU
-> Texture
constructor create:
arg texture_id: GLuint
arg flags: TextureFlags
arg size: PhysicalSizeU32
arg background_color: ColorU
arg gl_context: GlContextPtr
arg format: RawImageFormat
-> Texture
constructor allocate_clip_mask:
arg gl: GlContextPtr
arg size: PhysicalSizeU32
arg background: ColorU
-> Texture
Allocates an OpenGL texture of a given size with a single red channel (used for image masks)
8 methods
fn draw_tesselated_svg_gpu_node:
&mut self
arg node: TessellatedGPUSvgNode
arg size: PhysicalSizeU32
arg color: ColorU
arg transforms: StyleTransformVec
-> bool
fn clear:
&mut self
fn apply_fxaa:
&mut self
-> bool
fn get_descriptor:
&self
fn draw_tesselated_colored_svg_gpu_node:
&mut self
arg node: TessellatedColoredGPUSvgNode
arg size: PhysicalSizeU32
arg transforms: StyleTransformVec
-> bool
fn paint_dot:
&mut self
arg cx: f32
arg cy: f32
arg brush: Brush
fn paint_stroke:
&mut self
arg x0: f32
arg y0: f32
arg x1: f32
arg y1: f32
arg brush: Brush
&self
-> RawImage
Draws a
TessellatedGPUSvgNodewith the given color to the textureApplies an FXAA filter to the texture
Draws a
TessellatedColoredGPUSvgNodeto the textureGPU painting: stamp one soft-brush dab centered at (
cx,cy) in texture pixel coordinates (origin top-left, matching [RawImage::paint_dot]). No-op if the GL context is unusable -- the caller should then use the CPURawImagepath (GlContextPtr::is_gl_usable).GPU painting: stamp dabs along (
x0,y0)->(x1,y1) into this texture via an FBO + the soft-brush shader, alpha-over blended. Same spacing + falloff as the CPURawImage::paint_stroke. No-op if GL is unusable.Read this texture's pixels back into an RGBA8
RawImage(top-left origin) -- for exporting the painted canvas to disk. Binds an FBO + glReadPixels.struct GlContextPtr
has destructor3 fields
225 methods
fn get_type:
&self
-> GlType
&self
arg target: GLenum
arg size: GLsizeiptr
arg data: GlVoidPtrConst
arg usage: GLenum
&self
arg target: GLenum
arg offset: isize
arg size: GLsizeiptr
arg data: GlVoidPtrConst
fn map_buffer:
&self
arg target: GLenum
arg access: GLbitfield
-> GlVoidPtrMut
fn map_buffer_range:
&self
arg target: GLenum
arg offset: GLintptr
arg length: GLsizeiptr
arg access: GLbitfield
-> GlVoidPtrMut
fn unmap_buffer:
fn tex_buffer:
fn read_buffer:
&self
arg mode: GLenum
fn read_pixels:
fn sample_coverage:
&self
arg value: GLclampf
arg invert: bool
fn polygon_offset:
fn pixel_store_i:
fn gen_buffers:
fn gen_framebuffers:
fn gen_textures:
fn gen_queries:
fn begin_query:
fn end_query:
&self
arg target: GLenum
fn query_counter:
fn delete_queries:
&self
arg queries: GLuintVecRef
&self
arg vertex_arrays: GLuintVecRef
fn delete_buffers:
&self
arg buffers: GLuintVecRef
&self
arg renderbuffers: GLuintVecRef
&self
arg framebuffers: GLuintVecRef
fn delete_textures:
&self
arg textures: GLuintVecRef
fn depth_func:
&self
arg func: GLenum
fn active_texture:
&self
arg texture: GLenum
fn attach_shader:
fn get_uniform_iv:
&self
arg program: GLuint
arg location: GLint
arg result: GLintVecRefMut
fn get_uniform_fv:
&self
arg program: GLuint
arg location: GLint
arg result: GLfloatVecRefMut
fn bind_buffer_base:
&self
arg target: GLenum
arg index: GLuint
arg buffer: GLuint
arg offset: GLintptr
arg size: GLsizeiptr
fn bind_buffer:
&self
arg vao: GLuint
fn bind_framebuffer:
fn bind_texture:
fn draw_buffers:
&self
arg bufs: GLenumVecRef
fn tex_image_2d:
fn tex_image_3d:
fn tex_sub_image_2d:
fn tex_sub_image_3d:
fn tex_storage_2d:
fn tex_storage_3d:
&self
arg target: GLenum
arg level: GLint
arg format: GLenum
arg ty: GLenum
arg output: U8VecRefMut
&self
arg target: GLenum
arg attachments: GLenumVecRef
fn get_integer_v:
&self
arg name: GLenum
arg result: GLintVecRefMut
fn get_integer_64v:
&self
arg name: GLenum
arg result: GLint64VecRefMut
fn get_integer_iv:
&self
arg name: GLenum
arg index: GLuint
arg result: GLintVecRefMut
fn get_integer_64iv:
&self
arg name: GLenum
arg index: GLuint
arg result: GLint64VecRefMut
fn get_boolean_v:
&self
arg name: GLenum
arg result: GLbooleanVecRefMut
fn get_float_v:
&self
arg name: GLenum
arg result: GLfloatVecRefMut
fn tex_parameter_i:
fn tex_parameter_f:
fn blit_framebuffer:
fn vertex_attrib_4f:
fn viewport:
fn scissor:
fn line_width:
&self
arg width: GLfloat
fn use_program:
&self
arg program: GLuint
fn validate_program:
&self
arg program: GLuint
fn draw_arrays:
fn draw_elements:
fn blend_color:
&self
arg r: f32
arg g: f32
arg b: f32
arg a: f32
fn blend_func:
fn blend_equation:
&self
arg mode: GLenum
fn color_mask:
&self
arg r: bool
arg g: bool
arg b: bool
arg a: bool
fn cull_face:
&self
arg mode: GLenum
fn front_face:
&self
arg mode: GLenum
fn enable:
&self
arg cap: GLenum
fn disable:
&self
arg cap: GLenum
fn hint:
fn is_enabled:
fn is_shader:
fn is_texture:
fn is_framebuffer:
fn is_renderbuffer:
fn enable_vertex_attrib_array:
&self
arg index: GLuint
fn disable_vertex_attrib_array:
&self
arg index: GLuint
fn uniform_1f:
fn uniform_1fv:
fn uniform_1i:
fn uniform_1iv:
fn uniform_1ui:
fn uniform_2f:
fn uniform_2fv:
fn uniform_2i:
fn uniform_2iv:
fn uniform_2ui:
fn uniform_3f:
fn uniform_3fv:
fn uniform_3i:
fn uniform_3iv:
fn uniform_3ui:
fn uniform_4f:
fn uniform_4i:
fn uniform_4iv:
fn uniform_4ui:
fn uniform_4fv:
fn depth_mask:
&self
arg flag: bool
fn depth_range:
&self
arg near: f64
arg far: f64
fn get_program_iv:
&self
arg program: GLuint
arg pname: GLenum
arg result: GLintVecRefMut
&self
arg program: GLuint
fn program_binary:
&self
arg index: GLuint
arg pname: GLenum
arg result: GLintVecRefMut
&self
arg index: GLuint
arg pname: GLenum
arg result: GLfloatVecRefMut
fn get_vertex_attrib_pointer_v:
&self
arg index: GLuint
arg pname: GLenum
-> GLsizeiptr
fn get_shader_iv:
&self
arg shader: GLuint
arg pname: GLenum
arg result: GLintVecRefMut
fn compile_shader:
&self
arg shader: GLuint
fn create_program:
&self
-> GLuint
fn delete_program:
&self
arg program: GLuint
fn create_shader:
fn delete_shader:
&self
arg shader: GLuint
fn detach_shader:
fn link_program:
&self
arg program: GLuint
fn clear_color:
&self
arg r: f32
arg g: f32
arg b: f32
arg a: f32
fn clear:
&self
arg buffer_mask: GLbitfield
fn clear_depth:
&self
arg depth: f64
fn clear_stencil:
&self
arg s: GLint
fn flush:
&self
fn finish:
&self
fn get_error:
&self
-> GLenum
fn stencil_mask:
&self
arg mask: GLuint
fn stencil_func:
fn stencil_op:
fn egl_image_target_texture2d_oes:
&self
arg target: GLenum
arg image: GlVoidPtrConst
fn generate_mipmap:
&self
arg target: GLenum
&self
&self
fn fence_sync:
&self
arg condition: GLenum
arg flags: GLbitfield
-> GLsyncPtr
fn client_wait_sync:
&self
arg sync: GLsyncPtr
arg flags: GLbitfield
arg timeout: GLuint64
-> u32
fn wait_sync:
&self
arg sync: GLsyncPtr
arg flags: GLbitfield
arg timeout: GLuint64
fn delete_sync:
&self
arg sync: GLsyncPtr
fn gen_fences_apple:
&self
arg fences: GLuintVecRef
fn set_fence_apple:
&self
arg fence: GLuint
&self
arg fence: GLuint
fn test_fence_apple:
&self
arg fence: GLuint
&self
&self
&self
arg mode: GLenum
&self
arg vao: GLuint
fn delete_vertex_arrays_apple:
&self
arg vertex_arrays: GLuintVecRef
&self
arg source_id: GLuint
arg source_level: GLint
arg dest_target: GLenum
arg dest_id: GLuint
arg dest_level: GLint
arg x_offset: GLint
arg y_offset: GLint
arg x: GLint
arg y: GLint
arg width: GLsizei
arg height: GLsizei
arg unpack_flip_y: GLboolean
arg unpack_premultiply_alpha: GLboolean
arg unpack_unmultiply_alpha: GLboolean
fn egl_image_target_renderbuffer_storage_oes:
&self
arg target: u32
arg image: GlVoidPtrConst
&self
arg source_id: GLuint
arg source_level: GLint
arg dest_target: GLenum
arg dest_id: GLuint
arg dest_level: GLint
arg x_offset: GLint
arg y_offset: GLint
arg z_offset: GLint
arg x: GLint
arg y: GLint
arg z: GLint
arg width: GLsizei
arg height: GLsizei
arg depth: GLsizei
arg unpack_flip_y: GLboolean
arg unpack_premultiply_alpha: GLboolean
arg unpack_unmultiply_alpha: GLboolean
fn buffer_storage:
&self
arg target: GLenum
arg size: GLsizeiptr
arg data: GlVoidPtrConst
arg flags: GLbitfield
&self
arg target: GLenum
arg offset: GLintptr
arg length: GLsizeiptr
fn get_svg_shader:
&self
-> GLuint
fn get_fxaa_shader:
&self
-> GLuint
fn shader_source:
&self
arg program: GLuint
arg names: RefstrVecRef
-> GLuintVec
fn get_string:
fn get_string_i:
&self
arg message: String
&self
arg message: String
&self
-> String
fn is_gl_usable:
&self
-> bool
The GLSL
#versionthe driver accepted at construction (e.g. "150" or "300 es"), discovered by the probe. Empty string if the context is unusable / software. Exposed in the API so apps can report/branch on it.Whether this hardware GL context proved usable at construction (the SVG shaders compiled+linked at some GLSL version).
falsemeans context creation succeeded but the driver can't run our shaders -- the caller should fall back to CPU rendering. Alwaysfalsefor a Software context (which never compiles these shaders); only meaningful on the GPU path.struct TextureFlags
2 fields
Whether this texture contains an alpha component
is_opaque: bool
Optimization: use the compositor instead of OpenGL for energy optimization
is_video_texture: bool
enum GlType
2 variants
Gl
Gles
struct VertexArrayObject
has destructor5 fields
vertex_layout: VertexLayout
vao_id: GLuint
gl_context: GlContextPtr
refcount: c_void
run_destructor: bool
struct VertexBuffer
has destructor8 fields
vao: VertexArrayObject
vertex_buffer_id: GLuint
vertex_buffer_len: usize
index_buffer_id: GLuint
index_buffer_len: usize
refcount: c_void
index_buffer_format: IndexBufferFormat
run_destructor: bool
struct GlVoidPtrConst
has destructorPassing *const c_void is not easily possible when generating APIs, so this wrapper struct is for easier API generation
2 fields
ptr: c_void
run_destructor: bool
struct GlVoidPtrMut
1 field
ptr: c_void
struct GetProgramBinaryReturn
has destructorC-ABI stable reexport of
(U8Vec, u32)2 fields
_0: U8Vec
_1: u32
struct GetActiveAttribReturn
has destructorC-ABI stable reexport of
(i32, u32, AzString)3 fields
struct GLsyncPtr
has destructorC-ABI stable reexport of
*const gleam::gl::GLsync2 fields
ptr: c_void
run_destructor: bool
struct GetActiveUniformReturn
has destructorC-ABI stable reexport of
(i32, u32, AzString)3 fields
struct SvgVertex
2 fields
x: f32
y: f32
enum IndexBufferFormat
6 variants
Points
Lines
LineStrip
Triangles
TriangleStrip
TriangleFan
struct SvgVertexVecSlice
2 fields
struct DebugMessageVecSlice
has destructor2 fields
struct GLuintVecSlice
2 fields
ptr: GLuint
len: usize
struct GLintVecSlice
2 fields
mod component
31 typesComponent system for reusable UI building blocks.
struct ComponentMap
has destructor1 field
libraries: ComponentLibraryVec
1 constructor
constructor create:
-> ComponentMap
0 methods
struct ComponentLibrary
has destructor8 fields
name: String
version: String
description: String
components: ComponentDefVec
exportable: bool
modifiable: bool
data_models: ComponentDataModelVec
enum_models: ComponentEnumModelVec
struct ComponentDef
has destructor10 fields
id: ComponentId
display_name: String
description: String
css: String
source: ComponentSource
data_model: ComponentDataModel
render_fn: ComponentRenderFn
compile_fn: ComponentCompileFn
render_fn_source: OptionString
compile_fn_source: OptionString
0 methods
enum ComponentEventFilter
9 variants
AfterMount
BeforeUnmount
NodeResized
DefaultAction
Selected
Updated
Dismissed
TornOff
Docked
struct ComponentDataModel
has destructor3 fields
union enum ComponentFieldType
has destructor20 variants
String
Bool
I32
I64
U32
U64
Usize
F32
F64
ColorU
CssProperty
ImageRef
FontRef
StyledDom
Callback(ComponentCallbackSignature)
RefAny(String)
OptionType(ComponentFieldTypeBox)
VecType(ComponentFieldTypeBox)
StructRef(String)
EnumRef(String)
union enum ComponentDefaultValue
has destructor14 variants
None
String(String)
Bool(bool)
I32(i32)
I64(i64)
U32(u32)
U64(u64)
Usize(usize)
F32(f32)
F64(f64)
ColorU(ColorU)
ComponentInstance(ComponentInstanceDefault)
CallbackFnPointer(String)
Json(String)
enum CompileTarget
4 variants
Rust
C
Cpp
Python
struct ComponentId
has destructor2 constructors
constructor builtin:
arg name: String
-> ComponentId
constructor create:
arg collection: String
arg name: String
-> ComponentId
1 method
fn qualified_name:
&self
-> String
Returns "collection:name" format string
struct ComponentDataField
has destructor5 fields
name: String
field_type: ComponentFieldType
default_value: OptionComponentDefaultValue
required: bool
description: String
struct ComponentCompileFn
Opaque compile function pointer for component code generation.
1 field
_internal: usize
struct ComponentRenderFn
Opaque render function pointer for component DOM rendering.
1 field
_internal: usize
fnptr RegisterComponentLibraryFnType
Raw function pointer that returns a complete ComponentLibrary when called.
More
Pass one to AppConfig.add_component_library to register a vendored component set. The library is built once, at registration time.
signature
enum CssColorComponent
7 variants
Red
Green
Blue
Hue
Saturation
Lightness
Alpha
struct ComponentEnumVariant
has destructor3 fields
struct ComponentDataFieldVecSlice
has destructor2 fields
struct ComponentLibraryVecSlice
has destructor2 fields
struct ComponentEnumModel
has destructor3 fields
struct ComponentDefVecSlice
has destructor2 fields
struct ComponentDataModelVecSlice
has destructor2 fields
struct ComponentEnumVariantVecSlice
has destructor2 fields
struct ComponentFieldTypeBox
1 field
ptr: c_void
struct ComponentEnumModelVecSlice
has destructor2 fields
struct ComponentFieldOverride
has destructor2 fields
field_name: String
source: ComponentFieldValueSource
struct ComponentInstanceDefault
has destructor3 fields
struct ComponentCallbackSignature
has destructor2 fields
return_type: String
args: ComponentCallbackArgVec
struct ComponentCallbackArg
has destructor2 fields
name: String
arg_type: ComponentFieldType
struct ComponentFieldOverrideVecSlice
has destructor2 fields
struct ComponentCallbackArgVecSlice
has destructor2 fields
mod http
10 typesHTTP client module for downloading resources (language packs, etc.)
struct HttpRequestConfig
has destructor6 fields
timeout_secs: u64
max_response_size: u64
user_agent: String
headers: HttpHeaderVec
disable_tls_cert_verification: bool
client: OptionHttpClient
1 constructor
constructor create:
Create a new config with default values
10 methods
fn http_get:
&self
arg url: String
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn download_bytes:
&self
arg url: String
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn http_post:
fn with_timeout:
self
arg secs: u64
fn with_max_size:
self
arg max_bytes: u64
fn with_user_agent:
self
arg ua: String
fn with_header:
fn is_url_reachable:
&self
arg url: String
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn http_request:
&self
arg method: HttpMethod
arg url: String
arg body: U8Vec
arg content_type: String
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn with_client:
self
arg client: HttpClient
HTTP GET request using this configuration, resuming
on_resultwith anHttpGetResult(downcast withHttpGetResult::downcast(result)). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched. On web CORS applies and cannot be escaped: a target that does not sendAccess-Control-Allow-Originfails withHttpError::Othernaming CORS.Download a URL to bytes using this configuration, resuming
on_resultwith anHttpBytesResult(a non-2xx status is anHttpError::HttpStatus). Same contract ashttp_get.HTTP POST with a body, using this configuration, resuming
on_resultwith anHttpGetResult. Same contract ashttp_get.Set timeout in seconds
Set maximum response size (0 = unlimited)
Set User-Agent header
Add a header
Check whether a URL is reachable (a HEAD request answered with a 2xx status) using this configuration's timeout and TLS settings, resuming
on_resultwith anHttpReachableResult. On web opaqueno-corsanswers make "reachable" approximate. Same contract ashttp_get.HTTP request with an arbitrary verb and optional body, using this configuration, resuming
on_resultwith anHttpGetResult. An empty body sends no body (GET/HEAD semantics);content_typeonly applies when a body is present. Same contract ashttp_get.Send requests through a shared connection pool instead of opening a connection per request
struct HttpResponse
has destructor5 fields
5 methods
fn body_as_string:
&self
-> OptionString
fn is_success:
&self
-> bool
fn is_redirect:
&self
-> bool
fn is_client_error:
&self
-> bool
fn is_server_error:
&self
-> bool
Try to convert the body to a UTF-8 string
Check if the response was successful (2xx status)
Check if the response is a redirect (3xx status)
Check if the response is a client error (4xx status)
Check if the response is a server error (5xx status)
enum HttpMethod
HTTP verb for HttpRequestConfig::http_request.
6 variants
Get
Head
Post
Put
Patch
Delete
struct HttpHeaderVecSlice
has destructor2 fields
ptr: HttpHeader
len: usize
struct HttpGetResult
has destructorResult of
HttpRequestConfig::http_get/http_post/http_request.1 field
result: ResultHttpResponseHttpError
struct HttpBytesResult
has destructorResult of
HttpRequestConfig::download_bytes.1 field
result: ResultU8VecHttpError
struct HttpReachableResult
has destructorResult of
HttpRequestConfig::is_url_reachable.reachableistruefor a 2xx answer to a HEAD request;errorcarries the transport error when the request could not be made at all (Nonefor a plain non-2xx status).2 fields
reachable: bool
error: OptionString
struct HttpClient
A connection pool that requests can share (C-compatible handle).
More
Created by the application, never by the framework: a request without a client opens its own connection. Hand clones to
HttpRequestConfig::with_clientor to a widget; all clones share one pool, which closes its connections when the last clone is dropped.2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor create:
arg config: HttpClientConfig
-> HttpClient
Create a connection pool with the given settings
1 method
fn get_config:
&self
The settings this client was created with
struct HttpClientConfig
Settings for an
HttpClient's connection pool (C-compatible).4 fields
max_idle_connections: u32
max_idle_connections_per_host: u32
dns_cache_secs: u32
disable_tls_cert_verification: bool
1 constructor
constructor create:
Create a new config with default values
3 methods
self
arg n: u32
fn with_max_idle_connections_per_host:
self
arg n: u32
self
arg secs: u32
Set how many idle connections the pool keeps across all hosts
Set how many idle connections the pool keeps to any one host
Reuse each host's DNS answer for
secsseconds (0 = no cache)
mod vec
366 typesDefinition of azuls internal
Vec<*>wrappersstruct ListViewRowVec
has destructorWrapper over a Rust-allocated
Vec<ListViewRow>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ListViewRow
fn copy_from_ptr:
arg ptr: *const ListViewRow
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ListViewRowVecCreates a
ListViewRowVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ListViewRowVeccontaining a single elementCopies elements from a C array into a
ListViewRowVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ListViewRowVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleFilterVec
has destructorWrapper over a Rust-allocated
Vec<StyleFilter>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleFilter
fn copy_from_ptr:
arg ptr: *const StyleFilter
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleFilterVecCreates a
StyleFilterVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleFilterVeccontaining a single elementCopies elements from a C array into a
StyleFilterVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleFilterVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct AccessibilityStateVec
has destructorWrapper over a Rust-allocated
Vec<AccessibilityState>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: AccessibilityState
fn copy_from_ptr:
arg ptr: *const AccessibilityState
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
AccessibilityStateVecCreates a
AccessibilityStateVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
AccessibilityStateVeccontaining a single elementCopies elements from a C array into a
AccessibilityStateVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
AccessibilityStateVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct MenuItemVec
has destructorWrapper over a Rust-allocated
Vec<MenuItem>4 fields
11 methods
fn create:
-> MenuItemVec
fn with_capacity:
arg cap: usize
-> MenuItemVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: MenuItem
-> MenuItemVec
fn copy_from_ptr:
arg ptr: *const MenuItem
arg len: usize
-> MenuItemVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
MenuItemVecCreates a
MenuItemVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
MenuItemVeccontaining a single elementCopies elements from a C array into a
MenuItemVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
MenuItemVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleFontFamilyVec
has destructorWrapper over a Rust-allocated
Vec<StyleFontFamily>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleFontFamily
fn copy_from_ptr:
arg ptr: *const StyleFontFamily
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleFontFamilyVecCreates a
StyleFontFamilyVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleFontFamilyVeccontaining a single elementCopies elements from a C array into a
StyleFontFamilyVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleFontFamilyVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct DomVec
has destructorWrapper over a Rust-allocated
Vec<Dom>4 fields
11 methods
fn create:
-> DomVec
fn with_capacity:
arg cap: usize
-> DomVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionDom
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionDom
fn as_c_slice:
&self
-> DomVecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> DomVecSlice
Creates an empty
DomVecCreates a
DomVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
DomVeccontaining a single elementCopies elements from a C array into a
DomVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DomVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct IdOrClassVec
has destructorWrapper over a Rust-allocated
Vec<IdOrClass>4 fields
11 methods
fn create:
-> IdOrClassVec
fn with_capacity:
arg cap: usize
-> IdOrClassVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: IdOrClass
-> IdOrClassVec
fn copy_from_ptr:
arg ptr: *const IdOrClass
arg len: usize
-> IdOrClassVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
IdOrClassVecCreates a
IdOrClassVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
IdOrClassVeccontaining a single elementCopies elements from a C array into a
IdOrClassVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
IdOrClassVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct DynamicSelectorVec
has destructorWrapper over a Rust-allocated
Vec<DynamicSelector>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: DynamicSelector
fn copy_from_ptr:
arg ptr: *const DynamicSelector
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DynamicSelectorVecCreates a
DynamicSelectorVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
DynamicSelectorVeccontaining a single elementCopies elements from a C array into a
DynamicSelectorVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DynamicSelectorVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CssPropertyWithConditionsVec
has destructorWrapper over a Rust-allocated
Vec<CssPropertyWithConditions>4 fields
ptr: CssPropertyWithConditions
len: usize
cap: usize
destructor: CssPropertyWithConditionsVecDestructor
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
fn copy_from_ptr:
arg ptr: *const CssPropertyWithConditions
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CssPropertyWithConditionsVecCreates a
CssPropertyWithConditionsVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CssPropertyWithConditionsVeccontaining a single elementCopies elements from a C array into a
CssPropertyWithConditionsVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CssPropertyWithConditionsVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleBackgroundContentVec
has destructorWrapper over a Rust-allocated
Vec<StyleBackgroundContent>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleBackgroundContent
fn copy_from_ptr:
arg ptr: *const StyleBackgroundContent
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleBackgroundContentVecCreates a
StyleBackgroundContentVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleBackgroundContentVeccontaining a single elementCopies elements from a C array into a
StyleBackgroundContentVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleBackgroundContentVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleBackgroundPositionVec
has destructorWrapper over a Rust-allocated
Vec<StyleBackgroundPosition>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleBackgroundPosition
fn copy_from_ptr:
arg ptr: *const StyleBackgroundPosition
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleBackgroundPositionVecCreates a
StyleBackgroundPositionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleBackgroundPositionVeccontaining a single elementCopies elements from a C array into a
StyleBackgroundPositionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleBackgroundPositionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleBackgroundRepeatVec
has destructorWrapper over a Rust-allocated
Vec<StyleBackgroundRepeat>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleBackgroundRepeat
fn copy_from_ptr:
arg ptr: *const StyleBackgroundRepeat
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleBackgroundRepeatVecCreates a
StyleBackgroundRepeatVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleBackgroundRepeatVeccontaining a single elementCopies elements from a C array into a
StyleBackgroundRepeatVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleBackgroundRepeatVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleBackgroundSizeVec
has destructorWrapper over a Rust-allocated
Vec<StyleBackgroundSize>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleBackgroundSize
fn copy_from_ptr:
arg ptr: *const StyleBackgroundSize
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleBackgroundSizeVecCreates a
StyleBackgroundSizeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleBackgroundSizeVeccontaining a single elementCopies elements from a C array into a
StyleBackgroundSizeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleBackgroundSizeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyleTransformVec
has destructorWrapper over a Rust-allocated
Vec<StyleTransform>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyleTransform
fn copy_from_ptr:
arg ptr: *const StyleTransform
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleTransformVecCreates a
StyleTransformVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyleTransformVeccontaining a single elementCopies elements from a C array into a
StyleTransformVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleTransformVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct SvgVertexVec
has destructorWrapper over a Rust-allocated
Vec<SvgVertex>4 fields
11 methods
fn create:
-> SvgVertexVec
fn with_capacity:
arg cap: usize
-> SvgVertexVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: SvgVertex
-> SvgVertexVec
fn copy_from_ptr:
arg ptr: *const SvgVertex
arg len: usize
-> SvgVertexVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
SvgVertexVecCreates a
SvgVertexVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
SvgVertexVeccontaining a single elementCopies elements from a C array into a
SvgVertexVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
SvgVertexVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct VideoFrameVec
has destructorWrapper over a Rust-allocated
Vec<VideoFrame>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: VideoFrame
fn copy_from_ptr:
arg ptr: *const VideoFrame
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
VideoFrameVecCreates a
VideoFrameVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
VideoFrameVeccontaining a single elementCopies elements from a C array into a
VideoFrameVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
VideoFrameVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct U32Vec
has destructorWrapper over a Rust-allocated
Vec<u32>4 fields
11 methods
fn create:
-> U32Vec
fn with_capacity:
arg cap: usize
-> U32Vec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionU32
fn from_item:
arg item: u32
-> U32Vec
fn copy_from_ptr:
arg ptr: *const u32
arg len: usize
-> U32Vec
fn c_get:
&self
arg index: usize
-> OptionU32
fn as_c_slice:
&self
-> U32VecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> U32VecSlice
Creates an empty
U32VecCreates a
U32Vecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
U32Veccontaining a single elementCopies elements from a C array into a
U32Vec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
U32VecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct VirtualKeyCodeVec
has destructorWrapper over a Rust-allocated
Vec<VirtualKeyCode>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: VirtualKeyCode
fn copy_from_ptr:
arg ptr: *const VirtualKeyCode
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
VirtualKeyCodeVecCreates a
VirtualKeyCodeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
VirtualKeyCodeVeccontaining a single elementCopies elements from a C array into a
VirtualKeyCodeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
VirtualKeyCodeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CascadeInfoVec
has destructorWrapper over a Rust-allocated
Vec<CascadeInfo>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: CascadeInfo
fn copy_from_ptr:
arg ptr: *const CascadeInfo
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CascadeInfoVecCreates a
CascadeInfoVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CascadeInfoVeccontaining a single elementCopies elements from a C array into a
CascadeInfoVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CascadeInfoVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CssDeclarationVec
has destructorWrapper over a Rust-allocated
Vec<CssDeclaration>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: CssDeclaration
fn copy_from_ptr:
arg ptr: *const CssDeclaration
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CssDeclarationVecCreates a
CssDeclarationVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CssDeclarationVeccontaining a single elementCopies elements from a C array into a
CssDeclarationVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CssDeclarationVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CssPathSelectorVec
has destructorWrapper over a Rust-allocated
Vec<CssPathSelector>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: CssPathSelector
fn copy_from_ptr:
arg ptr: *const CssPathSelector
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CssPathSelectorVecCreates a
CssPathSelectorVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CssPathSelectorVeccontaining a single elementCopies elements from a C array into a
CssPathSelectorVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CssPathSelectorVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CssVec
has destructorWrapper over a Rust-allocated
Vec<Css>4 fields
11 methods
fn create:
-> CssVec
fn with_capacity:
arg cap: usize
-> CssVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionCss
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionCss
fn as_c_slice:
&self
-> CssVecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> CssVecSlice
Creates an empty
CssVecCreates a
CssVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CssVeccontaining a single elementCopies elements from a C array into a
CssVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CssVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CssRuleBlockVec
has destructorWrapper over a Rust-allocated
Vec<CssRuleBlock>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: CssRuleBlock
fn copy_from_ptr:
arg ptr: *const CssRuleBlock
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CssRuleBlockVecCreates a
CssRuleBlockVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CssRuleBlockVeccontaining a single elementCopies elements from a C array into a
CssRuleBlockVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CssRuleBlockVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct U16Vec
has destructorWrapper over a Rust-allocated
Vec<u16>4 fields
11 methods
fn create:
-> U16Vec
fn with_capacity:
arg cap: usize
-> U16Vec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionU16
fn from_item:
arg item: u16
-> U16Vec
fn copy_from_ptr:
arg ptr: *const u16
arg len: usize
-> U16Vec
fn c_get:
&self
arg index: usize
-> OptionU16
fn as_c_slice:
&self
-> U16VecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> U16VecSlice
Creates an empty
U16VecCreates a
U16Vecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
U16Veccontaining a single elementCopies elements from a C array into a
U16Vec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
U16VecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct F32Vec
has destructorWrapper over a Rust-allocated
Vec<f32>4 fields
11 methods
fn create:
-> F32Vec
fn with_capacity:
arg cap: usize
-> F32Vec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionF32
fn from_item:
arg item: f32
-> F32Vec
fn copy_from_ptr:
arg ptr: *const f32
arg len: usize
-> F32Vec
fn c_get:
&self
arg index: usize
-> OptionF32
fn as_c_slice:
&self
-> F32VecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> F32VecSlice
Creates an empty
F32VecCreates a
F32Vecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
F32Veccontaining a single elementCopies elements from a C array into a
F32Vec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
F32VecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct U8Vec
has destructorWrapper over a Rust-allocated
Vec<u8>4 fields
1 constructor
constructor copy_from_bytes:
arg ptr: *const u8
arg start: usize
arg len: usize
-> U8Vec
Creates a new, heap-allocated U8Vec by copying the memory into Rust (heap allocation)
12 methods
fn as_ref_vec:
&self
-> U8VecRef
fn create:
-> U8Vec
fn with_capacity:
arg cap: usize
-> U8Vec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionU8
fn from_item:
arg item: u8
-> U8Vec
fn copy_from_ptr:
arg ptr: *const u8
arg len: usize
-> U8Vec
fn c_get:
&self
arg index: usize
-> OptionU8
fn as_c_slice:
&self
-> U8VecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> U8VecSlice
Returns the
U8Vecas a non-owning slice, NOTE: TheU8Vecthat this slice was borrowed from MUST NOT be deleted before theU8VecRefCreates an empty
U8VecCreates a
U8Vecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
U8Veccontaining a single elementCopies elements from a C array into a
U8Vec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
U8VecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct GLuintVec
has destructorWrapper over a Rust-allocated
Vec<GLuint>4 fields
11 methods
fn create:
-> GLuintVec
fn with_capacity:
arg cap: usize
-> GLuintVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionU32
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionU32
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
GLuintVecCreates a
GLuintVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
GLuintVeccontaining a single elementCopies elements from a C array into a
GLuintVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
GLuintVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct GLintVec
has destructorWrapper over a Rust-allocated
Vec<GLint>4 fields
11 methods
fn create:
-> GLintVec
fn with_capacity:
arg cap: usize
-> GLintVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionI32
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionI32
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
GLintVecCreates a
GLintVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
GLintVeccontaining a single elementCopies elements from a C array into a
GLintVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
GLintVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StringVec
has destructorWrapper over a Rust-allocated
Vec<String>4 fields
11 methods
fn create:
-> StringVec
fn with_capacity:
arg cap: usize
-> StringVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionString
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionString
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StringVecCreates a
StringVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StringVeccontaining a single elementCopies elements from a C array into a
StringVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StringVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct MimeTypeDataVec
has destructorWrapper over a Rust-allocated
Vec<MimeTypeData>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: MimeTypeData
fn copy_from_ptr:
arg ptr: *const MimeTypeData
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
MimeTypeDataVecCreates a
MimeTypeDataVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
MimeTypeDataVeccontaining a single elementCopies elements from a C array into a
MimeTypeDataVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
MimeTypeDataVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StringPairVec
has destructorWrapper over a Rust-allocated
Vec<StringPair>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StringPair
fn copy_from_ptr:
arg ptr: *const StringPair
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StringPairVecCreates a
StringPairVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StringPairVeccontaining a single elementCopies elements from a C array into a
StringPairVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StringPairVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct NormalizedLinearColorStopVec
has destructorWrapper over a Rust-allocated
Vec<NormalizedLinearColorStop>4 fields
ptr: NormalizedLinearColorStop
len: usize
cap: usize
destructor: NormalizedLinearColorStopVecDestructor
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
fn copy_from_ptr:
arg ptr: *const NormalizedLinearColorStop
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NormalizedLinearColorStopVecCreates a
NormalizedLinearColorStopVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
NormalizedLinearColorStopVeccontaining a single elementCopies elements from a C array into a
NormalizedLinearColorStopVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NormalizedLinearColorStopVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct NormalizedRadialColorStopVec
has destructorWrapper over a Rust-allocated
Vec<NormalizedRadialColorStop>4 fields
ptr: NormalizedRadialColorStop
len: usize
cap: usize
destructor: NormalizedRadialColorStopVecDestructor
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
fn copy_from_ptr:
arg ptr: *const NormalizedRadialColorStop
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NormalizedRadialColorStopVecCreates a
NormalizedRadialColorStopVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
NormalizedRadialColorStopVeccontaining a single elementCopies elements from a C array into a
NormalizedRadialColorStopVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NormalizedRadialColorStopVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct NodeHierarchyItemVec
has destructorWrapper over a Rust-allocated
Vec<NodeHierarchyItem>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: NodeHierarchyItem
fn copy_from_ptr:
arg ptr: *const NodeHierarchyItem
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NodeHierarchyItemVecCreates a
NodeHierarchyItemVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
NodeHierarchyItemVeccontaining a single elementCopies elements from a C array into a
NodeHierarchyItemVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NodeHierarchyItemVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct TagIdToNodeIdMappingVec
has destructorWrapper over a Rust-allocated
Vec<TagIdToNodeIdMapping>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: TagIdToNodeIdMapping
fn copy_from_ptr:
arg ptr: *const TagIdToNodeIdMapping
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TagIdToNodeIdMappingVecCreates a
TagIdToNodeIdMappingVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
TagIdToNodeIdMappingVeccontaining a single elementCopies elements from a C array into a
TagIdToNodeIdMappingVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
TagIdToNodeIdMappingVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct ParentWithNodeDepthVec
has destructorWrapper over a Rust-allocated
Vec<ParentWithNodeDepth>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ParentWithNodeDepth
fn copy_from_ptr:
arg ptr: *const ParentWithNodeDepth
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ParentWithNodeDepthVecCreates a
ParentWithNodeDepthVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ParentWithNodeDepthVeccontaining a single elementCopies elements from a C array into a
ParentWithNodeDepthVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ParentWithNodeDepthVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct NodeDataVec
has destructorWrapper over a Rust-allocated
Vec<NodeData>4 fields
11 methods
fn create:
-> NodeDataVec
fn with_capacity:
arg cap: usize
-> NodeDataVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: NodeData
-> NodeDataVec
fn copy_from_ptr:
arg ptr: *const NodeData
arg len: usize
-> NodeDataVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NodeDataVecCreates a
NodeDataVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
NodeDataVeccontaining a single elementCopies elements from a C array into a
NodeDataVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NodeDataVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct AttributeTypeVec
has destructorWrapper over a Rust-allocated
Vec<AttributeType>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: AttributeType
fn copy_from_ptr:
arg ptr: *const AttributeType
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
AttributeTypeVecCreates a
AttributeTypeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
AttributeTypeVeccontaining a single elementCopies elements from a C array into a
AttributeTypeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
AttributeTypeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CoreCallbackDataVec
has destructorWrapper over a Rust-allocated
Vec<CoreCallbackData>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: CoreCallbackData
fn copy_from_ptr:
arg ptr: *const CoreCallbackData
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CoreCallbackDataVecCreates a
CoreCallbackDataVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
CoreCallbackDataVeccontaining a single elementCopies elements from a C array into a
CoreCallbackDataVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
CoreCallbackDataVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct AccessibilityActionVec
has destructorWrapper over a Rust-allocated
Vec<AccessibilityAction>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: AccessibilityAction
fn copy_from_ptr:
arg ptr: *const AccessibilityAction
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
AccessibilityActionVecCreates a
AccessibilityActionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
AccessibilityActionVeccontaining a single elementCopies elements from a C array into a
AccessibilityActionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
AccessibilityActionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct XmlNodeChildVec
has destructorWrapper over a Rust-allocated
Vec<XmlNodeChild>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: XmlNodeChild
fn copy_from_ptr:
arg ptr: *const XmlNodeChild
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
XmlNodeChildVecCreates a
XmlNodeChildVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
XmlNodeChildVeccontaining a single elementCopies elements from a C array into a
XmlNodeChildVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
XmlNodeChildVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct GridTrackSizingVec
has destructorWrapper over a Rust-allocated
Vec<GridTrackSizing>4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: GridTrackSizing
fn copy_from_ptr:
arg ptr: *const GridTrackSizing
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
GridTrackSizingVecCreates a
GridTrackSizingVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
GridTrackSizingVeccontaining a single elementCopies elements from a C array into a
GridTrackSizingVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
GridTrackSizingVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct GLbooleanVecRefMut
2 fields
ptr: c_void
len: usize
struct GLfloatVecRefMut
2 fields
ptr: c_void
len: usize
struct U8VecRefMut
2 fields
ptr: c_void
len: usize
struct TessellatedSvgNodeVecRef
2 fields
ptr: c_void
len: usize
struct F32VecRef
2 fields
ptr: c_void
len: usize
struct GLuintVecRef
2 fields
ptr: c_void
len: usize
struct I32VecRef
2 fields
ptr: c_void
len: usize
struct U8VecRef
2 fields
ptr: c_void
len: usize
struct GLintVecRefMut
2 fields
ptr: c_void
len: usize
struct GLenumVecRef
2 fields
ptr: c_void
len: usize
struct GLint64VecRefMut
2 fields
ptr: c_void
len: usize
fnptr StyleBackgroundContentVecDestructorType
signature
arg *mut StyleBackgroundContentVec
fnptr StyleBackgroundRepeatVecDestructorType
signature
arg *mut StyleBackgroundRepeatVec
union enum StyleFilterVecDestructor
4 variants
union enum StyleTransformVecDestructor
4 variants
fnptr MenuItemVecDestructorType
signature
arg *mut MenuItemVec
fnptr AccessibilityStateVecDestructorType
signature
arg *mut AccessibilityStateVec
fnptr CssPropertyWithConditionsVecDestructorType
signature
arg *mut CssPropertyWithConditionsVec
fnptr NormalizedLinearColorStopVecDestructorType
signature
arg *mut NormalizedLinearColorStopVec
fnptr F32VecDestructorType
signature
arg *mut F32Vec
union enum GLuintVecDestructor
4 variants
union enum XmlNodeChildVecDestructor
4 variants
fnptr StyleBackgroundSizeVecDestructorType
signature
arg *mut StyleBackgroundSizeVec
union enum StyleBackgroundContentVecDestructor
4 variants
fnptr StringVecDestructorType
signature
arg *mut StringVec
union enum CascadeInfoVecDestructor
4 variants
fnptr DomVecDestructorType
signature
arg *mut DomVec
union enum AccessibilityStateVecDestructor
4 variants
fnptr StringPairVecDestructorType
signature
arg *mut StringPairVec
fnptr MimeTypeDataVecDestructorType
signature
arg *mut MimeTypeDataVec
union enum DomVecDestructor
4 variants
union enum StringVecDestructor
4 variants
fnptr CssRuleBlockVecDestructorType
signature
arg *mut CssRuleBlockVec
union enum NodeDataVecDestructor
4 variants
union enum MenuItemVecDestructor
4 variants
fnptr AttributeTypeVecDestructorType
signature
arg *mut AttributeTypeVec
union enum ListViewRowVecDestructor
4 variants
fnptr StyleFilterVecDestructorType
signature
arg *mut StyleFilterVec
fnptr U32VecDestructorType
signature
arg *mut U32Vec
union enum SvgVertexVecDestructor
4 variants
union enum VideoFrameVecDestructor
4 variants
union enum CssVecDestructor
4 variants
union enum U32VecDestructor
4 variants
union enum CssRuleBlockVecDestructor
4 variants
fnptr ParentWithNodeDepthVecDestructorType
signature
arg *mut ParentWithNodeDepthVec
union enum NormalizedLinearColorStopVecDestructor
4 variants
fnptr CoreCallbackDataVecDestructorType
signature
arg *mut CoreCallbackDataVec
union enum StyleFontFamilyVecDestructor
4 variants
fnptr CascadeInfoVecDestructorType
signature
arg *mut CascadeInfoVec
fnptr U8VecDestructorType
signature
arg *mut U8Vec
fnptr NodeHierarchyItemVecDestructorType
signature
arg *mut NodeHierarchyItemVec
union enum CssPathSelectorVecDestructor
4 variants
fnptr StyleBackgroundPositionVecDestructorType
signature
arg *mut StyleBackgroundPositionVec
fnptr VirtualKeyCodeVecDestructorType
signature
arg *mut VirtualKeyCodeVec
union enum NodeHierarchyItemVecDestructor
4 variants
union enum VirtualKeyCodeVecDestructor
4 variants
fnptr SvgVertexVecDestructorType
signature
arg *mut SvgVertexVec
fnptr VideoFrameVecDestructorType
signature
arg *mut VideoFrameVec
union enum F32VecDestructor
4 variants
union enum StyleBackgroundRepeatVecDestructor
4 variants
union enum AccessibilityActionVecDestructor
4 variants
fnptr ListViewRowVecDestructorType
signature
arg *mut ListViewRowVec
fnptr GLuintVecDestructorType
signature
arg *mut GLuintVec
fnptr StyleTransformVecDestructorType
signature
arg *mut StyleTransformVec
fnptr TagIdToNodeIdMappingVecDestructorType
signature
arg *mut TagIdToNodeIdMappingVec
union enum U16VecDestructor
4 variants
union enum TagIdToNodeIdMappingVecDestructor
4 variants
fnptr U16VecDestructorType
signature
arg *mut U16Vec
fnptr GridTrackSizingVecDestructorType
signature
arg *mut GridTrackSizingVec
fnptr CssDeclarationVecDestructorType
signature
arg *mut CssDeclarationVec
union enum ParentWithNodeDepthVecDestructor
4 variants
union enum GLintVecDestructor
4 variants
union enum CssPropertyWithConditionsVecDestructor
4 variants
fnptr DynamicSelectorVecDestructorType
signature
arg *mut DynamicSelectorVec
union enum DynamicSelectorVecDestructor
4 variants
fnptr NormalizedRadialColorStopVecDestructorType
signature
arg *mut NormalizedRadialColorStopVec
union enum NormalizedRadialColorStopVecDestructor
4 variants
union enum StyleBackgroundPositionVecDestructor
4 variants
fnptr AccessibilityActionVecDestructorType
signature
arg *mut AccessibilityActionVec
fnptr GLintVecDestructorType
signature
arg *mut GLintVec
union enum AttributeTypeVecDestructor
4 variants
fnptr NodeDataVecDestructorType
signature
arg *mut NodeDataVec
union enum CssDeclarationVecDestructor
4 variants
union enum IdOrClassVecDestructor
4 variants
union enum StyleBackgroundSizeVecDestructor
4 variants
fnptr StyleFontFamilyVecDestructorType
signature
arg *mut StyleFontFamilyVec
union enum StringPairVecDestructor
4 variants
union enum MimeTypeDataVecDestructor
4 variants
union enum CoreCallbackDataVecDestructor
4 variants
union enum U8VecDestructor
4 variants
union enum GridTrackSizingVecDestructor
4 variants
fnptr IdOrClassVecDestructorType
signature
arg *mut IdOrClassVec
fnptr XmlNodeChildVecDestructorType
signature
arg *mut XmlNodeChildVec
fnptr CssVecDestructorType
signature
arg *mut CssVec
fnptr CssPathSelectorVecDestructorType
signature
arg *mut CssPathSelectorVec
fnptr VertexAttributeVecDestructorType
signature
arg *mut VertexAttributeVec
union enum VertexAttributeVecDestructor
4 variants
struct VertexAttributeVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: VertexAttribute
fn copy_from_ptr:
arg ptr: *const VertexAttribute
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
VertexAttributeVecCreates a
VertexAttributeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
VertexAttributeVeccontaining a single elementCopies elements from a C array into a
VertexAttributeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
VertexAttributeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DebugMessageVecDestructor
4 variants
fnptr DebugMessageVecDestructorType
signature
arg *mut DebugMessageVec
struct DebugMessageVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: DebugMessage
fn copy_from_ptr:
arg ptr: *const DebugMessage
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DebugMessageVecCreates a
DebugMessageVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
DebugMessageVeccontaining a single elementCopies elements from a C array into a
DebugMessageVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DebugMessageVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum ShapePointVecDestructor
4 variants
fnptr ShapePointVecDestructorType
signature
arg *mut ShapePointVec
struct ShapePointVec
4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ShapePoint
fn copy_from_ptr:
arg ptr: *const ShapePoint
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ShapePointVecCreates a
ShapePointVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ShapePointVeccontaining a single elementCopies elements from a C array into a
ShapePointVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ShapePointVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct MonitorVec
has destructor4 fields
11 methods
fn create:
-> MonitorVec
fn with_capacity:
arg cap: usize
-> MonitorVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: Monitor
-> MonitorVec
fn copy_from_ptr:
arg ptr: *const Monitor
arg len: usize
-> MonitorVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
MonitorVecCreates a
MonitorVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
MonitorVeccontaining a single elementCopies elements from a C array into a
MonitorVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
MonitorVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr VideoModeVecDestructorType
signature
arg *mut VideoModeVec
fnptr ScanCodeVecDestructorType
signature
arg *mut ScanCodeVec
struct VideoModeVec
4 fields
11 methods
fn create:
-> VideoModeVec
fn with_capacity:
arg cap: usize
-> VideoModeVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: VideoMode
-> VideoModeVec
fn copy_from_ptr:
arg ptr: *const VideoMode
arg len: usize
-> VideoModeVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
VideoModeVecCreates a
VideoModeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
VideoModeVeccontaining a single elementCopies elements from a C array into a
VideoModeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
VideoModeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct XWindowTypeVec
4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: XWindowType
fn copy_from_ptr:
arg ptr: *const XWindowType
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
XWindowTypeVecCreates a
XWindowTypeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
XWindowTypeVeccontaining a single elementCopies elements from a C array into a
XWindowTypeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
XWindowTypeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum XWindowTypeVecDestructor
4 variants
fnptr MonitorVecDestructorType
signature
arg *mut MonitorVec
union enum MonitorVecDestructor
4 variants
union enum VideoModeVecDestructor
4 variants
fnptr XWindowTypeVecDestructorType
signature
arg *mut XWindowTypeVec
union enum ScanCodeVecDestructor
4 variants
struct ScanCodeVec
4 fields
11 methods
fn create:
-> ScanCodeVec
fn with_capacity:
arg cap: usize
-> ScanCodeVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionU32
fn from_item:
arg item: ScanCode
-> ScanCodeVec
fn copy_from_ptr:
arg ptr: *const ScanCode
arg len: usize
-> ScanCodeVec
fn c_get:
&self
arg index: usize
-> OptionU32
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ScanCodeVecCreates a
ScanCodeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ScanCodeVeccontaining a single elementCopies elements from a C array into a
ScanCodeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ScanCodeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum StyledNodeVecDestructor
4 variants
struct ContentGroupVec
4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ContentGroup
fn copy_from_ptr:
arg ptr: *const ContentGroup
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ContentGroupVecCreates a
ContentGroupVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ContentGroupVeccontaining a single elementCopies elements from a C array into a
ContentGroupVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ContentGroupVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StyledNodeVec
4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyledNode
fn copy_from_ptr:
arg ptr: *const StyledNode
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyledNodeVecCreates a
StyledNodeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyledNodeVeccontaining a single elementCopies elements from a C array into a
StyledNodeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyledNodeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr ContentGroupVecDestructorType
signature
arg *mut ContentGroupVec
union enum ContentGroupVecDestructor
4 variants
fnptr StyledNodeVecDestructorType
signature
arg *mut StyledNodeVec
fnptr SelectionRangeVecDestructorType
signature
arg *mut SelectionRangeVec
struct DocumentSelectionSpanVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: DocumentSelectionSpan
fn copy_from_ptr:
arg ptr: *const DocumentSelectionSpan
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DocumentSelectionSpanVecCreates a
DocumentSelectionSpanVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
DocumentSelectionSpanVeccontaining a single elementCopies elements from a C array into a
DocumentSelectionSpanVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
DocumentSelectionSpanVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DocumentSelectionSpanVecDestructor
4 variants
fnptr DocumentSelectionSpanVecDestructorType
signature
arg *mut DocumentSelectionSpanVec
struct DocumentTextEditVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: DocumentTextEdit
fn copy_from_ptr:
arg ptr: *const DocumentTextEdit
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DocumentTextEditVecCreates a
DocumentTextEditVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
DocumentTextEditVeccontaining a single elementCopies elements from a C array into a
DocumentTextEditVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
DocumentTextEditVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DocumentTextEditVecDestructor
4 variants
fnptr DocumentTextEditVecDestructorType
signature
arg *mut DocumentTextEditVec
fnptr DomIdVecDestructorType
signature
arg *mut DomIdVec
struct DomIdVec
has destructorWrapper over a Rust-allocated
Vec<DomId>4 fields
11 methods
fn create:
-> DomIdVec
fn with_capacity:
arg cap: usize
-> DomIdVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionDomId
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionDomId
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DomIdVecCreates a
DomIdVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
DomIdVeccontaining a single elementCopies elements from a C array into a
DomIdVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DomIdVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DomIdVecDestructor
4 variants
struct RefstrVecRef
2 fields
ptr: c_void
len: usize
union enum TimerIdVecDestructor
4 variants
struct TimerIdVec
has destructorWrapper over a Rust-allocated
Vec<TimerId>4 fields
11 methods
fn create:
-> TimerIdVec
fn with_capacity:
arg cap: usize
-> TimerIdVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: TimerId
-> TimerIdVec
fn copy_from_ptr:
arg ptr: *const TimerId
arg len: usize
-> TimerIdVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TimerIdVecCreates a
TimerIdVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
TimerIdVeccontaining a single elementCopies elements from a C array into a
TimerIdVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
TimerIdVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct SelectionRangeVec
4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: SelectionRange
fn copy_from_ptr:
arg ptr: *const SelectionRange
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
SelectionRangeVecCreates a
SelectionRangeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
SelectionRangeVeccontaining a single elementCopies elements from a C array into a
SelectionRangeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
SelectionRangeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr TimerIdVecDestructorType
signature
arg *mut TimerIdVec
union enum ThreadIdVecDestructor
4 variants
struct ThreadIdVec
has destructorWrapper over a Rust-allocated
Vec<ThreadId>4 fields
11 methods
fn create:
-> ThreadIdVec
fn with_capacity:
arg cap: usize
-> ThreadIdVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ThreadId
-> ThreadIdVec
fn copy_from_ptr:
arg ptr: *const ThreadId
arg len: usize
-> ThreadIdVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ThreadIdVecCreates a
ThreadIdVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ThreadIdVeccontaining a single elementCopies elements from a C array into a
ThreadIdVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ThreadIdVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum SelectionRangeVecDestructor
4 variants
fnptr ThreadIdVecDestructorType
signature
arg *mut ThreadIdVec
union enum StyledTextRunVecDestructor
4 variants
fnptr StyledTextRunVecDestructorType
signature
arg *mut StyledTextRunVec
union enum TabletDeviceInfoVecDestructor
4 variants
union enum HidDeviceVecDestructor
4 variants
struct HidReportVec
has destructor4 fields
10 methods
fn create:
-> HidReportVec
fn with_capacity:
arg cap: usize
-> HidReportVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: HidReport
-> HidReportVec
fn copy_from_ptr:
arg ptr: *const HidReport
arg len: usize
-> HidReportVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
HidReportVecCreates a
HidReportVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
HidReportVeccontaining a single elementCopies elements from a C array into a
HidReportVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
HidReportVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum HidReportVecDestructor
4 variants
fnptr TabletDeviceInfoVecDestructorType
signature
arg *mut TabletDeviceInfoVec
struct PageSetupOverrideVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: PageSetupOverride
fn copy_from_ptr:
arg ptr: *const PageSetupOverride
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
PageSetupOverrideVecCreates a
PageSetupOverrideVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
PageSetupOverrideVeccontaining a single elementCopies elements from a C array into a
PageSetupOverrideVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
PageSetupOverrideVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct MarginBoxContentVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: MarginBoxContent
fn copy_from_ptr:
arg ptr: *const MarginBoxContent
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
MarginBoxContentVecCreates a
MarginBoxContentVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
MarginBoxContentVeccontaining a single elementCopies elements from a C array into a
MarginBoxContentVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
MarginBoxContentVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum PageBreakPositionVecDestructor
4 variants
struct PageBreakPositionVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: PageBreakPosition
fn copy_from_ptr:
arg ptr: *const PageBreakPosition
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
PageBreakPositionVecCreates a
PageBreakPositionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
PageBreakPositionVeccontaining a single elementCopies elements from a C array into a
PageBreakPositionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
PageBreakPositionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum PageSetupOverrideVecDestructor
4 variants
fnptr PageSetupOverrideVecDestructorType
signature
arg *mut PageSetupOverrideVec
fnptr PageBreakPositionVecDestructorType
signature
arg *mut PageBreakPositionVec
fnptr MarginBoxContentVecDestructorType
signature
arg *mut MarginBoxContentVec
union enum MarginBoxContentVecDestructor
4 variants
struct TabletDeviceInfoVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: TabletDeviceInfo
fn copy_from_ptr:
arg ptr: *const TabletDeviceInfo
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TabletDeviceInfoVecCreates a
TabletDeviceInfoVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
TabletDeviceInfoVeccontaining a single elementCopies elements from a C array into a
TabletDeviceInfoVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
TabletDeviceInfoVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr HidDeviceVecDestructorType
signature
arg *mut HidDeviceVec
struct StyledTextRunVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: StyledTextRun
fn copy_from_ptr:
arg ptr: *const StyledTextRun
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyledTextRunVecCreates a
StyledTextRunVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
StyledTextRunVeccontaining a single elementCopies elements from a C array into a
StyledTextRunVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyledTextRunVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr SelectionVecDestructorType
signature
arg *mut SelectionVec
struct SelectionVec
4 fields
11 methods
fn create:
-> SelectionVec
fn with_capacity:
arg cap: usize
-> SelectionVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: Selection
-> SelectionVec
fn copy_from_ptr:
arg ptr: *const Selection
arg len: usize
-> SelectionVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
SelectionVecCreates a
SelectionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
SelectionVeccontaining a single elementCopies elements from a C array into a
SelectionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
SelectionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum SelectionVecDestructor
4 variants
struct HttpHeaderVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: HttpHeader
fn copy_from_ptr:
arg ptr: *const HttpHeader
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
HttpHeaderVecCreates a
HttpHeaderVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
HttpHeaderVeccontaining a single elementCopies elements from a C array into a
HttpHeaderVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
HttpHeaderVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr HttpHeaderVecDestructorType
signature
arg *mut HttpHeaderVec
fnptr FmtArgVecDestructorType
signature
arg *mut FmtArgVec
struct FmtArgVec
has destructor4 fields
11 methods
fn create:
-> FmtArgVec
fn with_capacity:
arg cap: usize
-> FmtArgVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionFmtArg
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionFmtArg
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
FmtArgVecCreates a
FmtArgVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
FmtArgVeccontaining a single elementCopies elements from a C array into a
FmtArgVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
FmtArgVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum FmtArgVecDestructor
4 variants
union enum HttpHeaderVecDestructor
4 variants
struct JsonVec
has destructor4 fields
1 constructor
constructor copy_from_array:
Creates a new, heap-allocated JsonVec by copying elements from a C array
11 methods
fn create:
-> JsonVec
fn with_capacity:
arg cap: usize
-> JsonVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
-> OptionJson
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionJson
fn as_c_slice:
&self
-> JsonVecSlice
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
-> JsonVecSlice
Creates an empty
JsonVecCreates a
JsonVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
JsonVeccontaining a single elementCopies elements from a C array into a
JsonVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
JsonVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum JsonVecDestructor
4 variants
fnptr JsonVecDestructorType
signature
arg *mut JsonVec
struct DirEntryVec
has destructor4 fields
11 methods
fn create:
-> DirEntryVec
fn with_capacity:
arg cap: usize
-> DirEntryVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: DirEntry
-> DirEntryVec
fn copy_from_ptr:
arg ptr: *const DirEntry
arg len: usize
-> DirEntryVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DirEntryVecCreates a
DirEntryVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
DirEntryVeccontaining a single elementCopies elements from a C array into a
DirEntryVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DirEntryVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr DirEntryVecDestructorType
signature
arg *mut DirEntryVec
union enum DirEntryVecDestructor
4 variants
struct JsonKeyValueVec
has destructor4 fields
1 constructor
constructor copy_from_array:
arg ptr: *const JsonKeyValue
arg len: usize
Creates a new, heap-allocated JsonKeyValueVec by copying elements from a C array
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: JsonKeyValue
fn copy_from_ptr:
arg ptr: *const JsonKeyValue
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
JsonKeyValueVecCreates a
JsonKeyValueVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
JsonKeyValueVeccontaining a single elementCopies elements from a C array into a
JsonKeyValueVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
JsonKeyValueVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr JsonKeyValueVecDestructorType
signature
arg *mut JsonKeyValueVec
union enum JsonKeyValueVecDestructor
4 variants
fnptr NamedFontVecDestructorType
signature
arg *mut NamedFontVec
union enum NamedFontVecDestructor
4 variants
struct NamedFontVec
has destructor4 fields
11 methods
fn create:
-> NamedFontVec
fn with_capacity:
arg cap: usize
-> NamedFontVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: NamedFont
-> NamedFontVec
fn copy_from_ptr:
arg ptr: *const NamedFont
arg len: usize
-> NamedFontVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NamedFontVecCreates a
NamedFontVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
NamedFontVeccontaining a single elementCopies elements from a C array into a
NamedFontVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NamedFontVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct ExternalResourceVec
has destructor4 fields
11 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn from_item:
arg item: ExternalResource
fn copy_from_ptr:
arg ptr: *const ExternalResource
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ExternalResourceVecCreates a
ExternalResourceVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Creates a
ExternalResourceVeccontaining a single elementCopies elements from a C array into a
ExternalResourceVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ExternalResourceVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum ExternalResourceVecDestructor
4 variants
fnptr ExternalResourceVecDestructorType
signature
arg *mut ExternalResourceVec
union enum NodeHierarchyItemIdVecDestructor
4 variants
fnptr NodeHierarchyItemIdVecDestructorType
signature
arg *mut NodeHierarchyItemIdVec
struct NodeHierarchyItemIdVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: NodeHierarchyItemId
fn copy_from_ptr:
arg ptr: *const NodeHierarchyItemId
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
NodeHierarchyItemIdVecCreates a
NodeHierarchyItemIdVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
NodeHierarchyItemIdVeccontaining a single elementCopies elements from a C array into a
NodeHierarchyItemIdVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
NodeHierarchyItemIdVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct CalcAstItemVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: CalcAstItem
fn copy_from_ptr:
arg ptr: *const CalcAstItem
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
fn c_get:
&self
arg index: usize
Creates an empty
CalcAstItemVecCreates a
CalcAstItemVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
CalcAstItemVeccontaining a single elementCopies elements from a C array into a
CalcAstItemVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
CalcAstItemVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
fnptr CalcAstItemVecDestructorType
signature
arg *mut CalcAstItemVec
union enum CalcAstItemVecDestructor
4 variants
struct GridAreaDefinitionVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: GridAreaDefinition
fn copy_from_ptr:
arg ptr: *const GridAreaDefinition
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
GridAreaDefinitionVecCreates a
GridAreaDefinitionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
GridAreaDefinitionVeccontaining a single elementCopies elements from a C array into a
GridAreaDefinitionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
GridAreaDefinitionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum GridAreaDefinitionVecDestructor
4 variants
fnptr GridAreaDefinitionVecDestructorType
signature
arg *mut GridAreaDefinitionVec
struct ComponentDataFieldVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentDataField
fn copy_from_ptr:
arg ptr: *const ComponentDataField
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentDataFieldVecCreates a
ComponentDataFieldVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentDataFieldVeccontaining a single elementCopies elements from a C array into a
ComponentDataFieldVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentDataFieldVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr ComponentDataFieldVecDestructorType
signature
arg *mut ComponentDataFieldVec
union enum ComponentDataFieldVecDestructor
4 variants
union enum ComponentDefVecDestructor
4 variants
fnptr ComponentDefVecDestructorType
signature
arg *mut ComponentDefVec
struct ComponentDefVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentDef
fn copy_from_ptr:
arg ptr: *const ComponentDef
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentDefVecCreates a
ComponentDefVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentDefVeccontaining a single elementCopies elements from a C array into a
ComponentDefVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentDefVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct ComponentLibraryVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentLibrary
fn copy_from_ptr:
arg ptr: *const ComponentLibrary
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentLibraryVecCreates a
ComponentLibraryVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentLibraryVeccontaining a single elementCopies elements from a C array into a
ComponentLibraryVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentLibraryVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr ComponentLibraryVecDestructorType
signature
arg *mut ComponentLibraryVec
union enum ComponentLibraryVecDestructor
4 variants
fnptr ComponentDataModelVecDestructorType
signature
arg *mut ComponentDataModelVec
union enum ComponentDataModelVecDestructor
4 variants
struct ComponentDataModelVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentDataModel
fn copy_from_ptr:
arg ptr: *const ComponentDataModel
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentDataModelVecCreates a
ComponentDataModelVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentDataModelVeccontaining a single elementCopies elements from a C array into a
ComponentDataModelVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentDataModelVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr ComponentEnumModelVecDestructorType
signature
arg *mut ComponentEnumModelVec
union enum ComponentEnumVariantVecDestructor
4 variants
struct ComponentEnumModelVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentEnumModel
fn copy_from_ptr:
arg ptr: *const ComponentEnumModel
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentEnumModelVecCreates a
ComponentEnumModelVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentEnumModelVeccontaining a single elementCopies elements from a C array into a
ComponentEnumModelVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentEnumModelVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum ComponentEnumModelVecDestructor
4 variants
fnptr ComponentEnumVariantVecDestructorType
signature
arg *mut ComponentEnumVariantVec
struct ComponentEnumVariantVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentEnumVariant
fn copy_from_ptr:
arg ptr: *const ComponentEnumVariant
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentEnumVariantVecCreates a
ComponentEnumVariantVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentEnumVariantVeccontaining a single elementCopies elements from a C array into a
ComponentEnumVariantVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentEnumVariantVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr ComponentCallbackArgVecDestructorType
signature
arg *mut ComponentCallbackArgVec
fnptr ComponentFieldOverrideVecDestructorType
signature
arg *mut ComponentFieldOverrideVec
struct ComponentCallbackArgVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentCallbackArg
fn copy_from_ptr:
arg ptr: *const ComponentCallbackArg
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentCallbackArgVecCreates a
ComponentCallbackArgVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentCallbackArgVeccontaining a single elementCopies elements from a C array into a
ComponentCallbackArgVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentCallbackArgVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum ComponentFieldOverrideVecDestructor
4 variants
struct ComponentFieldOverrideVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: ComponentFieldOverride
fn copy_from_ptr:
arg ptr: *const ComponentFieldOverride
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
ComponentFieldOverrideVecCreates a
ComponentFieldOverrideVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
ComponentFieldOverrideVeccontaining a single elementCopies elements from a C array into a
ComponentFieldOverrideVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
ComponentFieldOverrideVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum ComponentCallbackArgVecDestructor
4 variants
union enum SvgPathElementVecDestructor
4 variants
fnptr SvgPathElementVecDestructorType
signature
arg *mut SvgPathElementVec
struct SvgPathElementVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: SvgPathElement
fn copy_from_ptr:
arg ptr: *const SvgPathElement
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
SvgPathElementVecCreates a
SvgPathElementVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
SvgPathElementVeccontaining a single elementCopies elements from a C array into a
SvgPathElementVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
SvgPathElementVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum SvgPathVecDestructor
4 variants
fnptr SvgPathVecDestructorType
signature
arg *mut SvgPathVec
struct SvgPathVec
4 fields
10 methods
fn create:
-> SvgPathVec
fn with_capacity:
arg cap: usize
-> SvgPathVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: SvgPath
-> SvgPathVec
fn copy_from_ptr:
arg ptr: *const SvgPath
arg len: usize
-> SvgPathVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
SvgPathVecCreates a
SvgPathVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
SvgPathVeccontaining a single elementCopies elements from a C array into a
SvgPathVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
SvgPathVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum RibbonTabVecDestructor
4 variants
struct RibbonTabVec
has destructor4 fields
10 methods
fn create:
-> RibbonTabVec
fn with_capacity:
arg cap: usize
-> RibbonTabVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: RibbonTab
-> RibbonTabVec
fn copy_from_ptr:
arg ptr: *const RibbonTab
arg len: usize
-> RibbonTabVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
RibbonTabVecCreates a
RibbonTabVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
RibbonTabVeccontaining a single elementCopies elements from a C array into a
RibbonTabVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
RibbonTabVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr RibbonTabVecDestructorType
signature
arg *mut RibbonTabVec
struct TreeViewNodeVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: TreeViewNode
fn copy_from_ptr:
arg ptr: *const TreeViewNode
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TreeViewNodeVecCreates a
TreeViewNodeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
TreeViewNodeVeccontaining a single elementCopies elements from a C array into a
TreeViewNodeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
TreeViewNodeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr TreeViewNodeVecDestructorType
signature
arg *mut TreeViewNodeVec
union enum TreeViewNodeVecDestructor
4 variants
fnptr RouteVecDestructorType
signature
arg *mut RouteVec
struct RouteVec
has destructor4 fields
10 methods
fn create:
-> RouteVec
fn with_capacity:
arg cap: usize
-> RouteVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
fn copy_from_ptr:
fn c_get:
&self
arg index: usize
-> OptionRoute
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
RouteVecCreates a
RouteVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
RouteVeccontaining a single elementCopies elements from a C array into a
RouteVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
RouteVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum RouteVecDestructor
4 variants
fnptr TouchPointVecDestructorType
signature
arg *mut TouchPointVec
union enum TouchPointVecDestructor
4 variants
struct TouchPointVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: TouchPoint
fn copy_from_ptr:
arg ptr: *const TouchPoint
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TouchPointVecCreates a
TouchPointVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
TouchPointVeccontaining a single elementCopies elements from a C array into a
TouchPointVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
TouchPointVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr LogicalRectVecDestructorType
signature
arg *mut LogicalRectVec
union enum LogicalRectVecDestructor
4 variants
struct LogicalRectVec
has destructorWrapper over a Rust-allocated
Vec<LogicalRect>4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: LogicalRect
fn copy_from_ptr:
arg ptr: *const LogicalRect
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
LogicalRectVecCreates a
LogicalRectVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
LogicalRectVeccontaining a single elementCopies elements from a C array into a
LogicalRectVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
LogicalRectVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr LayoutRectVecDestructorType
signature
arg *mut LayoutRectVec
union enum LayoutRectVecDestructor
4 variants
struct LayoutRectVec
has destructorWrapper over a Rust-allocated
Vec<LayoutRect>4 fields
4 constructors
constructor create:
constructor with_capacity:
arg cap: usize
constructor from_item:
arg item: LayoutRect
constructor copy_from_ptr:
arg ptr: *const LayoutRect
arg len: usize
Creates an empty
LayoutRectVecCreates a
LayoutRectVecwith a given capacityCreates a
LayoutRectVeccontaining a single elementCopies elements from a C array into a
LayoutRectVec. The array must be valid forlenelements.7 methods
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn get:
&self
arg index: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Returns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a reference to the element at the given index, or None if out of bounds
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
LayoutRectVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr DbValueVecDestructorType
signature
arg *mut DbValueVec
union enum DbValueVecDestructor
4 variants
struct DbValueVec
has destructor4 fields
10 methods
fn create:
-> DbValueVec
fn with_capacity:
arg cap: usize
-> DbValueVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: DbValue
-> DbValueVec
fn copy_from_ptr:
arg ptr: *const DbValue
arg len: usize
-> DbValueVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DbValueVecCreates a
DbValueVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
DbValueVeccontaining a single elementCopies elements from a C array into a
DbValueVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DbValueVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct LoadedFontVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: LoadedFont
fn copy_from_ptr:
arg ptr: *const LoadedFont
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
LoadedFontVecCreates a
LoadedFontVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
LoadedFontVeccontaining a single elementCopies elements from a C array into a
LoadedFontVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
LoadedFontVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr LoadedFontVecDestructorType
signature
arg *mut LoadedFontVec
union enum LoadedFontVecDestructor
4 variants
fnptr FluentLoadErrorVecDestructorType
signature
arg *mut FluentLoadErrorVec
struct FluentLoadErrorVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: FluentLoadError
fn copy_from_ptr:
arg ptr: *const FluentLoadError
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
FluentLoadErrorVecCreates a
FluentLoadErrorVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
FluentLoadErrorVeccontaining a single elementCopies elements from a C array into a
FluentLoadErrorVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
FluentLoadErrorVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum FluentLoadErrorVecDestructor
4 variants
struct AccordionSectionVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: AccordionSection
fn copy_from_ptr:
arg ptr: *const AccordionSection
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
AccordionSectionVecCreates a
AccordionSectionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
AccordionSectionVeccontaining a single elementCopies elements from a C array into a
AccordionSectionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
AccordionSectionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum AccordionSectionVecDestructor
4 variants
fnptr AccordionSectionVecDestructorType
signature
arg *mut AccordionSectionVec
union enum CssPropertyVecDestructor
4 variants
struct CssPropertyVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: CssProperty
fn copy_from_ptr:
arg ptr: *const CssProperty
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
CssPropertyVecCreates a
CssPropertyVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
CssPropertyVeccontaining a single elementCopies elements from a C array into a
CssPropertyVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
CssPropertyVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr CssPropertyVecDestructorType
signature
arg *mut CssPropertyVec
struct IcuStringVec
has destructor4 fields
10 methods
fn create:
-> IcuStringVec
fn with_capacity:
arg cap: usize
-> IcuStringVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
-> OptionString
fn from_item:
arg item: String
-> IcuStringVec
fn copy_from_ptr:
arg ptr: *const String
arg len: usize
-> IcuStringVec
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
IcuStringVecCreates a
IcuStringVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
IcuStringVeccontaining a single elementCopies elements from a C array into a
IcuStringVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
IcuStringVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum IcuStringVecDestructor
4 variants
fnptr IcuStringVecDestructorType
signature
arg *mut IcuStringVec
struct IdentifiedSelectionVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: IdentifiedSelection
fn copy_from_ptr:
arg ptr: *const IdentifiedSelection
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
IdentifiedSelectionVecCreates a
IdentifiedSelectionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
IdentifiedSelectionVeccontaining a single elementCopies elements from a C array into a
IdentifiedSelectionVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
IdentifiedSelectionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum IdentifiedSelectionVecDestructor
4 variants
fnptr IdentifiedSelectionVecDestructorType
signature
arg *mut IdentifiedSelectionVec
union enum FullWindowStateVecDestructor
4 variants
fnptr FullWindowStateVecDestructorType
signature
arg *mut FullWindowStateVec
struct FullWindowStateVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: FullWindowState
fn copy_from_ptr:
arg ptr: *const FullWindowState
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
FullWindowStateVecCreates a
FullWindowStateVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
FullWindowStateVeccontaining a single elementCopies elements from a C array into a
FullWindowStateVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
FullWindowStateVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum RibbonGalleryCellVecDestructor
4 variants
struct RibbonItemVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: RibbonItem
fn copy_from_ptr:
arg ptr: *const RibbonItem
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
RibbonItemVecCreates a
RibbonItemVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
RibbonItemVeccontaining a single elementCopies elements from a C array into a
RibbonItemVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
RibbonItemVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct RibbonGalleryCellVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: RibbonGalleryCell
fn copy_from_ptr:
arg ptr: *const RibbonGalleryCell
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
RibbonGalleryCellVecCreates a
RibbonGalleryCellVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
RibbonGalleryCellVeccontaining a single elementCopies elements from a C array into a
RibbonGalleryCellVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
RibbonGalleryCellVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum RibbonItemVecDestructor
4 variants
fnptr RibbonGalleryCellVecDestructorType
signature
arg *mut RibbonGalleryCellVec
fnptr RibbonItemVecDestructorType
signature
arg *mut RibbonItemVec
struct RibbonGroupVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: RibbonGroup
fn copy_from_ptr:
arg ptr: *const RibbonGroup
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
RibbonGroupVecCreates a
RibbonGroupVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
RibbonGroupVeccontaining a single elementCopies elements from a C array into a
RibbonGroupVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
RibbonGroupVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr RibbonGroupVecDestructorType
signature
arg *mut RibbonGroupVec
union enum RibbonGroupVecDestructor
4 variants
struct KeyframeStopVec
has destructorWrapper over a Rust-allocated
Vec<KeyframeStop>4 fields
10 methods
fn create:
fn len:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: KeyframeStop
fn with_capacity:
arg cap: usize
fn capacity:
&self
-> usize
fn copy_from_ptr:
arg ptr: *const KeyframeStop
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
KeyframeStopVecReturns the number of elements in the Vec
Returns whether the Vec is empty
Creates a
KeyframeStopVeccontaining a single elementCreates a
KeyframeStopVecwith a given capacityReturns the capacity of the Vec
Copies elements from a C array into a
KeyframeStopVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
KeyframeStopVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum KeyframeStopVecDestructor
4 variants
fnptr KeyframeStopVecDestructorType
signature
arg *mut KeyframeStopVec
struct KeyframesVec
has destructorWrapper over a Rust-allocated
Vec<Keyframes>4 fields
10 methods
fn create:
-> KeyframesVec
fn len:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: Keyframes
-> KeyframesVec
fn with_capacity:
arg cap: usize
-> KeyframesVec
fn capacity:
&self
-> usize
fn copy_from_ptr:
arg ptr: *const Keyframes
arg len: usize
-> KeyframesVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
KeyframesVecReturns the number of elements in the Vec
Returns whether the Vec is empty
Creates a
KeyframesVeccontaining a single elementCreates a
KeyframesVecwith a given capacityReturns the capacity of the Vec
Copies elements from a C array into a
KeyframesVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
KeyframesVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum KeyframesVecDestructor
4 variants
fnptr KeyframesVecDestructorType
signature
arg *mut KeyframesVec
struct StyleAnimationVec
has destructorWrapper over a Rust-allocated
Vec<StyleAnimation>4 fields
10 methods
fn create:
fn len:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: StyleAnimation
fn with_capacity:
arg cap: usize
fn capacity:
&self
-> usize
fn copy_from_ptr:
arg ptr: *const StyleAnimation
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StyleAnimationVecReturns the number of elements in the Vec
Returns whether the Vec is empty
Creates a
StyleAnimationVeccontaining a single elementCreates a
StyleAnimationVecwith a given capacityReturns the capacity of the Vec
Copies elements from a C array into a
StyleAnimationVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StyleAnimationVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum StyleAnimationVecDestructor
4 variants
fnptr StyleAnimationVecDestructorType
signature
arg *mut StyleAnimationVec
struct FrameConsumerVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: FrameConsumer
fn copy_from_ptr:
arg ptr: *const FrameConsumer
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
FrameConsumerVecCreates a
FrameConsumerVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
FrameConsumerVeccontaining a single elementCopies elements from a C array into a
FrameConsumerVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
FrameConsumerVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum FrameConsumerVecDestructor
4 variants
fnptr FrameConsumerVecDestructorType
signature
arg *mut FrameConsumerVec
union enum TrayIconImageVecDestructor
4 variants
fnptr TrayIconImageVecDestructorType
signature
arg *mut TrayIconImageVec
struct TrayIconImageVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: TrayIconImage
fn copy_from_ptr:
arg ptr: *const TrayIconImage
arg len: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
TrayIconImageVecCreates a
TrayIconImageVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
TrayIconImageVeccontaining a single elementCopies elements from a C array into a
TrayIconImageVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
TrayIconImageVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr StatusBarSegmentVecDestructorType
signature
arg *mut StatusBarSegmentVec
struct QuickAccessActionVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: QuickAccessAction
fn copy_from_ptr:
arg ptr: *const QuickAccessAction
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
QuickAccessActionVecCreates a
QuickAccessActionVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
QuickAccessActionVeccontaining a single elementCopies elements from a C array into a
QuickAccessActionVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
QuickAccessActionVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum StatusBarSegmentVecDestructor
4 variants
fnptr StatusBarViewVecDestructorType
signature
arg *mut StatusBarViewVec
struct StatusBarViewVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: StatusBarView
fn copy_from_ptr:
arg ptr: *const StatusBarView
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StatusBarViewVecCreates a
StatusBarViewVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
StatusBarViewVeccontaining a single elementCopies elements from a C array into a
StatusBarViewVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StatusBarViewVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct StatusBarSegmentVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: StatusBarSegment
fn copy_from_ptr:
arg ptr: *const StatusBarSegment
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
StatusBarSegmentVecCreates a
StatusBarSegmentVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
StatusBarSegmentVeccontaining a single elementCopies elements from a C array into a
StatusBarSegmentVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
StatusBarSegmentVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr QuickAccessActionVecDestructorType
signature
arg *mut QuickAccessActionVec
union enum QuickAccessActionVecDestructor
4 variants
union enum StatusBarViewVecDestructor
4 variants
union enum DomNodeIdVecDestructor
4 variants
struct DomNodeIdVec
4 fields
10 methods
fn create:
-> DomNodeIdVec
fn with_capacity:
arg cap: usize
-> DomNodeIdVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn c_get:
&self
arg index: usize
fn from_item:
arg item: DomNodeId
-> DomNodeIdVec
fn copy_from_ptr:
arg ptr: *const DomNodeId
arg len: usize
-> DomNodeIdVec
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DomNodeIdVecCreates a
DomNodeIdVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Creates a
DomNodeIdVeccontaining a single elementCopies elements from a C array into a
DomNodeIdVec. The array must be valid forlenelements.Returns a C-compatible slice of the entire Vec as a
DomNodeIdVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr DomNodeIdVecDestructorType
signature
arg *mut DomNodeIdVec
union enum PointerSeatVecDestructor
4 variants
fnptr PointerSeatVecDestructorType
signature
arg *mut PointerSeatVec
struct PointerSeatVec
4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: PointerSeat
fn copy_from_ptr:
arg ptr: *const PointerSeat
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
PointerSeatVecCreates a
PointerSeatVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
PointerSeatVeccontaining a single elementCopies elements from a C array into a
PointerSeatVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
PointerSeatVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr KeyboardSeatVecDestructorType
signature
arg *mut KeyboardSeatVec
union enum KeyboardSeatVecDestructor
4 variants
struct KeyboardSeatVec
has destructor4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: KeyboardSeat
fn copy_from_ptr:
arg ptr: *const KeyboardSeat
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
KeyboardSeatVecCreates a
KeyboardSeatVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
KeyboardSeatVeccontaining a single elementCopies elements from a C array into a
KeyboardSeatVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
KeyboardSeatVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
struct HidDeviceVec
has destructor4 fields
10 methods
fn create:
-> HidDeviceVec
fn with_capacity:
arg cap: usize
-> HidDeviceVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: HidDevice
-> HidDeviceVec
fn copy_from_ptr:
arg ptr: *const HidDevice
arg len: usize
-> HidDeviceVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
HidDeviceVecCreates a
HidDeviceVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
HidDeviceVeccontaining a single elementCopies elements from a C array into a
HidDeviceVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
HidDeviceVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
fnptr HidReportVecDestructorType
signature
arg *mut HidReportVec
struct FilePathVec
has destructorWrapper over a Rust-allocated
Vec<FilePath>4 fields
10 methods
fn create:
-> FilePathVec
fn with_capacity:
arg cap: usize
-> FilePathVec
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: FilePath
-> FilePathVec
fn copy_from_ptr:
arg ptr: *const FilePath
arg len: usize
-> FilePathVec
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
FilePathVecCreates a
FilePathVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
FilePathVeccontaining a single elementCopies elements from a C array into a
FilePathVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
FilePathVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum FilePathVecDestructor
4 variants
fnptr FilePathVecDestructorType
signature
arg *mut FilePathVec
struct DbIndexSchemaVec
has destructorWrapper over a Rust-allocated
Vec<DbIndexSchema>4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: DbIndexSchema
fn copy_from_ptr:
arg ptr: *const DbIndexSchema
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DbIndexSchemaVecCreates a
DbIndexSchemaVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
DbIndexSchemaVeccontaining a single elementCopies elements from a C array into a
DbIndexSchemaVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DbIndexSchemaVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DbIndexSchemaVecDestructor
4 variants
fnptr DbIndexSchemaVecDestructorType
signature
arg *mut DbIndexSchemaVec
struct DbStoreSchemaVec
has destructorWrapper over a Rust-allocated
Vec<DbStoreSchema>4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: DbStoreSchema
fn copy_from_ptr:
arg ptr: *const DbStoreSchema
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DbStoreSchemaVecCreates a
DbStoreSchemaVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
DbStoreSchemaVeccontaining a single elementCopies elements from a C array into a
DbStoreSchemaVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DbStoreSchemaVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DbStoreSchemaVecDestructor
4 variants
fnptr DbStoreSchemaVecDestructorType
signature
arg *mut DbStoreSchemaVec
struct DbCollectionScopeVec
has destructorWrapper over a Rust-allocated
Vec<DbCollectionScope>4 fields
10 methods
fn create:
fn with_capacity:
arg cap: usize
fn len:
&self
-> usize
fn capacity:
&self
-> usize
fn is_empty:
&self
-> bool
fn from_item:
arg item: DbCollectionScope
fn copy_from_ptr:
arg ptr: *const DbCollectionScope
arg len: usize
fn c_get:
&self
arg index: usize
fn as_c_slice:
&self
fn as_c_slice_range:
&self
arg start: usize
arg end: usize
Creates an empty
DbCollectionScopeVecCreates a
DbCollectionScopeVecwith a given capacityReturns the number of elements in the Vec
Returns the capacity of the Vec
Returns whether the Vec is empty
Creates a
DbCollectionScopeVeccontaining a single elementCopies elements from a C array into a
DbCollectionScopeVec. The array must be valid forlenelements.Returns a copy of the element at the given index, or None if out of bounds. C-API compatible.
Returns a C-compatible slice of the entire Vec as a
DbCollectionScopeVecSlice.Returns a C-compatible slice of a range within the Vec. Range is clamped to valid bounds.
union enum DbCollectionScopeVecDestructor
4 variants
fnptr DbCollectionScopeVecDestructorType
signature
arg *mut DbCollectionScopeVec
mod option
304 typesDefinition of azuls internal
Option<*>wrappersunion enum OptionScrollState
2 variants
None
Some(ScrollState)
union enum OptionListViewOnRowClick
2 variants
None
Some(ListViewOnRowClick)
union enum OptionListViewOnColumnClick
2 variants
None
Some(ListViewOnColumnClick)
union enum OptionListViewOnLazyLoadScroll
2 variants
None
Some(ListViewOnLazyLoadScroll)
union enum OptionMenu
has destructor2 variants
None
Some(Menu)
union enum OptionPixelValueNoPercent
2 variants
None
Some(PixelValueNoPercent)
union enum OptionPixelValue
2 variants
None
Some(PixelValue)
union enum OptionColorInputOnValueChange
2 variants
None
Some(ColorInputOnValueChange)
union enum OptionButtonOnClick
2 variants
None
Some(ButtonOnClick)
union enum OptionTabOnClick
2 variants
None
Some(TabOnClick)
union enum OptionFileInputOnPathChange
2 variants
None
Some(FileInputOnPathChange)
union enum OptionCheckBoxOnToggle
2 variants
None
Some(CheckBoxOnToggle)
union enum OptionDropDownOnChoiceChange
2 variants
None
Some(DropDownOnChoiceChange)
union enum OptionTextInputOnTextInput
2 variants
None
Some(TextInputOnTextInput)
union enum OptionTextInputOnVirtualKeyDown
2 variants
None
union enum OptionTextInputOnFocusLost
2 variants
None
Some(TextInputOnFocusLost)
union enum OptionTextInputSelection
2 variants
None
Some(TextInputSelection)
union enum OptionNumberInputOnFocusLost
2 variants
None
Some(NumberInputOnFocusLost)
union enum OptionNumberInputOnValueChange
2 variants
None
Some(NumberInputOnValueChange)
union enum OptionMenuItemIcon
has destructor2 variants
None
Some(MenuItemIcon)
union enum OptionVirtualKeyCodeCombo
has destructor2 variants
None
Some(VirtualKeyCodeCombo)
union enum OptionTimerId
2 variants
None
Some(TimerId)
union enum OptionTimer
2 variants
None
Some(Timer)
union enum OptionThread
2 variants
None
Some(Thread)
union enum OptionI16
2 variants
None
Some(i16)
union enum OptionU16
2 variants
None
Some(u16)
union enum OptionU32
2 variants
None
Some(u32)
union enum OptionImageRef
has destructor2 variants
None
Some(ImageRef)
union enum OptionFontRef
has destructor2 variants
None
Some(FontRef)
union enum OptionRefAny
2 variants
None
Some(RefAny)
union enum OptionLayoutSize
2 variants
None
Some(LayoutSize)
union enum OptionLayoutRect
2 variants
None
Some(LayoutRect)
union enum OptionDomNodeId
2 variants
None
Some(DomNodeId)
union enum OptionColorU
2 variants
None
Some(ColorU)
union enum OptionRawImage
has destructor2 variants
None
Some(RawImage)
union enum OptionTabIndex
2 variants
None
Some(TabIndex)
union enum OptionDuration
2 variants
None
Some(Duration)
union enum OptionUsize
2 variants
None
Some(usize)
union enum OptionCoreMenuCallback
2 variants
None
Some(CoreMenuCallback)
struct SvgParseOptions
has destructor10 fields
relative_image_path: OptionString
default_font_family: String
languages: StringVec
dpi: f32
font_size: f32
shape_rendering: ShapeRendering
text_rendering: TextRendering
image_rendering: ImageRendering
fontdb: FontDatabase
keep_named_groups: bool
struct SvgRenderOptions
4 fields
target_size: OptionLayoutSize
background_color: OptionColorU
fit: SvgFitTo
transform: SvgRenderTransform
union enum OptionLogicalPosition
2 variants
None
Some(LogicalPosition)
union enum OptionScreenPosition
2 variants
None
Some(ScreenPosition)
union enum OptionCursorNodePosition
2 variants
None
Some(CursorNodePosition)
union enum OptionDragDelta
2 variants
None
Some(DragDelta)
union enum OptionString
has destructor2 variants
None
Some(String)
union enum OptionF32
2 variants
None
Some(f32)
union enum OptionF64
2 variants
None
Some(f64)
union enum OptionBool
2 variants
None
Some(bool)
union enum OptionI64
2 variants
None
Some(i64)
union enum OptionWaylandTheme
has destructor2 variants
None
Some(WaylandTheme)
union enum OptionMouseCursorType
2 variants
None
Some(MouseCursorType)
union enum OptionWindowIcon
has destructor2 variants
None
Some(WindowIcon)
union enum OptionCallback
2 variants
None
Some(Callback)
union enum OptionTaskBarIcon
has destructor2 variants
None
Some(TaskBarIcon)
union enum OptionLinuxDecorationsState
2 variants
None
Some(LinuxDecorationsState)
union enum OptionI32
2 variants
None
Some(i32)
union enum OptionLogicalSize
2 variants
None
Some(LogicalSize)
union enum OptionLogicalRect
2 variants
None
Some(LogicalRect)
union enum OptionVirtualKeyCode
2 variants
None
Some(VirtualKeyCode)
union enum OptionX11Visual
2 variants
None
Some(X11Visual)
union enum OptionRendererOptions
2 variants
None
Some(RendererOptions)
union enum OptionWindowTheme
2 variants
None
Some(WindowTheme)
union enum OptionInstant
2 variants
None
Some(Instant)
union enum OptionAccessibilityRole
2 variants
None
Some(AccessibilityRole)
union enum OptionGlContextPtr
has destructor2 variants
None
Some(GlContextPtr)
union enum OptionSelectionRange
2 variants
None
Some(SelectionRange)
union enum OptionDocumentPosition
2 variants
None
Some(DocumentPosition)
union enum OptionDocumentSelectionSpan
2 variants
None
Some(DocumentSelectionSpan)
union enum OptionDocumentTextEdit
has destructor2 variants
None
Some(DocumentTextEdit)
union enum OptionU32Vec
has destructor2 variants
None
Some(U32Vec)
union enum OptionKeyboardState
has destructor2 variants
None
Some(KeyboardState)
union enum OptionMouseState
2 variants
None
Some(MouseState)
union enum OptionSelectionState
2 variants
None
Some(SelectionState)
union enum OptionThreadSendMsg
2 variants
None
Some(ThreadSendMsg)
union enum OptionCssProperty
2 variants
None
Some(CssProperty)
union enum OptionTextCursor
2 variants
None
Some(TextCursor)
union enum OptionU64
2 variants
None
Some(u64)
union enum OptionWindowFlags
2 variants
None
Some(WindowFlags)
union enum OptionCoreImageCallback
2 variants
None
Some(CoreImageCallback)
union enum OptionPenTilt
2 variants
None
Some(PenTilt)
union enum OptionGestureDirection
2 variants
None
Some(GestureDirection)
union enum OptionDetectedPinch
2 variants
None
Some(DetectedPinch)
union enum OptionDetectedRotation
2 variants
None
Some(DetectedRotation)
union enum OptionDetectedLongPress
2 variants
None
Some(DetectedLongPress)
union enum OptionSelectAllResult
has destructor2 variants
None
Some(SelectAllResult)
union enum OptionDeleteResult
has destructor2 variants
None
Some(DeleteResult)
union enum OptionDragState
has destructor2 variants
None
Some(DragState)
union enum OptionPenState
2 variants
None
Some(PenState)
union enum OptionUndoableOperation
has destructor2 variants
None
Some(UndoableOperation)
union enum OptionClipboardContent
has destructor2 variants
None
Some(ClipboardContent)
union enum OptionFilePath
has destructor2 variants
None
Some(FilePath)
union enum OptionJson
has destructor2 variants
None
Some(Json)
struct IconStyleOptions
3 fields
union enum OptionDatasetMergeCallback
2 variants
None
Some(DatasetMergeCallback)
struct ScrollIntoViewOptions
3 fields
4 constructors
constructor nearest:
constructor center:
constructor start:
constructor end:
Create options with "nearest" alignment for both axes
Create options with "center" alignment for both axes
Create options with "start" alignment for both axes
Create options to align the end of the target with the end of the viewport
2 methods
fn with_instant:
self
fn with_smooth:
self
Set instant scroll behavior
Set smooth scroll behavior
union enum OptionPendingTextEdit
has destructor2 variants
None
Some(PendingTextEdit)
union enum OptionMimeTypeHint
has destructor2 variants
None
Some(MimeTypeHint)
union enum OptionThreadId
2 variants
None
Some(ThreadId)
union enum OptionDom
has destructor2 variants
None
Some(Dom)
union enum OptionAccessibilityAction
has destructor2 variants
None
Some(AccessibilityAction)
union enum OptionDomId
2 variants
None
Some(DomId)
union enum OptionExternalResource
has destructor2 variants
None
Some(ExternalResource)
union enum OptionAccessibilityState
2 variants
None
Some(AccessibilityState)
union enum OptionTagIdToNodeIdMapping
2 variants
None
Some(TagIdToNodeIdMapping)
union enum OptionDirEntry
has destructor2 variants
None
Some(DirEntry)
union enum OptionNamedFont
has destructor2 variants
None
Some(NamedFont)
union enum OptionStyleFilter
2 variants
None
Some(StyleFilter)
union enum OptionSvgVertex
2 variants
None
Some(SvgVertex)
union enum OptionCascadeInfo
2 variants
None
Some(CascadeInfo)
union enum OptionStyledNode
2 variants
None
Some(StyledNode)
union enum OptionStyleTransform
2 variants
None
Some(StyleTransform)
union enum OptionStyleBackgroundPosition
2 variants
None
Some(StyleBackgroundPosition)
union enum OptionFmtArg
has destructor2 variants
None
Some(FmtArg)
union enum OptionCssDeclaration
has destructor2 variants
None
Some(CssDeclaration)
union enum OptionMonitor
has destructor2 variants
None
Some(Monitor)
union enum OptionJsonKeyValue
has destructor2 variants
None
Some(JsonKeyValue)
union enum OptionNormalizedRadialColorStop
2 variants
None
union enum OptionHttpHeader
has destructor2 variants
None
Some(HttpHeader)
union enum OptionNodeHierarchyItem
2 variants
None
Some(NodeHierarchyItem)
union enum OptionCssRuleBlock
has destructor2 variants
None
Some(CssRuleBlock)
union enum OptionCss
has destructor2 variants
None
Some(Css)
union enum OptionCoreCallbackData
2 variants
None
Some(CoreCallbackData)
union enum OptionNormalizedLinearColorStop
2 variants
None
union enum OptionXmlNodeChild
has destructor2 variants
None
Some(XmlNodeChild)
union enum OptionStyleBackgroundContent
has destructor2 variants
None
Some(StyleBackgroundContent)
union enum OptionVertexAttribute
has destructor2 variants
None
Some(VertexAttribute)
union enum OptionMenuItem
has destructor2 variants
None
Some(MenuItem)
union enum OptionDebugMessage
has destructor2 variants
None
Some(DebugMessage)
union enum OptionListViewRow
has destructor2 variants
None
Some(ListViewRow)
union enum OptionCssPathSelector
has destructor2 variants
None
Some(CssPathSelector)
union enum OptionParentWithNodeDepth
2 variants
None
Some(ParentWithNodeDepth)
union enum OptionNodeData
has destructor2 variants
None
Some(NodeData)
union enum OptionStyleBackgroundSize
2 variants
None
Some(StyleBackgroundSize)
union enum OptionStyledTextRun
has destructor2 variants
None
Some(StyledTextRun)
union enum OptionSelection
2 variants
None
Some(Selection)
union enum OptionCssPropertyWithConditions
has destructor2 variants
None
union enum OptionContentGroup
2 variants
None
Some(ContentGroup)
union enum OptionVideoMode
2 variants
None
Some(VideoMode)
union enum OptionXWindowType
2 variants
None
Some(XWindowType)
union enum OptionIdOrClass
has destructor2 variants
None
Some(IdOrClass)
union enum OptionStyleBackgroundRepeat
2 variants
None
Some(StyleBackgroundRepeat)
union enum OptionGridTrackSizing
2 variants
None
Some(GridTrackSizing)
union enum OptionShapePoint
2 variants
None
Some(ShapePoint)
union enum OptionStyleFontFamily
has destructor2 variants
None
Some(StyleFontFamily)
union enum OptionDynamicSelector
has destructor2 variants
None
Some(DynamicSelector)
union enum OptionStringVec
has destructor2 variants
None
Some(StringVec)
union enum OptionU8VecRef
2 variants
None
Some(U8VecRef)
union enum OptionJsonVec
has destructor2 variants
None
Some(JsonVec)
union enum OptionJsonKeyValueVec
has destructor2 variants
None
Some(JsonKeyValueVec)
union enum OptionAttributeType
has destructor2 variants
None
Some(AttributeType)
union enum OptionNodeHierarchyItemId
2 variants
union enum OptionStringPair
has destructor2 variants
union enum OptionMimeTypeData
has destructor2 variants
union enum OptionU8
2 variants
No value
None
Some value of type u8
Some(u8)
union enum OptionLinuxDesktopEnv
2 variants
None
Some(LinuxDesktopEnv)
union enum OptionCssMockEnvironment
has destructor2 variants
None
Some(CssMockEnvironment)
union enum OptionScrollPhysics
2 variants
None
Some(ScrollPhysics)
union enum OptionOsVersion
2 variants
None
Some(OsVersion)
union enum OptionOsCondition
2 variants
None
Some(OsCondition)
union enum OptionThemeCondition
has destructor2 variants
None
Some(ThemeCondition)
union enum OptionCalcAstItem
2 variants
union enum OptionGridAreaDefinition
has destructor2 variants
union enum OptionComponentDef
has destructor2 variants
union enum OptionComponentLibrary
has destructor2 variants
union enum OptionComponentDataField
has destructor2 variants
union enum OptionComponentDataModel
has destructor2 variants
union enum OptionComponentEnumModel
has destructor2 variants
union enum OptionComponentEnumVariant
has destructor2 variants
union enum OptionComponentDefaultValue
has destructor2 variants
None
Some(ComponentDefaultValue)
union enum OptionComponentFieldOverride
has destructor2 variants
union enum OptionComponentCallbackArg
has destructor2 variants
union enum OptionSvgDashPattern
2 variants
None
Some(SvgDashPattern)
union enum OptionSvgPoint
2 variants
None
Some(SvgPoint)
union enum OptionSvgPath
2 variants
None
Some(SvgPath)
union enum OptionSvgPathElement
2 variants
union enum OptionRibbonOnTabClick
2 variants
None
Some(RibbonOnTabClick)
union enum OptionTreeViewOnNodeClick
2 variants
None
Some(TreeViewOnNodeClick)
union enum OptionRibbonTab
has destructor2 variants
union enum OptionTreeViewNode
has destructor2 variants
None
Some(TreeViewNode)
union enum OptionRoute
has destructor2 variants
None
Some(Route)
union enum OptionRouteMatch
has destructor2 variants
None
Some(RouteMatch)
union enum OptionTouchPoint
2 variants
union enum OptionFileTypeList
has destructor2 variants
None
Some(FileTypeList)
union enum OptionLocationFix
2 variants
None
Some(LocationFix)
union enum OptionBiometricResult
2 variants
None
Some(BiometricResult)
union enum OptionKeyringResult
has destructor2 variants
None
Some(KeyringResult)
union enum OptionDbValue
has destructor2 variants
union enum OptionSensorReading
2 variants
None
Some(SensorReading)
union enum OptionGamepadState
2 variants
None
Some(GamepadState)
union enum OptionTabletDeviceInfo
has destructor2 variants
None
Some(TabletDeviceInfo)
union enum OptionOnVideoFrame
2 variants
None
Some(OnVideoFrame)
union enum OptionMapViewportChanged
2 variants
None
Some(MapViewportChanged)
union enum OptionMapPinTap
2 variants
None
Some(MapPinTap)
union enum OptionOnAudioFrame
2 variants
None
Some(OnAudioFrame)
union enum OptionU8Vec
has destructor2 variants
None
Some(U8Vec)
union enum OptionWtEvent
has destructorOptional
WtEventreturned byWebTransport::recv()(None when nothing queued).2 variants
None
Some(WtEvent)
union enum OptionVideoFrame
has destructor2 variants
None
Some(VideoFrame)
union enum OptionDecodedVideo
has destructor2 variants
None
Some(DecodedVideo)
union enum OptionLoadedFont
has destructor2 variants
None
Some(LoadedFont)
union enum OptionFluentLoadError
has destructor2 variants
union enum OptionSwitchOnToggle
2 variants
None
Some(SwitchOnToggle)
union enum OptionSliderOnValueChange
2 variants
None
Some(SliderOnValueChange)
union enum OptionSegmentedOnChange
2 variants
None
Some(SegmentedOnChange)
union enum OptionRadioGroupOnChange
2 variants
None
Some(RadioGroupOnChange)
union enum OptionTextAreaOnFocusLost
2 variants
None
Some(TextAreaOnFocusLost)
union enum OptionTextAreaOnTextInput
2 variants
None
Some(TextAreaOnTextInput)
union enum OptionAlertOnDismiss
2 variants
None
Some(AlertOnDismiss)
union enum OptionAccordionOnToggle
2 variants
None
Some(AccordionOnToggle)
union enum OptionChipOnRemove
2 variants
None
Some(ChipOnRemove)
union enum OptionPopoverOnToggle
2 variants
None
Some(PopoverOnToggle)
union enum OptionComboBoxOnSelect
2 variants
None
Some(ComboBoxOnSelect)
union enum OptionModalOnClose
2 variants
None
Some(ModalOnClose)
union enum OptionToastOnDismiss
2 variants
None
Some(ToastOnDismiss)
union enum OptionPaginationOnChange
2 variants
None
Some(PaginationOnChange)
union enum OptionStepperOnStepChange
2 variants
None
Some(StepperOnStepChange)
union enum OptionSplitPaneOnResize
2 variants
None
Some(SplitPaneOnResize)
union enum OptionDatePickerOnChange
2 variants
None
Some(DatePickerOnChange)
union enum OptionTimePickerOnChange
2 variants
None
Some(TimePickerOnChange)
union enum OptionAccordionSection
has destructor2 variants
union enum OptionCardOnClick
2 variants
None
Some(CardOnClick)
union enum OptionChipOnClick
2 variants
None
Some(ChipOnClick)
union enum OptionTextAreaOnVirtualKeyDown
2 variants
None
Some(TextAreaOnVirtualKeyDown)
union enum OptionIdentifiedSelection
2 variants
None
Some(IdentifiedSelection)
union enum OptionFullWindowState
has destructor2 variants
None
Some(FullWindowState)
union enum OptionRibbonGalleryOnSelect
2 variants
None
Some(RibbonGalleryOnSelect)
union enum OptionRibbonItem
has destructor2 variants
union enum OptionRibbonGalleryCell
has destructor2 variants
union enum OptionRibbonAppButton
has destructor2 variants
None
Some(RibbonAppButton)
union enum OptionRibbonGroup
has destructor2 variants
union enum OptionStyleAnimation
has destructor2 variants
union enum OptionKeyframes
has destructor2 variants
union enum OptionKeyframeStop
2 variants
union enum OptionEmailAddress
has destructor2 variants
None
Some(EmailAddress)
union enum OptionOnConsumerFrame
2 variants
None
Some(OnConsumerFrame)
union enum OptionFrameConsumer
2 variants
union enum OptionTrayIconImage
has destructor2 variants
None
Some(TrayIconImage)
union enum OptionDocumentChangeset
has destructor2 variants
None
Some(DocumentChangeset)
union enum OptionStatusBarZoom
2 variants
None
Some(StatusBarZoom)
union enum OptionStatusBarOnViewSelect
2 variants
None
Some(StatusBarOnViewSelect)
union enum OptionStatusBarViewSwitcher
has destructor2 variants
None
Some(StatusBarViewSwitcher)
union enum OptionStatusBarView
has destructor2 variants
union enum OptionQuickAccessAction
has destructor2 variants
union enum OptionStatusBarSegment
has destructor2 variants
union enum OptionPhysicalKey
2 variants
None
Some(PhysicalKey)
union enum OptionTabletPadState
2 variants
None
Some(TabletPadState)
union enum OptionDialState
2 variants
None
Some(DialState)
union enum OptionTabletToolKind
2 variants
None
Some(TabletToolKind)
union enum OptionScrollNodeInfo
2 variants
None
Some(ScrollNodeInfo)
union enum OptionHidDevice
has destructor2 variants
union enum OptionHidReport
has destructor2 variants
union enum OptionCompositionCursor
2 variants
None
Some(CompositionCursor)
union enum OptionRawMotionEventData
2 variants
None
Some(RawMotionEventData)
union enum OptionInputSample
2 variants
None
Some(InputSample)
union enum OptionPointerSeat
2 variants
union enum OptionMediaControlRequest
has destructor2 variants
None
Some(MediaControlRequest)
union enum OptionProximity
2 variants
None
Some(Proximity)
union enum OptionSystemAudioChange
2 variants
None
Some(SystemAudioChange)
union enum OptionKeyboardSeat
has destructor2 variants
union enum OptionPaginationInfo
2 variants
None
Some(PaginationInfo)
union enum OptionPageSetup
has destructor2 variants
None
Some(PageSetup)
union enum OptionNodeId
2 variants
None
Some(NodeId)
union enum OptionPageSequence
has destructor2 variants
None
Some(PageSequence)
union enum OptionMarginBoxContent
has destructor2 variants
union enum OptionPageSetupOverride
has destructor2 variants
union enum OptionPageBreakPosition
2 variants
union enum OptionPlaybackState
2 variants
None
Some(PlaybackState)
union enum OptionFileOpenResult
has destructor2 variants
None
Some(FileOpenResult)
union enum OptionFileOpenMultiResult
has destructor2 variants
None
Some(FileOpenMultiResult)
union enum OptionColorPickResult
2 variants
None
Some(ColorPickResult)
union enum OptionSaveTarget
has destructor2 variants
None
Some(SaveTarget)
union enum OptionSaveTargetResult
has destructor2 variants
None
Some(SaveTargetResult)
union enum OptionFileReadBytesResult
has destructor2 variants
None
Some(FileReadBytesResult)
union enum OptionFileReadStringResult
has destructor2 variants
None
Some(FileReadStringResult)
union enum OptionFileDirListResult
has destructor2 variants
None
Some(FileDirListResult)
union enum OptionImageDecodeResult
has destructor2 variants
None
Some(ImageDecodeResult)
union enum OptionHttpGetResult
has destructor2 variants
None
Some(HttpGetResult)
union enum OptionHttpBytesResult
has destructor2 variants
None
Some(HttpBytesResult)
union enum OptionHttpReachableResult
has destructor2 variants
None
Some(HttpReachableResult)
union enum OptionAudioDeviceListResult
has destructor2 variants
None
Some(AudioDeviceListResult)
union enum OptionVideoDecodeResult
has destructor2 variants
None
Some(VideoDecodeResult)
union enum OptionScreenRecordingResult
has destructor2 variants
None
Some(ScreenRecordingResult)
union enum OptionDbIndexSchema
has destructor2 variants
None
Some(DbIndexSchema)
union enum OptionDbStoreSchema
has destructor2 variants
None
Some(DbStoreSchema)
union enum OptionDbKeyRange
has destructor2 variants
None
Some(DbKeyRange)
union enum OptionDbIndexPredicate
has destructor2 variants
None
Some(DbIndexPredicate)
union enum OptionDbCollectionScope
has destructor2 variants
None
Some(DbCollectionScope)
union enum OptionDbScope
has destructor2 variants
None
Some(DbScope)
union enum OptionDbSyncStatus
has destructor2 variants
None
Some(DbSyncStatus)
union enum OptionDbOpenResult
has destructor2 variants
None
Some(DbOpenResult)
union enum OptionDbValueResult
has destructor2 variants
None
Some(DbValueResult)
union enum OptionDbRowsResult
has destructor2 variants
None
Some(DbRowsResult)
union enum OptionDbChangeResult
has destructor2 variants
None
Some(DbChangeResult)
union enum OptionDbSyncStatusResult
has destructor2 variants
None
Some(DbSyncStatusResult)
union enum OptionCssPropertyWithConditionsVec
has destructor2 variants
None
union enum OptionUiTheme
2 variants
None
Some(UiTheme)
union enum OptionHttpClient
2 variants
None
Some(HttpClient)
union enum OptionThreadPool
2 variants
None
Some(ThreadPool)
union enum OptionMapMount
2 variants
None
Some(MapMount)
union enum OptionVideoMount
2 variants
None
Some(VideoMount)
union enum OptionIrohEvent
has destructor2 variants
mod error
84 typesDefinition of error and
Result<T, E>typesunion enum ResultSvgSvgParseError
has destructor2 variants
Ok(Svg)
Err(SvgParseError)
union enum SvgParseError
has destructor6 variants
union enum XmlError
has destructor34 variants
NoParserAvailable
InvalidXmlPrefixUri(XmlTextPos)
UnexpectedXmlUri(XmlTextPos)
UnexpectedXmlnsUri(XmlTextPos)
InvalidElementNamePrefix(XmlTextPos)
DuplicatedNamespace(DuplicatedNamespaceError)
UnknownNamespace(UnknownNamespaceError)
UnexpectedCloseTag(UnexpectedCloseTagError)
UnexpectedEntityCloseTag(XmlTextPos)
UnknownEntityReference(UnknownEntityReferenceError)
MalformedEntityReference(XmlTextPos)
EntityReferenceLoop(XmlTextPos)
InvalidAttributeValue(XmlTextPos)
DuplicatedAttribute(DuplicatedAttributeError)
NoRootNode
SizeLimit
DtdDetected
Invalid hierarchy close tags, i.e
<app></p></app>MalformedHierarchy(MalformedHierarchyError)
ParserError(XmlParseError)
UnclosedRootNode
UnexpectedDeclaration(XmlTextPos)
NodesLimitReached
AttributesLimitReached
NamespacesLimitReached
InvalidName(XmlTextPos)
NonXmlChar(XmlTextPos)
InvalidChar(XmlTextPos)
InvalidChar2(XmlTextPos)
InvalidString(XmlTextPos)
InvalidExternalID(XmlTextPos)
InvalidComment(XmlTextPos)
InvalidCharacterData(XmlTextPos)
UnknownToken(XmlTextPos)
UnexpectedEndOfStream
struct DuplicatedNamespaceError
has destructor2 fields
ns: String
pos: XmlTextPos
struct UnknownNamespaceError
has destructor2 fields
ns: String
pos: XmlTextPos
struct UnexpectedCloseTagError
has destructor3 fields
struct UnknownEntityReferenceError
has destructor2 fields
entity: String
pos: XmlTextPos
struct DuplicatedAttributeError
has destructor2 fields
attribute: String
pos: XmlTextPos
union enum XmlParseError
has destructor10 variants
InvalidDeclaration(XmlTextError)
InvalidComment(XmlTextError)
InvalidPI(XmlTextError)
InvalidDoctype(XmlTextError)
InvalidEntity(XmlTextError)
InvalidElement(XmlTextError)
InvalidAttribute(XmlTextError)
InvalidCdata(XmlTextError)
InvalidCharData(XmlTextError)
UnknownToken(XmlTextPos)
struct XmlTextError
has destructor2 fields
stream_error: XmlStreamError
pos: XmlTextPos
union enum XmlStreamError
has destructor13 variants
UnexpectedEndOfStream
InvalidName
NonXmlChar(NonXmlCharError)
InvalidChar(InvalidCharError)
InvalidCharMultiple(InvalidCharMultipleError)
InvalidQuote(InvalidQuoteError)
InvalidSpace(InvalidSpaceError)
InvalidString(InvalidStringError)
InvalidReference
InvalidExternalID
InvalidCommentData
InvalidCommentEnd
InvalidCharacterData
struct NonXmlCharError
2 fields
ch: u32
pos: XmlTextPos
struct InvalidCharError
3 fields
struct InvalidCharMultipleError
has destructor3 fields
struct InvalidQuoteError
2 fields
got: u8
pos: XmlTextPos
struct InvalidSpaceError
2 fields
got: u8
pos: XmlTextPos
struct InvalidStringError
has destructor2 fields
got: String
pos: XmlTextPos
enum EncodeImageError
5 variants
EncoderNotAvailable
InsufficientMemory
DimensionError
InvalidData
Unknown
union enum ResultRawImageDecodeImageError
has destructor2 variants
Ok(RawImage)
Err(DecodeImageError)
enum DecodeImageError
4 variants
InsufficientMemory
DimensionError
UnsupportedImageFormat
Unknown
union enum ResultU8VecEncodeImageError
has destructor2 variants
Ok(U8Vec)
Err(EncodeImageError)
union enum ResultVoidString
has destructor2 variants
Ok
Err(String)
union enum ResultParsedSvgSvgParseError
has destructor2 variants
Ok(ParsedSvg)
Err(SvgParseError)
struct SelectAllResult
has destructor2 fields
full_text: String
selection_range: SelectionRange
struct DeleteResult
has destructor2 fields
range_to_delete: SelectionRange
deleted_text: String
struct IcuError
has destructor1 field
message: String
struct HttpResponseTooLargeError
2 fields
max_size: u64
actual_size: u64
union enum HttpError
has destructor8 variants
InvalidUrl(String)
ConnectionFailed(String)
Timeout
TlsError(String)
HttpStatus(HttpStatusError)
IoError(String)
ResponseTooLarge(HttpResponseTooLargeError)
Other(String)
7 constructors
constructor invalid_url:
constructor connection_failed:
constructor tls_error:
constructor http_status:
constructor io_error:
constructor response_too_large:
arg max_size: u64
arg actual_size: u64
-> HttpError
constructor other:
struct HttpStatusError
has destructor2 fields
status_code: u16
message: String
struct FileError
has destructor2 fields
message: String
kind: FileErrorKind
enum FileErrorKind
11 variants
NotFound
PermissionDenied
AlreadyExists
InvalidPath
IoError
DirectoryNotEmpty
IsDirectory
IsFile
Other
The operation needs a user gesture and was requested outside one (browser pickers only open from a transient activation).
NeedsUserGesture
No implementation exists on this engine / target (distinct from
PermissionDenied, which is a decision).Unsupported
union enum ResultEmptyStructFileError
has destructor2 variants
Ok(EmptyStruct)
Err(FileError)
union enum ResultHttpResponseHttpError
has destructor2 variants
Ok(HttpResponse)
Err(HttpError)
union enum Resultu64FileError
has destructor2 variants
Ok(u64)
Err(FileError)
union enum ResultFileMetadataFileError
has destructor2 variants
Ok(FileMetadata)
Err(FileError)
union enum ResultDirEntryVecFileError
has destructor2 variants
Ok(DirEntryVec)
Err(FileError)
struct JsonParseError
has destructor3 fields
union enum ResultJsonJsonParseError
has destructor2 variants
Ok(Json)
Err(JsonParseError)
union enum ResultUrlUrlParseError
has destructor2 variants
Ok(Url)
Err(UrlParseError)
struct UrlParseError
has destructor1 field
message: String
union enum RenderDomError
has destructor2 variants
Component(ComponentError)
CssError(CssParseErrorOwned)
union enum DomXmlParseError
has destructor9 variants
NoHtmlNode
MultipleHtmlRootNodes
NoBodyInHtml
MultipleBodyNodes
Xml(XmlError)
MalformedHierarchy(MalformedHierarchyError)
RenderDom(RenderDomError)
Component(ComponentParseError)
Css(CssParseErrorOwned)
struct ErrorLocation
1 field
original_pos: usize
struct PixelNoValueGivenError
has destructor2 fields
value: String
metric: SizeMetric
struct VarOnShorthandPropertyError
has destructor2 fields
value: String
union enum PercentageParseError
has destructor3 variants
struct WrongComponentCountError
has destructor3 fields
struct AngleNoValueGivenError
has destructor2 fields
value: String
metric: AngleMetric
struct WhiteSpaceInComponentNameError
has destructor2 fields
arg_pos: usize
arg_name: String
union enum CompileError
has destructor3 variants
union enum ComponentError
has destructor2 variants
UselessFunctionArgument(UselessFunctionArgumentError)
UnknownComponent(String)
struct UnknownSelectorError
has destructor2 fields
selector: String
suggestion: OptionString
union enum StyleLineHeightParseError
has destructor1 variant
Percentage(PercentageParseError)
union enum ComponentParseError
has destructor7 variants
NotAComponent
UnnamedComponent
MissingName(usize)
MissingType(MissingTypeError)
WhiteSpaceInComponentName(WhiteSpaceInComponentNameError)
WhiteSpaceInComponentType(WhiteSpaceInComponentTypeError)
CssError(CssParseErrorOwned)
struct MissingTypeError
has destructor2 fields
arg_pos: usize
arg_name: String
union enum CssParsingErrorOwned
has destructor139 variants
Border(CssBorderParseErrorOwned)
BorderRadius(CssStyleBorderRadiusParseErrorOwned)
Padding(LayoutPaddingParseErrorOwned)
Margin(LayoutMarginParseErrorOwned)
Overflow(InvalidValueErrOwned)
BoxShadow(CssShadowParseErrorOwned)
Color(CssColorParseErrorOwned)
PixelValue(CssPixelValueParseErrorOwned)
Percentage(PercentageParseError)
FontFamily(CssStyleFontFamilyParseErrorOwned)
InvalidValue(InvalidValueErrOwned)
FlexGrow(FlexGrowParseErrorOwned)
FlexShrink(FlexShrinkParseErrorOwned)
Background(CssBackgroundParseErrorOwned)
BackgroundPosition(CssBackgroundPositionParseErrorOwned)
Opacity(OpacityParseErrorOwned)
Visibility(StyleVisibilityParseErrorOwned)
LayoutScrollbarWidth(LayoutScrollbarWidthParseErrorOwned)
OverscrollBehavior(OverscrollBehaviorParseErrorOwned)
StyleScrollbarColor(StyleScrollbarColorParseErrorOwned)
ScrollbarVisibilityMode(ScrollbarVisibilityModeParseErrorOwned)
ScrollbarFadeDelay(ScrollbarFadeDelayParseErrorOwned)
ScrollbarFadeDuration(ScrollbarFadeDurationParseErrorOwned)
Transform(CssStyleTransformParseErrorOwned)
TransformOrigin(CssStyleTransformOriginParseErrorOwned)
PerspectiveOrigin(CssStylePerspectiveOriginParseErrorOwned)
Filter(CssStyleFilterParseErrorOwned)
TextColor(StyleTextColorParseErrorOwned)
FontSize(CssStyleFontSizeParseErrorOwned)
FontWeight(CssFontWeightParseErrorOwned)
FontStyle(CssFontStyleParseErrorOwned)
TextAlign(StyleTextAlignParseErrorOwned)
TextJustify(TextJustifyParseErrorOwned)
VerticalAlign(StyleVerticalAlignParseErrorOwned)
LetterSpacing(StyleLetterSpacingParseErrorOwned)
TextIndent(StyleTextIndentParseErrorOwned)
InitialLetter(StyleInitialLetterParseErrorOwned)
LineClamp(StyleLineClampParseErrorOwned)
HangingPunctuation(StyleHangingPunctuationParseErrorOwned)
TextCombineUpright(StyleTextCombineUprightParseErrorOwned)
UnicodeBidi(StyleUnicodeBidiParseErrorOwned)
TextBoxTrim(StyleTextBoxTrimParseErrorOwned)
TextBoxEdge(StyleTextBoxEdgeParseErrorOwned)
DominantBaseline(StyleDominantBaselineParseErrorOwned)
AlignmentBaseline(StyleAlignmentBaselineParseErrorOwned)
BaselineSource(StyleBaselineSourceParseErrorOwned)
LineFitEdge(StyleLineFitEdgeParseErrorOwned)
InitialLetterAlign(StyleInitialLetterAlignParseErrorOwned)
InitialLetterWrap(StyleInitialLetterWrapParseErrorOwned)
ScrollbarGutter(StyleScrollbarGutterParseErrorOwned)
OverflowClipMargin(StyleOverflowClipMarginParseErrorOwned)
Clip(StyleClipRectParseErrorOwned)
ExclusionMargin(StyleExclusionMarginParseErrorOwned)
HyphenationLanguage(StyleHyphenationLanguageParseErrorOwned)
LineHeight(StyleLineHeightParseError)
WordSpacing(StyleWordSpacingParseErrorOwned)
TabSize(StyleTabSizeParseErrorOwned)
WhiteSpace(StyleWhiteSpaceParseErrorOwned)
Hyphens(StyleHyphensParseErrorOwned)
WordBreak(StyleWordBreakParseErrorOwned)
OverflowWrap(StyleOverflowWrapParseErrorOwned)
LineBreak(StyleLineBreakParseErrorOwned)
TextOverflow(StyleTextOverflowParseErrorOwned)
ObjectFit(StyleObjectFitParseErrorOwned)
ObjectPosition(StyleObjectPositionParseErrorOwned)
AspectRatio(StyleAspectRatioParseErrorOwned)
TextOrientation(StyleTextOrientationParseErrorOwned)
TextAlignLast(StyleTextAlignLastParseErrorOwned)
TextTransform(StyleTextTransformParseErrorOwned)
Direction(StyleDirectionParseErrorOwned)
UserSelect(StyleUserSelectParseErrorOwned)
TextDecoration(StyleTextDecorationParseErrorOwned)
Cursor(CursorParseErrorOwned)
CaretColor(CssColorParseErrorOwned)
CaretAnimationDuration(DurationParseErrorOwned)
Animation(StyleAnimationParseErrorOwned)
CaretWidth(CssPixelValueParseErrorOwned)
SelectionBackgroundColor(CssColorParseErrorOwned)
SelectionColor(CssColorParseErrorOwned)
SelectionRadius(CssPixelValueParseErrorOwned)
LayoutDisplay(LayoutDisplayParseErrorOwned)
LayoutFloat(LayoutFloatParseErrorOwned)
LayoutBoxSizing(LayoutBoxSizingParseErrorOwned)
LayoutWidth(LayoutWidthParseErrorOwned)
LayoutHeight(LayoutHeightParseErrorOwned)
LayoutMinWidth(LayoutMinWidthParseErrorOwned)
LayoutMinHeight(LayoutMinHeightParseErrorOwned)
LayoutMaxWidth(LayoutMaxWidthParseErrorOwned)
LayoutMaxHeight(LayoutMaxHeightParseErrorOwned)
LayoutPosition(LayoutPositionParseErrorOwned)
LayoutTop(LayoutTopParseErrorOwned)
LayoutRight(LayoutRightParseErrorOwned)
LayoutLeft(LayoutLeftParseErrorOwned)
LayoutInsetBottom(LayoutInsetBottomParseErrorOwned)
LayoutZIndex(LayoutZIndexParseErrorOwned)
FlexWrap(FlexWrapParseErrorOwned)
FlexDirection(FlexDirectionParseErrorOwned)
FlexBasis(FlexBasisParseErrorOwned)
JustifyContent(JustifyContentParseErrorOwned)
AlignItems(AlignItemsParseErrorOwned)
AlignContent(AlignContentParseErrorOwned)
Grid(GridParseErrorOwned)
GridAutoFlow(GridAutoFlowParseErrorOwned)
JustifySelf(JustifySelfParseErrorOwned)
JustifyItems(JustifyItemsParseErrorOwned)
AlignSelf(AlignSelfParseErrorOwned)
LayoutWritingMode(LayoutWritingModeParseErrorOwned)
LayoutClear(LayoutClearParseErrorOwned)
LayoutOverflow(LayoutOverflowParseErrorOwned)
BorderTopLeftRadius(StyleBorderTopLeftRadiusParseErrorOwned)
BorderTopRightRadius(StyleBorderTopRightRadiusParseErrorOwned)
BorderBottomLeftRadius(StyleBorderBottomLeftRadiusParseErrorOwned)
BorderBottomRightRadius(StyleBorderBottomRightRadiusParseErrorOwned)
BorderStyle(CssBorderStyleParseErrorOwned)
BackfaceVisibility(CssBackfaceVisibilityParseErrorOwned)
AppRegion(CssAppRegionParseErrorOwned)
MixBlendMode(MixBlendModeParseErrorOwned)
PageBreak(PageBreakParseErrorOwned)
BreakInside(BreakInsideParseErrorOwned)
Widows(WidowsParseErrorOwned)
Orphans(OrphansParseErrorOwned)
BoxDecorationBreak(BoxDecorationBreakParseErrorOwned)
ColumnCount(ColumnCountParseErrorOwned)
ColumnWidth(ColumnWidthParseErrorOwned)
ColumnSpan(ColumnSpanParseErrorOwned)
ColumnFill(ColumnFillParseErrorOwned)
ColumnRuleWidth(ColumnRuleWidthParseErrorOwned)
ColumnRuleStyle(ColumnRuleStyleParseErrorOwned)
ColumnRuleColor(ColumnRuleColorParseErrorOwned)
FlowInto(FlowIntoParseErrorOwned)
FlowFrom(FlowFromParseErrorOwned)
GenericParseError
Content
Counter
ListStyleType(StyleListStyleTypeParseErrorOwned)
ListStylePosition(StyleListStylePositionParseErrorOwned)
StringSet
enum ParseFloatError
2 variants
Empty
Invalid
enum ParseIntError
5 variants
Empty
InvalidDigit
PosOverflow
NegOverflow
Zero
struct CssSyntaxErrorPos
2 fields
row: usize
col: usize
union enum CssSyntaxError
4 variants
UnexpectedEndOfStream(CssSyntaxErrorPos)
InvalidAdvance(CssSyntaxInvalidAdvance)
UnsupportedToken(CssSyntaxErrorPos)
UnknownToken(CssSyntaxErrorPos)
struct ErrorLocationRange
2 fields
start: ErrorLocation
end: ErrorLocation
union enum ResultStyledDomRenderDomError
has destructor2 variants
Ok(StyledDom)
Err(RenderDomError)
union enum ResultStringCompileError
has destructor2 variants
Ok(String)
Err(CompileError)
union enum KeyringResult
has destructor7 variants
struct CustomE2eOpResult
has destructorOutcome of a user-defined E2E op.
handledis 'was this op mine at all', NOT 'did it succeed'. The debug server turns false into an explicit unknown-op error rather than an OK, so a typo'd op name in a scenario fails instead of passing silently.2 fields
handled: bool
json: String
enum DocumentEditError
3 variants
HostNotFound
TargetNotFound
Unsupported
union enum ResultAppliedEditDocumentEditError
has destructor2 variants
Ok(AppliedEdit)
Err(DocumentEditError)
enum DbErrorKind
Why a database operation failed.
8 variants
The handle is closed (or
opennever succeeded).NotOpen
The store name is empty or not usable as a store.
InvalidStore
The key is not usable as a key (
Nullkeys are rejected).InvalidKey
The local store could not be read or written.
Io
The local engine reported an error.
Engine
This build has no local engine (
db-sqlitefeature off).NoEngine
The backup endpoint answered with an error.
Sync
Other
struct DbError
has destructorA database error: a kind plus a message.
2 fields
kind: DbErrorKind
message: String
mod fluent
5 typesProject Fluent localization: message bundles and argument formatting.
struct IcuLocalizerHandle
3 fields
ptr: c_void
copies: c_void
run_destructor: bool
2 constructors
constructor from_system_language:
arg language: String
constructor create:
arg default_locale: String
Create a cache initialized with the system language.
Create a new empty cache with a default locale.
17 methods
&self
-> String
&mut self
arg locale: String
fn set_locale:
&mut self
arg locale: String
fn load_data_blob:
&self
arg data: U8VecRef
-> bool
fn get_language:
fn format_integer:
fn format_decimal:
&self
arg locale: String
arg value: i64
fn pluralize:
fn format_date:
&self
arg locale: String
arg date: IcuDate
arg length: FormatLength
-> IcuResult
fn format_time:
fn format_datetime:
&self
arg locale: String
arg datetime: IcuDateTime
arg length: FormatLength
-> IcuResult
fn compare_strings:
fn strings_equal:
fn format_plural:
fn clear_cache:
&self
&self
-> usize
Get the default locale string.
Set the default locale.
Alias for set_default_locale for compatibility.
Load additional locale data from a binary blob for all cached localizers.
More
The blob should be generated using
icu4x-datagenwith the--format blobflag. This allows supporting locales that aren't compiled into the binary.Returns
trueif the data was successfully loaded.Get the language part of a locale (e.g., "en" from "en-US").
Format an integer with locale-appropriate grouping.
More
Example
Format a decimal number.
More
# Arguments *
locale- BCP 47 locale string (e.g., "en-US", "de-DE") *integer_part- The full integer value (e.g., 123456 for 1234.56) *decimal_places- Number of decimal places (e.g., 2 for 1234.56)Get the plural category for a number.
More
Example
Select a string based on plural rules.
More
# Arguments *
locale- BCP 47 locale string *value- The number to pluralize *zero,one,two,few,many,other- Strings for each categoryFormat a date according to the specified locale.
More
Example
Format a time according to the specified locale.
More
Example
Format a date and time according to the specified locale.
Compare two strings according to locale-specific collation rules.
More
Returns -1 if a < b, 0 if a == b, 1 if a > b.
Example
Check if two strings are equal according to locale collation rules.
Convenience function to format a localized message with plural support.
More
This handles the common case of "{count} {item/items}" patterns. The
{}placeholder in the template will be replaced with the formatted number.Clear the cache (useful for memory management or locale data reload).
Get the number of cached locales.
struct FluentLocalizerHandle
3 fields
ptr: c_void
copies: c_void
run_destructor: bool
1 constructor
10 methods
&self
-> String
&self
arg locale: String
fn add_resource:
fn load_from_zip:
&self
arg data: U8VecRef
fn translate:
fn has_message:
&self
-> StringVec
fn clear_locale:
&self
arg locale: String
fn clear_all:
&self
Get the default locale string.
Set the default locale.
Add a Fluent resource (FTL content) for a specific locale.
More
Returns true if the resource was successfully added.
Add a Fluent resource from bytes (for loading from files).
Load translations from a ZIP archive containing .fluent files.
More
File naming convention:
{locale}.fluentor{locale}/{filename}.fluentTranslate a message ID to the target locale.
More
Returns the translated string, or the message ID if not found.
Check if a message ID exists in the given locale.
Get the list of all loaded locales.
Clear all loaded resources for a specific locale.
Clear all loaded resources.
struct FluentLoadErrorVecSlice
has destructor2 fields
struct FluentZipLoadResult
has destructor3 fields
union enum FluentSyntaxCheckResult
has destructor2 variants
Ok
Errors(StringVec)
2 constructors
constructor checkSyntax:
arg source: String
constructor checkSyntaxBytes:
arg data: U8VecRef
Check the syntax of a Fluent (FTL) string.
More
Returns Ok if valid, or Errors with a list of error strings. Each error string has the format 'line:column: message'.
Check the syntax of a Fluent (FTL) file from bytes.
More
Returns Ok if valid, or Errors with a list of error strings.
1 method
fn getErrors:
&self
Get the error strings if this is an Errors result.
More
Returns None if this is Ok.
mod webtransport
5 typesenum WtReliability
Per-send reliability / quality knob for
WebTransportsends.3 variants
ReliableOrdered
ReliableUnordered
Datagram
struct WtStats
Connection stats for app-side throttling (from QUIC; zero for the v1 stub).
6 fields
rtt_us: u64
cwnd_bytes: u64
send_queue_bytes: u64
bytes_sent: u64
bytes_recv: u64
packet_loss_x1000: u32
enum WtEventKind
Discriminant for
WtEvent.8 variants
Connected
Disconnected
PeerJoined
PeerLeft
Video
Audio
Chat
System
struct WtEvent
has destructorOne inbound room event. Inspect
kind; only the relevant fields are set.audiois ready forAudioSink::play;data(Video) is the encoded frame.7 fields
mod iroh
9 typesenum IrohRelayMode
Where an endpoint may relay traffic when no direct UDP path to a peer exists.
3 variants
Direct paths only: peers must reach each other over the local network or public addresses.
Disabled
The public relay servers operated by n0.
Default
The relay server named in
IrohConfig::relay_url.Custom
struct IrohConfig
has destructorSettings for
IrohEndpoint::bind.6 fields
Application protocol name. Only peers that bind the same name can connect.
alpn: String
Relay fallback for peers without a direct path.
relay_mode: IrohRelayMode
Relay server URL, used when
relay_modeisCustom.relay_url: String
32-byte secret key that fixes the endpoint id. Empty generates a new identity.
secret_key: U8Vec
Local UDP port, 0 for any free port.
port: u16
Largest inbound frame or message in bytes. Larger ones are dropped.
max_frame_bytes: u32
1 constructor
constructor create:
arg alpn: String
-> IrohConfig
Config for the protocol
alpn: default relays, a new identity, any free port, 16 MiB frames.5 methods
fn with_relay_mode:
self
arg relay_mode: IrohRelayMode
-> IrohConfig
fn with_relay_url:
self
arg url: String
-> IrohConfig
fn with_secret_key:
self
arg secret_key: U8Vec
-> IrohConfig
fn with_port:
self
arg port: u16
-> IrohConfig
self
arg max_frame_bytes: u32
-> IrohConfig
Returns the config with
relay_modereplaced.Returns the config relaying through the server at
url.Returns the config with a persisted 32-byte identity, as read from
IrohEndpoint::secret_key.Returns the config bound to the local UDP
port.Returns the config accepting inbound frames and messages up to
max_frame_bytes.enum IrohEventKind
What an
IrohEventreports.6 variants
The endpoint knows its addresses.
textis its ticket.Ready
A connection was dialed or accepted.
textis the remote endpoint id.PeerConnected
A connection closed.
textis the reason.PeerDisconnected
The newest frame of a track. Frames that arrived while it was pending were skipped.
Frame
A reliable message, delivered in the order the peer sent it.
Message
A bind, dial or transport failure.
textdescribes it.Error
struct IrohEvent
has destructorOne event from
IrohEndpoint::recv. Fields that do not apply tokindare zero or empty.6 fields
Connection handle, 0 when the event concerns no peer.
peer: u64
Send counter of a
FrameorMessage. Gaps between frames are skipped frames.sequence: u64
Ticket, remote endpoint id or error text, depending on
kind.text: String
Payload of a
FrameorMessage.data: U8Vec
kind: IrohEventKind
Track of a
Frame.track: u32
struct IrohPeerStats
Path and throughput statistics of one connection.
10 fields
Whether the connection is still open.
connected: bool
Whether traffic flows over a direct UDP path rather than a relay.
direct: bool
Smoothed round-trip time of the selected path, in microseconds.
rtt_us: u64
Congestion window of the selected path, in bytes.
cwnd_bytes: u64
bytes_sent: u64
bytes_received: u64
lost_packets: u64
frames_sent: u64
frames_received: u64
Outbound frames replaced by a newer frame of the same track before they left.
frames_skipped: u64
struct IrohEndpoint
A QUIC endpoint that dials and accepts peers by ticket and exchanges frames and messages with them.
More
Copies share one endpoint; it closes when the last copy is dropped or
closeis called.2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor bind:
arg config: IrohConfig
-> IrohEndpoint
Binds an endpoint. On failure
is_boundis false and the firstrecvreturns theErrorevent.14 methods
fn is_bound:
&self
-> bool
fn endpoint_id:
&self
-> String
fn secret_key:
&self
-> U8Vec
fn ticket:
&self
-> String
fn connect:
&self
arg ticket: String
-> bool
fn send_frame:
&self
arg peer: u64
arg track: u32
arg data: U8Vec
-> bool
fn broadcast_frame:
&self
arg track: u32
arg data: U8Vec
-> bool
fn send_message:
&self
arg peer: u64
arg data: U8Vec
-> bool
fn disconnect:
&self
arg peer: u64
-> bool
fn peer_count:
&self
-> usize
fn peer_endpoint_id:
&self
arg peer: u64
-> String
fn peer_stats:
&self
arg peer: u64
fn recv:
&self
fn close:
&mut self
Whether the endpoint is bound and not closed.
Public key identifying this endpoint, as lowercase hex. Empty when not bound.
The 32-byte identity key, for
IrohConfig::with_secret_keyon the next start. Empty when not bound.Dialing string with this endpoint's id and current addresses. Empty when not bound.
Dials the endpoint in
ticket, or a bare endpoint id. The outcome arrives asPeerConnectedorError.More
Returns false, and queues the
Errorevent, when the ticket cannot be dialed at all.Queues a frame for one peer. A newer frame of the same track replaces one that has not left yet.
Queues a frame for every connected peer, replacing unsent frames of the track. False without peers.
Sends a reliable message. The peer receives messages in the order they were sent.
Closes the connection to
peer. Returns false when no such connection is open.Number of open connections.
Endpoint id of the peer behind a connection handle. Empty when the connection is gone.
Path and throughput statistics of a connection. All zero when the connection is gone.
Takes the next event. Connection events and messages come first, then the newest frame of each track in turn.
Closes the endpoint and its connections for every copy of this handle, then releases this copy.
struct IrohPeerCapacity
What a peer can contribute to forwarding, as measured or reported by that peer.
6 fields
Connection handle or roster index identifying the peer.
peer: u64
Estimated upload capacity in kbit/s.
uplink_kbps: u32
Share of recent intervals without loss spikes or RTT jumps, 0.0 to 1.0.
stability: f32
on_battery: bool
Reachable only through a relay, as browsers are.
relay_only: bool
The user declined to forward other people's media.
opted_out: bool
1 constructor
constructor create:
arg peer: u64
arg uplink_kbps: u32
A stable, mains-powered, directly reachable peer with
uplink_kbpsof upload.1 method
fn score:
&self
-> f32
Forwarding score: uplink times stability, cut to 30 percent on battery, 0 when relay-only or opted out.
enum IrohTileRole
How a video tile is shown, which caps the resolution it requests.
5 variants
The presentation or main speaker.
Stage
Active speakers next to the stage.
Side
Recent speakers in the strip.
Filmstrip
A tile of the paged gallery.
Gallery
A tile the viewer pinned.
Pinned
2 methods
fn max_height:
&self
arg room_size: u32
-> u32
fn rendition_height:
&self
arg tile_height: f32
arg scale_factor: f32
arg room_size: u32
-> u32
Largest rendition height this role may request in a room of
room_sizepeople.Rendition height (90, 180, 360 or 720) to request for a tile
tile_heightlogical pixels tall; 0 for a hidden tile.struct IrohLoadBalancer
Chooses which peers of a room forward media for everyone else.
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor create:
An empty room.
8 methods
fn set_peer:
&mut self
arg capacity: IrohPeerCapacity
fn remove_peer:
&mut self
arg peer: u64
-> bool
fn peer_count:
&self
-> usize
fn select_backbone:
&mut self
arg fanout_kbps: u64
-> usize
fn backbone_peer:
&self
arg index: usize
-> OptionU64
fn is_backbone:
&self
arg peer: u64
-> bool
fn backbone_size:
arg room_size: u32
-> u32
fn rendition_kbps:
arg height: u32
-> u32
Adds
capacity, replacing the earlier record of the same peer.Removes a peer and drops it from the backbone. Returns whether it was present.
Number of peers in the room.
Chooses forwarders able to carry
fanout_kbpsof culled demand. Returns how many were chosen.The forwarder at
index, best score first, afterselect_backbone.Whether
peerwas chosen as a forwarder by the lastselect_backbone.Minimum forwarder count for a room of
room_size: everyone up to 8 people, then max(ceil(sqrt N), ceil(N / 8)).Bitrate in kbit/s the planner assumes for a rendition of
heightpixels.
mod misc
17 typesenum Capability
19 variants
Camera
Microphone
ScreenCapture
Geolocation
GeolocationBackground
Biometric
Motion
PhotoLibrary
PhotoLibraryWrite
Contacts
Calendars
Reminders
Notifications
Bluetooth
BluetoothBackground
NearbyWifi
LocalNetwork
AppTrackingTransparency
InputMonitoring
union enum PermissionState
6 variants
enum PermissionQuality
2 variants
Full
Reduced
struct PaginationSnapshot
Boxed pagination analysis: page count, page-of-Y and every break position computed WITHOUT materializing any per-page display list (the document- editor precalculation). Obtain via
Pdf.compute_pagination(). An empty handle reports 0 pages.2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor empty:
An empty handle (0 pages - the failure value).
8 methods
fn page_count:
&self
-> usize
&self
-> f32
fn break_count:
&self
-> usize
fn break_y:
&self
arg index: usize
-> f32
fn break_is_forced:
&self
arg index: usize
-> bool
&self
arg index: usize
-> bool
fn page_of_y:
&self
arg y: f32
-> usize
fn break_path:
&self
arg index: usize
-> U32Vec
Number of pages (0 for an empty handle).
Total document-space content height.
Number of page breaks.
Document-space Y of break
index(0.0 out of range).Whether break
indexwas forced by CSS break-before/after.Whether break
indexwas moved by an avoid-rule (break-inside, widows/orphans, atomic lines or table rows).Which page a document-space Y lands on - 'what page is this node on?' with NO page ever materialized.
Root-to-node child-index DOM path of break
index- where inserting a break node BEFORE the addressed node reproduces this page boundary structurally (consumable byDomSplit::at_path). EMPTY when out of range, when the break has no block at/after it, or when the snapshot was computed by a path without structural mapping.enum InstallKind
What kind of installation the running binary is - decides whether self-update is even on the table.
6 variants
SystemPackageManager
Snap
Flatpak
WindowsStore
UserWritable
ReadOnly
struct ReleaseInfo
has destructorOne release, as the update manifest describes it.
9 fields
version: String
download_url: String
changelog_md_url: String
The changelog Markdown itself, when the source carried it inline (a GitHub release body does). Preferred over fetching changelog_md_url.
changelog_md_inline: String
digest: String
Minisign signature of the artifact by the release-signing key (full .minisig text); required whenever the app pins a root_public_key.
signature: String
Root-delegated signing-key statement: azul-signing-key-v1|pubkey=..|expires=..|generation=..
signing_key_statement: String
Minisign signature of the statement string by the ROOT key (full .minisig text).
signing_key_statement_sig: String
Headers the download needs when the artifact is not on open HTTP - an OCI registry blob wants the same bearer token the manifest request used. Empty for ordinary downloads.
download_headers: StringPairVec
enum TransientAnchor
5 variants
Bottom
Top
Left
Right
Cursor
enum TransientDismiss
3 variants
Outside
Escape
None
enum TransientTearoff
3 variants
None
Free
Zone
enum TransientDock
2 variants
Popup
Inline
struct DocOpRemoveChildren
3 fields
struct EditResumePoint
has destructor3 fields
enum MediaControlKind
4 variants
SeekRelative
SeekAbsolute
OpenUri
SetVolume
struct MediaControlRequest
has destructor5 fields
struct PlaybackState
5 fields
position_s: f32
duration_s: f32
volume: f32
playing: bool
muted: bool
mod zip
1 typestruct Zip
2 fields
ptr: c_void
run_destructor: bool
3 constructors
constructor create:
-> Zip
constructor from_bytes:
constructor from_file:
An empty archive.
Parse ZIP
bytes.More
A malformed archive (or a build without the
zipfeature) yields a valid but EMPTY handle rather than a null one, so callers that forget to check get nothing instead of a crash. Path traversal (..) is rejected by the underlying reader.Read and parse a
.zipoff disk. Empty handle if it cannot be read.13 methods
fn is_valid:
&self
-> bool
fn add_file:
fn add_directory:
&mut self
arg path: String
fn remove:
&mut self
arg path: String
fn contains:
&self
arg path: String
-> bool
fn file_count:
&self
-> usize
fn file_path:
&self
arg index: usize
-> String
fn file_data:
&self
arg index: usize
-> U8Vec
&self
arg index: usize
-> bool
fn get_file:
fn to_bytes:
&self
-> U8Vec
&self
arg level: u8
-> U8Vec
fn to_file:
&self
arg path: String
-> bool
trueif this handle owns an archive. False only for a handle whose memory could not be allocated, or one already deleted.Append a file entry. A repeated path is kept as-is: ZIP permits duplicates, and silently dropping one would lose data the caller believes it stored.
Append a directory entry (no data). Only needed for readers that expect explicit directory records - file paths may contain
/freely.Drop every entry with this exact path.
trueif an entry with this exact path exists.Number of entries, files and directories alike.
Path of entry
index; empty string when out of range.Contents of entry
index; empty when out of range or a directory.trueif entryindexis a directory record.Contents of the entry at
path; empty if absent.More
Ambiguous with a real zero-byte entry - use
containswhen the difference matters.Compress to ZIP bytes with deflate level 6.
More
Empty on failure or without the
zipfeature - test the result rather than assuming it worked.Compress to ZIP bytes.
level0 stores uncompressed (fastest, right for already-compressed payloads); 1-9 deflate at that level.Write the archive to
path.trueon success.
mod tray
9 typesstruct TrayIconImage
has destructor2 methods
fn create:
arg width: u32
arg height: u32
arg rgba: U8Vec
fn to_argb32_be:
&self
-> U8Vec
rgbamust be exactlywidth * height * 4bytes; returnsNoneotherwise.More
Returns
OptionTrayIconImagerather thanOption<Self>so the signature crosses the C ABI unchanged.The icon's pixels as ARGB32 in network (big-endian) byte order, the wire format
org.kde.StatusNotifierItem'sIconPixmap(a(iiay)) requires. Nothing else uses this layout, so it is computed on demand.enum TrayCategory
4 variants
ApplicationStatus
Communications
SystemServices
Hardware
struct TrayIconData
has destructor8 fields
id: String
title: String
icon: TrayIconSource
attention_icon: TrayIconSource
tooltip: OptionString
category: TrayCategory
status: TrayStatus
1 constructor
constructor create:
arg id: String
arg title: String
-> TrayIconData
5 methods
fn with_icon:
self
arg icon: TrayIconImage
-> TrayIconData
fn with_tooltip:
self
arg tooltip: String
-> TrayIconData
fn with_named_icon:
self
arg spec: String
-> TrayIconData
fn best_icon:
&self
arg target_px: u32
Use an explicit RGBA bitmap. Prefer [
Self::with_named_icon] unless the icon genuinely is not in a pack.Use an icon from the icon registry, by the same spec an
<icon>node takes -"settings","mypack:logo", or a fallback list. Preferred: it renders at whatever size each platform asks for.The icon closest to
target_px, preferring the smallest one that is at leasttarget_px(upscaling a small icon looks far worse than downscaling a large one - this is why Windows' ownLoadIconMetricscales down from a larger frame rather than up). Only meaningful for [TrayIconSource::Rgba]; aNamedicon is rasterized at the exact size instead, so it never needs picking.More
Returns an owned
OptionTrayIconImagerather thanOption<&_>because a borrow cannot cross the C ABI. The clone is oneU8Vecbump.union enum TrayIconSource
has destructor3 variants
enum TrayStatus
3 variants
Passive
Active
NeedsAttention
enum TrayScrollAxis
2 variants
Vertical
Horizontal
enum TrayEventType
5 variants
Activate
SecondaryActivate
ContextMenu
Scroll
MenuItem
struct TrayIconImageVecSlice
has destructor2 fields
mod json
6 typesstruct Json
has destructor2 fields
value_type: JsonType
internal: JsonInternal
9 constructors
constructor parse:
arg s: String
constructor object:
arg entries: JsonKeyValueVec
-> Json
constructor array:
constructor parse_bytes:
arg bytes: U8VecRef
constructor null:
-> Json
constructor bool:
arg value: bool
-> Json
constructor float:
arg value: f64
-> Json
constructor int:
arg value: i64
-> Json
constructor string:
Parse JSON from a string
Create a JSON object from key-value pairs
Create a JSON array from a vector of JSON values
Parse JSON from bytes (UTF-8)
Create a null JSON value
Create a boolean JSON value
Create a floating-point JSON value
Create an integer JSON value
Create a string JSON value
22 methods
fn to_string:
&self
-> String
fn get_key:
&self
arg key: String
-> OptionJson
fn get_index:
&self
arg index: usize
-> OptionJson
fn as_string:
&self
-> OptionString
fn jq:
fn is_null:
&self
-> bool
fn is_bool:
&self
-> bool
fn is_float:
&self
-> bool
fn is_string:
&self
-> bool
fn is_array:
&self
-> bool
fn is_object:
&self
-> bool
fn as_bool:
&self
-> OptionBool
fn as_float:
&self
-> OptionF64
fn as_int:
&self
-> OptionI64
fn len:
&self
-> usize
fn is_empty:
&self
-> bool
fn keys:
&self
-> StringVec
fn to_array:
&self
fn to_object:
&self
fn to_string_pretty:
&self
-> String
fn jq_all:
self
arg deserialize_fn: usize
Serialize to JSON string
Get object value by key
Get array element by index
Get as string (returns None if not a string)
Access a nested value using a JSON Pointer (RFC 6901).
More
The pointer syntax uses
/to separate path components: -/fooaccesses key "foo" in an object -/0accesses index 0 in an array -/foo/bar/0accesses nested pathsReturns Json::null() if the path doesn't exist or points to an invalid location.
Example
Check if this is null
Check if this is a boolean
Check if this is a floating-point number
Check if this is a string
Check if this is an array
Check if this is an object
Get as boolean (returns None if not a bool)
Get as float (returns None if not a number)
Get as integer (returns None if not a number or not an integer)
Get the number of elements (for arrays) or keys (for objects)
Check if empty (for arrays/objects)
Get all keys of an object
Convert array to Vec<Json>
Convert object to Vec<JsonKeyValue>
Serialize to pretty-printed JSON string
Access nested values using a JSON Pointer with wildcard support.
More
Similar to
jq()but supports*wildcard to iterate over all elements in an array or all values in an object.The wildcard
*matches all keys/indices at that position and returns a Vec of all matched values.Examples
Deserialize this JSON into a RefAny using the provided deserialize function pointer.
More
The deserialize_fn should be obtained from an existing RefAny of the target type via RefAny::get_deserialize_fn().
Returns Ok(RefAny) on success, or Err(String) with an error message on failure.
enum JsonType
6 variants
Null
Bool
Number
String
Array
Object
struct JsonKeyValueVecSlice
has destructor2 fields
struct JsonVecSlice
has destructor2 fields
struct JsonInternal
has destructor3 fields
mod pdf
20 typesstruct Pdf
1 field
_reserved: u8
6 methods
fn from_dom:
fn from_styled_dom_with_resources:
&self
arg styled_dom: StyledDom
arg page_width_px: f32
arg page_height_px: f32
arg font_cache: FontCacheSnapshot
arg image_cache: ImageCacheSnapshot
-> U8Vec
fn write_json:
fn read_json:
&self
arg callback_info: CallbackInfo
arg dom: Dom
arg page_width_px: f32
arg page_height_px: f32
-> U8Vec
&self
arg styled_dom: StyledDom
arg page_width_px: f32
arg page_height_px: f32
arg font_cache: FontCacheSnapshot
arg image_cache: ImageCacheSnapshot
Render
domto PDF bytes at the given page size (logical px) - the "HTML/DOM -> PDF" path. Headless, multi-page, no file I/O; save the returned bytes yourself. Empty without thepdffeature or on failure.Fully TYPED export: an already-styled DOM plus resource snapshots - no JSON, no base64, no re-decode. Take the styled dom / fonts / images from a callback (
get_styled_dom_clone/get_font_cache_clone/get_image_cache_clone) and the PDF is the window's content re-laid-out at page size. Runs off-thread fine. Empty handles fall back to fresh system resources.Write a PDF from a JSON document model -> PDF bytes. Empty on a malformed model or without the
pdffeature.Read a PDF (
bytes) into the JSON document model. JSONnullon a parse error or without thepdffeature.Like
from_dom, but called from inside a running app's callback: reuses the window's live font manager and image cache, so the PDF resolves exactly the fonts and images the screen did (print-preview parity). Empty without thepdffeature or on failure.PRECALCULATION-ONLY pagination: full layout + break analysis at the given page size, but NO per-page display list is ever materialized. Same resource snapshots as
from_styled_dom_with_resources; runs off-thread fine. The returned handle answers page-count / page-of-Y / break positions; an empty handle (0 pages) signals failure or a build without thepdffeature.struct PageBreakPositionVecSlice
2 fields
struct PageBreakPosition
3 fields
struct FakePageConfig
has destructor16 fields
page_sequence: OptionPageSequence
header_text: OptionString
header_height: f32
font_size: f32
number_format: CounterFormat
break_policy: BreakPolicy
text_color: ColorU
show_header: bool
header_page_number: bool
header_total_pages: bool
skip_first_page: bool
enum CounterFormat
7 variants
Decimal
DecimalLeadingZero
LowerRoman
UpperRoman
LowerAlpha
UpperAlpha
LowerGreek
struct PaginationInfo
3 fields
struct BreakPolicy
6 fields
max_push_distance: f32
honor_break_inside: bool
widows_orphans: bool
atomic_lines: bool
atomic_table_rows: bool
repeat_table_headers: bool
struct PageSetup
has destructor3 fields
page_size: LogicalSize
margins: PageMargins
struct PageSequence
has destructor5 fields
default: PageSetup
overrides: PageSetupOverrideVec
first_page: OptionPageSetup
odd_pages: OptionPageSetup
even_pages: OptionPageSetup
struct PageMargins
4 fields
top: f32
right: f32
bottom: f32
left: f32
union enum MarginBoxContent
has destructor9 variants
None
RunningElement(String)
NamedString(String)
PageCounter
PagesCounter
PageCounterFormatted(CounterFormat)
Combined(MarginBoxContentVec)
Text(String)
Custom(MarginBoxCustom)
struct PageSetupOverrideVecSlice
has destructor2 fields
struct MarginBoxContentVecSlice
has destructor2 fields
struct PageSetupOverride
has destructor2 fields
page: usize
setup: PageSetup
union enum BreakKind
3 variants
Forced
Interval
Avoided(f32)
struct MarginBoxCustom
2 fields
callback: MarginBoxCallback
data: RefAny
struct PageInfo
7 fields
page_number: usize
total_pages: usize
is_first: bool
is_last: bool
is_left: bool
is_right: bool
is_blank: bool
struct MarginBoxCallback
2 fields
ctx: OptionRefAny
mod gesture
11 typesstruct DetectedRotation
Result of rotation gesture detection (angle + center + duration).
3 fields
Rotation angle in radians (positive = clockwise)
angle_radians: f32
Center point of rotation
center: LogicalPosition
Duration of rotation so far, in milliseconds
duration_ms: u64
enum TabletToolKind
What kind of input device a
TabletDeviceInfodescribes.10 variants
Stylus
Eraser
Pad
Touch
Unknown
Brush
Pencil
Airbrush
Mouse
Lens
struct TabletDeviceInfo
has destructorIdentity and capabilities of one tablet input device - the
xinput listlevel of information: enough for an app to tell the user WHICH tablet is in use, offer a device picker, or configure a custom mapping. Fields a backend cannot know are zero / empty rather than guessed.12 fields
Driver-reported device name.
name: String
Vendor display name resolved from vendor_id; empty when unknown.
vendor_name: String
Kernel device node (/dev/input/event..) where known, else empty.
path: String
Matches PenState.device_id / WacomPadState.device_id on the same backend.
device_id: u64
USB vendor id (0 = unknown).
vendor_id: u32
USB product id (0 = unknown).
product_id: u32
kind: TabletToolKind
TABLET_CAP_* bitset: 1 pressure, 2 tilt, 4 rotation, 8 slider, 16 wheel, 32 touch-ring.
capabilities: u32
Raw driver pressure maximum (diagnostic; PenState.pressure is normalized).
pressure_max: f32
Active-area width in millimeters, 0.0 = unknown.
physical_width_mm: f32
Active-area height in millimeters, 0.0 = unknown.
physical_height_mm: f32
Number of buttons the device reports (pad: ExpressKeys).
num_buttons: u32
struct DetectedLongPress
Result of long-press detection (position + hold duration).
4 fields
Position where the long press is happening
position: LogicalPosition
How long the pointer has been held in place (milliseconds)
duration_ms: u64
Whether the callback has already been invoked for this long press
callback_invoked: bool
Session ID this long press belongs to
session_id: u64
struct TabletDeviceInfoVecSlice
has destructor2 fields
struct TabletPadState
9 fields
device_id: u64
express_keys: u32
touch_ring: f32
strip: f32
dial_delta: f32
mode: u32
mode_count: u32
touch_ring_active: bool
strip_active: bool
union enum HapticTarget
3 variants
System
Gamepad(u32)
Pen
struct DialState
5 fields
struct HapticRequest
4 fields
enum HapticPattern
19 variants
Selection
ImpactLight
ImpactMedium
ImpactHeavy
ImpactSoft
ImpactRigid
Success
Warning
Error
KeyPress
KeyRelease
LongPress
ContextClick
TextHandleMove
GestureStart
GestureEnd
Rise
Fall
Spin
union enum NativeGestureEvent
5 variants
DoubleClick
LongPress(DetectedLongPress)
Swipe(GestureDirection)
Pinch(DetectedPinch)
Rotation(DetectedRotation)
mod db
26 typesstruct Db
A handle to an open local-first database: a key/value + index store whose local working set replicates to an optional backup endpoint. Reference counted: clones share the store; it closes when the last clone is dropped or
closeis called. Desktop keeps a pure-Rust SQLite engine as a hidden implementation detail, web uses IndexedDB; raw SQL is not part of the API on any target. On 32-bit Linux (i686, armv7) the 0.2.0 builds ship without the bundled engine, because turso_sync_engine 0.7.2 does not compile for a 32-bitoff_t;openfails there exactly as in a build without thedb-sqlitefeature.2 fields
ptr: c_void
run_destructor: bool
13 methods
fn open:
arg config: DbConfig
arg data: RefAny
arg on_open: ResumeCallback
-> RequestId
fn is_open:
&self
-> bool
fn get:
&self
arg store: String
arg key: DbValue
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn set:
fn remove:
fn iterate:
&self
arg store: String
arg range: DbKeyRange
arg limit: u32
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn query_index:
&self
arg store: String
arg index: String
arg range: DbKeyRange
arg limit: u32
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn subscribe:
&self
arg scope: DbScope
arg data: RefAny
arg on_change: ResumeCallback
-> RequestId
fn sync_now:
&self
arg scope: OptionDbScope
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn sync_status:
&self
-> DbSyncStatus
&mut self
arg data: RefAny
arg on_status: ResumeCallback
fn set_on_conflict:
&mut self
arg store: String
arg data: RefAny
arg on_merge: DbMergeCallback
fn close:
&mut self
Open (or create) the local store described by
configand resumeon_openwith aDbOpenResult. The stores declared in the schema exist before the callback runs. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns, on web on a later task.truewhile the handle is open (the engine is present andclosehas not been called).Read
keyfromstore, resumingon_resultwith aDbValueResult(value: Nonewhen the key is absent). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns, on web on a later task.Write
valueunderkeyinstore. Fire-and-forget: the row lands in the local store immediately (read-your-writes) and is marked dirty in the oplog until the next successful push.falsefor an invalid store / key or a closed handle.Delete
keyfromstore(a tombstone that syncs like any other write).falsefor an invalid store / key or a closed handle.The rows of
storewhose key falls inrange, in key order, at mostlimitof them (0= no limit), resumingon_resultwith aDbRowsResultwhose grid has the two columnskeyandvalue. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns, on web on a later task.The rows of
storewhoseindexkey falls inrange, in index-key order, at mostlimit(0= no limit); same result shape asiterate. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns, on web on a later task.Extend the local working set to cover
scopeand deliver aDbChangeResulttoon_changefor every change inside it, local or pulled, until the handle is closed. Fires repeatedly; the returned id identifies the subscription.Explicit sync point: push every dirty row to the backup endpoint, then refresh the given (or the configured) scope from it, resuming
on_resultwith aDbSyncStatusResult. Offline leaves the writes queued and reportsQueued; it is not an error. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns, on web on a later task.A snapshot of the sync state (poll getter).
Deliver a
DbSyncStatusResulttoon_statusafter every sync until the handle is closed. Fires repeatedly.Install the merge function for
store(used when its conflict policy isMerge).Close the store. Every clone of the handle sees
is_open() == falseafterwards; subscriptions are dropped.struct DbRows
has destructorA column-named, row-major value grid: the rows of an
iterate/query_indexanswer (key,valuecolumns). Cell(row, col)isvalues[row * num_columns + col].2 fields
columns: StringVec
values: DbValueVec
3 methods
fn num_columns:
&self
-> usize
fn num_rows:
&self
-> usize
fn get:
&self
arg row: usize
arg col: usize
Number of columns.
Number of rows (
0when there are no columns).The cell at
(row, col), orNoneif out of range.struct DbValueVecSlice
has destructor2 fields
enum DbConflictPolicy
How a sync conflict (the same key changed locally and remotely since the last sync) is resolved for a store.
4 variants
The newer modification wins (the default).
LastWriteWins
The remote value always wins.
ServerWins
The local value always wins.
ClientWins
The store's
DbMergeCallback(Db::set_on_conflict) computes the merged value; falls back toLastWriteWinswhen none is registered.Merge
enum DbSyncState
Where a database stands with its backup endpoint.
6 variants
No
backup_sync_urlconfigured, or the handle is closed.Disconnected
Everything pushed and pulled.
Idle
Pushing
Pulling
Offline: local writes are queued in the oplog and pushed on the next successful sync. Never an error.
Queued
The last sync failed for a reason other than being offline (
errorsays why).Error
struct DbIndexSchema
has destructorA secondary index over a store. Values are indexed when they are JSON objects:
key_pathnames the top-level field whose value becomes the index key; values that are not JSON objects, or lack the field, are simply not indexed.struct DbIndexSchemaVecSlice
has destructor2 fields
struct DbStoreSchema
has destructorOne store (collection) of a
DbSchema: its name, indexes and the conflict policy applied when syncing it.3 fields
struct DbStoreSchemaVecSlice
has destructor2 fields
struct DbSchema
has destructorThe declarative schema of a database: its stores with their indexes and conflict policies. No DDL strings - the engine derives its tables from this on every target. Stores not declared here are created on first write, without indexes and with
LastWriteWins.1 field
stores: DbStoreSchemaVec
struct DbKeyRange
has destructorA key range:
Nonebounds are unbounded,*_openexcludes the bound itself. Keys order the way SQLite orders values (Null < numbers < text < blobs).4 fields
3 constructors
constructor all:
-> DbKeyRange
constructor between:
arg lower: DbValue
arg upper: DbValue
-> DbKeyRange
constructor only:
arg key: DbValue
-> DbKeyRange
Every key.
lower <= key <= upper.Exactly
key.struct DbIndexPredicate
has destructorA predicate over a store's secondary index: the rows whose index key falls in
range.2 fields
index: String
range: DbKeyRange
struct DbCollectionScope
has destructorThe part of one store a scope covers: a key range and / or an index predicate; both
Nonemeans the whole store.3 fields
1 constructor
constructor whole_store:
arg store: String
The whole
store.struct DbCollectionScopeVecSlice
has destructor2 fields
struct DbScope
has destructorThe working set a database replicates locally: a set of collection scopes. An empty scope means "everything the remote has".
1 field
collections: DbCollectionScopeVec
1 constructor
constructor everything:
-> DbScope
Everything.
struct DbAutoSync
When the runtime syncs on its own: every
interval, and / or when the app has not written to the store for a moment (on_idle: about 1.5 s after the last write, when unpushed writes exist). Driven by the runtime's per-frame pump on desktop and by the host on web; every automatic sync reports throughDb::set_on_sync_status.2 fields
interval: OptionDuration
on_idle: bool
1 constructor
constructor manual:
-> DbAutoSync
No automatic sync: only explicit
sync_nowcalls.struct DbConfig
has destructorHow to open a database. Builder-style:
DbConfig::create(local_name)plus thewith_*setters. Identical on every target: the local store is a file under the app's data directory on desktop and IndexedDB on web;":memory:"is a throwaway in-memory store. Remote backup / sync is a first-class option on both targets.7 fields
local_name: String
backup_sync_url: OptionString
auth_token: OptionString
schema: DbSchema
scope: OptionDbScope
local_budget_bytes: u64
auto_sync: DbAutoSync
1 constructor
6 methods
fn with_auth_token:
fn with_schema:
fn with_scope:
self
arg bytes: u64
-> DbConfig
fn with_auto_sync:
self
arg auto: DbAutoSync
-> DbConfig
Remote backup / sync endpoint (HTTPS). Local-first: the remote is a backup and a way to share the working set, never the source of truth for reads.
Bearer token sent with every sync request.
Declare the stores, their indexes and per-store conflict policies.
The working set replicated locally (default: everything).
Local size budget in bytes (
0= unlimited). Under pressure clean rows are evicted, oldest first; dirty (unpushed) rows never.When the runtime syncs on its own (see
DbAutoSync).struct DbSyncStatus
has destructorA snapshot of a database's sync state, delivered by
Db::sync_status,Db::sync_nowandDb::set_on_sync_status.working_set_coverage_x1000is how much of the configured scope the local working set holds (1000 = complete); timestamps are milliseconds since the Unix epoch (0 = never);quota_bytes_availableis what the platform reports as available for the local store (0 = unknown).8 fields
state: DbSyncState
working_set_coverage_x1000: u32
pending_push_ops: u64
last_synced_ms: u64
local_bytes_used: u64
local_bytes_budget: u64
quota_bytes_available: u64
error: OptionString
struct DbConflict
has destructorA sync conflict handed to a store's
DbMergeCallback: the same key was modified locally and remotely since the last sync. Timestamps are milliseconds since the Unix epoch.struct DbMergeCallback
Function pointer + host context for a store's merge policy (
Db::set_on_conflict).2 fields
ctx: OptionRefAny
struct DbOpenResult
has destructorResult of
Db::open.1 field
result: ResultDbDbError
struct DbValueResult
has destructorResult of
Db::get: the value (Nonewhen absent) or an error message.2 fields
value: OptionDbValue
error: OptionString
struct DbRowsResult
has destructorResult of
Db::iterate/Db::query_index: the matching rows as a two-column grid (key,value) or an error message.2 fields
rows: DbRows
error: OptionString
struct DbSyncStatusResult
has destructorResult of
Db::sync_nowand everyDb::set_on_sync_statusdelivery.1 field
status: DbSyncStatus
mod audio
8 typesstruct AudioDeviceList
has destructor1 method
fn enumerate:
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
Enumerate the machine's audio devices (output sinks + input sources, by name) and resume
on_resultwith anAudioDeviceListResult. Linux: PipeWire / PulseAudio (pactl); empty where no enumeration backend exists. On web device labels stay blank until agetUserMediapermission has been granted. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched.struct AudioConfig
2 fields
sample_rate: u32
channels: u16
struct AudioSink
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor open:
arg config: AudioConfig
-> AudioSink
Open an audio output for
config(sample rate + channels). Returns an invalid handle (is_open()false) on failure. The stub engine always "opens"; the real rodio / AVAudio backend may fail (no device).4 methods
fn is_open:
&self
-> bool
fn play:
&self
arg frame: AudioFrame
fn frames_played:
&self
-> u64
fn close:
&mut self
Whether the sink opened successfully.
Queue
framefor playback. Interleavedf32samples in the frame's format are sent to the output. (Stub: counts the frame; the on-device backend plays the samples.)Number of frames submitted via [
play](Self::play) so far (0if not open). Mostly a stub progress signal until the real backend lands.Stop playback + release the output. (Dropping the handle does this too;
closeis for explicit/FFI control.)enum MediaPlaybackState
3 variants
Stopped
Playing
Paused
enum SystemAudioChange
6 variants
Granted
Interrupted
Ducked
Resumed
Ended
Lost
struct AudioDeviceListResult
has destructorResult of
AudioDeviceList::enumerate.1 field
devices: AudioDeviceList
struct AudioFrame
has destructor3 fields
1 method
fn frame_count:
&self
-> usize
Number of sample *frames* (samples per channel) in this chunk.
mod video
6 typesstruct VideoProvisionOutcome
has destructor3 fields
struct VideoStartupCheck
has destructor6 fields
1 constructor
constructor run:
Run all the readiness checks (call once at startup). Inspection only.
1 method
fn remediate:
Apply whatever [
run](Self::run) found - repair an unbootable kernel first (the urgent one), then install the GPU driver - via the consent + pkexec path. Side-effecting; call only after the user has seendetailand consented.struct VideoConfig
has destructor5 fields
struct VideoFrameVecSlice
has destructor2 fields
struct VideoFrame
has destructor3 fields
mod uuid
1 typestruct Uuid
Static-method namespace for UUID string generation (
Uuid::v4,Uuid::short).More
The intended mint for MARKER strings (
Dom::with_marker+CallbackInfo::get_node_id_by_marker): markers are created fresh at layout() time, and a UUID guarantees - with no coordination - that the string collides with nothing else in the process.1 field
_reserved: u8
1 constructor
2 methods
fn v4:
-> String
fn short:
-> String
A fresh random (version 4) UUID in canonical hyphenated lowercase form, e.g. "550e8400-e29b-41d4-a716-446655440000" (36 characters).
A fresh random (version 4) UUID as a 22-character flickrBase58 string - the short-uuid encoding of the same 128 bits
v4would print. The compact spelling for markers, log lines and URLs.
mod gamepad
8 typesenum GamepadButton
23 variants
South
East
North
West
LeftBumper
RightBumper
LeftTrigger
RightTrigger
Select
Start
Mode
LeftThumb
RightThumb
DPadUp
DPadDown
DPadLeft
DPadRight
Misc1
Paddle1
Paddle2
Paddle3
Paddle4
Touchpad
struct GamepadState
22 fields
id: GamepadId
buttons: u32
left_stick_x: f32
left_stick_y: f32
right_stick_x: f32
right_stick_y: f32
left_z: f32
right_z: f32
battery: f32
touchpad_x: f32
touchpad_y: f32
touchpad2_x: f32
touchpad2_y: f32
gyro_x: f32
gyro_y: f32
gyro_z: f32
accel_x: f32
accel_y: f32
accel_z: f32
connected: bool
touchpad_active: bool
touchpad2_active: bool
2 methods
fn is_pressed:
&self
arg button: GamepadButton
-> bool
fn axis:
&self
arg axis: GamepadAxis
-> f32
Whether
buttonis currently held.The current value of
axis(sticks[-1, 1], triggers[0, 1]).enum GamepadAxis
6 variants
LeftStickX
LeftStickY
RightStickX
RightStickY
LeftZ
RightZ
struct GamepadId
1 field
id: u32
struct HidDeviceVecSlice
has destructor2 fields
struct HidReportVecSlice
has destructor2 fields
mod file
10 typesstruct FileMetadata
5 fields
struct FilePath
has destructor1 field
inner: String
25 constructors
constructor from_str:
constructor get_temp_dir:
-> FilePath
constructor create:
constructor empty:
-> FilePath
constructor get_current_dir:
constructor get_home_dir:
constructor get_cache_dir:
constructor get_config_dir:
constructor get_config_local_dir:
constructor get_data_dir:
constructor get_data_local_dir:
constructor get_desktop_dir:
constructor get_document_dir:
constructor get_download_dir:
constructor get_executable_dir:
constructor get_font_dir:
constructor get_picture_dir:
constructor get_preference_dir:
constructor get_public_dir:
constructor get_runtime_dir:
constructor get_state_dir:
constructor get_audio_dir:
constructor get_video_dir:
constructor get_template_dir:
constructor from:
Creates a path from a string slice
Returns the system temporary directory
Creates a new path from a string
Creates an empty path
Returns the current working directory
Returns the user's home directory (e.g., /home/username on Linux, C:\Users\username on Windows)
Returns the user's cache directory (e.g., ~/.cache on Linux, ~/Library/Caches on macOS)
Returns the user's config directory (e.g., ~/.config on Linux, ~/Library/Application Support on macOS)
Returns the user's local config directory
Returns the user's data directory (e.g., ~/.local/share on Linux, ~/Library/Application Support on macOS)
Returns the user's local data directory
Returns the user's desktop directory (e.g., ~/Desktop)
Returns the user's documents directory (e.g., ~/Documents)
Returns the user's downloads directory (e.g., ~/Downloads)
Returns the user's executable directory (e.g., ~/.local/bin on Linux)
Returns the user's font directory (e.g., ~/.local/share/fonts on Linux, ~/Library/Fonts on macOS)
Returns the user's pictures directory (e.g., ~/Pictures)
Returns the user's preference directory (e.g., ~/.config on Linux, ~/Library/Preferences on macOS)
Returns the user's public directory (e.g., ~/Public)
Returns the user's runtime directory (e.g., /run/user/1000 on Linux)
Returns the user's state directory (e.g., ~/.local/state on Linux)
Returns the user's audio directory (e.g., ~/Music)
Returns the user's video directory (e.g., ~/Videos)
Returns the user's templates directory
24 methods
fn read_string:
&self
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn write_string:
&self
arg data: String
fn exists:
&self
-> bool
fn join:
fn join_str:
fn read_bytes:
&self
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn write_bytes:
&self
arg data: U8Vec
fn parent:
&self
fn file_name:
&self
-> OptionString
fn extension:
&self
-> OptionString
fn is_file:
&self
-> bool
fn is_dir:
&self
-> bool
fn is_absolute:
&self
-> bool
fn create_dir_all:
&self
fn create_dir:
&self
fn remove_file:
&self
fn remove_dir:
&self
fn remove_dir_all:
&self
fn copy_to:
&self
arg dest: FilePath
fn rename_to:
&self
arg dest: FilePath
fn as_string:
&self
-> String
fn read_dir:
&self
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
fn metadata:
&self
fn canonicalize:
&self
Read the entire file at this path as a string and resume
on_resultwith aFileReadStringResult. Same contract asread_bytes.Writes a string to the file at this path
Checks if the path exists on the filesystem
Joins this path with another path component
Joins this path with a string component
Read the entire file at this path as bytes and resume
on_resultwith aFileReadBytesResult(downcast withFileReadBytesResult::downcast(result)). Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched.Writes bytes to the file at this path
Returns the parent directory of this path
Returns the file name component of this path
Returns the file extension of this path
Checks if the path is a file
Checks if the path is a directory
Checks if the path is absolute
Creates this directory and all parent directories
Creates this directory (parent must exist)
Removes this file
Removes this directory (must be empty)
Removes this directory and all contents
Copies a file from this path to another path
Renames/moves a file from this path to another path
Returns the path as an AzString
List the directory at this path and resume
on_resultwith aFileDirListResult. Same contract asread_bytes.Returns metadata about the file/directory
Makes the path canonical (absolute, with no
.or..components)enum FileType
4 variants
File
Directory
Symlink
Other
struct DirEntryVecSlice
has destructor2 fields
struct FileReadBytesResult
has destructorResult of
FilePath::read_bytes.1 field
result: ResultU8VecFileError
struct FileReadStringResult
has destructorResult of
FilePath::read_string.1 field
result: ResultStringFileError
struct FileDirListResult
has destructorResult of
FilePath::read_dir.1 field
result: ResultDirEntryVecFileError
struct FilePathVecSlice
has destructor2 fields
mod url
1 typestruct Url
has destructor2 constructors
constructor parse:
arg s: String
constructor from_parts:
Parse a URL from a string
More
# Arguments *
s- The URL string to parse# Returns *
Result<Url, UrlParseError>- The parsed URL or an errorCreate a URL from components
5 methods
fn to_string:
&self
-> String
fn is_https:
&self
-> bool
fn is_http:
&self
-> bool
fn effective_port:
&self
-> u16
fn join:
&self
arg path: String
Get the full URL as a string
Check if this is an HTTPS URL
Check if this is an HTTP URL
Get the effective port (using default ports for http/https)
Join a relative path to this URL
mod screen
4 typesstruct ScreenRecorder
2 fields
ptr: c_void
run_destructor: bool
1 constructor
constructor start:
arg path: String
arg width: u32
arg height: u32
arg fps: u32
Start recording RGBA frames of
widthxheightatfpsto the MP4 atpath(software gstreamer x264). Returns an invalid handle (is_recording()false) if gstreamer (gst-launch-1.0) isn't installed. On webpathis reinterpreted as the suggested download name of the finished recording.4 methods
fn is_recording:
&self
-> bool
fn write_frame:
&self
arg frame: VideoFrame
-> bool
fn frames_written:
&self
-> u64
fn finish:
&mut self
arg data: RefAny
arg on_result: ResumeCallback
-> RequestId
Whether recording is active (the gstreamer subprocess started).
Feed one RGBA
VideoFrame(itswidthxheightmust matchstart). Returns false if not recording, the frame is too small, or the encoder exited.Frames written so far.
Finish the recording and resume
on_resultwith aScreenRecordingResult: closes the encoder's input so it finalizes the MP4, waits for it and releases the handle. Finalizing is asynchronous by nature (MediaRecorder'sdataavailableon web), which is why the answer is a resume. Never runs the callback re-entrantly inside the requesting activation: on desktop it runs right after the current activation returns (same frame), on web on a later task.datais handed back to the callback untouched.struct ScreenCaptureConfig
3 fields
union enum ScreenCaptureSource
3 variants
PrimaryDisplay
Display(u32)
Window(u64)
struct ScreenRecordingResult
has destructorResult of
ScreenRecorder::finish.okistruewhen the recording was finalized;errorsays why not otherwise.2 fields
ok: bool
error: OptionString
mod camera
2 typesenum CameraFacing
3 variants
Front
Back
External
struct CameraConfig
5 fields
mod sensor
5 typesstruct SensorReading
5 fields
enum SensorKind
11 variants
Accelerometer
Gyroscope
Magnetometer
RotationVector
Gravity
LinearAcceleration
AmbientLight
Proximity
Barometer
StepCounter
HingeAngle
union enum Proximity
3 variants
struct ProximityDistance
2 fields
value: f32
unit: DistanceUnit
enum DistanceUnit
3 variants
Millimeters
Centimeters
Meters
mod fmt
3 typesstruct FmtArgVecSlice
has destructor2 fields