Re: [NTG-context] Broken Index Behavior?

2018-03-05 Thread luigi scarso
On Mon, Mar 5, 2018 at 10:30 PM, Brian Wedde  wrote:
> Thanks Luigi. I am getting the "correct" results on my local workstation as
> well. However, when working on an installation on a Amazon Linux EC2
> instance, the index refuses to aggregate the results. This even happens if i
> copy my entire ConTeXt directory to the Amazon Linux machine verbatim. I
> have also tried the latest ConText version and get the same weird results. I
> am convinced that this has something to with the environment and not the
> installation itself, but I don't know where to look anymore. I am out of
> ideas. I have:
>
> - Disabled SELinux
> - Copied files from known working installation
> - Installed latest versions
> - chmod everything 777
>
> Any ideas on where to look would still be appreciated.
No idea ... you can send me your files off-list (as I have done).
Btw, I have used the texlive 2017.

-- 
luigi
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] Broken Index Behavior?

2018-03-05 Thread Brian Wedde
Thanks Luigi. I am getting the "correct" results on my local workstation 
as well. However, when working on an installation on a Amazon Linux EC2 
instance, the index refuses to aggregate the results. This even happens 
if i copy my entire ConTeXt directory to the Amazon Linux machine 
verbatim. I have also tried the latest ConText version and get the same 
weird results. I am convinced that this has something to with the 
environment and not the installation itself, but I don't know where to 
look anymore. I am out of ideas. I have:


- Disabled SELinux
- Copied files from known working installation
- Installed latest versions
- chmod everything 777

Any ideas on where to look would still be appreciated.

Thanks

- brian
___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Hans Hagen

On 3/5/2018 4:33 PM, Joseph Canedo wrote:
I see. So is it reliable to simply use lua function 
tex.getcount(‘realpageno’) in vertical mode to determine that page has 
changed ? Or do I need some other mechanism please ? If page has changed 
I agree that there is no need to deal with hangindent.


i don't know your logic but say that you have a dropped thingie that is 
5 lines high then you can check for available room


\setbox\scratchbox\hbox{...}
\getnoflines{\htdp\scratchbox}
\testpage[\noflines]

then you're for sure on the next page in which case your prevgraf is 
what you expect (assuming you stay on that page for a while)



I use grid typesetting so normally all lines have same height ?


they get snapped so they can take nlines

(the prevgraf variable just counts lines and doesn't look at the 
dimensions)



*De : *Hans Hagen 
*Envoyé le :*lundi 5 mars 2018 16:06
*À : *ntg-context@ntg.nl 
*Objet :*Re: [NTG-context] prevgraf change if page break occurs in a 
paragraph


On 3/5/2018 3:51 PM, Joseph Canedo wrote:

 > If I have a callback called just after paragraph has been split into

 > lines, would not be enough to count the number of hboxes in the vbox the

 > paragraph itself is contained ? Cannot say it’s ideal (easier to simply

 > read tex.prevgraf for sure), but might be possible, unless I missed

 > something (totally possible).

 >

 > In a couple of cases I see \prevgraf being larger than number of lines

 > of previous paragraph, including lines for paragraph before than one as

 > well. Could not create a MWE unfortunately to reproduce this case so far.

 >

 > I’ll try to amend my dropcaps/lettrine logic then. What are the reasons

 > behind this change in \prevgraf TeX primitive which AFAIK exists since

 > TeX has been written ? I thought that one of the strong points in TeX

 > was overall stability of its behaviour among versions. Here with this

 > semantic change in \prevgraf in recent luatex, this stability is a bit

 > broken IMO.

it's *not changed* in luatex .. context *itself* sets the prevgraf at

the next page as indicator of the left-over lines

say that you have:

XXX --

XXX --

--

--

- a page break between the first and second line is a bug in your code

- a page break after the second line is harmless and as we're on a new

page then there is nothing to be done i.e. prevgraf then is set to 2 (as

we have two lines if we look back)

say that you have:

