Class MenuHorizontalMirroringPolicy
Pure decision rule for whether a horizontal menu's composite option rows (selector/slider/toggle —
anything beyond a simple labeled button) may apply real OptionAlignment.RIGHT element mirroring,
or must fall back to CENTER.
Inherited Members
Namespace: Serenity.Menu.Domain.Entities
Assembly: Serenity.Menu.Domain.dll
Syntax
public static class MenuHorizontalMirroringPolicy
Remarks
Vertical rows all share one resolved column width (the widest option, applied uniformly via
SetOptionWidth), so mirroring a row's internal elements around that shared width is safe and
already relied upon. CONTENT gives every horizontal option its
own measured width instead, so a composite row's mirrored internal layout (authored/measured against its
own content) has no shared width to mirror against and can overlap its label/value — this was observed
and fixed by clamping to CENTER (commit 468176f4d). The other modes
(UNIFORM, FILL,
EXPLICIT) give every option the same width, matching the
vertical case, so real mirroring is safe there too.
Methods
CanMirrorRight(HorizontalOptionWidthMode)
Determines whether a horizontal composite option row may mirror its elements for RIGHT alignment.
Declaration
public static bool CanMirrorRight(HorizontalOptionWidthMode widthMode)
Parameters
| Type | Name | Description |
|---|---|---|
| HorizontalOptionWidthMode | widthMode | The menu's configured horizontal option width mode. |
Returns
| Type | Description |
|---|---|
| bool | True when every option shares one column width, so mirroring is safe. |