Struct sciter::dom::Element [] [src]

pub struct Element { /* fields omitted */ }

DOM element wrapper. See the module-level documentation also.

Methods

impl Element
[src]

[src]

Construct Element object from HELEMENT handle.

[src]

Create new element, it is disconnected initially from the DOM.

[src]

Create new element as child of parent.

[src]

Deprecated since 0.5.0

: please use Element::with_parent() instead.

Create new element as child of parent. Deprecated.

[src]

Create new element with specified text, it is disconnected initially from the DOM.

[src]

Create new element with specified type, which is useful for controls and widgets (initially disconnected).

[src]

Get root DOM element of the Sciter document.

[src]

Get focus DOM element of the Sciter document.

[src]

Get highlighted element.

[src]

Find DOM element of the Sciter document by coordinates.

[src]

Get element handle by its UID.

[src]

Access element pointer.

[src]

Get element UID - identifier suitable for storage.

[src]

Return element tag as string (e.g. 'div', 'body').

[src]

Get inner text of the element as string.

[src]

Set inner text of the element.

[src]

Get html representation of the element as utf-8 bytes.

[src]

Set inner or outer html of the element.

[src]

Get value of the element.

[src]

Set value of the element.

[src]

Get HWINDOW of containing window.

[src]

Get bounding rectangle of the element. See the ELEMENT_AREAS enum for kind flags.

[src]

Sends sinking/bubbling event to the child/parent chain of element.

[src]

Post asynchronously a sinking/bubbling event to the child/parent chain of element.

[src]

Send or posts event to the child/parent chain of element.

[src]

Send or posts event with specified params to the child/parent chain of element.

[src]

Evaluate the given script in context of the element.

[src]

Call scripting function defined in the namespace of the element (a.k.a. global function).

You can use the make_args!(args...) macro which helps you to construct script arguments from Rust types.

[src]

Call scripting method defined for the element.

You can use the make_args!(args...) macro which helps you to construct script arguments from Rust types.

[src]

Get number of the attributes.

[src]

Get attribute name by its index.

[src]

Get attribute value by its index.

[src]

Get attribute value by its name.

[src]

Add or replace attribute.

[src]

Remove attribute.

[src]

Toggle attribute.

[src]

Remove all attributes from the element.

[src]

Get style attribute of the element by its name.

[src]

[src]

Get index of this element in its parent collection.

[src]

Get root of the element.

[src]

Get parent element.

[src]

Get first sibling element.

[src]

Get last sibling element.

[src]

Get next sibling element.

[src]

Get previous sibling element.

[src]

Get first child element.

[src]

Get last child element.

[src]

Get element's child at specified index.

Important traits for Children<'a>
[src]

An iterator over the direct children of a DOM element.

[src]

Get element's child at specified index.

[src]

Get number of child elements.

[src]

Get number of child elements.

[src]

Returns true is self has zero elements.

[src]

Clear content of the element.

[src]

Create new element as copy of existing element.

The new element is a full (deep) copy of the element and is initially disconnected from the DOM. Note that Element.clone() does not clone DOM element, just increments its reference count.

[src]

Insert element at index position of this element.

Note that we cannot follow Rust semantic here because the newly created Element is unusable before it will be inserted at DOM.

[src]

Append element as last child of this element.

[src]

Append element as last child of this element.

[src]

Remove the last child from this element and returns it, or None if this element is empty.

[src]

Take element out of its container (and DOM tree).

[src]

Take element out of its container (and DOM tree) and force destruction of all behaviors.

[src]

Swap element positions.

[src]

Test this element against CSS selector(s).

[src]

Will find first parent element starting from this satisfying given css selector(s).

[src]

Will find first element starting from this satisfying given css selector(s).

[src]

Will find all elements starting from this satisfying given css selector(s).

[src]

Apply changes and refresh element area in its window.

[src]

Start Timer for the element. Element will receive on_timer event.

Note that timer events are not bubbling, so you need attach handler to the target element directly.

[src]

Stop Timer for the element.

[src]

Attach the native event handler to this element.

[src]

Detach your handler from the element. Handlers identified by token from attach_handler() result.

Trait Implementations

impl PartialEq for Element
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

[src]

This method tests for !=.

impl Send for Element
[src]

sciter::Element can be transferred across thread boundaries.

impl Sync for Element
[src]

It is safe to share sciter::Element between threads - underlaying API is thread-safe.

impl Drop for Element
[src]

Release element pointer.

[src]

Executes the destructor for this type. Read more

impl Clone for Element
[src]

Increment reference count of the dom element.

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Display for Element
[src]

Human element representation.

[src]

Formats the value using the given formatter. Read more

impl Debug for Element
[src]

Machine-like element visualization.

[src]

Formats the value using the given formatter. Read more

impl<'a> IntoIterator for &'a Element
[src]

Allows for child in &el {} enumeration.

The type of the elements being iterated over.

Which kind of iterator are we turning this into?

Important traits for Children<'a>
[src]

Creates an iterator from a value. Read more