qui.utils

Contains functions that might be useful in making new widgets, like for formatting text.

Members

Functions

adjustScrollingOffset
void adjustScrollingOffset(uint selected, uint size, uint lineWidth, uint offset)

Adjusts offset (aka _scrollX or _scrollY) in scrolling so the selected character is visible TODO: FIX THIS

centerAlignText
dstring centerAlignText(dstring text, uint width, dchar fill)

Center-aligns text

getLimitedSize
uint getLimitedSize(uint calculated, uint min, uint max)
scrollHorizontal
dstring scrollHorizontal(dstring line, int xOffset, uint width, dchar spaceChar)
dchar[] scrollHorizontal(dchar[] line, int xOffset, uint width)
char[] scrollHorizontal(char[] line, int xOffset, uint width)

To scroll a line, by an xOffset

Meta