diff --git a/src/canvas.rs b/src/canvas.rs index c5bedc6fb..44a74cea7 100644 --- a/src/canvas.rs +++ b/src/canvas.rs @@ -295,7 +295,7 @@ impl Painter { }) .split(vertical_dialog_chunk[1]); - self.draw_help_dialog::(f, app_state, middle_dialog_chunk[1]); + self.draw_help_dialog(f, app_state, middle_dialog_chunk[1]); } else if app_state.delete_dialog_state.is_showing_dd { let dd_text = self.get_dd_spans(app_state); @@ -335,7 +335,7 @@ impl Painter { // This is a bit nasty, but it works well... I guess. app_state.delete_dialog_state.is_showing_dd = - self.draw_dd_dialog::(f, dd_text, app_state, middle_dialog_chunk[1]); + self.draw_dd_dialog(f, dd_text, app_state, middle_dialog_chunk[1]); } else if app_state.is_expanded { if let Some(frozen_draw_loc) = frozen_draw_loc { self.draw_frozen_indicator(f, frozen_draw_loc); @@ -346,37 +346,32 @@ impl Painter { .constraints([Constraint::Percentage(100)]) .split(terminal_size); match &app_state.current_widget.widget_type { - Cpu => self.draw_cpu::( - f, - app_state, - rect[0], - app_state.current_widget.widget_id, - ), - CpuLegend => self.draw_cpu::( + Cpu => self.draw_cpu(f, app_state, rect[0], app_state.current_widget.widget_id), + CpuLegend => self.draw_cpu( f, app_state, rect[0], app_state.current_widget.widget_id - 1, ), - Mem | BasicMem => self.draw_memory_graph::( + Mem | BasicMem => self.draw_memory_graph( f, app_state, rect[0], app_state.current_widget.widget_id, ), - Disk => self.draw_disk_table::( + Disk => self.draw_disk_table( f, app_state, rect[0], app_state.current_widget.widget_id, ), - Temp => self.draw_temp_table::( + Temp => self.draw_temp_table( f, app_state, rect[0], app_state.current_widget.widget_id, ), - Net => self.draw_network_graph::( + Net => self.draw_network_graph( f, app_state, rect[0], @@ -391,9 +386,9 @@ impl Painter { _ => 0, }; - self.draw_process_widget::(f, app_state, rect[0], true, widget_id); + self.draw_process_widget(f, app_state, rect[0], true, widget_id); } - Battery => self.draw_battery_display::( + Battery => self.draw_battery_display( f, app_state, rect[0], @@ -471,13 +466,13 @@ impl Painter { .split(vertical_chunks[1]); if vertical_chunks[0].width >= 2 { - self.draw_basic_cpu::(f, app_state, vertical_chunks[0], 1); + self.draw_basic_cpu(f, app_state, vertical_chunks[0], 1); } if middle_chunks[0].width >= 2 { - self.draw_basic_memory::(f, app_state, middle_chunks[0], 2); + self.draw_basic_memory(f, app_state, middle_chunks[0], 2); } if middle_chunks[1].width >= 2 { - self.draw_basic_network::(f, app_state, middle_chunks[1], 3); + self.draw_basic_network(f, app_state, middle_chunks[1], 3); } let mut later_widget_id: Option = None; @@ -486,12 +481,9 @@ impl Painter { later_widget_id = Some(widget_id); if vertical_chunks[3].width >= 2 { match basic_table_widget_state.currently_displayed_widget_type { - Disk => self.draw_disk_table::( - f, - app_state, - vertical_chunks[3], - widget_id, - ), + Disk => { + self.draw_disk_table(f, app_state, vertical_chunks[3], widget_id) + } Proc | ProcSort => { let wid = widget_id - match basic_table_widget_state.currently_displayed_widget_type @@ -500,7 +492,7 @@ impl Painter { ProcSort => 2, _ => 0, }; - self.draw_process_widget::( + self.draw_process_widget( f, app_state, vertical_chunks[3], @@ -508,13 +500,10 @@ impl Painter { wid, ); } - Temp => self.draw_temp_table::( - f, - app_state, - vertical_chunks[3], - widget_id, - ), - Battery => self.draw_battery_display::( + Temp => { + self.draw_temp_table(f, app_state, vertical_chunks[3], widget_id) + } + Battery => self.draw_battery_display( f, app_state, vertical_chunks[3], @@ -527,7 +516,7 @@ impl Painter { } if let Some(widget_id) = later_widget_id { - self.draw_basic_table_arrows::(f, app_state, vertical_chunks[2], widget_id); + self.draw_basic_table_arrows(f, app_state, vertical_chunks[2], widget_id); } } else { // Draws using the passed in (or default) layout. @@ -731,7 +720,7 @@ impl Painter { ); // Side effect, draw here. - self.draw_widgets_with_constraints::( + self.draw_widgets_with_constraints( f, app_state, widgets, @@ -754,7 +743,7 @@ impl Painter { .flat_map(|col| &col.children) .zip(self.derived_widget_draw_locs.iter().flatten().flatten()) .for_each(|(widgets, widget_draw_locs)| { - self.draw_widgets_with_constraints::( + self.draw_widgets_with_constraints( f, app_state, widgets, @@ -778,7 +767,7 @@ impl Painter { Ok(()) } - fn draw_widgets_with_constraints( + fn draw_widgets_with_constraints( &self, f: &mut Frame<'_>, app_state: &mut App, widgets: &BottomColRow, widget_draw_locs: &[Rect], ) { @@ -787,28 +776,19 @@ impl Painter { if widget_draw_loc.width >= 2 && widget_draw_loc.height >= 2 { match &widget.widget_type { Empty => {} - Cpu => self.draw_cpu::(f, app_state, *widget_draw_loc, widget.widget_id), - Mem => self.draw_memory_graph::( - f, - app_state, - *widget_draw_loc, - widget.widget_id, - ), - Net => self.draw_network::(f, app_state, *widget_draw_loc, widget.widget_id), - Temp => { - self.draw_temp_table::(f, app_state, *widget_draw_loc, widget.widget_id) - } - Disk => { - self.draw_disk_table::(f, app_state, *widget_draw_loc, widget.widget_id) - } - Proc => self.draw_process_widget::( + Cpu => self.draw_cpu(f, app_state, *widget_draw_loc, widget.widget_id), + Mem => self.draw_memory_graph(f, app_state, *widget_draw_loc, widget.widget_id), + Net => self.draw_network(f, app_state, *widget_draw_loc, widget.widget_id), + Temp => self.draw_temp_table(f, app_state, *widget_draw_loc, widget.widget_id), + Disk => self.draw_disk_table(f, app_state, *widget_draw_loc, widget.widget_id), + Proc => self.draw_process_widget( f, app_state, *widget_draw_loc, true, widget.widget_id, ), - Battery => self.draw_battery_display::( + Battery => self.draw_battery_display( f, app_state, *widget_draw_loc, diff --git a/src/canvas/dialogs/dd_dialog.rs b/src/canvas/dialogs/dd_dialog.rs index 73a10a598..876552bf4 100644 --- a/src/canvas/dialogs/dd_dialog.rs +++ b/src/canvas/dialogs/dd_dialog.rs @@ -2,7 +2,6 @@ use std::cmp::min; use tui::{ - backend::Backend, layout::{Alignment, Constraint, Direction, Layout, Rect}, terminal::Frame, text::{Line, Span, Text}, @@ -351,7 +350,7 @@ impl Painter { } } - pub fn draw_dd_dialog( + pub fn draw_dd_dialog( &self, f: &mut Frame<'_>, dd_text: Option>, app_state: &mut App, draw_loc: Rect, ) -> bool { if let Some(dd_text) = dd_text { diff --git a/src/canvas/dialogs/help_dialog.rs b/src/canvas/dialogs/help_dialog.rs index a35713570..39bf25752 100644 --- a/src/canvas/dialogs/help_dialog.rs +++ b/src/canvas/dialogs/help_dialog.rs @@ -1,7 +1,6 @@ use std::cmp::{max, min}; use tui::{ - backend::Backend, layout::{Alignment, Rect}, terminal::Frame, text::Line, @@ -16,9 +15,7 @@ const HELP_BASE: &str = " Help ── Esc to close "; // TODO: [REFACTOR] Make generic dialog boxes to build off of instead? impl Painter { - pub fn draw_help_dialog( - &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, - ) { + pub fn draw_help_dialog(&self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect) { let help_title = Line::from(vec![ Span::styled(" Help ", self.colours.widget_title_style), Span::styled( diff --git a/src/canvas/widgets/basic_table_arrows.rs b/src/canvas/widgets/basic_table_arrows.rs index 1b93650d5..352c7f1ec 100644 --- a/src/canvas/widgets/basic_table_arrows.rs +++ b/src/canvas/widgets/basic_table_arrows.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Alignment, Constraint, Direction, Layout, Rect}, terminal::Frame, text::Line, @@ -13,7 +12,7 @@ use crate::{ }; impl Painter { - pub fn draw_basic_table_arrows( + pub fn draw_basic_table_arrows( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { if let Some(current_table) = app_state.widget_map.get(&widget_id) { diff --git a/src/canvas/widgets/battery_display.rs b/src/canvas/widgets/battery_display.rs index e616e186c..4cd5c23b8 100644 --- a/src/canvas/widgets/battery_display.rs +++ b/src/canvas/widgets/battery_display.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, terminal::Frame, text::{Line, Span}, @@ -16,7 +15,7 @@ use crate::{ }; impl Painter { - pub fn draw_battery_display( + pub fn draw_battery_display( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, draw_border: bool, widget_id: u64, ) { diff --git a/src/canvas/widgets/cpu_basic.rs b/src/canvas/widgets/cpu_basic.rs index a96256802..da502d695 100644 --- a/src/canvas/widgets/cpu_basic.rs +++ b/src/canvas/widgets/cpu_basic.rs @@ -1,7 +1,6 @@ use std::cmp::min; use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, terminal::Frame, widgets::Block, @@ -17,7 +16,7 @@ use crate::{ impl Painter { /// Inspired by htop. - pub fn draw_basic_cpu( + pub fn draw_basic_cpu( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { // Skip the first element, it's the "all" element diff --git a/src/canvas/widgets/cpu_graph.rs b/src/canvas/widgets/cpu_graph.rs index 5426110ec..9e9dab2fa 100644 --- a/src/canvas/widgets/cpu_graph.rs +++ b/src/canvas/widgets/cpu_graph.rs @@ -1,7 +1,6 @@ use std::borrow::Cow; use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, symbols::Marker, terminal::Frame, @@ -22,9 +21,7 @@ const AVG_POSITION: usize = 1; const ALL_POSITION: usize = 0; impl Painter { - pub fn draw_cpu( - &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, - ) { + pub fn draw_cpu(&self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64) { let legend_width = (draw_loc.width as f64 * 0.15) as u16; if legend_width < 6 { @@ -36,7 +33,7 @@ impl Painter { app_state.move_widget_selection(&WidgetDirection::Left); } } - self.draw_cpu_graph::(f, app_state, draw_loc, widget_id); + self.draw_cpu_graph(f, app_state, draw_loc, widget_id); if let Some(cpu_widget_state) = app_state.states.cpu_state.widget_states.get_mut(&widget_id) { @@ -80,8 +77,8 @@ impl Painter { .constraints(constraints) .split(draw_loc); - self.draw_cpu_graph::(f, app_state, partitioned_draw_loc[graph_index], widget_id); - self.draw_cpu_legend::( + self.draw_cpu_graph(f, app_state, partitioned_draw_loc[graph_index], widget_id); + self.draw_cpu_legend( f, app_state, partitioned_draw_loc[legend_index], @@ -175,7 +172,7 @@ impl Painter { } } - fn draw_cpu_graph( + fn draw_cpu_graph( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { const Y_BOUNDS: [f64; 2] = [0.0, 100.5]; @@ -236,11 +233,11 @@ impl Painter { legend_constraints: None, marker, } - .draw_time_graph::(f, draw_loc, &points); + .draw_time_graph(f, draw_loc, &points); } } - fn draw_cpu_legend( + fn draw_cpu_legend( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { let recalculate_column_widths = app_state.should_get_widget_bounds(); @@ -262,7 +259,7 @@ impl Painter { selection_state: SelectionState::new(app_state.is_expanded, is_on_widget), }; - cpu_widget_state.table.draw::( + cpu_widget_state.table.draw( f, &draw_info, app_state.widget_map.get_mut(&widget_id), diff --git a/src/canvas/widgets/disk_table.rs b/src/canvas/widgets/disk_table.rs index 16ce50727..cfea61b60 100644 --- a/src/canvas/widgets/disk_table.rs +++ b/src/canvas/widgets/disk_table.rs @@ -1,4 +1,4 @@ -use tui::{backend::Backend, layout::Rect, terminal::Frame}; +use tui::{layout::Rect, terminal::Frame}; use crate::{ app::{self}, @@ -7,7 +7,7 @@ use crate::{ }; impl Painter { - pub fn draw_disk_table( + pub fn draw_disk_table( &self, f: &mut Frame<'_>, app_state: &mut app::App, draw_loc: Rect, widget_id: u64, ) { let recalculate_column_widths = app_state.should_get_widget_bounds(); @@ -26,7 +26,7 @@ impl Painter { selection_state: SelectionState::new(app_state.is_expanded, is_on_widget), }; - disk_widget_state.table.draw::( + disk_widget_state.table.draw( f, &draw_info, app_state.widget_map.get_mut(&widget_id), diff --git a/src/canvas/widgets/mem_basic.rs b/src/canvas/widgets/mem_basic.rs index 9b536b5db..d24ae22ec 100644 --- a/src/canvas/widgets/mem_basic.rs +++ b/src/canvas/widgets/mem_basic.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, terminal::Frame, widgets::Block, @@ -10,7 +9,7 @@ use crate::{ }; impl Painter { - pub fn draw_basic_memory( + pub fn draw_basic_memory( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { let mem_data = &app_state.converted_data.mem_data; diff --git a/src/canvas/widgets/mem_graph.rs b/src/canvas/widgets/mem_graph.rs index c9a63e68a..42e05e024 100644 --- a/src/canvas/widgets/mem_graph.rs +++ b/src/canvas/widgets/mem_graph.rs @@ -1,7 +1,6 @@ use std::borrow::Cow; use tui::{ - backend::Backend, layout::{Constraint, Rect}, symbols::Marker, terminal::Frame, @@ -14,7 +13,7 @@ use crate::{ }; impl Painter { - pub fn draw_memory_graph( + pub fn draw_memory_graph( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { const Y_BOUNDS: [f64; 2] = [0.0, 100.5]; @@ -134,7 +133,7 @@ impl Painter { legend_constraints: Some((Constraint::Ratio(3, 4), Constraint::Ratio(3, 4))), marker, } - .draw_time_graph::(f, draw_loc, &points); + .draw_time_graph(f, draw_loc, &points); } if app_state.should_get_widget_bounds() { diff --git a/src/canvas/widgets/network_basic.rs b/src/canvas/widgets/network_basic.rs index 5c9df06dd..63e0e52ff 100644 --- a/src/canvas/widgets/network_basic.rs +++ b/src/canvas/widgets/network_basic.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, terminal::Frame, text::{Line, Span}, @@ -9,7 +8,7 @@ use tui::{ use crate::{app::App, canvas::Painter, constants::*}; impl Painter { - pub fn draw_basic_network( + pub fn draw_basic_network( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { let divided_loc = Layout::default() diff --git a/src/canvas/widgets/network_graph.rs b/src/canvas/widgets/network_graph.rs index 6a5db8ca5..8f0885fad 100644 --- a/src/canvas/widgets/network_graph.rs +++ b/src/canvas/widgets/network_graph.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, symbols::Marker, terminal::Frame, @@ -18,7 +17,7 @@ use crate::{ }; impl Painter { - pub fn draw_network( + pub fn draw_network( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { if app_state.app_config_fields.use_old_network_legend { @@ -32,10 +31,10 @@ impl Painter { ]) .split(draw_loc); - self.draw_network_graph::(f, app_state, network_chunk[0], widget_id, true); + self.draw_network_graph(f, app_state, network_chunk[0], widget_id, true); self.draw_network_labels(f, app_state, network_chunk[1], widget_id); } else { - self.draw_network_graph::(f, app_state, draw_loc, widget_id, false); + self.draw_network_graph(f, app_state, draw_loc, widget_id, false); } if app_state.should_get_widget_bounds() { @@ -50,7 +49,7 @@ impl Painter { } } - pub fn draw_network_graph( + pub fn draw_network_graph( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, hide_legend: bool, ) { @@ -163,7 +162,7 @@ impl Painter { legend_constraints: Some(legend_constraints), marker, } - .draw_time_graph::(f, draw_loc, &points); + .draw_time_graph(f, draw_loc, &points); } } diff --git a/src/canvas/widgets/process_table.rs b/src/canvas/widgets/process_table.rs index e08c488bc..8aef6bea0 100644 --- a/src/canvas/widgets/process_table.rs +++ b/src/canvas/widgets/process_table.rs @@ -1,5 +1,4 @@ use tui::{ - backend::Backend, layout::{Alignment, Constraint, Direction, Layout, Rect}, style::Style, terminal::Frame, @@ -20,7 +19,7 @@ const SORT_MENU_WIDTH: u16 = 7; impl Painter { /// Draws and handles all process-related drawing. Use this. /// - `widget_id` here represents the widget ID of the process widget itself! - pub fn draw_process_widget( + pub fn draw_process_widget( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, draw_border: bool, widget_id: u64, ) { @@ -52,10 +51,10 @@ impl Painter { .split(proc_draw_loc); proc_draw_loc = processes_chunk[1]; - self.draw_sort_table::(f, app_state, processes_chunk[0], widget_id + 2); + self.draw_sort_table(f, app_state, processes_chunk[0], widget_id + 2); } - self.draw_processes_table::(f, app_state, proc_draw_loc, widget_id); + self.draw_processes_table(f, app_state, proc_draw_loc, widget_id); } if let Some(proc_widget_state) = app_state @@ -73,7 +72,7 @@ impl Painter { /// Draws the process sort box. /// - `widget_id` represents the widget ID of the process widget itself.an - fn draw_processes_table( + fn draw_processes_table( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { let should_get_widget_bounds = app_state.should_get_widget_bounds(); @@ -95,7 +94,7 @@ impl Painter { selection_state: SelectionState::new(app_state.is_expanded, is_on_widget), }; - proc_widget_state.table.draw::( + proc_widget_state.table.draw( f, &draw_info, app_state.widget_map.get_mut(&widget_id), @@ -311,7 +310,7 @@ impl Painter { /// Draws the process sort box. /// - `widget_id` represents the widget ID of the sort box itself --- NOT the process widget /// state that is stored. - fn draw_sort_table( + fn draw_sort_table( &self, f: &mut Frame<'_>, app_state: &mut App, draw_loc: Rect, widget_id: u64, ) { let should_get_widget_bounds = app_state.should_get_widget_bounds(); @@ -332,7 +331,7 @@ impl Painter { selection_state: SelectionState::new(app_state.is_expanded, is_on_widget), }; - pws.sort_table.draw::( + pws.sort_table.draw( f, &draw_info, app_state.widget_map.get_mut(&widget_id), diff --git a/src/canvas/widgets/temperature_table.rs b/src/canvas/widgets/temperature_table.rs index ab5006e7b..6c0475a47 100644 --- a/src/canvas/widgets/temperature_table.rs +++ b/src/canvas/widgets/temperature_table.rs @@ -1,4 +1,4 @@ -use tui::{backend::Backend, layout::Rect, terminal::Frame}; +use tui::{layout::Rect, terminal::Frame}; use crate::{ app, @@ -7,7 +7,7 @@ use crate::{ }; impl Painter { - pub fn draw_temp_table( + pub fn draw_temp_table( &self, f: &mut Frame<'_>, app_state: &mut app::App, draw_loc: Rect, widget_id: u64, ) { let recalculate_column_widths = app_state.should_get_widget_bounds(); @@ -26,7 +26,7 @@ impl Painter { selection_state: SelectionState::new(app_state.is_expanded, is_on_widget), }; - temp_widget_state.table.draw::( + temp_widget_state.table.draw( f, &draw_info, app_state.widget_map.get_mut(&widget_id), diff --git a/src/components/data_table/draw.rs b/src/components/data_table/draw.rs index d5c0b1fbd..15faae222 100644 --- a/src/components/data_table/draw.rs +++ b/src/components/data_table/draw.rs @@ -5,7 +5,6 @@ use std::{ use concat_string::concat_string; use tui::{ - backend::Backend, layout::{Constraint, Direction, Layout, Rect}, text::{Line, Span, Text}, widgets::{Block, Borders, Row, Table}, @@ -139,7 +138,7 @@ where }) } - pub fn draw( + pub fn draw( &mut self, f: &mut Frame<'_>, draw_info: &DrawInfo, widget: Option<&mut BottomWidget>, painter: &Painter, ) { diff --git a/src/components/time_graph.rs b/src/components/time_graph.rs index 33245d38a..63d7330b6 100644 --- a/src/components/time_graph.rs +++ b/src/components/time_graph.rs @@ -2,7 +2,6 @@ use std::borrow::Cow; use concat_string::concat_string; use tui::{ - backend::Backend, layout::{Constraint, Rect}, style::Style, symbols::Marker, @@ -124,9 +123,7 @@ impl<'a> TimeGraph<'a> { /// - Draws with the higher time value on the left, and lower on the right. /// - Expects a [`TimeGraph`] to be passed in, which details how to draw the graph. /// - Expects `graph_data`, which represents *what* data to draw, and various details like style and optional legends. - pub fn draw_time_graph( - &self, f: &mut Frame<'_>, draw_loc: Rect, graph_data: &[GraphData<'_>], - ) { + pub fn draw_time_graph(&self, f: &mut Frame<'_>, draw_loc: Rect, graph_data: &[GraphData<'_>]) { let x_axis = self.generate_x_axis(); let y_axis = self.generate_y_axis(); diff --git a/src/components/tui_widget/time_chart/canvas.rs b/src/components/tui_widget/time_chart/canvas.rs index 416664700..b6cc41c1a 100644 --- a/src/components/tui_widget/time_chart/canvas.rs +++ b/src/components/tui_widget/time_chart/canvas.rs @@ -364,9 +364,9 @@ impl<'a> Context<'a> { let grid: Box = match marker { symbols::Marker::Dot => Box::new(CharGrid::new(width, height, '•')), symbols::Marker::Block => Box::new(CharGrid::new(width, height, '█')), - symbols::Marker::HalfBlock => Box::new(CharGrid::new(width, height, '▀')), - symbols::Marker::Braille => Box::new(BrailleGrid::new(width, height)), symbols::Marker::Bar => Box::new(CharGrid::new(width, height, '▄')), + symbols::Marker::Braille => Box::new(BrailleGrid::new(width, height)), + symbols::Marker::HalfBlock => Box::new(CharGrid::new(width, height, '▀')), }; Context { x_bounds,