OpenSite/Reference/Features/Unit preferences: Difference between revisions

From BathAfrica Documentation
Jump to navigation Jump to search
Publish Cursor documentation reconciled with OpenSite source 77c3fee; tests not rerun
 
Use sidebar contents consistently on unit-preferences reference
Line 1: Line 1:
__NOTOC__
{{BathAfrica Feature
{{BathAfrica Feature
|review=Development documentation for OpenSite 0.0.1, source snapshot 77c3fee (Phase 13C). Reviewed against implementation on 29 October 2026. Tests and the Windows desktop were not rerun for this publication; this is not a released-product support claim.
|review=Development documentation for OpenSite 0.0.1, source snapshot 77c3fee (Phase 13C). Reviewed against implementation on 29 October 2026. Tests and the Windows desktop were not rerun for this publication; this is not a released-product support claim.

Revision as of 13:15, 29 October 2026


Review notice: Development documentation for OpenSite 0.0.1, source snapshot 77c3fee (Phase 13C). Reviewed against implementation on 29 October 2026. Tests and the Windows desktop were not rerun for this publication; this is not a released-product support claim.

Select how quantities are presented without changing the stored values.

Stable identifier
foundation.unit-preferences

Status reported by source

Implemented in the reviewed development source. Historical test evidence is recorded by the repository; no test rerun or product release is claimed by this publication.

Units

The service stores profile ids and unit ids. It does not store an SI value.

Behavior

The application default profile is SI. The user can select engineering_metric or us_customary. A document key and a property can override the presentation. The default object owns a private settings service. UnitPreferences(SettingsService&) uses a caller-owned service, and that service is the only preferences file. Save writes opensite-settings version 1. Load still accepts opensite-unit-preferences version 1 and migrates it. A change to units.profile through the shared service updates this object and notifies its listeners. Listeners are notified after a real change.

Errors

corrupt_preferences, unsupported_version, reentrant_call, and incompatible_dimension when a display unit does not match the quantity.

Limitations

The desktop Preferences window and document/property presentation consume this service. Scope and property overrides affect formatting, not canonical SI values. Language/country remain separate settings. Do not treat a preference file as an engineering document or as a design-code unit system.

Available hosts

C++ service, CLI, embedded Python and Windows desktop preferences/quantity presentation. The core service does not depend on Qt.

Licensing and access

A profile change is presentation. It does not check a design code and it does not change a stored SI value.

Verification evidence

Repository evidence references (not rerun for this publication): CTest foundation.unit_preferences. ADR-0016. The seven CI jobs for commit 34d462a9ac58634ed66604a4df829fc5a7a7730e are in the Phase 1 acceptance report.


Documentation basis

Source-reviewed against development commit 77c3fee13944bcc4b5d487c77eb1f82fbe4c6ea7, branch feature/phase-13c-properties-python-expressions. This review inspected the implementation and repository evidence; it did not run the Windows application or repeat CTest.

  • src/foundation/unit_preferences.cpp
  • src/gui/preferences_window.cpp
  • docs/verification/Phase-11P-Preferences.md

OpenSite overview · Reference · Guides