XXX --

XXX

- if you get a page break here, again there is nothing to be done as

you're on a next page

- if you need to pick up in the next pagagraph (on the same page) then

prevgraf is 1

so, what in your case does it mean that when your next paragraph is on

the next page you look at prevgraf? there is no need to hangindent as

your hanging stuff is on the previous page

also, in general prevgraf is kind of useless when you have lines higher

than lineheight so if you use a callback, you also should calculate the

real accumulated drop so far

 > Joseph

 >

 > *De : *Hans Hagen 

 > *Envoyé le :*lundi 5 mars 2018 10:15

 > *À : *ntg-context@ntg.nl 

 > *Objet :*Re: [NTG-context] prevgraf change if page break occurs in a

 > paragraph

 >

 > On 3/5/2018 9:43 AM, Joseph Canedo wrote:

 >

 >  > I see. I use prevgraf to get number of lines in most recent 
paragraph to


 >

 >  > compute eventually hangindent if there is a lettrine in paragraph (in

 >

 >  > case first paragraph has fewer lines than the lettrine itself, of 
course


 >

 >  > next paragraph needs to setup hangindent properly).

 >

 > but .. that one is then still on the same page; in fact, you should

 >

 > check for realpage being changed then

 >

 >  > I guess as an alternative, I could use the callback after paragraph is

 >

 >  > split in N lines to count the number of lines, or is this number 
can be


 >

 >  > accessed via some other existing variable in tex lua « table » ?

 >

 >  > Currently I access prevgraf value Inside lua. Probably better than

 >

 >  > making things more complicated in luatex itself.

 >

 > prevgraf is still ok after a 7 line paragraph but ... when you cross a

 >

 > page, and have say 4 lines moved to the next one, then a 7 line

 >

 > hangafter would be wrong (you can check if a par is on the same page)

 >

 > with callbacks after breaking in lines you still don't know ...

 >

 > Hans

 >

 > -

 >

 >     Hans Hagen | PRAGMA ADE

 >

 >     Ridderstraat 27 | 8061 GH Hasselt | The Netherlands

 >

 >      tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl

 >

 > -

 >

 > 

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Joseph Canedo
BTW, I could write a MWE for the case when \prevgraf aggregates number of lines 
for 2 paragraphs (sometimes).

\starttext

\dorecurse{15}{
One line par.\par\nobreak A\\ B\\ C\\ D\\ E\\ F\\ G\\ H\\ I\\ J\\ K\\ L \\M\\ N.

\the\prevgraf

}

\stoptext

In some cases when « One line par » appears at first line of page (except the 
first one in this MWE output at least), you might see « 15 » after N. line.

De : Joseph Canedo
Envoyé le :lundi 5 mars 2018 16:32
À : mailing list for ConTeXt users
Objet :RE: [NTG-context] prevgraf change if page break occurs in a paragraph

I see. So is it reliable to simply use lua function tex.getcount(‘realpageno’) 
in vertical mode to determine that page has changed ? Or do I need some other 
mechanism please ? If page has changed I agree that there is no need to deal 
with hangindent.

I use grid typesetting so normally all lines have same height ?

De : Hans Hagen
Envoyé le :lundi 5 mars 2018 16:06
À : ntg-context@ntg.nl
Objet :Re: [NTG-context] prevgraf change if page break occurs in a paragraph

On 3/5/2018 3:51 PM, Joseph Canedo wrote:
> If I have a callback called just after paragraph has been split into 
> lines, would not be enough to count the number of hboxes in the vbox the 
> paragraph itself is contained ? Cannot say it’s ideal (easier to simply 
> read tex.prevgraf for sure), but might be possible, unless I missed 
> something (totally possible).
> 
> In a couple of cases I see \prevgraf being larger than number of lines 
> of previous paragraph, including lines for paragraph before than one as 
> well. Could not create a MWE unfortunately to reproduce this case so far.
> 
> I’ll try to amend my dropcaps/lettrine logic then. What are the reasons 
> behind this change in \prevgraf TeX primitive which AFAIK exists since 
> TeX has been written ? I thought that one of the strong points in TeX 
> was overall stability of its behaviour among versions. Here with this 
> semantic change in \prevgraf in recent luatex, this stability is a bit 
> broken IMO.

