summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-07-29 17:06:04 +0000
committerKarl Berry <karl@freefriends.org>2012-07-29 17:06:04 +0000
commit13f625a8c0179b6984b24ed7e1fb6d25b23e2c7c (patch)
tree47a60abc453f9ed0603baf3671a93c3748adcf5a /Master/texmf-dist/tex/context
parentb0f3361df8e042de432eea3dde12086a360f57eb (diff)
context-vim (10jun12)
git-svn-id: svn://tug.org/texlive/trunk@27231 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/context')
-rw-r--r--Master/texmf-dist/tex/context/third/vim/2context.vim3
-rw-r--r--Master/texmf-dist/tex/context/third/vim/t-syntax-highlight.mkiv26
2 files changed, 24 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/context/third/vim/2context.vim b/Master/texmf-dist/tex/context/third/vim/2context.vim
index 67c7bafdc6a..9c72ba1bd19 100644
--- a/Master/texmf-dist/tex/context/third/vim/2context.vim
+++ b/Master/texmf-dist/tex/context/third/vim/2context.vim
@@ -135,6 +135,9 @@ while s:lnum <= s:lstop
let s:new = '\HGL{' . s:new . '}'
endif
+ " Add begin and end line markers
+ let s:new = "\\SYNBOL{}" . s:new . "\\SYNEOL{}"
+
call add(s:lines, s:new)
" Increment line numbers
diff --git a/Master/texmf-dist/tex/context/third/vim/t-syntax-highlight.mkiv b/Master/texmf-dist/tex/context/third/vim/t-syntax-highlight.mkiv
index 64da7ca386c..caf5d56a6fd 100644
--- a/Master/texmf-dist/tex/context/third/vim/t-syntax-highlight.mkiv
+++ b/Master/texmf-dist/tex/context/third/vim/t-syntax-highlight.mkiv
@@ -1,6 +1,6 @@
%D \module
%D [ file=t-syntax-highlight,
-%D version=2012.06.07,
+%D version=2012.06.09,
%D title=\CONTEXT\ User Module,
%D subtitle=Code syntax highlighting,
%D author=Aditya Mahajan,
@@ -9,7 +9,7 @@
%D email=adityam <at> ieee <dot> org,
%D license=Simplified BSD License]
-\writestatus{loading}{Code syntax highlighting (ver: 2012.06.07)}
+\writestatus{loading}{Code syntax highlighting (ver: 2012.06.09)}
\startmodule [syntax-highlight]
\usemodule [syntax-groups]
@@ -37,7 +37,7 @@
\appendtoks
\defineexternalfilter[\currentsyntaxhighlighting]
[\s!parent=\????syntaxhighlighting\currentexternalfilter,\c!taglabel=\vimtyping@id]%
- \definelinenumbering [\currentsyntaxhighlighting]%
+ \normalexpanded{\definelinenumbering [\currentsyntaxhighlighting]}%
\setevalue{type\currentsyntaxhighlighting file}{\getvalue{process\currentsyntaxhighlighting file}}%
\to\everydefinesyntaxhighlighting
@@ -77,6 +77,8 @@
\let\\\textbackslash
\let\{\textbraceleft
\let\}\textbraceright
+ \let\SYNBOL\donothing
+ \let\SYNEOL\donothing
\setupbar[syntaxhighlightline][color=\externalfilterparameter\c!highlightcolor]
@@ -104,9 +106,12 @@
\starttexdefinition syntaxhighlighting@linenumbering_start
\doifinset{\externalfilterparameter\c!numbering}\syntaxhighlighting@yes
- {\startlinenumbering
+ {\let\SYNBOL=\syntaxhighlighting_begin_number_lines
+ \let\SYNEOL=\syntaxhighlighting_end_number_lines
+ \startlinenumbering
[\currentsyntaxhighlighting]
[
+ \c!method=\v!type,
\c!start=\externalfilterparameter{\c!number\c!start},
\c!step=\externalfilterparameter{\c!number\c!step},
\c!continue=\externalfilterparameter{\c!number\c!continue},
@@ -120,6 +125,17 @@
{\stoplinenumbering}
\stoptexdefinition
+\newcount\nofsyntaxhighlightinglines
+
+\starttexdefinition syntaxhighlighting_begin_number_lines
+ \global\advance\nofsyntaxhighlightinglines\plusone
+ \attribute\verbatimlineattribute\nofsyntaxhighlightinglines
+\stoptexdefinition
+
+\starttexdefinition syntaxhighlighting_end_number_lines
+ \attribute\verbatimlineattribute\attributeunsetvalue
+\stoptexdefinition
+
\setupsyntaxhighlighting
[\c!tab=4,
@@ -151,7 +167,7 @@
\c!number\c!step=1,
\c!number\c!continue=\v!no,
\c!numberconversion=\v!numbers,
- \c!number\c!method=\v!first,
+ \c!number\c!method=\v!type, Not used
\c!number\c!location=\v!left,
\c!numberstyle=\ttx,
\c!numbercolor=,