List of usage examples for com.badlogic.gdx.graphics Color tmp
Color tmp
To view the source code for com.badlogic.gdx.graphics Color tmp.
Click Source Link
From source file:com.aia.hichef.ui.n.MyWindow.java
License:Apache License
protected void drawBackground(Batch batch, float parentAlpha, float x, float y) { float width = getWidth(), height = getHeight(); float padTop = getPadTop(); super.drawBackground(batch, parentAlpha, x, y); // Draw button table. buttonTable.getColor().a = getColor().a; buttonTable.pack();//from w w w.j a v a2 s . c o m buttonTable.setPosition(width - buttonTable.getWidth(), Math.min(height - padTop, height - buttonTable.getHeight())); buttonTable.draw(batch, parentAlpha); // Draw the title without the batch transformed or clipping applied. y += height; TextBounds bounds = titleCache.getBounds(); if ((titleAlignment & Align.left) != 0) x += getPadLeft(); else if ((titleAlignment & Align.right) != 0) x += width - bounds.width - getPadRight(); else x += (width - bounds.width) / 2; if ((titleAlignment & Align.top) == 0) { if ((titleAlignment & Align.bottom) != 0) y -= padTop - bounds.height; else y -= (padTop - bounds.height) / 2; } titleCache.setColors(Color.tmp.set(getColor()).mul(style.titleFontColor)); titleCache.setPosition((int) x, (int) y); titleCache.draw(batch, parentAlpha); }