pub struct Preview {
pub url: Option<String>,
pub alias: Option<String>,
}Expand description
A preview of an image — the one way the IDE draws any image reference:
its PNG data URL (size px, nearest-neighbour; None if it can’t be
drawn) and, for a raw resource path (minecraft:textures/item/apple.png),
the alias to write instead (item:apple) — which is also what’s drawn.
Fields§
§url: Option<String>§alias: Option<String>Trait Implementations§
Auto Trait Implementations§
impl Freeze for Preview
impl RefUnwindSafe for Preview
impl Send for Preview
impl Sync for Preview
impl Unpin for Preview
impl UnsafeUnpin for Preview
impl UnwindSafe for Preview
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more