aboutsummaryrefslogtreecommitdiff
path: root/themes/dark
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2013-05-15 17:00:50 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2013-05-15 17:00:50 -0400
commitd042865f672d6708df80250c9c59172148a55f11 (patch)
treea9c38372853d202d843564ebff9c6eeee60b88fb /themes/dark
parente2767cd40f0994ea97cb91fb9e9ceef58b8f3342 (diff)
downloadtextadept-d042865f672d6708df80250c9c59172148a55f11.tar.gz
textadept-d042865f672d6708df80250c9c59172148a55f11.zip
Rewrote theme implementation.
Themes are now just single files that share Textadept's Lua state. Also added a new "settings.lua" that functions in place of buffer and view theme files. Requires latest Scintillua.
Diffstat (limited to 'themes/dark')
-rw-r--r--themes/dark/buffer.lua16
-rw-r--r--themes/dark/lexer.lua100
-rw-r--r--themes/dark/view.lua124
3 files changed, 0 insertions, 240 deletions
diff --git a/themes/dark/buffer.lua b/themes/dark/buffer.lua
deleted file mode 100644
index 2dfa07b2..00000000
--- a/themes/dark/buffer.lua
+++ /dev/null
@@ -1,16 +0,0 @@
--- Copyright 2007-2013 Mitchell mitchell.att.foicica.com. See LICENSE.
--- Dark editor theme for Textadept.
-
-local buffer = buffer
-
--- Folding.
-buffer.property['fold'] = '1'
-buffer.property['fold.by.indentation'] = '1'
-buffer.property['fold.line.comments'] = '0'
-
--- Tabs and Indentation.
-buffer.tab_width = 2
-buffer.use_tabs = false
---buffer.indent = 2
-buffer.tab_indents = true
-buffer.back_space_un_indents = true
diff --git a/themes/dark/lexer.lua b/themes/dark/lexer.lua
deleted file mode 100644
index 4824fb8c..00000000
--- a/themes/dark/lexer.lua
+++ /dev/null
@@ -1,100 +0,0 @@
--- Copyright 2007-2013 Mitchell mitchell.att.foicica.com. See LICENSE.
--- Dark lexer theme for Textadept.
--- Contributions by Ana Balan.
-
--- Please note this theme is in a separate Lua state than Textadept's main one.
--- This means the global variables like 'buffer', 'view', and 'gui' are not
--- available here. Only the variables in the 'lexer' module are.
-
-local l, color, style = lexer, lexer.color, lexer.style
-
-l.colors = {
- -- Greyscale colors.
---dark_black = color('00', '00', '00'),
- black = color('1A', '1A', '1A'),
- light_black = color('33', '33', '33'),
- -- color('4D', '4D', '4D'),
- dark_grey = color('66', '66', '66'),
---grey = color('80', '80', '80'),
- light_grey = color('99', '99', '99'),
- -- color('B3', 'B3', 'B3'),
- dark_white = color('CC', 'CC', 'CC'),
---white = color('E6', 'E6', 'E6'),
---light_white = color('FF', 'FF', 'FF'),
-
- -- Dark colors.
---dark_red = color('66', '1A', '1A'),
---dark_yellow = color('66', '66', '1A'),
---dark_green = color('1A', '66', '1A'),
---dark_teal = color('1A', '66', '66'),
---dark_purple = color('66', '1A', '66'),
---dark_orange = color('B3', '66', '1A'),
---dark_pink = color('B3', '66', '66'),
---dark_lavender = color('66', '66', 'B3'),
---dark_blue = color('1A', '66', 'B3'),
-
- -- Normal colors.
- red = color('99', '4D', '4D'),
- yellow = color('99', '99', '4D'),
- green = color('4D', '99', '4D'),
- teal = color('4D', '99', '99'),
- purple = color('99', '4D', '99'),
- orange = color('E6', '99', '4D'),
---pink = color('E6', '99', '99'),
- lavender = color('99', '99', 'E6'),
- blue = color('4D', '99', 'E6'),
-
- -- Light colors.
- light_red = color('CC', '80', '80'),
- light_yellow = color('CC', 'CC', '80'),
- light_green = color('80', 'CC', '80'),
---light_teal = color('80', 'CC', 'CC'),
---light_purple = color('CC', '80', 'CC'),
---light_orange = color('FF', 'CC', '80'),
---light_pink = color('FF', 'CC', 'CC'),
---light_lavender = color('CC', 'CC', 'FF'),
- light_blue = color('80', 'CC', 'FF'),
-}
-
-l.style_nothing = style{ }
-l.style_class = style{fore = l.colors.light_yellow }
-l.style_comment = style{fore = l.colors.dark_grey }
-l.style_constant = style{fore = l.colors.red }
-l.style_definition = style{fore = l.colors.light_yellow }
-l.style_error = style{fore = l.colors.red, italic = true}
-l.style_function = style{fore = l.colors.blue }
-l.style_keyword = style{fore = l.colors.dark_white }
-l.style_label = style{fore = l.colors.orange }
-l.style_number = style{fore = l.colors.teal }
-l.style_operator = style{fore = l.colors.yellow }
-l.style_regex = style{fore = l.colors.light_green }
-l.style_string = style{fore = l.colors.green }
-l.style_preproc = style{fore = l.colors.purple }
-l.style_tag = style{fore = l.colors.dark_white }
-l.style_type = style{fore = l.colors.lavender }
-l.style_variable = style{fore = l.colors.light_blue }
-l.style_whitespace = style{ }
-l.style_embedded = l.style_tag..{back = l.colors.light_black}
-l.style_identifier = l.style_nothing
-
--- Default styles.
-local font_face = 'Bitstream Vera Sans Mono'
-local font_size = 10
-if WIN32 then
- font_face = 'Courier New'
-elseif OSX then
- font_face = 'Monaco'
- font_size = 12
-end
-l.style_default = style{
- font = font_face, size = font_size,
- fore = l.colors.light_grey, back = l.colors.black
-}
-l.style_line_number = style{fore = l.colors.dark_grey, back = l.colors.black}
-l.style_bracelight = style{fore = l.colors.light_blue}
-l.style_bracebad = style{fore = l.colors.light_red}
-l.style_controlchar = l.style_nothing
-l.style_indentguide = style{
- fore = l.colors.light_black, back = l.colors.light_black
-}
-l.style_calltip = style{fore = l.colors.light_grey, back = l.colors.light_black}
diff --git a/themes/dark/view.lua b/themes/dark/view.lua
deleted file mode 100644
index 76170b12..00000000
--- a/themes/dark/view.lua
+++ /dev/null
@@ -1,124 +0,0 @@
--- Copyright 2007-2013 Mitchell mitchell.att.foicica.com. See LICENSE.
--- Dark editor theme for Textadept.
-
-local c = _SCINTILLA.constants
-local buffer = buffer
-
--- Multiple Selection and Virtual Space
-buffer.multiple_selection = true
-buffer.additional_selection_typing = true
---buffer.multi_paste = c.SC_MULTIPASTE_EACH
---buffer.virtual_space_options = c.SCVS_RECTANGULARSELECTION +
--- c.SCVS_USERACCESSIBLE
-buffer.rectangular_selection_modifier = (WIN32 or OSX) and c.SCMOD_ALT or
- c.SCMOD_SUPER
---buffer.additional_sel_alpha =
---buffer.additional_sel_fore =
---buffer.additional_sel_back =
---buffer.additional_caret_fore =
---buffer.additional_carets_blink = false
---buffer.additional_carets_visible = false
-
--- Scrolling.
-buffer:set_x_caret_policy(1, 20) -- CARET_SLOP
-buffer:set_y_caret_policy(13, 1) -- CARET_SLOP | CARET_STRICT | CARET_EVEN
---buffer:set_visible_policy()
---buffer.h_scroll_bar = false
---buffer.v_scroll_bar = false
---buffer.x_offset =
---buffer.scroll_width =
---buffer.scroll_width_tracking = true
---buffer.end_at_last_line = false
-
--- Whitespace
---buffer.view_ws = c.SCWS_VISIBLEALWAYS
---buffer.whitespace_size =
---buffer.extra_ascent =
---buffer.extra_descent =
-
--- Line Endings
---buffer.view_eol = true
-
--- Caret and Selection Styles.
-buffer:set_sel_fore(true, 0x333333)
-buffer:set_sel_back(true, 0x808080)
---buffer.sel_alpha =
---buffer.sel_eol_filled = true
-buffer.caret_fore = 0x808080
-buffer.caret_line_visible = true
---buffer.caret_line_visible_always = true
-buffer.caret_line_back = 0x333333
---buffer.caret_line_back_alpha =
---buffer.caret_period = 0
---buffer.caret_style = c.CARETSTYLE_BLOCK
---buffer.caret_width =
---buffer.caret_sticky = c.SC_CARETSTICKY_ON
-
--- Line Number Margin.
-buffer.margin_width_n[0] = 4 + 4 * buffer:text_width(c.STYLE_LINENUMBER, '9')
-
--- Marker Margin.
-buffer.margin_width_n[1] = 0 -- marker margin invisible
-
--- Fold Margin.
-buffer.margin_type_n[2] = c.SC_MARGIN_SYMBOL
-buffer.margin_width_n[2] = 10
-buffer.margin_mask_n[2] = c.SC_MASK_FOLDERS
-buffer.margin_sensitive_n[2] = true
---buffer.margin_left =
---buffer.margin_right =
-buffer:set_fold_margin_colour(true, 0x1A1A1A)
-buffer:set_fold_margin_hi_colour(true, 0x1A1A1A)
-
--- Annotations.
-buffer.annotation_visible = c.ANNOTATION_BOXED
-
--- Other.
-buffer.buffered_draw = not OSX -- Quartz buffers drawing
---buffer.two_phase_draw = false
-
--- Indentation Guides.
-buffer.indentation_guides = c.SC_IV_LOOKBOTH
-
--- Fold Margin Markers.
-buffer:marker_define(c.SC_MARKNUM_FOLDEROPEN, c.SC_MARK_ARROWDOWN)
-buffer.marker_fore[c.SC_MARKNUM_FOLDEROPEN] = 0x666666
-buffer.marker_back[c.SC_MARKNUM_FOLDEROPEN] = 0x666666
-buffer:marker_define(c.SC_MARKNUM_FOLDER, c.SC_MARK_ARROW)
-buffer.marker_fore[c.SC_MARKNUM_FOLDER] = 0x666666
-buffer.marker_back[c.SC_MARKNUM_FOLDER] = 0x666666
-buffer:marker_define(c.SC_MARKNUM_FOLDERSUB, c.SC_MARK_EMPTY)
-buffer:marker_define(c.SC_MARKNUM_FOLDERTAIL, c.SC_MARK_EMPTY)
-buffer:marker_define(c.SC_MARKNUM_FOLDEREND, c.SC_MARK_EMPTY)
-buffer:marker_define(c.SC_MARKNUM_FOLDEROPENMID, c.SC_MARK_EMPTY)
-buffer:marker_define(c.SC_MARKNUM_FOLDERMIDTAIL, c.SC_MARK_EMPTY)
-
--- Autocompletion.
---buffer.auto_c_cancel_at_start = false
-buffer.auto_c_choose_single = true
---buffer.auto_c_auto_hide = false
---buffer.auto_c_max_height =
---buffer.auto_c_max_width =
-
--- Call Tips.
---buffer.call_tip_use_style =
-
--- Folding.
-buffer.fold_flags = c.SC_FOLDFLAG_LINEAFTER_CONTRACTED
-buffer.automatic_fold = c.SC_AUTOMATICFOLD_SHOW + c.SC_AUTOMATICFOLD_CLICK +
- c.SC_AUTOMATICFOLD_CHANGE
-
--- Line Wrapping.
---buffer.wrap_mode = c.SC_WRAP_WORD
---buffer.wrap_visual_flags = c.SC_WRAPVISUALFLAG_MARGIN
---buffer.wrap_visual_flags_location = c.SC_WRAPVISUALFLAGLOC_END_BY_TEXT
---buffer.wrap_indent_mode = c.SC_WRAPINDENT_SAME
---buffer.wrap_start_indent =
-
--- Long Lines.
---buffer.edge_mode = c.EDGE_LINE
---buffer.edge_column = 80
---buffer.edge_colour = 0x666666
-
--- Notifications.
-buffer.mod_event_mask = c.SC_MOD_CHANGEFOLD