it's *not changed* in luatex .. context *itself* sets the prevgraf at 
the next page as indicator of the left-over lines

say that you have:

XXX --
XXX --
--
--

- a page break between the first and second line is a bug in your code
- a page break after the second line is harmless and as we're on a new 
page then there is nothing to be done i.e. prevgraf then is set to 2 (as 
we have two lines if we look back)

say that you have:

XXX --
XXX

- if you get a page break here, again there is nothing to be done as 
you're on a next page
- if you need to pick up in the next pagagraph (on the same page) then
prevgraf is 1

so, what in your case does it mean that when your next paragraph is on 
the next page you look at prevgraf? there is no need to hangindent as 
your hanging stuff is on the previous page

also, in general prevgraf is kind of useless when you have lines higher 
than lineheight so if you use a callback, you also should calculate the 
real accumulated drop so far

> Joseph
> 
> *De : *Hans Hagen 
> *Envoyé le :*lundi 5 mars 2018 10:15
> *À : *ntg-context@ntg.nl 
> *Objet :*Re: [NTG-context] prevgraf change if page break occurs in a 
> paragraph
> 
> On 3/5/2018 9:43 AM, Joseph Canedo wrote:
> 
>  > I see. I use prevgraf to get number of lines in most recent paragraph to
> 
>  > compute eventually hangindent if there is a lettrine in paragraph (in
> 
>  > case first paragraph has fewer lines than the lettrine itself, of course
> 
>  > next paragraph needs to setup hangindent properly).
> 
> but .. that one is then still on the same page; in fact, you should
> 
> check for realpage being changed then
> 
>  > I guess as an alternative, I could use the callback after paragraph is
> 
>  > split in N lines to count the number of lines, or is this number can be
> 
>  > accessed via some other existing variable in tex lua « table » ?
> 
>  > Currently I access prevgraf value Inside lua. Probably better than
> 
>  > making things more complicated in luatex itself.
> 
> prevgraf is still ok after a 7 line paragraph but ... when you cross a
> 
> page, and have say 4 lines moved to the next one, then a 7 line
> 
> hangafter would be wrong (you can check if a par is on the same page)
> 
> with callbacks after breaking in lines you still don't know ...
> 
> Hans
> 
> -
> 
>     Hans Hagen | PRAGMA ADE
> 
>     Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> 
>      tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> 
> -
> 
> ___
> 
> If your question is of interest to others as well, please add an entry 
> to 

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Joseph Canedo
I see. So is it reliable to simply use lua function tex.getcount(‘realpageno’) 
in vertical mode to determine that page has changed ? Or do I need some other 
mechanism please ? If page has changed I agree that there is no need to deal 
with hangindent.

I use grid typesetting so normally all lines have same height ?

De : Hans Hagen
Envoyé le :lundi 5 mars 2018 16:06
À : ntg-context@ntg.nl
Objet :Re: [NTG-context] prevgraf change if page break occurs in a paragraph

On 3/5/2018 3:51 PM, Joseph Canedo wrote:
> If I have a callback called just after paragraph has been split into 
> lines, would not be enough to count the number of hboxes in the vbox the 
> paragraph itself is contained ? Cannot say it’s ideal (easier to simply 
> read tex.prevgraf for sure), but might be possible, unless I missed 
> something (totally possible).
> 
> In a couple of cases I see \prevgraf being larger than number of lines 
> of previous paragraph, including lines for paragraph before than one as 
> well. Could not create a MWE unfortunately to reproduce this case so far.
> 
> I’ll try to amend my dropcaps/lettrine logic then. What are the reasons 
> behind this change in \prevgraf TeX primitive which AFAIK exists since 
> TeX has been written ? I thought that one of the strong points in TeX 
> was overall stability of its behaviour among versions. Here with this 
> semantic change in \prevgraf in recent luatex, this stability is a bit 
> broken IMO.

