public abstract class UIPane extends UI2dContext
UI2dContainer.ArrowKeyFocus, UI2dContainer.Layout
Modifier and Type | Field and Description |
---|---|
protected LX |
lx |
protected static int |
MARGIN |
protected static int |
PADDING |
protected UI2dScrollContext[] |
sections |
static int |
TOP_OFFSET |
bottomMargin, height, leftMargin, rightMargin, textAlignHorizontal, textAlignVertical, textOffsetX, textOffsetY, topMargin, width, x, y
children, hasFocus, mousePressContextMenu, visible
Modifier | Constructor and Description |
---|---|
protected |
UIPane(UI ui,
LX lx,
String[] sectionNames,
int x,
int w) |
Modifier and Type | Method and Description |
---|---|
void |
onDraw(UI ui,
PGraphics pg)
Subclasses should override this method to perform their drawing functions.
|
void |
onMousePressed(MouseEvent mouseEvent,
float mx,
float my)
Subclasses override to receive mouse events
|
protected void |
onResize()
Subclasses may override this method, invoked when the component is resized
|
UIPane |
setActiveSection(int index) |
UIPane |
toggleActiveSection() |
UIPane |
toggleActiveSection(int delta) |
drawBackground, getGraphics
addChildren, addTopLevelComponent, getChild, getChildren, getContentHeight, getContentTarget, getContentWidth, iterator, newHorizontalContainer, newHorizontalContainer, newHorizontalContainer, newVerticalContainer, newVerticalContainer, newVerticalContainer, onKeyPressed, reflow, removeAllChildren, setArrowKeyFocus, setChildMargin, setChildSpacing, setChildSpacing, setContentHeight, setContentSize, setContentTarget, setContentWidth, setLayout, setMinHeight, setMinWidth, setPadding, setPadding, setPadding
addToContainer, addToContainer, breakTextToWidth, clipTextToWidth, contains, drawBorder, drawFocus, drawFocusCorners, drawFocusCorners, getBackgroundColor, getBorderColor, getBorderRounding, getBorderWeight, getContainer, getFocusColor, getFocusSize, getFont, getFontColor, getHeight, getNextSibling, getParent, getPrevSibling, getWidth, getX, getY, hasBackground, hasBorder, hasFont, hasFontColor, isMappable, redraw, removeFromContainer, setBackground, setBackgroundColor, setBorder, setBorderColor, setBorderRounding, setBorderWeight, setBottomMargin, setContainerIndex, setDescription, setFocusBackground, setFocusBackgroundColor, setFocusColor, setFocusCorners, setFont, setFontColor, setFontColor, setHeight, setLeftMargin, setMappable, setMargin, setMargin, setMargin, setPosition, setPosition, setPosition, setPosition, setRightMargin, setSize, setTextAlignment, setTextAlignment, setTextOffset, setTopMargin, setVisible, setWidth, setX, setY
addLoopTask, beginDraw, blur, bringToFront, consumeKeyEvent, consumeMousePress, consumeMouseWheelEvent, endDraw, focus, getDescription, getFocusedChild, getLX, getUI, hasDirectFocus, hasFocus, isVisible, keyEventConsumed, loop, mousePressConsumed, onBlur, onFocus, onUIResize, removeLoopTask, toggleVisible
onKeyReleased, onKeyTyped, onMouseClicked, onMouseDragged, onMouseMoved, onMouseOut, onMouseOver, onMouseReleased, onMouseWheel
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
forEach, spliterator
protected static final int MARGIN
protected static final int PADDING
public static final int TOP_OFFSET
protected final LX lx
protected final UI2dScrollContext[] sections
protected void onResize()
UI2dComponent
onResize
in class UI2dContext
public void onDraw(UI ui, PGraphics pg)
UIObject
public UIPane toggleActiveSection(int delta)
public UIPane toggleActiveSection()
public UIPane setActiveSection(int index)
public void onMousePressed(MouseEvent mouseEvent, float mx, float my)
UIEventHandler
onMousePressed
in class UIEventHandler
mouseEvent
- Mouse eventmx
- x-coordinatemy
- y-coordinateLX library by Mark C. Slee. © 2012-2020