public static class Button.FlatButtonRenderer extends Object implements Button.ButtonRenderer
Constructor and Description |
---|
FlatButtonRenderer() |
Modifier and Type | Method and Description |
---|---|
void |
drawComponent(TextGUIGraphics graphics,
Button button)
Using the supplied graphics object, draws the component passed in.
|
TerminalPosition |
getCursorLocation(Button component) |
TerminalSize |
getPreferredSize(Button component)
Given the supplied component, how large does this renderer want the component to be? Notice that this is the
responsibility of the renderer and not the component itself, since the component has no idea what its visual
representation looks like.
|
public TerminalPosition getCursorLocation(Button component)
getCursorLocation
in interface InteractableRenderer<Button>
public TerminalSize getPreferredSize(Button component)
ComponentRenderer
getPreferredSize
in interface ComponentRenderer<Button>
component
- Component to calculate the preferred size ofpublic void drawComponent(TextGUIGraphics graphics, Button button)
ComponentRenderer
drawComponent
in interface ComponentRenderer<Button>
graphics
- Graphics object to use for drawingbutton
- Component to drawCopyright © 2016. All rights reserved.