pub struct App {Show 44 fields
pub workspace: Workspace,
pub project: Project,
pub settings: Settings,
pub keymap: Keymap,
pub theme: Theme,
pub page: Page,
pub focus: Panel,
pub scroll: ScrollState,
pub project_files: Vec<PathBuf>,
pub explorer_selected: usize,
pub mode: Mode,
pub status: Status,
pub debugger: StateMachine,
pub registers: RegisterFile,
pub breakpoints: BreakpointSet,
pub memory: MemoryBlock,
pub memory_address: Option<u64>,
pub stack: MemoryBlock,
pub recording: bool,
pub at_exit: bool,
pub frames: Vec<Frame>,
pub frame_selected: usize,
pub disassembly: Vec<DisassemblyLine>,
pub current_address: Option<u64>,
pub current_line: Option<(PathBuf, usize)>,
pub build: Option<BuildOutcome>,
pub last_run: Option<ProcessOutput>,
pub output: Vec<String>,
pub terminal: Option<TerminalScreen>,
pub diagnostics: Vec<Diagnostic>,
pub register_format: Format,
pub disassembly_syntax: Syntax,
pub ide_page: Page,
pub scratchpad: Scratchpad,
pub scratchpad_result: Option<Result<Outcome, String>>,
pub learning: Progress,
pub clipboard: String,
pub instructions: Database,
pub syscalls: Database,
pub syscall_query: String,
pub syscall_selected: usize,
pub breakpoint_selected: usize,
pub search_query: String,
pub should_quit: bool,
/* private fields */
}Expand description
Everything the interface shows.
Fields§
§workspace: WorkspaceOpen documents.
project: ProjectThe project being worked on.
settings: SettingsUser settings.
keymap: KeymapKey bindings.
theme: ThemeColours and glyphs.
page: PageThe page on show.
focus: PanelWhich panel has focus. Always one of App::page’s panels.
scroll: ScrollStateHow far each panel is scrolled.
project_files: Vec<PathBuf>The project’s files, as the explorer last found them.
explorer_selected: usizeWhich row of the explorer’s file list is selected.
mode: ModeWhat the interface is doing.
status: StatusThe status bar message.
debugger: StateMachineThe debug session’s state.
registers: RegisterFileRegister values at the last stop.
breakpoints: BreakpointSetBreakpoints the user has asked for.
memory: MemoryBlockThe memory currently on show.
memory_address: Option<u64>The address the memory panel is looking at.
stack: MemoryBlockStack contents around the stack pointer.
recording: boolWhether execution is being recorded, so it can be stepped backwards.
at_exit: boolWhether recording halted the program just before it exits.
frames: Vec<Frame>The call stack at the last stop, innermost frame first.
frame_selected: usizeWhich frame the call stack panel highlights.
disassembly: Vec<DisassemblyLine>The disassembly on show.
current_address: Option<u64>Where execution is stopped.
current_line: Option<(PathBuf, usize)>The source line execution is stopped at.
build: Option<BuildOutcome>The last build’s result.
last_run: Option<ProcessOutput>The last program run’s result.
output: Vec<String>Lines shown in the output panel.
terminal: Option<TerminalScreen>A live VT screen while an interactive program owns the Output panel.
diagnostics: Vec<Diagnostic>Diagnostics from the last build.
register_format: FormatHow register values are shown.
disassembly_syntax: SyntaxWhich operand order the disassembly uses.
ide_page: PageWhether the learning panel is showing.
scratchpad: ScratchpadThe snippet being tried, and the values it starts from.
scratchpad_result: Option<Result<Outcome, String>>What the last snippet produced, or why it could not run.
learning: ProgressWhere the reader is in the material.
clipboard: StringText cut or copied, used by paste.
instructions: DatabaseInstruction semantics, loaded once.
syscalls: DatabaseThe syscall table, loaded once.
syscall_query: StringThe syscall panel’s query.
syscall_selected: usizeWhich syscall is highlighted.
breakpoint_selected: usizeWhich breakpoint is highlighted.
search_query: StringThe search query in effect.
should_quit: boolWhether the application should exit.
Implementations§
Source§impl App
impl App
Sourcepub fn new(project: Project, settings: Settings) -> Result<Self, Error>
pub fn new(project: Project, settings: Settings) -> Result<Self, Error>
Creates the application for a project.
Sourcepub fn focus_panel(&mut self, panel: Panel)
pub fn focus_panel(&mut self, panel: Panel)
Focuses a panel, opening a page that shows it if necessary.
Sourcepub fn apply(&mut self, command: &Command) -> Effect
pub fn apply(&mut self, command: &Command) -> Effect
Applies a command, returning any I/O the run loop must perform.
Sourcepub fn cancel_overlay(&mut self)
pub fn cancel_overlay(&mut self)
Cancels whatever overlay is open.
Sourcepub fn accept_prompt(&mut self) -> Effect
pub fn accept_prompt(&mut self) -> Effect
Accepts the current prompt’s answer.
Sourcepub fn refresh_picker(&mut self)
pub fn refresh_picker(&mut self)
Recomputes the open picker’s matches for its query.
Sourcepub fn accept_picker(&mut self) -> Effect
pub fn accept_picker(&mut self) -> Effect
Jumps to the picker’s highlighted match.
Sourcepub fn close_active_document(&mut self)
pub fn close_active_document(&mut self)
Closes the active document after callers have handled unsaved changes.
Sourcepub fn accept_palette(&mut self) -> Effect
pub fn accept_palette(&mut self) -> Effect
Runs the highlighted palette command.
Sourcepub fn finish_build(&mut self, outcome: BuildOutcome)
pub fn finish_build(&mut self, outcome: BuildOutcome)
Records a finished build.
Sourcepub fn fail_build(&mut self, message: impl Into<String>)
pub fn fail_build(&mut self, message: impl Into<String>)
Records that a build could not be attempted.
Sourcepub fn finish_run(&mut self, output: ProcessOutput)
pub fn finish_run(&mut self, output: ProcessOutput)
Records a finished program run.
Sourcepub fn finish_terminal(&mut self)
pub fn finish_terminal(&mut self)
Freezes a live terminal into the ordinary scrollable Output log.
Sourcepub fn refresh_project_files(&mut self)
pub fn refresh_project_files(&mut self)
Re-reads the project’s files for the explorer.
Sourcepub fn move_explorer_selection(&mut self, rows: isize)
pub fn move_explorer_selection(&mut self, rows: isize)
Moves the explorer’s selection by rows, keeping it in the list.
Sourcepub fn open_selected_file(&mut self) -> Effect
pub fn open_selected_file(&mut self) -> Effect
Opens the file the explorer has selected.
Sourcepub fn show_file(&mut self, path: &Path) -> bool
pub fn show_file(&mut self, path: &Path) -> bool
Makes path the active document, opening it if necessary.
Sourcepub fn toggle_breakpoint_in(&mut self, path: &Path, line: usize) -> Effect
pub fn toggle_breakpoint_in(&mut self, path: &Path, line: usize) -> Effect
Adds or removes a breakpoint on one-based line of path.
Sourcepub fn diagnostic_at(&self, path: &Path, line: usize) -> Option<&Diagnostic>
pub fn diagnostic_at(&self, path: &Path, line: usize) -> Option<&Diagnostic>
The first build message on one-based line of path.
Sourcepub fn pending_breakpoints(&self) -> Vec<Location>
pub fn pending_breakpoints(&self) -> Vec<Location>
The breakpoint locations that still need sending to the debugger.
Sourcepub fn matching_syscalls(&self) -> Vec<&Syscall>
pub fn matching_syscalls(&self) -> Vec<&Syscall>
The syscalls matching the current query.
Sourcepub fn current_explanation(&self) -> Option<Explanation>
pub fn current_explanation(&self) -> Option<Explanation>
The explanation for the instruction currently in view.
Sourcepub fn show_execution(&mut self)
pub fn show_execution(&mut self)
The open document for a path GDB reported.
Sourcepub fn follow_execution(&mut self) -> bool
pub fn follow_execution(&mut self) -> bool
Moves the editor to the file and line execution stopped on.
Sourcepub fn resolve_reported_path(&self, reported: &Path) -> PathBuf
pub fn resolve_reported_path(&self, reported: &Path) -> PathBuf
Turns a path a tool reported into one that can be opened.
Sourcepub fn index_of_document(&self, path: &Path) -> Option<usize>
pub fn index_of_document(&self, path: &Path) -> Option<usize>
The index of the open document for a path a tool reported.
Auto Trait Implementations§
impl Freeze for App
impl RefUnwindSafe for App
impl Send for App
impl Sync for App
impl Unpin for App
impl UnsafeUnpin for App
impl UnwindSafe for App
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
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> ⓘ
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> ⓘ
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 more