Example usage for com.badlogic.gdx.graphics.g2d NinePatch setMiddleHeight

List of usage examples for com.badlogic.gdx.graphics.g2d NinePatch setMiddleHeight

Introduction

In this page you can find the example usage for com.badlogic.gdx.graphics.g2d NinePatch setMiddleHeight.

Prototype

public void setMiddleHeight(float middleHeight) 

Source Link

Document

Set the height of the middle row of the patch.

Usage

From source file:de.cubicvoxel.openspacebox.ingame.ui.logbook.LogEntryView.java

License:Open Source License

private NinePatchDrawable createBackground() {
    NinePatch ninePatch = new NinePatch(OpenSpaceBox.getAsset(TextureAsset.UI_PANEL), 270, 270, 270, 270);
    ninePatch.setTopHeight(DRAWABLE_BORDER_THICKNESS);
    ninePatch.setBottomHeight(DRAWABLE_BORDER_THICKNESS);
    ninePatch.setLeftWidth(DRAWABLE_BORDER_THICKNESS);
    ninePatch.setRightWidth(DRAWABLE_BORDER_THICKNESS);
    ninePatch.setMiddleHeight(1);
    ninePatch.setMiddleWidth(1);//from  ww w  . j  a  v  a2  s .co  m
    return new NinePatchDrawable(ninePatch);
}