From 0da52c3054680ef4e5189278978773d3114224b3 Mon Sep 17 00:00:00 2001 From: landon Date: Sat, 19 Sep 2026 11:10:02 -0500 Subject: [PATCH] Fix Story Bible Editor's content panel rendering a sliver wide MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ui.set_width() was called on the shared horizontal-layout Ui before the tree and editor panels were split off, so it shrank the whole row — tree, separator, and editor panel together — down to a third of the window's width instead of just the tree column. The editor's own heading (the open item's path) was narrow enough to wrap one letter per line as a result. Moving the width constraint onto the tree panel's own child Ui, where it belongs, leaves the editor panel free to take the rest of the row. Co-Authored-By: Claude Sonnet 5 --- src/app/story_bible_editor.rs | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) 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();