GuiPanelSize struct
A GUI panel's surface size in metres and the zoom of the content drawn on it. The surface spans panel-space X from -Width/2 to +Width/2 and hangs down from the pose to -Height.
Namespace: Quaternar.Qaros · Assembly: Quaternar.Qaros.dll
public readonly struct GuiPanelSize
Constructors
GuiPanelSize(float, float, float)
public GuiPanelSize(float widthMeters, float heightMeters, float contentScale)
Parameters
| Name | Type | Description |
|---|---|---|
widthMeters | float | |
heightMeters | float | |
contentScale | float |
Properties
| Member | Description |
|---|---|
| WidthMeters | |
| HeightMeters | |
| ContentScale | Zoom of the content raster on the surface: 1.0 fits the content across the full panel, 2.0 shows it at twice the size so only half fits, 0.5 at half size. It changes how contacts map to content pixels, not the panel's size. |
| Default | 1 m by 1 m, content scale 1. |
WidthMeters
public float WidthMeters { get; }
Value: float
HeightMeters
public float HeightMeters { get; }
Value: float
ContentScale
Zoom of the content raster on the surface: 1.0 fits the content across the full panel, 2.0 shows it at twice the size so only half fits, 0.5 at half size. It changes how contacts map to content pixels, not the panel's size.
public float ContentScale { get; }
Value: float
Remarks
A website panel takes it as the page zoom, like a desktop browser's Ctrl+ and Ctrl-: the page is drawn larger and reflowed to the panel width. Only the application sets it; the panel's own + and - buttons resize the panel instead. A stream panel ignores it: its video is always drawn at full panel width and scrolled vertically when taller than the panel.
Default
1 m by 1 m, content scale 1.
public static GuiPanelSize Default { get; }
Value: GuiPanelSize