it's *not changed* in luatex .. context *itself* sets the prevgraf at 
the next page as indicator of the left-over lines

say that you have:

XXX --
XXX --
--
--

- a page break between the first and second line is a bug in your code
- a page break after the second line is harmless and as we're on a new 
page then there is nothing to be done i.e. prevgraf then is set to 2 (as 
we have two lines if we look back)

say that you have:

XXX --
XXX

- if you get a page break here, again there is nothing to be done as 
you're on a next page
- if you need to pick up in the next pagagraph (on the same page) then
prevgraf is 1

so, what in your case does it mean that when your next paragraph is on 
the next page you look at prevgraf? there is no need to hangindent as 
your hanging stuff is on the previous page

also, in general prevgraf is kind of useless when you have lines higher 
than lineheight so if you use a callback, you also should calculate the 
real accumulated drop so far

> Joseph
> 
> *De : *Hans Hagen 
> *Envoyé le :*lundi 5 mars 2018 10:15
> *À : *ntg-context@ntg.nl 
> *Objet :*Re: [NTG-context] prevgraf change if page break occurs in a 
> paragraph
> 
> On 3/5/2018 9:43 AM, Joseph Canedo wrote:
> 
>  > I see. I use prevgraf to get number of lines in most recent paragraph to
> 
>  > compute eventually hangindent if there is a lettrine in paragraph (in
> 
>  > case first paragraph has fewer lines than the lettrine itself, of course
> 
>  > next paragraph needs to setup hangindent properly).
> 
> but .. that one is then still on the same page; in fact, you should
> 
> check for realpage being changed then
> 
>  > I guess as an alternative, I could use the callback after paragraph is
> 
>  > split in N lines to count the number of lines, or is this number can be
> 
>  > accessed via some other existing variable in tex lua « table » ?
> 
>  > Currently I access prevgraf value Inside lua. Probably better than
> 
>  > making things more complicated in luatex itself.
> 
> prevgraf is still ok after a 7 line paragraph but ... when you cross a
> 
> page, and have say 4 lines moved to the next one, then a 7 line
> 
> hangafter would be wrong (you can check if a par is on the same page)
> 
> with callbacks after breaking in lines you still don't know ...
> 
> Hans
> 
> -
> 
>     Hans Hagen | PRAGMA ADE
> 
>     Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> 
>      tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
> 
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> 
> wiki : http://contextgarden.net
> 
> ___
> 
> 
> 
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : 

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Hans Hagen

On 3/5/2018 3:51 PM, Joseph Canedo wrote:
If I have a callback called just after paragraph has been split into 
lines, would not be enough to count the number of hboxes in the vbox the 
paragraph itself is contained ? Cannot say it’s ideal (easier to simply 
read tex.prevgraf for sure), but might be possible, unless I missed 
something (totally possible).


In a couple of cases I see \prevgraf being larger than number of lines 
of previous paragraph, including lines for paragraph before than one as 
well. Could not create a MWE unfortunately to reproduce this case so far.


I’ll try to amend my dropcaps/lettrine logic then. What are the reasons 
behind this change in \prevgraf TeX primitive which AFAIK exists since 
TeX has been written ? I thought that one of the strong points in TeX 
was overall stability of its behaviour among versions. Here with this 
semantic change in \prevgraf in recent luatex, this stability is a bit 
broken IMO.


it's *not changed* in luatex .. context *itself* sets the prevgraf at 
the next page as indicator of the left-over lines


say that you have:

XXX --
XXX --
--
--

- a page break between the first and second line is a bug in your code
- a page break after the second line is harmless and as we're on a new 
page then there is nothing to be done i.e. prevgraf then is set to 2 (as 
we have two lines if we look back)


say that you have:

XXX --
XXX

