This commit is contained in:
2026-06-23 21:51:31 -05:00
parent cbbe522fb1
commit cca56a6153
7 changed files with 171 additions and 52 deletions
+10 -2
View File
@@ -13,7 +13,7 @@ use crate::editor_menu::{MenuEntry, MenuLevel};
use crate::log::{LogWidget, log_preview_line};
use crate::render::{BoardWidget, board_to_screen, screen_to_board};
use crate::ui::Ui;
use crate::utils::rgba8_to_color;
use crate::utils::{glyph_to_span, rgba8_to_color};
use kiln_core::cp437::tile_to_char;
use kiln_core::game::GameState;
use kiln_core::glyph::Glyph;
@@ -458,6 +458,14 @@ pub(crate) fn draw_editor(frame: &mut Frame, ed: &mut EditorState, ui: &mut Ui)
Span::styled(label, label_style),
]));
}
MenuEntry::Glyph { key, glyph, label, .. } => {
lines.push(Line::from(vec![
Span::styled(format!("[{}] ", key), key_style),
glyph_to_span(glyph),
Span::raw(" "),
Span::styled(label, label_style),
]));
}
MenuEntry::Blank => lines.push(Line::from("")),
// A horizontal rule spanning the sidebar's inner width.
MenuEntry::Separator => lines.push(Line::from(Span::styled(
@@ -514,7 +522,7 @@ fn draw_footer_lines<'a>(
// The archetype currently being drawn (no UI to change it yet).
Line::from(Span::styled(ed.current_archetype.name(), label_style)),
Line::from(vec![
Span::styled("[g] ", key_style),
Span::styled("[G] ", key_style),
Span::styled("Glyph ", label_style),
preview,
]),