Struct conrod::UpdateArgs [] [src]

pub struct UpdateArgs<'a, W, C: 'a> where W: Widget {
    pub idx: Index,
    pub prev_state: &'a State<W::State>,
    pub xy: Point,
    pub dim: Dimensions,
    pub style: &'a W::Style,
    pub ui: UiCell<'a, C>,
}

Arguments for the Widget::update method in a struct to simplify the method signature.

Fields

idx: Index

W's unique index.

prev_state: &'a State<W::State>

The Widget's state that was last returned by the update method.

xy: Point

The absolute (centered origin) screen position of the widget.

dim: Dimensions

The dimensions of the Widget.

style: &'a W::Style

The Widget's current Style.

ui: UiCell<'a, C>

Restricted access to the Ui. Provides methods for immutably accessing the Ui's Theme and GlyphCache. Also allows calling Widget::set within the Widget::update method.