com.badlogic.gdx.scenes.scene2d.utils
Class BaseDrawable
java.lang.Object
com.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
- All Implemented Interfaces:
- Drawable
- Direct Known Subclasses:
- NinePatchDrawable, SpriteDrawable, TextureRegionDrawable
public class BaseDrawable
- extends java.lang.Object
- implements Drawable
Drawable that stores the size information but doesn't draw anything.
- Author:
- Nathan Sweet
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BaseDrawable
public BaseDrawable()
BaseDrawable
public BaseDrawable(Drawable drawable)
- Creates a new empty drawable with the same sizing information as the specified drawable.
draw
public void draw(SpriteBatch batch,
float x,
float y,
float width,
float height)
- Description copied from interface:
Drawable
- Draws this drawable at the specified bounds. The drawable should be tinted with
SpriteBatch.getColor()
, possibly by
mixing its own color.
- Specified by:
draw
in interface Drawable
getLeftWidth
public float getLeftWidth()
- Specified by:
getLeftWidth
in interface Drawable
setLeftWidth
public void setLeftWidth(float leftWidth)
- Specified by:
setLeftWidth
in interface Drawable
getRightWidth
public float getRightWidth()
- Specified by:
getRightWidth
in interface Drawable
setRightWidth
public void setRightWidth(float rightWidth)
- Specified by:
setRightWidth
in interface Drawable
getTopHeight
public float getTopHeight()
- Specified by:
getTopHeight
in interface Drawable
setTopHeight
public void setTopHeight(float topHeight)
- Specified by:
setTopHeight
in interface Drawable
getBottomHeight
public float getBottomHeight()
- Specified by:
getBottomHeight
in interface Drawable
setBottomHeight
public void setBottomHeight(float bottomHeight)
- Specified by:
setBottomHeight
in interface Drawable
getMinWidth
public float getMinWidth()
- Specified by:
getMinWidth
in interface Drawable
setMinWidth
public void setMinWidth(float minWidth)
- Specified by:
setMinWidth
in interface Drawable
getMinHeight
public float getMinHeight()
- Specified by:
getMinHeight
in interface Drawable
setMinHeight
public void setMinHeight(float minHeight)
- Specified by:
setMinHeight
in interface Drawable
Copyright 2010 Mario Zechner (contact@badlogicgames.com), Nathan Sweet (admin@esotericsoftware.com)