com.badlogic.gdx.scenes.scene2d.ui
Class Button
java.lang.Object
com.badlogic.gdx.scenes.scene2d.Actor
com.badlogic.gdx.scenes.scene2d.Group
com.badlogic.gdx.scenes.scene2d.ui.tablelayout.Table
com.badlogic.gdx.scenes.scene2d.ui.Button
- All Implemented Interfaces:
- Layout
- Direct Known Subclasses:
- CheckBox
public class Button
- extends Table
Fields inherited from class com.badlogic.gdx.scenes.scene2d.ui.tablelayout.Table |
isPressed |
Fields inherited from class com.badlogic.gdx.scenes.scene2d.Group |
batchTransform, children, debug, debugTexture, focusedActor, groups, immutableChildren, immutableGroups, keyboardFocusedActor, lastTouchedChild, localTransform, namesToActors, oldBatchTransform, point, scrollFocusedActor, transform, worldTransform |
Fields inherited from class com.badlogic.gdx.scenes.scene2d.Actor |
actions, color, height, name, originX, originY, parent, rotation, scaleX, scaleY, touchable, visible, width, x, y |
Methods inherited from class com.badlogic.gdx.scenes.scene2d.ui.tablelayout.Table |
add, align, align, bottom, center, clear, click, columnDefaults, debug, debug, debug, defaults, drawDebug, enableClipping, getAlign, getAllCells, getAllCells, getCell, getCell, getCells, getDebug, getHeight, getMaxHeight, getMaxWidth, getMinHeight, getMinWidth, getPadBottom, getPadLeft, getPadRight, getPadTop, getPrefHeight, getPrefWidth, getTableLayout, getWidget, getWidgets, getWidgets, height, height, hit, invalidate, invalidateHierarchy, layout, left, pad, pad, pad, pad, padBottom, padBottom, padLeft, padLeft, padRight, padRight, padTop, padTop, parse, parse, register, reset, right, row, setActor, setBackground, size, size, stack, top, touchDown, touchUp, width, width |
Methods inherited from class com.badlogic.gdx.scenes.scene2d.Group |
act, addActor, addActorAfter, addActorAt, addActorBefore, applyTransform, disableDebugging, drawChild, drawChildren, enableDebugging, findActor, focus, getActors, getGroups, keyboardFocus, keyDown, keyTyped, keyUp, removeActor, removeActorRecursive, resetTransform, scrolled, scrollFocus, sortChildren, swapActor, swapActor, toChildCoordinates, touchDragged, touchMoved, unfocusAll, unfocusAll, updateTransform |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
style
public Button.ButtonStyle style
isChecked
public boolean isChecked
Button
public Button(Skin skin)
Button
public Button(Button.ButtonStyle style)
Button
public Button(Actor child,
Skin skin)
Button
public Button(Actor child,
Button.ButtonStyle style)
Button
public Button(java.lang.String text,
Skin skin)
Button
public Button(java.lang.String text,
Button.ButtonStyle style)
Button
public Button(java.lang.String text,
Button.ButtonStyle style,
java.lang.String name)
Button
public Button(Button.ButtonStyle style,
java.lang.String name)
setStyle
public void setStyle(Button.ButtonStyle style)
setClickListener
public void setClickListener(ClickListener listener)
- Overrides:
setClickListener
in class Table
setText
public void setText(java.lang.String text)
getText
public java.lang.String getText()
draw
public void draw(SpriteBatch batch,
float parentAlpha)
- Description copied from class:
Actor
- Draws the Actor. The spriteBatch is configured so that the Actor can draw in its parents coordinate system. The parent's
alpha is passed to the method in order for the Actor to multiply it with its own alpha. This will allow
FadeIn
and
other Actions to have an effect even if they are only set on the parent of the Actor.
- Overrides:
draw
in class Table
- Parameters:
batch
- the spritebatch to render withparentAlpha
- the parent's alpha value.
Copyright 2010 Mario Zechner (contact@badlogicgames.com), Nathan Sweet (admin@esotericsoftware.com)