NativeElixirPdfUtilities.Validators.CssSizingValidator (native_elixir_pdf_utilities v1.1.0)
View SourceOwns shared calculated box dimensions and computed root sizing metadata.
Summary
Types
A validated calculation whose percentage dependency remains tied to the containing axis.
Functions
Computes the starting automatic margin from actual free space for a validated axis.
Resolves final authored automatic margins numerically while retaining their axis intent.
Prepares general box size arithmetic through the shared CSS calculation grammar.
Retains computed root dimensions without changing document canvas paint semantics.
Resolves box calculations against selected font metrics and the actual containing dimension.
Validates prepared box calculations including their genuine percentage dependency.
Validates canonical automatic-margin flags for computed styles and root sizing.
Checks calculation metadata in externally supplied computed styles before used-size resolution.
Checks canonical root sizing metadata before layout uses a genuine page or child viewport.
Types
Functions
Computes the starting automatic margin from actual free space for a validated axis.
Resolves final authored automatic margins numerically while retaining their axis intent.
@spec prepare_math(term()) :: {:ok, calculation()} | :error | {:error, NativeElixirPdfUtilities.Diagnostics.detailed_error()}
Prepares general box size arithmetic through the shared CSS calculation grammar.
Retains computed root dimensions without changing document canvas paint semantics.
@spec resolve_math(calculation(), number() | nil, map()) :: {:ok, number() | nil} | {:error, NativeElixirPdfUtilities.Diagnostics.detailed_error()}
Resolves box calculations against selected font metrics and the actual containing dimension.
Validates prepared box calculations including their genuine percentage dependency.
Validates canonical automatic-margin flags for computed styles and root sizing.
@spec validate_calculations(map(), String.t()) :: :ok | {:error, NativeElixirPdfUtilities.Diagnostics.detailed_error()}
Checks calculation metadata in externally supplied computed styles before used-size resolution.
Checks canonical root sizing metadata before layout uses a genuine page or child viewport.