- if you get a page break here, again there is nothing to be done as 
you're on a next page

- if you need to pick up in the next pagagraph (on the same page) then
prevgraf is 1

so, what in your case does it mean that when your next paragraph is on 
the next page you look at prevgraf? there is no need to hangindent as 
your hanging stuff is on the previous page


also, in general prevgraf is kind of useless when you have lines higher 
than lineheight so if you use a callback, you also should calculate the 
real accumulated drop so far



Joseph

*De : *Hans Hagen 
*Envoyé le :*lundi 5 mars 2018 10:15
*À : *ntg-context@ntg.nl 
*Objet :*Re: [NTG-context] prevgraf change if page break occurs in a 
paragraph


On 3/5/2018 9:43 AM, Joseph Canedo wrote:

 > I see. I use prevgraf to get number of lines in most recent paragraph to

 > compute eventually hangindent if there is a lettrine in paragraph (in

 > case first paragraph has fewer lines than the lettrine itself, of course

 > next paragraph needs to setup hangindent properly).

but .. that one is then still on the same page; in fact, you should

check for realpage being changed then

 > I guess as an alternative, I could use the callback after paragraph is

 > split in N lines to count the number of lines, or is this number can be

 > accessed via some other existing variable in tex lua « table » ?

 > Currently I access prevgraf value Inside lua. Probably better than

 > making things more complicated in luatex itself.

prevgraf is still ok after a 7 line paragraph but ... when you cross a

page, and have say 4 lines moved to the next one, then a 7 line

hangafter would be wrong (you can check if a par is on the same page)

with callbacks after breaking in lines you still don't know ...

Hans

-

    Hans Hagen | PRAGMA ADE

    Ridderstraat 27 | 8061 GH Hasselt | The Netherlands

     tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net

archive  : https://bitbucket.org/phg/context-mirror/commits/

wiki : http://contextgarden.net

___



___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___




--

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Joseph Canedo
If I have a callback called just after paragraph has been split into lines, 
would not be enough to count the number of hboxes in the vbox the paragraph 
itself is contained ? Cannot say it’s ideal (easier to simply read tex.prevgraf 
for sure), but might be possible, unless I missed something (totally possible).

In a couple of cases I see \prevgraf being larger than number of lines of 
previous paragraph, including lines for paragraph before than one as well. 
Could not create a MWE unfortunately to reproduce this case so far.

I’ll try to amend my dropcaps/lettrine logic then. What are the reasons behind 
this change in \prevgraf TeX primitive which AFAIK exists since TeX has been 
written ? I thought that one of the strong points in TeX was overall stability 
of its behaviour among versions. Here with this semantic change in \prevgraf in 
recent luatex, this stability is a bit broken IMO.

Joseph

De : Hans Hagen
Envoyé le :lundi 5 mars 2018 10:15
À : ntg-context@ntg.nl
Objet :Re: [NTG-context] prevgraf change if page break occurs in a paragraph

On 3/5/2018 9:43 AM, Joseph Canedo wrote:
> I see. I use prevgraf to get number of lines in most recent paragraph to 
> compute eventually hangindent if there is a lettrine in paragraph (in 
> case first paragraph has fewer lines than the lettrine itself, of course 
> next paragraph needs to setup hangindent properly).

but .. that one is then still on the same page; in fact, you should 
check for realpage being changed then

> I guess as an alternative, I could use the callback after paragraph is 
> split in N lines to count the number of lines, or is this number can be 
> accessed via some other existing variable in tex lua « table » ? 
> Currently I access prevgraf value Inside lua. Probably better than 
> making things more complicated in luatex itself.
prevgraf is still ok after a 7 line paragraph but ... when you cross a 
page, and have say 4 lines moved to the next one, then a 7 line 
hangafter would be wrong (you can check if a par is on the same page)

with callbacks after breaking in lines you still don't know ...

Hans

-
   Hans Hagen | PRAGMA ADE
   Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] ANNOUNCEMENT: Notepad++ for ConTeXt - Version 0.98

