pub struct Editor { /* private fields */ }Trait Implementations§
Source§impl EldironEditor for Editor
impl EldironEditor for Editor
fn update_server_state_icons(&mut self, ui: &mut TheUI)
Source§impl TheTrait for Editor
impl TheTrait for Editor
Source§fn set_cmd_line_args(&mut self, args: Vec<String>, ctx: &mut TheContext)
fn set_cmd_line_args(&mut self, args: Vec<String>, ctx: &mut TheContext)
Set the command line arguments
Source§fn update_ui(&mut self, ui: &mut TheUI, ctx: &mut TheContext) -> bool
fn update_ui(&mut self, ui: &mut TheUI, ctx: &mut TheContext) -> bool
Handle UI events and UI state
Source§fn has_changes(&self) -> bool
fn has_changes(&self) -> bool
Returns true if there are changes
fn new() -> Selfwhere
Self: Sized,
fn init(&mut self, _ctx: &mut TheContext)
fn window_title(&self) -> String
fn target_fps(&self) -> f64
fn fonts_to_load(&self) -> Vec<TheFontScript>
fn default_window_size(&self) -> (usize, usize)
Source§fn min_window_size(&self) -> (usize, usize)
fn min_window_size(&self) -> (usize, usize)
Minimum resizable window size.
Defaults to
default_window_size() but can be overridden independently.fn default_window_position(&self) -> Option<(i32, i32)>
fn window_icon(&self) -> Option<(Vec<u8>, u32, u32)>
fn init_ui(&mut self, ui: &mut TheUI, ctx: &mut TheContext)
fn window_moved(&mut self, x: i32, y: i32)
fn window_resized(&mut self, width: usize, height: usize)
fn set_cmd_line_args_early(&mut self, args: Vec<String>)
fn draw(&mut self, pixels: &mut [u8], ctx: &mut TheContext)
fn update(&mut self, ctx: &mut TheContext) -> bool
fn touch_down(&mut self, x: f32, y: f32, ctx: &mut TheContext) -> bool
fn touch_dragged(&mut self, x: f32, y: f32, ctx: &mut TheContext) -> bool
fn touch_up(&mut self, x: f32, y: f32, ctx: &mut TheContext) -> bool
fn hover(&mut self, _x: f32, _y: f32, ctx: &mut TheContext) -> bool
fn key_down( &mut self, char: Option<char>, key: Option<TheKeyCode>, ctx: &mut TheContext, ) -> bool
fn key_up( &mut self, char: Option<char>, key: Option<TheKeyCode>, ctx: &mut TheContext, ) -> bool
fn mouse_wheel(&mut self, delta: (isize, isize), ctx: &mut TheContext) -> bool
fn modifier_changed( &mut self, shift: bool, ctrl: bool, alt: bool, logo: bool, ) -> bool
fn dropped_file(&mut self, _path: String) -> bool
fn closing(&self) -> bool
fn post_ui(&mut self, ctx: &mut TheContext)
fn pre_ui(&mut self, ctx: &mut TheContext)
fn cut(&mut self) -> String
fn copy(&mut self) -> String
fn paste(&mut self, text: String)
fn undo(&mut self)
fn redo(&mut self)
Auto Trait Implementations§
impl Freeze for Editor
impl RefUnwindSafe for Editor
impl Send for Editor
impl !Sync for Editor
impl Unpin for Editor
impl UnsafeUnpin for Editor
impl UnwindSafe for Editor
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
Source§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
Source§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Convert
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.Source§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Convert
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.Source§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
Convert
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.Source§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
Convert
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.Source§impl<S> FromSample<S> for S
impl<S> FromSample<S> for S
fn from_sample_(s: S) -> S
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.