Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorMarco Pesenti Gritti <marco@localhost.localdomain>2006-09-08 13:09:10 (GMT)
committer Marco Pesenti Gritti <marco@localhost.localdomain>2006-09-08 13:09:10 (GMT)
commit233051875b0eb7466612156fbe7c5d7b33e6ddc4 (patch)
treea97f24500348e742eb6cccfb990f66b68362a8f8 /tools
parent2a2554f157d977efb182e55bb71e5c38d4ae4263 (diff)
Bring around both colors, since multiple combinations can have
the same base color.
Diffstat (limited to 'tools')
-rwxr-xr-xtools/hex-colors-to-dict7
1 files changed, 3 insertions, 4 deletions
diff --git a/tools/hex-colors-to-dict b/tools/hex-colors-to-dict
index 68073ab..babb483 100755
--- a/tools/hex-colors-to-dict
+++ b/tools/hex-colors-to-dict
@@ -2,16 +2,15 @@
import sys
-result = 'table = {\n'
-result += '\'white\' : \'black\' , \\\n'
+result = 'colors = [\n'
hex_file = open(sys.argv[1], 'r')
for line in hex_file.readlines():
[ stroke, fill ] = line.split()
- result += '\'#%s\' : \'#%s\', \\\n' % (fill, stroke)
+ result += '[\'#%s\', \'#%s\'], \\\n' % (fill, stroke)
-result += '}'
+result += ']'
hex_file.close()