2018-03-05 Thread Idris Samawi Hamid ادريس سماوي حامد

Dear ConTeXt gang,

A continuing desideratum for ConTeXt is a user-friendly writing and  
editing environment, where the range of application of the category  
“user-friendly” includes especially non-experts in programming or software  
development. The lack of such an environment is one factor that inhibits  
the wider use of ConTeXt. Despite its immense power, precision, and  
flexibility: At present it is not generally feasible for instructors and  
researchers in, e.g., the humanities to assign the use of ConTeXt to  
students, or to use it to collaborate on projects.


In addition, the first author (Idris) especially required a ConTeXt editor  
with, among other features, bidirectional capabilities to serve both  
academic writing as well as the needs of the Oriental TeX project,  
including the Zahrāʾ (aka Husayni) typeface system under current  
development.


In the course of an ongoing effort to address these lacunae, in 2017 a  
project to develop a set of utilities for the Windows editor Notepad++ was  
launched. After months of development and testing, Luigi and I are proud  
to present to the ConTeXt community


Notepad++ for ConTeXt: Lexer and Macro Utilities for editing ConTeXt  
Documents

Version 0.98

This package includes

I. A plugin for Notepad++ that implements, for the ConTeXt document  
processing system,
i)   a language lexer for semantic highlighting of TeX, LuaTeX, and  
ConTeXt commands;
ii)  autocompletion of commands with full support for calltips (set in  
columns);
iii) tagging and insertion of markup and templates, with support for  
mnemonic keys.


II. A color scheme and two complementary Notepad++ themes:
Silver Twilight Hi and Silver Twilight Lo.

Notepad++ for ConTeXt is available here:

https://github.com/luigiScarso/context-npp
https://github.com/luigiScarso/context-npp/blob/master/install/Npp-for-ConTeXt.zip

as well as here:

http://wiki.contextgarden.net/File:Npp-for-ConTeXt.zip

For a future TeXLive DVD: The package will be available under

texmf-dist/context/data/npp/context

The complete manual for Notepad++ ConTeXt, along with its TeX sources, may  
be

found in the following directory of the zip:

/Npp-for-ConTeXt/doc/npp-context-manual.pdf

It may also be downloaded here:
https://github.com/luigiScarso/context-npp/tree/master/doc

The README follows this announcement.

NOTA BENE: The old wiki page
http://wiki.contextgarden.net/Notepad++
is currently obsolete and needs to be updated in its entirety.

Further development is planned beyond this initial release. We warmly  
welcome and look forward to feedback and suggestions for improvement from  
the ConTeXt community!


Best wishes
Idris and Luigi

==
REAMDE.md:

*Notepad++ for ConTeXt: Lexer and Macro Utilities for editing ConTeXt  
Documents

Version 0.98*

This package includes

I. A plugin for Notepad++ that implements, for the ConTeXt document
processing system,
i) a language lexer for semantic highlighting of TeX, LuaTeX, and ConTeXt  
commands;
ii) autocompletion of commands with full support for calltips (set in  
columns);
iii) tagging and insertion of markup and templates, with support for  
mnemonic keys.


II. A color scheme and two complementary Notepad++ themes: Silver
Twilight Hi and Silver Twilight Lo.

Notepad++ for ConTeXt is available here:

https://github.com/luigiScarso/context-npp
https://github.com/luigiScarso/context-npp/blob/master/install/Npp-for-ConTeXt.zip

as well as here:

http://wiki.contextgarden.net/File:Npp-for-ConTeXt.zip

For a future TeXLive DVD: The package will be available under

texmf-dist/context/data/npp/context

The complete manual for Notepad++ ConTeXt, along with its TeX sources, may  
be

found in the following directory of the zip:

/Npp-for-ConTeXt/doc/npp-context-manual.pdf

It may also be downloaded here:
https://github.com/luigiScarso/context-npp/tree/master/doc

