ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* vim syntax highlighting in MKIV
@ 2010-06-25 19:48 Martin 'golodhrim' Scholz
  2010-06-25 21:24 ` Hans Hagen
  0 siblings, 1 reply; 13+ messages in thread
From: Martin 'golodhrim' Scholz @ 2010-06-25 19:48 UTC (permalink / raw)
  To: ntg-context

Hi Hans, Mojca, Aditya and List,

just tried to use the vim Syntax Highlighting module in ConTeXt MKIV, but 
if running the documents complains it searches a file called

	filename-vimsyntax.tmp-vimsyntax.tmp

sure that file not exists but there is a file called

	filename-vimsyntax.tmp

is there a way to do a workaround so that the vim Syntaxhighlighting 
module would work in MKIV or does it need to be rewriten completedly?

Greetings
-- 
---
Martin 'golodhrim' Scholz
Auf dem Sattler 4
34516 Ederbringhausen
Phone: +49 6454 799623
mobile: +49 176 63301749
Fax: +49 6454 
e-Mail: scholz.m82@googlemail.com

Think sideways!
		-- Ed De Bono

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-25 19:48 vim syntax highlighting in MKIV Martin 'golodhrim' Scholz
@ 2010-06-25 21:24 ` Hans Hagen
  2010-06-27  2:38   ` Aditya Mahajan
  0 siblings, 1 reply; 13+ messages in thread
From: Hans Hagen @ 2010-06-25 21:24 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Martin 'golodhrim' Scholz

On 25-6-2010 9:48, Martin 'golodhrim' Scholz wrote:
> Hi Hans, Mojca, Aditya and List,
>
> just tried to use the vim Syntax Highlighting module in ConTeXt MKIV, but
> if running the documents complains it searches a file called
>
> 	filename-vimsyntax.tmp-vimsyntax.tmp
>
> sure that file not exists but there is a file called
>
> 	filename-vimsyntax.tmp
>
> is there a way to do a workaround so that the vim Syntaxhighlighting
> module would work in MKIV or does it need to be rewriten completedly?

probably something that M or A can fix easily

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-25 21:24 ` Hans Hagen
@ 2010-06-27  2:38   ` Aditya Mahajan
  2010-06-27  5:41     ` Aditya Mahajan
  0 siblings, 1 reply; 13+ messages in thread
From: Aditya Mahajan @ 2010-06-27  2:38 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Fri, 25 Jun 2010, Hans Hagen wrote:

> On 25-6-2010 9:48, Martin 'golodhrim' Scholz wrote:
>> Hi Hans, Mojca, Aditya and List,
>> 
>> just tried to use the vim Syntax Highlighting module in ConTeXt MKIV, but
>> if running the documents complains it searches a file called
>>
>> 	filename-vimsyntax.tmp-vimsyntax.tmp
>> 
>> sure that file not exists but there is a file called
>>
>> 	filename-vimsyntax.tmp
>> 
>> is there a way to do a workaround so that the vim Syntaxhighlighting
>> module would work in MKIV or does it need to be rewriten completedly?
>
> probably something that M or A can fix easily

Something changed in mtxrun ...

Earlier (checked on the 2009.12.31) if I used

mtxrun bin:vim kpse:2context.vim

the "kpse:2context.vim" was expanded to the full path of 2context.vim. 
Now (in 2010.06.20), "kpse:2context.vim" expands to "tree://<full-path>". 
Of couse, vim does not understand the tree:// prefix and cannot load the 
file. Is there an option to avoid the tree:// prefix?

