]> git.mdlowis.com Git - projs/tide.git/commitdiff
tweaked monokai theme to match sublime more closely
authorMichael D. Lowis <mike.lowis@gentex.com>
Thu, 29 Jun 2017 18:53:59 +0000 (14:53 -0400)
committerMichael D. Lowis <mike.lowis@gentex.com>
Thu, 29 Jun 2017 18:53:59 +0000 (14:53 -0400)
lib/config.c
lib/view.c
themes/monokai

index 412522eb8faf01a3b4eba8b5a1b07df8e9928544..aa900a01ae5e0130bf5bac432767d112e8ac4795 100644 (file)
@@ -53,47 +53,46 @@ struct {
     [Color05] = { "tide.palette.05", INTEGER, { .num = 0xff93a1a1 } },
     [Color06] = { "tide.palette.06", INTEGER, { .num = 0xffeee8d5 } },
     [Color07] = { "tide.palette.07", INTEGER, { .num = 0xfffdf6e3 } },
-    [Color08] = { "tide.palette.08", INTEGER, { .num = 0xffdc322f } },
-    [Color09] = { "tide.palette.09", INTEGER, { .num = 0xffcb4b16 } },
-    [Color10] = { "tide.palette.10", INTEGER, { .num = 0xffb58900 } },
-    [Color11] = { "tide.palette.11", INTEGER, { .num = 0xff859900 } },
-    [Color12] = { "tide.palette.12", INTEGER, { .num = 0xff2aa198 } },
-    [Color13] = { "tide.palette.13", INTEGER, { .num = 0xff268bd2 } },
-    [Color14] = { "tide.palette.14", INTEGER, { .num = 0xff6c71c4 } },
-    [Color15] = { "tide.palette.15", INTEGER, { .num = 0xffd33682 } },
+    [Color08] = { "tide.palette.08", INTEGER, { .num = 0xffb58900 } }, // Yellow
+    [Color09] = { "tide.palette.09", INTEGER, { .num = 0xffcb4b16 } }, // Orange
+    [Color10] = { "tide.palette.10", INTEGER, { .num = 0xffdc322f } }, // Red
+    [Color11] = { "tide.palette.11", INTEGER, { .num = 0xffd33682 } }, // Magenta
+    [Color12] = { "tide.palette.12", INTEGER, { .num = 0xff6c71c4 } }, // Violet
+    [Color13] = { "tide.palette.13", INTEGER, { .num = 0xff268bd2 } }, // Blue
+    [Color14] = { "tide.palette.14", INTEGER, { .num = 0xff2aa198 } }, // Cyan
+    [Color15] = { "tide.palette.15", INTEGER, { .num = 0xff859900 } }, // Green
 
     /* UI Colors */
     [ClrScrollNor] = { "tide.colors.scroll.normal",   INTEGER, { .num = 0x0300 } },
-    [ClrGutterNor] = { "tide.colors.gutter.normal",   INTEGER, { .num = 0x0103 } },
-    [ClrGutterSel] = { "tide.colors.gutter.selected", INTEGER, { .num = 0x0D07 } },
+    [ClrGutterNor] = { "tide.colors.gutter.normal",   INTEGER, { .num = 0x0104 } },
+    [ClrGutterSel] = { "tide.colors.gutter.selected", INTEGER, { .num = 0x0207 } },
     [ClrStatusNor] = { "tide.colors.status.normal",   INTEGER, { .num = 0x0005 } },
     [ClrTagsNor]   = { "tide.colors.tags.normal",     INTEGER, { .num = 0x0105 } },
-    [ClrTagsSel]   = { "tide.colors.tags.selected",   INTEGER, { .num = 0x0501 } },
+    [ClrTagsSel]   = { "tide.colors.tags.selected",   INTEGER, { .num = 0x0205 } },
     [ClrTagsCsr]   = { "tide.colors.tags.cursor",     INTEGER, { .num = 0x07   } },
     [ClrEditNor]   = { "tide.colors.edit.normal",     INTEGER, { .num = 0x0005 } },
-    [ClrEditSel]   = { "tide.colors.edit.selected",   INTEGER, { .num = 0x0500 } },
+    [ClrEditSel]   = { "tide.colors.edit.selected",   INTEGER, { .num = 0x0205 } },
     [ClrEditCsr]   = { "tide.colors.edit.cursor",     INTEGER, { .num = 0x07   } },
     [ClrEditRul]   = { "tide.colors.edit.ruler",      INTEGER, { .num = 0x01   } },
     [ClrBorders]   = { "tide.colors.borders",         INTEGER, { .num = 0x0303 } },
 
     /* Syntax Colors */
-    [SynNormal]    = { "tide.colors.syntax.normal",       INTEGER, { .num = 0x0004 } },
+    [SynNormal]    = { "tide.colors.syntax.normal",       INTEGER, { .num = 0x0005 } },
     [SynComment]   = { "tide.colors.syntax.comment",      INTEGER, { .num = 0x0003 } },
-    [SynConstant]  = { "tide.colors.syntax.constant",     INTEGER, { .num = 0x000C } },
-    [SynString]    = { "tide.colors.syntax.string",       INTEGER, { .num = 0x000C } },
-    [SynChar]      = { "tide.colors.syntax.character",    INTEGER, { .num = 0x000C } },
-    [SynNumber]    = { "tide.colors.syntax.number",       INTEGER, { .num = 0x000C } },
-    [SynBoolean]   = { "tide.colors.syntax.boolean",      INTEGER, { .num = 0x000C } },
-    [SynFloat]     = { "tide.colors.syntax.float",        INTEGER, { .num = 0x000C } },
-
-    [SynVariable]  = { "tide.colors.syntax.variable",     INTEGER, { .num = 0x000D } },
-    [SynFunction]  = { "tide.colors.syntax.function",     INTEGER, { .num = 0x000D } },
-    [SynKeyword]   = { "tide.colors.syntax.keyword",      INTEGER, { .num = 0x000B } },
-    [SynOperator]  = { "tide.colors.syntax.operator",     INTEGER, { .num = 0x000A } },
+    [SynConstant]  = { "tide.colors.syntax.constant",     INTEGER, { .num = 0x000E } },
+    [SynNumber]    = { "tide.colors.syntax.number",       INTEGER, { .num = 0x000E } },
+    [SynBoolean]   = { "tide.colors.syntax.boolean",      INTEGER, { .num = 0x000E } },
+    [SynFloat]     = { "tide.colors.syntax.float",        INTEGER, { .num = 0x000E } },
+    [SynString]    = { "tide.colors.syntax.string",       INTEGER, { .num = 0x000E } },
+    [SynChar]      = { "tide.colors.syntax.character",    INTEGER, { .num = 0x000E } },
     [SynPreProc]   = { "tide.colors.syntax.preprocessor", INTEGER, { .num = 0x0009 } },
-    [SynType]      = { "tide.colors.syntax.type",         INTEGER, { .num = 0x000A } },
-    [SynStatement] = { "tide.colors.syntax.statement",    INTEGER, { .num = 0x000F } },
-    [SynSpecial]   = { "tide.colors.syntax.special",      INTEGER, { .num = 0x000A } },
+    [SynType]      = { "tide.colors.syntax.type",         INTEGER, { .num = 0x0008 } },
+    [SynKeyword]   = { "tide.colors.syntax.keyword",      INTEGER, { .num = 0x000F } },
+    [SynStatement] = { "tide.colors.syntax.statement",    INTEGER, { .num = 0x000A } },
+    [SynFunction]  = { "tide.colors.syntax.function",     INTEGER, { .num = 0x000B } },
+    [SynVariable]  = { "tide.colors.syntax.variable",     INTEGER, { .num = 0x000C } },
+    [SynSpecial]   = { "tide.colors.syntax.special",      INTEGER, { .num = 0x000D } },
+    [SynOperator]  = { "tide.colors.syntax.operator",     INTEGER, { .num = 0x000C } },
 };
 
 void config_init(void* disp) {
index f34451a85f5d413adbb155eae6588ee525ee5690..d7104a212fd9837e3b71f637a5a4c70aa45aecf4 100644 (file)
@@ -699,7 +699,7 @@ static void apply_colors(View* view) {
             if (!curr) { r = -1; break; } // Break both loops if we're done
 
             /* check if we're in the current region */
-            if (curr->beg <= off && off <= curr->end && !(row->cols[col].attr & 0xFF00)) {
+            if (curr->beg <= off && off <= curr->end) {
                 uint32_t attr = row->cols[col].attr;
                 row->cols[col].attr = (row->cols[col].attr & 0xFF00) | curr->color;
             }
index 2b5797a0c466f3b66c4e1386f54f0f29ada871c6..bd830037032b490c976b332fdc3c177866f6fe39 100644 (file)
@@ -1,21 +1,37 @@
 !-------------------------------------------------------------------------------
-! Monokai
+! Monokai - Based on default scheme for Sublime Text
 !-------------------------------------------------------------------------------
-
 ! 16-color Palette Definition
-tide.palette.00: 0xff272822 ! base00 - Default Background
-tide.palette.01: 0xff383830 ! base01 - Lighter Background (Used for status bars)
-tide.palette.02: 0xff49483e ! base02 - Selection Background
-tide.palette.03: 0xff75715e ! base03 - Comments, Invisibles, Line Highlighting
-tide.palette.04: 0xffa59f85 ! base04 - Dark Foreground (Used for status bars)
-tide.palette.05: 0xfff8f8f2 ! base05 - Default Foreground, Caret, Delimiters, Operators
-tide.palette.06: 0xfff5f4f1 ! base06 - Light Foreground (Not often used)
-tide.palette.07: 0xfff9f8f5 ! base07 - Light Background (Not often used)
-tide.palette.08: 0xfff92672 ! base08 - Variables, Diff Deleted
-tide.palette.09: 0xfffd971f ! base09 - Integers, Boolean, Constants
-tide.palette.10: 0xfff4bf75 ! base0A - Classes, Markup Bold, Search Text Background
-tide.palette.11: 0xffa6e22e ! base0B - Strings, Inherited Class, Markup Code, Diff Inserted
-tide.palette.12: 0xffa1efe4 ! base0C - Support, Regular Expressions, Escape Characters, Markup Quotes
-tide.palette.13: 0xff66d9ef ! base0D - Functions, Methods, Attribute IDs, Headings
-tide.palette.14: 0xffae81ff ! base0E - Keywords, Storage, Selector, Markup Italic, Diff Changed
-tide.palette.15: 0xffcc6633 ! base0F - Deprecated, Opening/Closing Embedded Language Tags e.g.
+tide.palette.00: 0xff272822
+tide.palette.01: 0xff383830
+tide.palette.02: 0xff49483e
+tide.palette.03: 0xff75715e
+tide.palette.04: 0xffa59f85
+tide.palette.05: 0xfff8f8f2
+tide.palette.06: 0xfff5f4f1
+tide.palette.07: 0xfff9f8f5
+tide.palette.08: 0xfff92672
+tide.palette.09: 0xfffd971f
+tide.palette.10: 0xffCEC56A
+tide.palette.11: 0xffa7a059
+tide.palette.12: 0xffa1efe4
+tide.palette.13: 0xff66d9ef
+tide.palette.14: 0xffae81ff
+tide.palette.15: 0xffcc6633
+
+tide.colors.syntax.normal:       0x0005
+tide.colors.syntax.comment:      0x0003
+tide.colors.syntax.preprocessor: 0x0008
+tide.colors.syntax.keyword:      0x0008
+tide.colors.syntax.type:         0x000D
+tide.colors.syntax.constant:     0x000E
+tide.colors.syntax.number:       0x000E
+tide.colors.syntax.boolean:      0x000E
+tide.colors.syntax.float:        0x000E
+tide.colors.syntax.string:       0x000A
+tide.colors.syntax.character:    0x000A
+tide.colors.syntax.variable:     0x0008
+tide.colors.syntax.operator:     0x000C
+tide.colors.syntax.function:     0x000D
+tide.colors.syntax.statement:    0x000F
+tide.colors.syntax.special:      0x000F