Completing development of the C++ plugin and lexer was done by the current
maintainer, Luigi Scarso (ConTeXt Development Team). Original C++ plugin
and lexer development was done by Dr. Jason Wu (Colorado State
University). Project vision and development planning (as well as the two
themes and color scheme) are by Professor Idris Samawi Hamid (Colorado
State University).

The Notepad++ for ConTeXt lexer is strongly influence by the plugin
WebEdit by Alexander Iljin:
https://sourceforge.net/projects/npp-plugins/files/WebEdit/

This plugin aims to support the editing of ConTeXt documents in a number
of ways. This includes some integration with the standalone distribution
of ConTeXt.

(For more information on ConTeXt see

http://wiki.contextgarden.net/Main_Page
http://www.pragma-ade.nl/index.htm .)

This plugin includes a language lexer for semantic highlighting of
ConTeXt commands; it also includes a system for tagging and inserting of
markup and templates, with support for mnemonic keys.

In its first phase of development, the plugin borrowed some ideas and
implementations from other 

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Hans Hagen

On 3/5/2018 9:43 AM, Joseph Canedo wrote:
I see. I use prevgraf to get number of lines in most recent paragraph to 
compute eventually hangindent if there is a lettrine in paragraph (in 
case first paragraph has fewer lines than the lettrine itself, of course 
next paragraph needs to setup hangindent properly).


but .. that one is then still on the same page; in fact, you should 
check for realpage being changed then


I guess as an alternative, I could use the callback after paragraph is 
split in N lines to count the number of lines, or is this number can be 
accessed via some other existing variable in tex lua « table » ? 
Currently I access prevgraf value Inside lua. Probably better than 
making things more complicated in luatex itself.
prevgraf is still ok after a 7 line paragraph but ... when you cross a 
page, and have say 4 lines moved to the next one, then a 7 line 
hangafter would be wrong (you can check if a par is on the same page)


with callbacks after breaking in lines you still don't know ...

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] prevgraf change if page break occurs in a paragraph

2018-03-05 Thread Joseph Canedo
I see. I use prevgraf to get number of lines in most recent paragraph to 
compute eventually hangindent if there is a lettrine in paragraph (in case 
first paragraph has fewer lines than the lettrine itself, of course next 
paragraph needs to setup hangindent properly).

I guess as an alternative, I could use the callback after paragraph is split in 
N lines to count the number of lines, or is this number can be accessed via 
some other existing variable in tex lua « table » ? Currently I access prevgraf 
value Inside lua. Probably better than making things more complicated in luatex 
itself.

Thanks a lot,

Joseph

De : Hans Hagen
Envoyé le :lundi 5 mars 2018 08:58
À : ntg-context@ntg.nl
Objet :Re: [NTG-context] prevgraf change if page break occurs in a paragraph

On 3/4/2018 10:59 PM, Joseph Canedo wrote:

> I am aware that ConTeXt betas might use experimental luaTeX changes (I 
> use both stable and latest and run both), just wanted to report a change 

not really, as we don't ship beta luatex's so context normally either 
has adaptive code or delays usage for a year

> in prevgraf result. Apparently with latest beta it reports the number of 
> lines in last page of paragraph (only tested with pars on 2 pages 
> maximum, haven’t tried longer ones). Simple MWE reproduces the case:
> 
> \starttext
> 
> \dorecurse{15}{
> 
> A\\ B\\ C\\ D\\ E\\ F\\ G\\ H\\ I\\ J\\ K\\ L \\M\\ N.
> 
> \the\prevgraf
> 
> }
> 
> \stoptext
> 
> Using ConTeXt online always reports « 14 » after the letters, latest 
> ConTeXt reports different numbers if the par before it has been split in 
> 2 pages.
well, i could store the old prevgraf (of make that an option) but it's a 
fact that a top of page is basically a change (in prevgraf and prevdepth)

what do you use prevgraf for?

Hans

-
   Hans Hagen | PRAGMA ADE
   Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | www.pragma-ade.nl | 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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

___
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://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___