diff --git a/src/app/story_bible_editor.rs b/src/app/story_bible_editor.rs index 1b94ea8..862f70a 100644 --- a/src/app/story_bible_editor.rs +++ b/src/app/story_bible_editor.rs @@ -231,11 +231,16 @@ impl App { // that borrow `self` have finished. let mut focused = false; ui.horizontal(|ui| { - // Left panel: Tree view (1/3 width) + // Left panel: Tree view (1/3 width). The width must be set on + // this panel's own child `Ui`, not the shared horizontal one — + // that had been shrinking the whole row (tree, separator, and + // the editor panel with it) down to a third of the window, + // which is why the editor's heading used to wrap one letter at + // a time. let tree_width = ui.available_width() / 3.0; - ui.set_width(tree_width); - + ui.vertical(|ui| { + ui.set_width(tree_width); ui.heading("Story Bible"); ui.separator();