Class TerminalViewportFitter
Fills a viewport with a terminal by reflowing its grid, the way a real terminal resizes when its window changes. It shows the three sizes the package keeps separate:
- cell size in device pixels, from a point size scaled by DPI, which sets the render resolution,
- columns and rows, computed so the grid fills the viewport at that cell size,
- the display size, the viewport the texture is stretched across. With DPI scaling on, cells keep a constant physical size and the column and row counts change with the display, which is what the reflow shows.
Assembly: DarkEffekt.Terminal
Section titled “Assembly: DarkEffekt.Terminal”[AddComponentMenu("Terminal/Terminal Viewport Fitter")][RequireComponent(typeof(RectTransform))][Icon("Packages/com.darkeffekt.terminal/Editor/Icons/Assets/TerminalViewportFitter.png")]public sealed class TerminalViewportFitter : MonoBehaviourInheritance: System.Object -> UnityEngine.Object -> UnityEngine.Component -> UnityEngine.Behaviour -> UnityEngine.MonoBehaviour
Properties
Section titled “Properties”Session
Section titled “Session”public TerminalSession Session { get; set; }FlatScreen
Section titled “FlatScreen”public TerminalScreenUGUI FlatScreen { get; set; }CellPointSize
Section titled “CellPointSize”The reference point size before DPI scaling. Set to demonstrate render-size control.
public float CellPointSize { get; set; }DpiScaling
Section titled “DpiScaling”public bool DpiScaling { get; set; }DpiOverride
Section titled “DpiOverride”public float DpiOverride { get; set; }ActiveDpiScale
Section titled “ActiveDpiScale”The DPI scale actually applied this frame.
public float ActiveDpiScale { get; }Columns
Section titled “Columns”public int Columns { get; }public int Rows { get; }CellPixelHeight
Section titled “CellPixelHeight”public int CellPixelHeight { get; }Methods
Section titled “Methods”Describe()
Section titled “Describe()”A one-line summary of the three sizes, for a status readout.
public string Describe()Returns
Section titled “Returns”System.String