├── close-to-the-sea-colour-example.png ├── extract_colours.rb ├── README ├── ruby_syntax_color_example.rb └── close_to_the_sea.tmTheme /close-to-the-sea-colour-example.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/s2k/Close-to-the-Sea/HEAD/close-to-the-sea-colour-example.png -------------------------------------------------------------------------------- /extract_colours.rb: -------------------------------------------------------------------------------- 1 | require 'nokogiri' 2 | require 'ap' 3 | 4 | fn = 'close_to_the_sea.tmTheme' 5 | 6 | hex_dgt = /[0-9a-fA-F]/ 7 | 8 | doc = Nokogiri::XML( open fn ) 9 | 10 | hex_vals = (doc / '//dict/array/dict/dict/string/text()').map{ | e | 11 | r = e.text.match(/#(#{ hex_dgt }+)/) 12 | r ? r[1] : nil 13 | }.compact.sort 14 | 15 | dec_vals = hex_vals.map{ | e | 16 | cols = e.scan( /#{ hex_dgt }{2,2}/ ).map{ | i | '%03d' % i.to_i( 16 )}.join(' ') 17 | "#{e}: #{cols}" 18 | } 19 | 20 | puts dec_vals -------------------------------------------------------------------------------- /README: -------------------------------------------------------------------------------- 1 | Close to the Sea 2 | 3 | A TextMate Colour Scheme 4 | 5 | See http://wiki.macromates.com/Themes/UserSubmittedThemes how to install a new colour scheme on your Mac. 6 | 7 | # Where do these colours come from and why this theme name? 8 | 9 | I live close the the sea and I love it. The colours in the thema come from photos I shot at the sea side. 10 | 11 | 12 | License: 13 | 14 | Creative Commons Attribution-NonCommercial-ShareAlike 15 | Also see http://creativecommons.org/licenses/by-nc-sa/3.0/ 16 | 17 | -------------------------------------------------------------------------------- /ruby_syntax_color_example.rb: -------------------------------------------------------------------------------- 1 | # encoding: UTF-8 2 | require 'pp' 3 | 4 | include Math 5 | 6 | CONSTANT_VALUE = "CONST" 7 | alpha = ( Math::PI / 0.25 ) ** 0.5 8 | 9 | class Ancestor 10 | def self.method_in_the_class a_thing, and_another 11 | end 12 | end 13 | 14 | class Inheritee < Ancestor 15 | method_in_the_class :foo, :bar 16 | def a_method args 17 | ap args 18 | end 19 | end 20 | 21 | puts `ls -la` 22 | 23 | @instance_variable = CONSTANT_VALUE 24 | a_variable = Math::PI * sin( alpha ** 2 ) 25 | foo = [ :bar_symbol, "is_green" + ' but can be blue as well' ] 26 | a_number = { :sum => 8787495 + 2543.4523e7, 'hex_val' => 0xfe4 } 27 | match = "somethingthatlook...likeasrting".match( /o.+gt(hat.*\.+).+eas.+$/ ) 28 | 29 | puts match.inspect, true, false 30 | 31 | notthat_long = <<-END 32 | A line 33 | and another 34 | END 35 | 36 | as_short = < 2 | 3 | 4 | 5 | name 6 | Close to the Sea 7 | settings 8 | 9 | 10 | settings 11 | 12 | background 13 | #172024 14 | caret 15 | #FFFFFF 16 | foreground 17 | #FFFFFA 18 | invisibles 19 | #FAFAF5 20 | lineHighlight 21 | #00000012 22 | selection 23 | #B5A9AD 24 | 25 | 26 | 27 | name 28 | Comment 29 | scope 30 | comment 31 | settings 32 | 33 | fontStyle 34 | italic 35 | foreground 36 | #78B2C7 37 | 38 | 39 | 40 | name 41 | String 42 | scope 43 | string 44 | settings 45 | 46 | fontStyle 47 | 48 | foreground 49 | #3A81C8 50 | 51 | 52 | 53 | name 54 | Number 55 | scope 56 | constant.numeric 57 | settings 58 | 59 | foreground 60 | #B8252A 61 | 62 | 63 | 64 | name 65 | Built-in constant 66 | scope 67 | constant.language 68 | settings 69 | 70 | fontStyle 71 | 72 | 73 | 74 | 75 | name 76 | Symbols 77 | scope 78 | constant.character, constant.other 79 | settings 80 | 81 | fontStyle 82 | 83 | foreground 84 | #AED4DC 85 | 86 | 87 | 88 | name 89 | Variable 90 | scope 91 | variable.language, variable.other 92 | settings 93 | 94 | fontStyle 95 | 96 | foreground 97 | #D0BFAF 98 | 99 | 100 | 101 | name 102 | Keyword 103 | scope 104 | keyword 105 | settings 106 | 107 | fontStyle 108 | bold 109 | foreground 110 | #5F919A 111 | 112 | 113 | 114 | name 115 | Storage 116 | scope 117 | storage 118 | settings 119 | 120 | fontStyle 121 | 122 | foreground 123 | #FFFFFA 124 | 125 | 126 | 127 | name 128 | Class name 129 | scope 130 | entity.name.class 131 | settings 132 | 133 | fontStyle 134 | 135 | foreground 136 | #FFFFFF 137 | 138 | 139 | 140 | name 141 | Inherited class 142 | scope 143 | entity.other.inherited-class 144 | settings 145 | 146 | fontStyle 147 | 148 | foreground 149 | #BC681E 150 | 151 | 152 | 153 | name 154 | Function name 155 | scope 156 | entity.name.function 157 | settings 158 | 159 | fontStyle 160 | 161 | foreground 162 | #EA511B 163 | 164 | 165 | 166 | name 167 | Function argument 168 | scope 169 | variable.parameter 170 | settings 171 | 172 | fontStyle 173 | 174 | foreground 175 | #C0EFFE 176 | 177 | 178 | 179 | name 180 | Tag name 181 | scope 182 | entity.name.tag 183 | settings 184 | 185 | 186 | 187 | name 188 | Tag attribute 189 | scope 190 | entity.other.attribute-name 191 | settings 192 | 193 | 194 | 195 | name 196 | Library function 197 | scope 198 | support.function 199 | settings 200 | 201 | fontStyle 202 | 203 | foreground 204 | #E1DA69 205 | 206 | 207 | 208 | name 209 | Library constant 210 | scope 211 | support.constant 212 | settings 213 | 214 | foreground 215 | #FF005C 216 | 217 | 218 | 219 | name 220 | Library class/type 221 | scope 222 | support.type, support.class 223 | settings 224 | 225 | fontStyle 226 | 227 | foreground 228 | #54BA42 229 | 230 | 231 | 232 | name 233 | Library variable 234 | scope 235 | support.other.variable 236 | settings 237 | 238 | foreground 239 | #FFFFFA 240 | 241 | 242 | 243 | name 244 | Invalid 245 | scope 246 | invalid 247 | settings 248 | 249 | 250 | 251 | uuid 252 | 3F59E097-7058-4272-830D-B05CCD1DCF06 253 | 254 | 255 | --------------------------------------------------------------------------------