[−][src]Trait stdweb::web::IHtmlElement
The IHtmlElement
interface represents any HTML element.
Provided methods
fn focus(&self)
Sets focus on the specified element, if it can be focused.
fn blur(&self)
Removes keyboard focus from the current element.
fn dataset(&self) -> StringMap
Allows access, both in reading and writing, to all of the custom data attributes (data-*) set on the element, either in HTML or in the DOM.
fn get_bounding_client_rect(&self) -> Rect
Returns the size of an element and its position relative to the viewport. (JavaScript docs)
fn offset_width(&self) -> i32
Returns the layout width of an element. Typically, an element's offsetWidth is a measurement which includes the element borders, the element horizontal padding, the element vertical scrollbar (if present, if rendered) and the element CSS width.
fn offset_height(&self) -> i32
Returns the height of the element including vertical padding and borders, as an integer.
fn inner_text(&self) -> String
A property which represents the "rendered" text content of a node and its descendants. It approximates the text the user would get if they highlighted the contents of the element with the cursor and then copied to the clipboard.
This feature was originally introduced by Internet Explorer, and was formally specified in the HTML standard in 2016 after being adopted by all major browser vendors.