Move the instrumentation off the header and into About
The render backend, the layout class and the frame rate sat permanently in a 44px strip that also carries the only way out of develop, the undo pair, the panel toggle and the export button. They cost about 200 logical pixels, and a `HorizontalLayout` given less width than its children's minimums does not shrink them — it runs off the end. There was already a breakpoint hiding them below 820px, which is why a tablet in portrait (768) looked fine and landscape (1200) did not: above the breakpoint the readouts came back and pushed the header off the right-hand edge. A breakpoint that hides a problem at one size and not another is a workaround, and this removes the reason for it rather than moving it. They are diagnostics — read once when something looks wrong, and then not again — so they are in Settings under ABOUT, beside the version, which is where someone goes when they have a bug to report rather than a photograph to edit. The version is there for the same reason and comes from `CARGO_PKG_VERSION`, so the line cannot disagree with the binary showing it. The frame rate keeps its warning hue. It is the number that says whether the zero-copy display path is holding up, which is the assumption the whole display design rests on, and that is worth colour wherever it is shown. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -764,6 +764,10 @@ pub fn run(paths: Vec<PathBuf>) -> Result<()> {
|
||||
let gpu = shared_gpu();
|
||||
|
||||
let window = AppWindow::new()?;
|
||||
// The version the About page shows. Taken from the crate rather than
|
||||
// passed in, so it is the version of the code that is running and cannot
|
||||
// be set to something else by a caller.
|
||||
window.set_app_version(env!("CARGO_PKG_VERSION").into());
|
||||
match &gpu {
|
||||
Some(ctx) => {
|
||||
log::info!("adapter: {} ({:?})", ctx.adapter_name(), ctx.backend());
|
||||
|
||||
Reference in New Issue
Block a user