Struct oxygengine_composite_renderer::component::CompositeUiElement [−][src]
pub struct CompositeUiElement {Show fields
pub id: Option<Cow<'static, str>>,
pub theme: Option<Cow<'static, str>>,
pub camera_name: Cow<'static, str>,
pub interactive: Option<Cow<'static, str>>,
pub element_type: UiElementType,
pub margin: UiMargin,
pub padding: UiMargin,
pub left_anchor: UiValue,
pub right_anchor: UiValue,
pub top_anchor: UiValue,
pub bottom_anchor: UiValue,
pub alignment: UiValueVec2,
pub offset: UiValueVec2,
pub fixed_width: Option<UiValue>,
pub fixed_height: Option<UiValue>,
pub scale: Vec2,
pub alpha: UiValue,
pub hidden: bool,
pub children: Vec<CompositeUiElement>,
pub state: HashMap<Cow<'static, str>, Scalar>,
// some fields omitted
}Fields
id: Option<Cow<'static, str>>theme: Option<Cow<'static, str>>camera_name: Cow<'static, str>interactive: Option<Cow<'static, str>>element_type: UiElementTypemargin: UiMarginpadding: UiMarginleft_anchor: UiValueright_anchor: UiValuetop_anchor: UiValuebottom_anchor: UiValuealignment: UiValueVec2offset: UiValueVec2fixed_width: Option<UiValue>fixed_height: Option<UiValue>scale: Vec2alpha: UiValuechildren: Vec<CompositeUiElement>state: HashMap<Cow<'static, str>, Scalar>Implementations
impl CompositeUiElement[src]
impl CompositeUiElement[src]pub fn rebuild(&mut self)[src]
pub fn find(&self, id: &str) -> Option<&CompositeUiElement>[src]
pub fn find_mut(&mut self, id: &str) -> Option<&mut CompositeUiElement>[src]
pub fn calculate_rect(
&self,
parent_rect: Rect,
themes: &CompositeUiThemes,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Rect[src]
&self,
parent_rect: Rect,
themes: &CompositeUiThemes,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Rect
pub fn calculate_value(
&self,
state: &UiValue,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Scalar[src]
&self,
state: &UiValue,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Scalar
pub fn calculate_value_vec2(
&self,
state: &UiValueVec2,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Vec2[src]
&self,
state: &UiValueVec2,
states: &[&HashMap<Cow<'static, str>, Scalar>]
) -> Vec2
pub fn build_rects_tree<'a>(
&'a self,
parent_rect: Rect,
themes: &CompositeUiThemes,
states: &mut Vec<&'a HashMap<Cow<'static, str>, Scalar>>
) -> Option<UiRectsTree>[src]
&'a self,
parent_rect: Rect,
themes: &CompositeUiThemes,
states: &mut Vec<&'a HashMap<Cow<'static, str>, Scalar>>
) -> Option<UiRectsTree>
pub fn build_commands<'a>(
&'a self,
parent_rect: Rect,
interactibles: &mut CompositeUiInteractibles,
themes: &CompositeUiThemes,
states: &mut Vec<&'a HashMap<Cow<'static, str>, Scalar>>
) -> (Vec<Command<'static>>, Rect)[src]
&'a self,
parent_rect: Rect,
interactibles: &mut CompositeUiInteractibles,
themes: &CompositeUiThemes,
states: &mut Vec<&'a HashMap<Cow<'static, str>, Scalar>>
) -> (Vec<Command<'static>>, Rect)
Trait Implementations
impl Clone for CompositeUiElement[src]
impl Clone for CompositeUiElement[src]fn clone(&self) -> CompositeUiElement[src]
pub fn clone_from(&mut self, source: &Self)1.0.0[src]
impl Component for CompositeUiElement[src]
impl Component for CompositeUiElement[src]type Storage = VecStorage<Self>
Associated storage type for this component.
impl Default for CompositeUiElement[src]
impl Default for CompositeUiElement[src]impl<'de> Deserialize<'de> for CompositeUiElement[src]
impl<'de> Deserialize<'de> for CompositeUiElement[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>, [src]
__D: Deserializer<'de>,
impl Prefab for CompositeUiElement[src]
impl Prefab for CompositeUiElement[src]fn post_from_prefab(&mut self)[src]
pub fn from_prefab(data: Value) -> Result<Self, PrefabError>[src]
pub fn from_prefab_with_extras(
data: Value,
_named_entities: &HashMap<String, Entity, RandomState>,
_state_token: ID<()>
) -> Result<Self, PrefabError>[src]
data: Value,
_named_entities: &HashMap<String, Entity, RandomState>,
_state_token: ID<()>
) -> Result<Self, PrefabError>
pub fn to_prefab(&self) -> Result<Value, PrefabError>[src]
pub fn from_prefab_str(data: &str) -> Result<Self, PrefabError>[src]
pub fn to_prefab_string(&self) -> Result<String, PrefabError>[src]
impl PrefabComponent for CompositeUiElement[src]
impl PrefabComponent for CompositeUiElement[src]impl Serialize for CompositeUiElement[src]
impl Serialize for CompositeUiElement[src]Auto Trait Implementations
impl RefUnwindSafe for CompositeUiElement
impl RefUnwindSafe for CompositeUiElementimpl Send for CompositeUiElement
impl Send for CompositeUiElementimpl Sync for CompositeUiElement
impl Sync for CompositeUiElementimpl Unpin for CompositeUiElement
impl Unpin for CompositeUiElementimpl UnwindSafe for CompositeUiElement
impl UnwindSafe for CompositeUiElementBlanket Implementations
impl<T> Any for T where
T: Any,
impl<T> Any for T where
T: Any, pub fn get_type_id(&self) -> TypeId
impl<'a, C> ComponentContainerModify<'a, ComponentContainer<'a, C>> for C where
C: Component, [src]
impl<'a, C> ComponentContainerModify<'a, ComponentContainer<'a, C>> for C where
C: Component, [src]pub fn fetch(world: &'a World, entity: Entity) -> ComponentContainer<'a, C>[src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>, [src]
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>, [src]impl<T> TryDefault for T where
T: Default,
impl<T> TryDefault for T where
T: Default,