Minor UI style tweaks
This commit is contained in:
@@ -24,7 +24,7 @@ import static mindustry.gen.Tex.*;
|
||||
@StyleDefaults
|
||||
public class Styles{
|
||||
//TODO all these names are inconsistent and not descriptive
|
||||
public static Drawable black, black9, black8, black6, black3, black5, none, flatDown, flatOver, accentDrawable;
|
||||
public static Drawable black, black9, black8, black6, black3, black5, grayPanel, none, flatDown, flatOver, accentDrawable;
|
||||
|
||||
public static ButtonStyle defaultb, underlineb;
|
||||
|
||||
@@ -32,6 +32,8 @@ public class Styles{
|
||||
public static TextButtonStyle defaultt,
|
||||
/** Flat, square, opaque. */
|
||||
flatt,
|
||||
/** Flat, square, opaque, gray. */
|
||||
grayt,
|
||||
/** Flat, square, toggleable. */
|
||||
flatTogglet,
|
||||
/** Flat, square, gray border.*/
|
||||
@@ -102,6 +104,7 @@ public class Styles{
|
||||
black5 = whiteui.tint(0f, 0f, 0f, 0.5f);
|
||||
black3 = whiteui.tint(0f, 0f, 0f, 0.3f);
|
||||
none = whiteui.tint(0f, 0f, 0f, 0f);
|
||||
grayPanel = whiteui.tint(Pal.darkestGray);
|
||||
flatDown = createFlatDown();
|
||||
flatOver = whiteui.tint(Color.valueOf("454545"));
|
||||
accentDrawable = whiteui.tint(Pal.accent);
|
||||
@@ -144,6 +147,14 @@ public class Styles{
|
||||
down = flatOver;
|
||||
up = black;
|
||||
}};
|
||||
grayt = new TextButtonStyle(){{
|
||||
over = flatOver;
|
||||
font = Fonts.def;
|
||||
fontColor = Color.white;
|
||||
disabledFontColor = Color.lightGray;
|
||||
down = flatOver;
|
||||
up = grayPanel;
|
||||
}};
|
||||
logict = new TextButtonStyle(){{
|
||||
over = flatOver;
|
||||
font = Fonts.def;
|
||||
|
||||
@@ -40,7 +40,7 @@ public class CustomGameDialog extends BaseDialog{
|
||||
float images = 146f;
|
||||
|
||||
ImageButtonStyle style = new ImageButtonStyle(){{
|
||||
up = Styles.none;
|
||||
up = Styles.grayPanel;
|
||||
down = Styles.flatOver;
|
||||
over = Styles.flatOver;
|
||||
disabled = Styles.none;
|
||||
|
||||
@@ -103,7 +103,7 @@ public class LoadDialog extends BaseDialog{
|
||||
|
||||
any = true;
|
||||
|
||||
TextButton button = new TextButton("", Styles.flatt);
|
||||
TextButton button = new TextButton("", Styles.grayt);
|
||||
button.getLabel().remove();
|
||||
button.clearChildren();
|
||||
|
||||
|
||||
@@ -180,7 +180,7 @@ public class MapsDialog extends BaseDialog{
|
||||
mapTable.row();
|
||||
}
|
||||
|
||||
TextButton button = mapTable.button("", Styles.flatt, () -> showMapInfo(map)).width(mapsize).pad(8).get();
|
||||
TextButton button = mapTable.button("", Styles.grayt, () -> showMapInfo(map)).width(mapsize).pad(8).get();
|
||||
button.clearChildren();
|
||||
button.margin(9);
|
||||
button.add(map.name()).width(mapsize - 18f).center().get().setEllipsis(true);
|
||||
|
||||
Reference in New Issue
Block a user