Class ElementStdBounds
- Namespace
- Vintagestory.API.Client
- Assembly
- VintagestoryAPI.dll
Just some default sizings for various ui elements
public static class ElementStdBounds
- Inheritance
-
ElementStdBounds
- Inherited Members
Fields
mainMenuUnscaledLogoHorPadding
public static int mainMenuUnscaledLogoHorPadding
Field Value
mainMenuUnscaledLogoSize
public static int mainMenuUnscaledLogoSize
Field Value
mainMenuUnscaledLogoVerPadding
public static int mainMenuUnscaledLogoVerPadding
Field Value
mainMenuUnscaledWoodPlankWidth
public static int mainMenuUnscaledWoodPlankWidth
Field Value
Properties
AutosizedMainDialog
Quick Method to create a new ElementBounds instance that is positioned at the screen center and sized accordingly to fit all it's child elements
public static ElementBounds AutosizedMainDialog { get; }
Property Value
Methods
AutosizedMainDialogAtPos(double)
Quick Method to create a new ElementBounds instance that draws a background for a dialog
public static ElementBounds AutosizedMainDialogAtPos(double fixedY)
Parameters
fixedY
double
Returns
DialogBackground()
Quick Method to create a new ElementBounds instance that draws a background for a dialog
public static ElementBounds DialogBackground()
Returns
DialogBackground(double, double)
Quick Method to create a new ElementBounds instance that draws a background for a dialog
public static ElementBounds DialogBackground(double horPadding, double verPadding)
Parameters
Returns
MainScreenRightPart()
Quick Method to create a new ElementBounds instance that draws a background for a dialog
public static ElementBounds MainScreenRightPart()
Returns
MenuButton(float, EnumDialogArea)
Quick Method to create a new ElementBounds instance to create a menu consiting of one ore more vertically arranged and horizontally centered buttons in a grid. The y position is calculated using rowIndex * 80.
public static ElementBounds MenuButton(float rowIndex, EnumDialogArea alignment = EnumDialogArea.CenterFixed)
Parameters
rowIndex
floatalignment
EnumDialogArea
Returns
Rowed(float, double, EnumDialogArea)
Quick Method to create a new ElementBounds instance to create a menu consiting of one ore more vertically arranged and horizontally centered buttons in a grid. The y position is calculated using rowIndex * 80.
public static ElementBounds Rowed(float rowIndex, double padding, EnumDialogArea alignment = EnumDialogArea.None)
Parameters
rowIndex
floatpadding
doublealignment
EnumDialogArea
Returns
Sign(double, double, double, double)
Quick Method to create a new ElementBounds instance that is currently used for Signs (e.g. graphics options)
public static ElementBounds Sign(double fixedX, double fixedY, double fixedWith, double fixedHeight = 80)
Parameters
Returns
Slider(double, double, double)
public static ElementBounds Slider(double x, double y, double width)
Parameters
Returns
Slot(double, double)
public static ElementBounds Slot(double x = 0, double y = 0)
Parameters
Returns
SlotGrid(EnumDialogArea, double, double, int, int)
public static ElementBounds SlotGrid(EnumDialogArea alignment, double x, double y, int cols, int rows)
Parameters
alignment
EnumDialogAreax
doubley
doublecols
introws
int
Returns
Statbar(EnumDialogArea, double)
Quick method to create a new ElementBounds instance that uses fixed element sizing. The X/Y Coordinates are left at 0.
public static ElementBounds Statbar(EnumDialogArea alignment, double width)
Parameters
alignment
EnumDialogAreawidth
double
Returns
TitleBar()
public static ElementBounds TitleBar()
Returns
ToggleButton(double, double, double, double)
public static ElementBounds ToggleButton(double fixedX, double fixedY, double width, double height)
Parameters
Returns
VerticalScrollbar(ElementBounds)
Creates a scrollbar right of given element bounds, requires the left element to be using fixed element positioning
public static ElementBounds VerticalScrollbar(ElementBounds leftElement)
Parameters
leftElement
ElementBounds