Advertisement
killerbng

color dicts

Mar 18th, 2015
309
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 2.73 KB | None | 0 0
  1. hex = dict(
  2.     #General
  3.     blue="#0000ff",
  4.     green="#008000",
  5.     grey="#808080",
  6.     #Hair
  7.     blonde="#eedec4",
  8.     angel_blonde="#b3a393",
  9.     brunette="#774812",
  10.     blonde_brunette_mix="#7c664f",
  11.     medium_brown="#6b3e2b",
  12.     light_brown="#b68366",
  13.     golden_brown="#d99d55",#Anya Golden Brown :)
  14.     #Eyes
  15.     hazel="#594c26",
  16.     anya_gray="#b6b1b1",
  17.     anya_grey_blue="#cce7ee",
  18.     anya_grey_blue2="#c1d5e1",
  19.     darkslategray="#28312f",
  20.     #Misc
  21.     pink_orange="#F68",
  22.     ligher_purple="#C09",
  23.     lips="#f08b83"
  24. )
  25.  
  26. rgb = dict(
  27.     #General
  28.     blue=(0,0,255),
  29.     white=(255,255,255),
  30.     black=(0,0,0),
  31.     red=(255,0,0),
  32.     green=(0,255,0),
  33.     dark_green=(0,155,0),
  34.     redHalf=(255,0,0,0.5),
  35.     greyLight=(204,204,204),
  36.     greyMed=(102,102,102),
  37.     greyDark=(50,50,50),
  38.     pink=(255,20,147),
  39.     #Hair Colors
  40.     saddle_brown=(107,62,43),
  41.     light_brown=(182,131,102),
  42.     blonde=(238,222,196),
  43.     angel_blonde=(179,163,147),
  44.     brunette=(119,72,18),
  45.     blonde_brunette_mix=(124,102,79),
  46.     golden_brown=(217,157,85),
  47.     #Eyes Colors
  48.     hazel=(89,76,38),
  49.     anya_grey=(182,177,177),
  50.     anya_grey_blue=(204,231,238),
  51.     anya_grey_blue2=(193,213,225),
  52.     grey_eyes=(128,128,128),
  53.     darkslategray=(40,49,47),
  54.     green_eyes=(0,128,0),
  55.     #Misc
  56.     pinkish_orange=(255,102,136),
  57.     lighter_purple=(204,0,153),
  58.     lips=(240,139,131)
  59. )
  60.  
  61. hs1 = dict(
  62.    #General
  63.     blue=(240,100,50),
  64.     green=(120,100,25),
  65.     grey=(0,0,50),
  66.     #Hair Colors
  67.     saddle_brown=(17,42,29),
  68.     light_brown=(21,35,55),
  69.     blonde=(37,55,85),
  70.     angel_blonde=(30,17,63),
  71.     brunette=(32,73,26),
  72.     blonde_brunette_mix=(0,22,39),
  73.     golden_brown=(32,63,59),
  74.     #Eyes Colors
  75.     hazel=(44,40,24),
  76.     anya_grey=(0,3,70),
  77.     anya_grey_blue=(192,50,86),
  78.     anya_grey_blue2=(202,34,81),
  79.     darkslategray=(166,10,17),
  80.     #Misc
  81.     pinkish_orange=(346,100,70),
  82.     lighter_purple=(315,100,40),
  83.     lips=(4,78,72)
  84. )
  85.  
  86. x11 = dict(
  87.  
  88. )
  89.  
  90. def hex_to_rgb(value):#Credit to Jeremy Cantrell
  91.     value = value.lstrip('#')
  92.     lv = len(value)
  93.     if lv == 1:
  94.         v = int(value, 16)*17
  95.         return v, v, v
  96.     if lv == 3:
  97.         return tuple(int(value[i:i+1], 16)*17 for i in range(0, 3))
  98.     return tuple(int(value[i:i + lv // 3], 16) for i in range(0, lv, lv // 3))
  99.  
  100. def rgb_to_hex(rgb):#Credit to Jeremy Cantrell
  101.     return '#%02x%02x%02x' % rgb
  102.  
  103. #Test
  104. #print(str(hex["blue"]))
  105. #print(str(rgb["blue"]))
  106. #print(str(hs1["blue"]))
  107. #print(str(hex_to_rgb("#f")))
  108. #print(str(hex_to_rgb("#fff")))
  109. #print(str(rgb_to_hex(rgb["lips"])))
  110. #print(str(rgb_to_hex((255, 255, 255))))
  111.  
  112.  
  113. """
  114. SOME OTHER EYE COLORS
  115. 887765
  116. 82745a
  117. a6a390  #THIS is a nice grey for eye colors
  118. """
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement