From 0c49023bbfab0c0c844f161b845017a81a39fe63 Mon Sep 17 00:00:00 2001 From: Oliver Jan Krylow Date: Mon, 8 May 2017 19:22:23 +0200 Subject: [PATCH] Added Solarized Light theme. --- android/assets/themes/solarized-dark.theme | 36 +++++++++---------- android/assets/themes/solarized-light.theme | 26 ++++++++++++++ android/assets/themes/theme.list | 2 ++ .../io/github/lonamiwebs/klooni/Theme.java | 5 ++- .../lonamiwebs/klooni/game/BaseScorer.java | 2 +- 5 files changed, 49 insertions(+), 22 deletions(-) create mode 100644 android/assets/themes/solarized-light.theme diff --git a/android/assets/themes/solarized-dark.theme b/android/assets/themes/solarized-dark.theme index 6f27107..7658374 100644 --- a/android/assets/themes/solarized-dark.theme +++ b/android/assets/themes/solarized-dark.theme @@ -1,26 +1,26 @@ { - "name": "Underwater", - "price": 50, + "name": "Solarized Dark", + "price": 0, "colors": { - "background": "0044aaff", - "foreground": "d7f4e3ff", + "background": "002b36ff", + "foreground": "fdf6e3ff", "buttons": [ - "37c871ff", - "2a7fffff", - "00ccffff", - "5f5fd3ff" + "859900ff", + "268bd2ff", + "d33682ff", + "cb4b16ff" ], - "empty_cell": "0066ffff", + "empty_cell": "073642ff", "cells": [ - "37c871ff", "2ad4ffff", "0000d4ff", - "00ffccff", "5599ffff", "87cddeff", "80b3ffff", - "00ff66ff", "00d4aaff" + "657b83ff", "b58900ff", "cb4b16ff", + "dc322fff", "d33682ff", "6c71c4ff", "268bd2ff", + "2aa198ff", "859900ff" ], - "current_score": "aaccffff", - "high_score": "2aff80ff", - "bonus": "aaeeffff", - "band": "3771c8ff", - "text": "002255ff" + "current_score": "586e75ff", + "high_score": "eee8d5ff", + "bonus": "586e75ff", + "band": "2aa198ff", + "text": "fdf6e3ff" }, - "cell_texture": "bubble.png" + "cell_texture": "circle.png" } diff --git a/android/assets/themes/solarized-light.theme b/android/assets/themes/solarized-light.theme new file mode 100644 index 0000000..815b198 --- /dev/null +++ b/android/assets/themes/solarized-light.theme @@ -0,0 +1,26 @@ +{ + "name": "Solarized Light", + "price": 0, + "colors": { + "background": "fdf6e3ff", + "foreground": "002b36ff", + "buttons": [ + "859900ff", + "268bd2ff", + "d33682ff", + "cb4b16ff" + ], + "empty_cell": "eee8d5ff", + "cells": [ + "657b83ff", "b58900ff", "cb4b16ff", + "dc322fff", "d33682ff", "6c71c4ff", "268bd2ff", + "2aa198ff", "859900ff" + ], + "current_score": "586e75ff", + "high_score": "eee8d5ff", + "bonus": "586e75ff", + "band": "b58900ff", + "text": "002b36ff" + }, + "cell_texture": "circle.png" +} diff --git a/android/assets/themes/theme.list b/android/assets/themes/theme.list index 8ffea23..7fbc883 100644 --- a/android/assets/themes/theme.list +++ b/android/assets/themes/theme.list @@ -2,3 +2,5 @@ default dark bandw underwater +solarized-dark +solarized-light diff --git a/core/src/io/github/lonamiwebs/klooni/Theme.java b/core/src/io/github/lonamiwebs/klooni/Theme.java index d366851..f15a83f 100644 --- a/core/src/io/github/lonamiwebs/klooni/Theme.java +++ b/core/src/io/github/lonamiwebs/klooni/Theme.java @@ -25,7 +25,7 @@ public class Theme { public Color background; public Color foreground; - public Color emptyCell; + private Color emptyCell; public Color currentScore; public Color highScore; @@ -34,7 +34,6 @@ public class Theme { public Color textColor; private Color[] cells; - private Color[] buttons; public static Skin skin; @@ -126,7 +125,7 @@ public class Theme { foreground = new Color((int)Long.parseLong(colors.getString("foreground"), 16)); JsonValue buttonColors = colors.get("buttons"); - buttons = new Color[buttonColors.size]; + Color[] buttons = new Color[buttonColors.size]; for (int i = 0; i < buttons.length; ++i) { buttons[i] = new Color((int)Long.parseLong(buttonColors.getString(i), 16)); if (buttonStyles[i] == null) { diff --git a/core/src/io/github/lonamiwebs/klooni/game/BaseScorer.java b/core/src/io/github/lonamiwebs/klooni/game/BaseScorer.java index c5017a6..8e5213c 100644 --- a/core/src/io/github/lonamiwebs/klooni/game/BaseScorer.java +++ b/core/src/io/github/lonamiwebs/klooni/game/BaseScorer.java @@ -18,7 +18,7 @@ public abstract class BaseScorer implements BinSerializable { //region Members - protected int currentScore; + int currentScore; final Label currentScoreLabel; final Label highScoreLabel;