[−][src]Struct amethyst_ui::UiLoader
Specialised UI loader
The recommended way of using this in State
s is with world.exec
.
Type parameters:
I
:Format
used for loadingTexture
sF
:Format
used for loadingFontAsset
W
: Type used for Widget IDs
Example:
ⓘThis example is not tested
let ui_handle = world.exec(|loader: UiLoader<TextureFormat, FontFormat>| { loader.load("renderable.ron", ()) });
Methods
impl<'a, C, W> UiLoader<'a, C, W> where
C: ToNativeWidget<W> + for<'de> Deserialize<'de> + Send + Sync + 'static,
W: WidgetId + DeserializeOwned,
[src]
C: ToNativeWidget<W> + for<'de> Deserialize<'de> + Send + Sync + 'static,
W: WidgetId + DeserializeOwned,
pub fn load<N, P>(
&self,
name: N,
progress: P
) -> Handle<UiPrefab<C::PrefabData, W>> where
N: Into<String>,
P: Progress,
[src]
&self,
name: N,
progress: P
) -> Handle<UiPrefab<C::PrefabData, W>> where
N: Into<String>,
P: Progress,
Load ui from disc
Trait Implementations
impl<'a, C, W> SystemData<'a> for UiLoader<'a, C, W> where
C: ToNativeWidget<W>,
W: WidgetId,
ReadExpect<'a, Loader>: SystemData<'a>,
Read<'a, AssetStorage<UiPrefab<C::PrefabData, W>>>: SystemData<'a>,
[src]
C: ToNativeWidget<W>,
W: WidgetId,
ReadExpect<'a, Loader>: SystemData<'a>,
Read<'a, AssetStorage<UiPrefab<C::PrefabData, W>>>: SystemData<'a>,
Auto Trait Implementations
impl<'a, C, W> Unpin for UiLoader<'a, C, W>
impl<'a, C, W> Sync for UiLoader<'a, C, W> where
<C as ToNativeWidget<W>>::PrefabData: Send + Sync,
<C as ToNativeWidget<W>>::PrefabData: Send + Sync,
impl<'a, C, W> Send for UiLoader<'a, C, W> where
<C as ToNativeWidget<W>>::PrefabData: Send + Sync,
<C as ToNativeWidget<W>>::PrefabData: Send + Sync,
impl<'a, C = NoCustomUi, W = u32> !UnwindSafe for UiLoader<'a, C, W>
impl<'a, C = NoCustomUi, W = u32> !RefUnwindSafe for UiLoader<'a, C, W>
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Same<T> for T
[src]
type Output = T
Should always be Self
impl<SS, SP> SupersetOf<SS> for SP where
SS: SubsetOf<SP>,
[src]
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
[src]
fn is_in_subset(&self) -> bool
[src]
unsafe fn to_subset_unchecked(&self) -> SS
[src]
fn from_subset(element: &SS) -> SP
[src]
impl<'a, T> DynamicSystemData<'a> for T where
T: SystemData<'a>,
[src]
T: SystemData<'a>,
type Accessor = StaticAccessor<T>
The accessor of the SystemData
, which specifies the read and write dependencies and does the fetching. Read more
fn setup(&StaticAccessor<T>, world: &mut World)
[src]
fn fetch(&StaticAccessor<T>, world: &'a World) -> T
[src]
impl<T> Resource for T where
T: Any + Send + Sync,
[src]
T: Any + Send + Sync,
impl<T> Any for T where
T: Any,
[src]
T: Any,
fn get_type_id(&self) -> TypeId
[src]
impl<T> Event for T where
T: Send + Sync + 'static,
[src]
T: Send + Sync + 'static,
impl<T> Erased for T
[src]
impl<T> SetParameter for T
[src]
fn set<T>(&mut self, value: T) -> <T as Parameter<Self>>::Result where
T: Parameter<Self>,
[src]
T: Parameter<Self>,
Sets value
as a parameter of self
.
impl<T> Supports<T> for T
[src]
impl<S, D, Swp, Dwp, T> AdaptInto<D, Swp, Dwp, T> for S where
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
[src]
D: AdaptFrom<S, Swp, Dwp, T>,
Dwp: WhitePoint,
Swp: WhitePoint,
T: Component + Float,
fn adapt_into_using<M>(self, method: M) -> D where
M: TransformMatrix<Swp, Dwp, T>,
[src]
M: TransformMatrix<Swp, Dwp, T>,
fn adapt_into(self) -> D
[src]
Convert the source color to the destination color using the bradford method by default Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
[src]
V: MultiLane<T>,