Say which axis each export dimension is, in the one place that renders
The box modes put two numeric fields one above the other, and on screen they are two anonymous numbers: `TextRow` draws its label behind the field rather than above it, so "Width" and "Height" never appear. That fault is older than this feature — the storage panel's cache sizes have the same missing labels, and the single "Size value" row always did — and it belongs in its own change rather than being fixed under cover of this one. But one unlabelled number is survivable and two are not, so the axis goes where the page does render it: the unit. It reads "3840 px wide" above "2160 px high", which is the sentence the user is trying to write anyway. The `label` bindings stay correct and stay where they are, so this becomes redundant rather than wrong the day `TextRow` is fixed. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -196,9 +196,15 @@ pub fn render(window: &AppWindow, controller: &SettingsController) {
|
||||
// `Original` carries no number, so the field beside the chips has nothing
|
||||
// to edit and is hidden rather than shown holding a meaningless zero.
|
||||
window.set_settings_sizing_has_value(s.export.sizing.value().is_some());
|
||||
// TRACES: FR-EXP-3
|
||||
// The unit carries the axis for the box modes, so that two numeric fields
|
||||
// one above the other are not two anonymous numbers. It reads "3840 px
|
||||
// wide" and "2160 px high", which is the sentence the user is trying to
|
||||
// write anyway.
|
||||
window.set_settings_sizing_unit(
|
||||
match s.export.sizing {
|
||||
SizingMode::Percentage(_) => "%",
|
||||
SizingMode::FitBox(..) | SizingMode::FillBox(..) => "px wide",
|
||||
_ => "px",
|
||||
}
|
||||
.into(),
|
||||
|
||||
@@ -677,7 +677,7 @@ export component SettingsPage inherits Rectangle {
|
||||
if root.sizing-has-height: TextRow {
|
||||
label: "Height";
|
||||
text: root.sizing-height;
|
||||
unit: "px";
|
||||
unit: "px high";
|
||||
field-width: 90px;
|
||||
accepted(t) => { root.sizing-height-changed(t); }
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user