base16-custom-dark.lua 4.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. -- Base16 Theme: Default Dark
  2. -- http://chriskempson.com/projects/base16/
  3. -- Theme author: Chris Kempson (http://chriskempson.com)
  4. -- Template Repository: https://github.com/rgieseke/base16-textadept
  5. -- Template adapted from Textadept's default templates
  6. -- Copyright 2007-2020 Mitchell mitchell.att.foicica.com. MIT licensed.
  7. -- Original from: https://raw.githubusercontent.com/rgieseke/base16-textadept/master/themes/base16-default-dark.lua
  8. local view, colors, styles = view, lexer.colors, lexer.styles
  9. -- Base16 colors
  10. colors.base00 = 0x222827 -- * default background [all bg except current line hightlight]
  11. colors.base01 = 0x252B2A -- * embedded/edge color [current line bg/php tag bg]
  12. colors.base02 = 0x8A9090 -- line number/call tip
  13. colors.base03 = 0x585858 -- * comment
  14. colors.base04 = 0xb8b8b8
  15. colors.base05 = 0xd8d8d8 -- operator
  16. colors.base0G = 0x7226F9 -- real operator
  17. colors.base06 = 0xe8e8e8
  18. colors.base07 = 0xf8f8f8 -- caret color
  19. colors.base08 = 0xF2F8F8 -- error/variable/brace bad/diff red
  20. colors.base09 = 0xFF81AE -- constant/number/type
  21. colors.base0A = 0x88caf7 -- class/label/preprocessor
  22. colors.base0B = 0x74DBE6 -- * string
  23. colors.base0C = 0xb9c186 -- regex/bracelight
  24. colors.base0D = 0xc2af7c -- bookmark
  25. colors.base0E = 0x7226F9 -- * function/keyword
  26. colors.base0F = 0x4669a1 -- embedded
  27. colors.base0H = 0xEFD966 -- FUNC_IDENTIFIERS
  28. colors.base0I = 0x0000ff -- php_tag
  29. colors.base0J = 0x2EE2A6 -- function names, green
  30. -- Default font.
  31. if not font then
  32. font = WIN32 and 'Consolas' or OSX and 'Menlo-Regular' or
  33. 'Monospace'
  34. end
  35. if not size then size = not OSX and 10 or 12 end
  36. -- Predefined styles.
  37. styles.default = {
  38. font = font, size = size, fore = colors.base05, back = colors.base00
  39. }
  40. styles.line_number = {fore = colors.base04, back = colors.base00}
  41. --styles.control_char =
  42. styles.indent_guide = {fore = colors.base03}
  43. styles.call_tip = {fore = colors.base04, back = colors.base01}
  44. styles.fold_display_text = {fore = colors.base01}
  45. -- Token styles.
  46. styles.class = {fore = colors.base0A}
  47. styles.comment = {fore = colors.base03}
  48. styles.constant = {fore = colors.base09}
  49. styles.embedded = {fore = colors.base0F, back = colors.base01}
  50. styles.error = {fore = colors.base08, italics = true}
  51. styles['function'] = {fore = colors.base0D}
  52. styles.identifier = {}
  53. styles.keyword = {fore = colors.base0E}
  54. styles.label = {fore = colors.base08}
  55. styles.number = {fore = colors.base09}
  56. styles.operator = {fore = colors.base0G}
  57. styles.preprocessor = {fore = colors.base0B}
  58. styles.regex = {fore = colors.base0C}
  59. styles.string = {fore = colors.base0B}
  60. styles.type = {fore = colors.base0A}
  61. styles.variable = {fore = colors.base08}
  62. styles.whitespace = {}
  63. -- Custom additions
  64. styles.php_tag = {fore = colors.base0I}
  65. styles.func_tags = {fore = colors.base0H}
  66. styles.func_head_names = {fore = colors.base0J} -- function function_head_names(...
  67. styles.special_tags = {fore = colors.base0H, italics = true} -- class, function etc.
  68. -- Multiple Selection and Virtual Space
  69. --view.additional_sel_alpha =
  70. --view.additional_sel_fore =
  71. --view.additional_sel_back =
  72. --view.additional_caret_fore =
  73. -- Caret and Selection Styles.
  74. view:set_sel_fore(true, colors.base06)
  75. view:set_sel_back(true, colors.base02)
  76. --view.sel_alpha =
  77. view.caret_fore = colors.base05
  78. view.caret_line_back = colors.base01
  79. --view.caret_line_back_alpha =
  80. -- Fold Margin.
  81. view:set_fold_margin_color(true, colors.base00)
  82. view:set_fold_margin_hi_color(true, colors.base00)
  83. -- Markers.
  84. --view.marker_fore[textadept.bookmarks.MARK_BOOKMARK] = colors.base00
  85. view.marker_back[textadept.bookmarks.MARK_BOOKMARK] = colors.base0B
  86. --view.marker_fore[textadept.run.MARK_WARNING] = colors.base00
  87. view.marker_back[textadept.run.MARK_WARNING] = colors.base0E
  88. --view.marker_fore[textadept.run.MARK_ERROR] = colors.base00
  89. view.marker_back[textadept.run.MARK_ERROR] = colors.base08
  90. for i = view.MARKNUM_FOLDEREND, view.MARKNUM_FOLDEROPEN do -- fold margin
  91. view.marker_fore[i] = colors.base00
  92. view.marker_back[i] = colors.base03
  93. view.marker_back_selected[i] = colors.base02
  94. end
  95. -- Indicators.
  96. view.indic_fore[ui.find.INDIC_FIND] = colors.base09
  97. view.indic_alpha[ui.find.INDIC_FIND] = 255
  98. view.indic_fore[textadept.editing.INDIC_BRACEMATCH] = colors.base06
  99. view.indic_fore[textadept.editing.INDIC_HIGHLIGHT] = colors.base07
  100. view.indic_alpha[textadept.editing.INDIC_HIGHLIGHT] = 64
  101. view.indic_fore[textadept.snippets.INDIC_PLACEHOLDER] = colors.base04
  102. -- Call tips.
  103. view.call_tip_fore_hlt = colors.base06
  104. -- Long Lines.
  105. view.edge_color = colors.base02
  106. -- Add red, green, and yellow for diff lexer.
  107. colors.red = colors.base08
  108. colors.green = colors.base0B
  109. colors.yellow = colors.base0E