pub struct WombatApp {
pub binary_file: Vec<u8>,
pub bytes_per_line: usize,
pub sidebar_as_window: bool,
}Expand description
We derive Deserialize/Serialize so we can persist app state on shutdown.
Fields§
§binary_file: Vec<u8>Binary file data
bytes_per_line: usizeBytes per line
Sidebar as window
Implementations§
Source§impl WombatApp
impl WombatApp
Sourcepub fn new_app_with_args(
cc: &CreationContext<'_>,
args: &[String],
) -> Result<Self, AppError>
pub fn new_app_with_args( cc: &CreationContext<'_>, args: &[String], ) -> Result<Self, AppError>
Sourcepub fn load_default_file() -> Vec<u8> ⓘ
pub fn load_default_file() -> Vec<u8> ⓘ
Load the default file (wombat icon)
Trait Implementations§
Source§impl BladvakApp<'_> for WombatApp
impl BladvakApp<'_> for WombatApp
Source§fn settings(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
fn settings(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
Setting panel ui
Source§fn is_side_panel(&self) -> bool
fn is_side_panel(&self) -> bool
should display a side_panel
should display a side_panel
Source§fn top_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
fn top_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
Top panel ui
hook on the file menu
Source§fn central_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
fn central_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
Central panel ui
Source§fn side_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
fn side_panel(&mut self, ui: &mut Ui, error_manager: &mut ErrorManager)
Side panel ui
Source§fn new_with_args(
cc: &CreationContext<'_>,
args: &[String],
) -> Result<Self, AppError>
fn new_with_args( cc: &CreationContext<'_>, args: &[String], ) -> Result<Self, AppError>
Builder func for native Read more
Source§impl<'de> Deserialize<'de> for WombatApp
impl<'de> Deserialize<'de> for WombatApp
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for WombatApp
impl RefUnwindSafe for WombatApp
impl Send for WombatApp
impl Sync for WombatApp
impl Unpin for WombatApp
impl UnwindSafe for WombatApp
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§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.