Almost all the errors in t-vim over the years have due to trying to 
support kpse: directive. (The errors were not a fault of ConTeXt, but the 
way quotes are handled by cmd.exe and the various shells in *nix. I still 
haven't figured out a syntax that works with all shells). This makes me 
wonder whether it was a good idea to make vim module work out of the box. 
Perhaps a more robust alternative was to ask the uses to copy 2context.vim 
to $HOME/.vim/scripts/ and forget about getting mtxrun to locate the file. 
What do others think?

Aditya

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27  2:38   ` Aditya Mahajan
@ 2010-06-27  5:41     ` Aditya Mahajan
  2010-06-27 10:04       ` Martin 'golodhrim' Scholz
                         ` (2 more replies)
  0 siblings, 3 replies; 13+ messages in thread
From: Aditya Mahajan @ 2010-06-27  5:41 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Sat, 26 Jun 2010, Aditya Mahajan wrote:

> Almost all the errors in t-vim over the years have due to trying to support 
> kpse: directive. (The errors were not a fault of ConTeXt, but the way quotes 
> are handled by cmd.exe and the various shells in *nix. I still haven't 
> figured out a syntax that works with all shells). This makes me wonder 
> whether it was a good idea to make vim module work out of the box. Perhaps a 
> more robust alternative was to ask the uses to copy 2context.vim to 
> $HOME/.vim/scripts/ and forget about getting mtxrun to locate the file. What 
> do others think?

In the spirit of MkIV, I have attempted to redo the vim module from 
scratch.

http://github.com/adityam/filter

Download t-vim.tex t-filter.tex and 2context.vim. For testing just place 
them in the current directory.

This new version is delegates the task of creating external files and 
running vim to get syntax highlighting to t-filter. It reads the file 
under a restrictive catcode regime... so 2context.vim only has to escape a 
few characters: \ { }, everything else has a catcode other (except space 
and newline which are active).

Currently, this new module only supports

* syntax highlighting (syntax=filetype)

* two color schemes (alternative=pscolor and alternative=blackandwhite)

* specifying start and stop lines (start=... , stop=...)

An additional feature is that the module stores the md5 sums of all files, 
and runs vim only if the file has changed. So, this should be 
significantly faster than the old module.

Difference

* No \typevimfile... instead \definevimtyping[whatever] creates a command
\typewhateverfile that can be used as
 	\typewhateverfile[options][file]

* Currently, no support for line numbering, although that should be easy 
to add now.

* No support for active spaces yet.

* Most importantly, this only runs under MkIV. That is because 
\doprocesslocalsetups is not defined in MkII.

Hans, can you add the definition of \doprocesslocalsetups to MkII?

I have only tested on linux. Testing on other platforms will be 
appreciated (Just run the files under test/vim/).

Aditya

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27  5:41     ` Aditya Mahajan
@ 2010-06-27 10:04       ` Martin 'golodhrim' Scholz
  2010-06-27 11:36       ` Peter Münster
  2010-06-27 12:02       ` Wolfgang Schuster
  2 siblings, 0 replies; 13+ messages in thread
From: Martin 'golodhrim' Scholz @ 2010-06-27 10:04 UTC (permalink / raw)
  To: ntg-context

On Sun, 27 Jun 2010 01:41:35 -0400, Aditya Mahajan wrote:

> On Sat, 26 Jun 2010, Aditya Mahajan wrote:
> 
>> Almost all the errors in t-vim over the years have due to trying to
>> support kpse: directive. (The errors were not a fault of ConTeXt, but
>> the way quotes are handled by cmd.exe and the various shells in *nix. I
>> still haven't figured out a syntax that works with all shells). This
>> makes me wonder whether it was a good idea to make vim module work out
>> of the box. Perhaps a more robust alternative was to ask the uses to
>> copy 2context.vim to $HOME/.vim/scripts/ and forget about getting
>> mtxrun to locate the file. What do others think?
> 
> In the spirit of MkIV, I have attempted to redo the vim module from
> scratch.
> 
> http://github.com/adityam/filter
> 
> Download t-vim.tex t-filter.tex and 2context.vim. For testing just place
> them in the current directory.
> 
> This new version is delegates the task of creating external files and
> running vim to get syntax highlighting to t-filter. It reads the file
> under a restrictive catcode regime... so 2context.vim only has to escape
> a few characters: \ { }, everything else has a catcode other (except
> space and newline which are active).
> 
> Currently, this new module only supports
> 
> * syntax highlighting (syntax=filetype)
> 
> * two color schemes (alternative=pscolor and alternative=blackandwhite)
> 
> * specifying start and stop lines (start=... , stop=...)
> 
> An additional feature is that the module stores the md5 sums of all
> files, and runs vim only if the file has changed. So, this should be
> significantly faster than the old module.
> 
> Difference
> 
> * No \typevimfile... instead \definevimtyping[whatever] creates a
> command \typewhateverfile that can be used as
>  	\typewhateverfile[options][file]
> 
> * Currently, no support for line numbering, although that should be easy
> to add now.
> 
> * No support for active spaces yet.
> 
> * Most importantly, this only runs under MkIV. That is because
> \doprocesslocalsetups is not defined in MkII.
> 
> Hans, can you add the definition of \doprocesslocalsetups to MkII?
> 
> I have only tested on linux. Testing on other platforms will be
> appreciated (Just run the files under test/vim/).
> 
> Aditya

Hi Aditya,
just cloned the your git and linked them into the project I use the 
syntax highlightling, and it works, thanks for the fast and professional 
help...

Greetings


-- 
---
Martin 'golodhrim' Scholz
Auf dem Sattler 4
34516 Ederbringhausen
Phone: +49 6454 799623
mobile: +49 176 63301749
Fax: +49 6454 
e-Mail: scholz.m82@googlemail.com

Avec!

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27  5:41     ` Aditya Mahajan
  2010-06-27 10:04       ` Martin 'golodhrim' Scholz
@ 2010-06-27 11:36       ` Peter Münster
  2010-06-27 15:49         ` Aditya Mahajan
  2010-06-27 12:02       ` Wolfgang Schuster
  2 siblings, 1 reply; 13+ messages in thread
From: Peter Münster @ 2010-06-27 11:36 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Sun, Jun 27 2010, Aditya Mahajan wrote:

> In the spirit of MkIV, I have attempted to redo the vim module from 
> scratch.
>
> http://github.com/adityam/filter
>
> Download t-vim.tex t-filter.tex and 2context.vim. For testing just place 
> them in the current directory.

Hello Aditya,

Thanks for these great modules!  It would be nice to make them available in
the minimals!

Cheers, Peter

-- 
Contact information: http://pmrb.free.fr/contact/


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27  5:41     ` Aditya Mahajan
  2010-06-27 10:04       ` Martin 'golodhrim' Scholz
  2010-06-27 11:36       ` Peter Münster
@ 2010-06-27 12:02       ` Wolfgang Schuster
  2010-06-27 15:47         ` Aditya Mahajan
  2 siblings, 1 reply; 13+ messages in thread
From: Wolfgang Schuster @ 2010-06-27 12:02 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 27.06.10 07:41, schrieb Aditya Mahajan:
> On Sat, 26 Jun 2010, Aditya Mahajan wrote:
>
>> Almost all the errors in t-vim over the years have due to trying to 
>> support kpse: directive. (The errors were not a fault of ConTeXt, but 
>> the way quotes are handled by cmd.exe and the various shells in *nix. 
>> I still haven't figured out a syntax that works with all shells). 
>> This makes me wonder whether it was a good idea to make vim module 
>> work out of the box. Perhaps a more robust alternative was to ask the 
>> uses to copy 2context.vim to $HOME/.vim/scripts/ and forget about 
>> getting mtxrun to locate the file. What do others think?
>
> In the spirit of MkIV, I have attempted to redo the vim module from 
> scratch.
>
> http://github.com/adityam/filter
>
> [...]
>
> * Most importantly, this only runs under MkIV. That is because 
> \doprocesslocalsetups is not defined in MkII.
>
> Hans, can you add the definition of \doprocesslocalsetups to MkII?

If you don't matter about performance you can use 
'\processcommacommand[...]\directsetup'

Wolfgang

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27 12:02       ` Wolfgang Schuster
@ 2010-06-27 15:47         ` Aditya Mahajan
  0 siblings, 0 replies; 13+ messages in thread
From: Aditya Mahajan @ 2010-06-27 15:47 UTC (permalink / raw)
  To: Wolfgang Schuster; +Cc: mailing list for ConTeXt users

On Sun, 27 Jun 2010, Wolfgang Schuster wrote:

> Am 27.06.10 07:41, schrieb Aditya Mahajan:
>> 
>> In the spirit of MkIV, I have attempted to redo the vim module from 
>> scratch.
>> 
>> http://github.com/adityam/filter
>> 
>> [...]
>> 
>> * Most importantly, this only runs under MkIV. That is because 
>> \doprocesslocalsetups is not defined in MkII.
>> 
>> Hans, can you add the definition of \doprocesslocalsetups to MkII?
>
> If you don't matter about performance you can use 
> '\processcommacommand[...]\directsetup'

Thanks. Works perfectly.

Aditya
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27 11:36       ` Peter Münster
@ 2010-06-27 15:49         ` Aditya Mahajan
  2010-06-27 18:16           ` Martin 'golodhrim' Scholz
  2010-09-04 16:10           ` Chen Shen
  0 siblings, 2 replies; 13+ messages in thread
From: Aditya Mahajan @ 2010-06-27 15:49 UTC (permalink / raw)
  To: mailing list for ConTeXt users

[-- Attachment #1: Type: TEXT/PLAIN, Size: 534 bytes --]

On Sun, 27 Jun 2010, Peter Münster wrote:

> On Sun, Jun 27 2010, Aditya Mahajan wrote:
>
>> In the spirit of MkIV, I have attempted to redo the vim module from
>> scratch.
>>
>> http://github.com/adityam/filter
>>
>> Download t-vim.tex t-filter.tex and 2context.vim. For testing just place
>> them in the current directory.
>
> Hello Aditya,
>
> Thanks for these great modules!  It would be nice to make them available in
> the minimals!

I will add them to the garden, once I the features stabalize a bit.

Aditya

[-- Attachment #2: Type: text/plain, Size: 486 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27 15:49         ` Aditya Mahajan
@ 2010-06-27 18:16           ` Martin 'golodhrim' Scholz
  2010-09-04 16:10           ` Chen Shen
  1 sibling, 0 replies; 13+ messages in thread
From: Martin 'golodhrim' Scholz @ 2010-06-27 18:16 UTC (permalink / raw)
  To: ntg-context

On Sun, 27 Jun 2010 11:49:22 -0400, Aditya Mahajan wrote:

> On Sun, 27 Jun 2010, Peter Münster wrote:
> 
>> On Sun, Jun 27 2010, Aditya Mahajan wrote:
>>
>>> In the spirit of MkIV, I have attempted to redo the vim module from
>>> scratch.
>>>
>>> http://github.com/adityam/filter
>>>
>>> Download t-vim.tex t-filter.tex and 2context.vim. For testing just
>>> place them in the current directory.
>>
>> Hello Aditya,
>>
>> Thanks for these great modules!  It would be nice to make them
>> available in the minimals!
> 
> I will add them to the garden, once I the features stabalize a bit.
> 
> Aditya

Hey Aditya,

if you keep them sync with your git, I would be proud to announce a 
tester in my person...

Greetings
-- 
---
Martin 'golodhrim' Scholz
Auf dem Sattler 4
34516 Ederbringhausen
Phone: +49 6454 799623
mobile: +49 176 63301749
Fax: +49 6454 
e-Mail: scholz.m82@googlemail.com

Once harm has been done, even a fool understands it.
		-- Homer

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-06-27 15:49         ` Aditya Mahajan
  2010-06-27 18:16           ` Martin 'golodhrim' Scholz
@ 2010-09-04 16:10           ` Chen Shen
  2010-09-04 17:15             ` Wolfgang Schuster
  1 sibling, 1 reply; 13+ messages in thread
From: Chen Shen @ 2010-09-04 16:10 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 3592 bytes --]

Hi Aditya,

Thanks for the great module!

There is a problem using t-vim/t-filter with the current and beta versions
of ConTeXt.
I was trying the Matlab example (tests/vim/matlab.tex), ConTeXt complains
that \startMATLAB is not defined,
but the execution can continue, and the correct pdf is produced.

regards,
shenchen

Below is the log message:

--------------------------------------------------
system          : module vim loaded
(t-vim.tex
system          : module filter loaded
(t-filter.tex)
color           : system hex is loaded
(/opt/home/hash/context/tex/texmf-context/tex/context/base/colo-hex.tex
(/opt/home/hash/context/tex/texmf-context/tex/context/base/colo-hex.mkiv)))
publications    : loading formatting style from bxml-apa
(/opt/home/hash/context/tex/texmf-context/tex/context/base/bxml-apa.mkiv)
systems         : begin file test.tex at line 6
! Undefined control sequence.

system          > error on line 7 in file test.tex: Undefined control
sequence ...

 1     \setupcolors[state=start]
 2     \usemodule [vim]
 3
 4     \definevimtyping  [MATLAB]  [syntax=matlab]
 5
 6     \starttext
 7 >>  \startMATLAB
 8     function russell_demo()
 9     % Do the example in ch 17 (p501) of Russell and Norvig
10     % (1,1) is top left corner.
11     r = 3; c = 4; p = 0.8; action_cost = -1/25;
12     obstacle = zeros(r,c); obstacle(2,2)=1;
13     terminal = zeros(r,c); terminal(1,4)=1; terminal(2,4)=1;
14     absorb = 1;
15     wrap_around = 0;
16     noop = 0;
17     T = mk_grid_world(r, c, p, obstacle, terminal, absorb, wrap_around,
noop);

<argument> \v!unknwon

\p!compareprocessaction ...]->\edef \!!stringb {#1
                                                  }\ifx \!!stringb
\s!defaul...
\next1 #1,->\p!doprocessaction {#1}
                                   \doprocesscommaitem
\processnextcommalist ...odoprocesscommaitem #4#5,
                                                  ]\relax \global \advance
\...
\dostartexternalfilter ...ter!!method \zerocount ]
                                                  \doifelse
{\externalfilter...
<to be read again>

l.7 \startMATLAB

?

(test-externalfilter-MATLAB-0.vimout
Overfull \hbox (30.53203pt too wide) in paragraph at lines 10--10
[][][]\*modern12pttttf* T = mk_grid_world(r, c, p, ob-sta-cle, ter-mi-nal,
ab-sorb, wrap_around, noop);
----------



On Sun, Jun 27, 2010 at 11:49 PM, Aditya Mahajan <adityam@umich.edu> wrote:

> On Sun, 27 Jun 2010, Peter Münster wrote:
>
>  On Sun, Jun 27 2010, Aditya Mahajan wrote:
>>
>>  In the spirit of MkIV, I have attempted to redo the vim module from
>>> scratch.
>>>
>>> http://github.com/adityam/filter
>>>
>>> Download t-vim.tex t-filter.tex and 2context.vim. For testing just place
>>> them in the current directory.
>>>
>>
>> Hello Aditya,
>>
>> Thanks for these great modules!  It would be nice to make them available
>> in
>> the minimals!
>>
>
> I will add them to the garden, once I the features stabalize a bit.
>
> Aditya
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
>
> ___________________________________________________________________________________
>
>

[-- Attachment #1.2: Type: text/html, Size: 5601 bytes --]

[-- Attachment #2: Type: text/plain, Size: 486 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-09-04 16:10           ` Chen Shen
@ 2010-09-04 17:15             ` Wolfgang Schuster
  2010-09-06 21:56               ` Aditya Mahajan
  0 siblings, 1 reply; 13+ messages in thread
From: Wolfgang Schuster @ 2010-09-04 17:15 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 04.09.2010 um 18:10 schrieb Chen Shen:

> Hi Aditya,
> 
> Thanks for the great module!
> 
> There is a problem using t-vim/t-filter with the current and beta versions of ConTeXt.
> I was trying the Matlab example (tests/vim/matlab.tex), ConTeXt complains that \startMATLAB is not defined, 
> but the execution can continue, and the correct pdf is produced.
> 
> ! Undefined control sequence.
> 
> system          > error on line 7 in file test.tex: Undefined control sequence ...
> 
>  1     \setupcolors[state=start]
>  2     \usemodule [vim]
>  3     
>  4     \definevimtyping  [MATLAB]  [syntax=matlab]
>  5     
>  6     \starttext
>  7 >>  \startMATLAB
>  8     function russell_demo()
>  9     % Do the example in ch 17 (p501) of Russell and Norvig
> 10     % (1,1) is top left corner.
> 11     r = 3; c = 4; p = 0.8; action_cost = -1/25;
> 12     obstacle = zeros(r,c); obstacle(2,2)=1;
> 13     terminal = zeros(r,c); terminal(1,4)=1; terminal(2,4)=1;
> 14     absorb = 1;
> 15     wrap_around = 0;
> 16     noop = 0;
> 17     T = mk_grid_world(r, c, p, obstacle, terminal, absorb, wrap_around, noop);
> 
> <argument> \v!unknwon 

context’s error message is misleading, the problem appears with the \startMATLAB
command but the undefined control sequence is “\v!unknwon” as shown below the message,
it’s only a typo in the module and the correct value is “\v!unknown”.

Wolfgang


___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 13+ messages in thread

* Re: vim syntax highlighting in MKIV
  2010-09-04 17:15             ` Wolfgang Schuster
@ 2010-09-06 21:56               ` Aditya Mahajan
  0 siblings, 0 replies; 13+ messages in thread
From: Aditya Mahajan @ 2010-09-06 21:56 UTC (permalink / raw)
  To: mailing list for ConTeXt users

[-- Attachment #1: Type: TEXT/PLAIN, Size: 337 bytes --]

On Sat, 4 Sep 2010, Wolfgang Schuster wrote:

> context’s error message is misleading, the problem appears with the \startMATLAB
> command but the undefined control sequence is “\v!unknwon” as shown below the message,
> it’s only a typo in the module and the correct value is “\v!unknown”.

Thanks. I have corrected this.

Aditya

[-- Attachment #2: Type: text/plain, Size: 486 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2010-09-06 21:56 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-06-25 19:48 vim syntax highlighting in MKIV Martin 'golodhrim' Scholz
2010-06-25 21:24 ` Hans Hagen
2010-06-27  2:38   ` Aditya Mahajan
2010-06-27  5:41     ` Aditya Mahajan
2010-06-27 10:04       ` Martin 'golodhrim' Scholz
2010-06-27 11:36       ` Peter Münster
2010-06-27 15:49         ` Aditya Mahajan
2010-06-27 18:16           ` Martin 'golodhrim' Scholz
2010-09-04 16:10           ` Chen Shen
2010-09-04 17:15             ` Wolfgang Schuster
2010-09-06 21:56               ` Aditya Mahajan
2010-06-27 12:02       ` Wolfgang Schuster
2010-06-27 15:47         ` Aditya Mahajan

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).