Re: [NTG-context] adjusting vertical space

2021-11-25 Thread Thomas A. Schmitz via ntg-context


On 11/25/21 00:06, jbf via ntg-context wrote:

The following MWE


You do know what MWE stands for, right?

Thomas
___
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] rule beneath chapter number

2021-11-12 Thread Thomas A. Schmitz via ntg-context


On 11/12/21 18:13, Henning Hraban Ramm via ntg-context wrote:

You’re right, tabular numbers are nonproportional. I meant versal (“normal”) 
numbers in opposite of oldstyle (mediaeval) numbers.


I think there are two mutually exclusive feature pairs that you're 
mixing up:


lnum vs onum: lining numbers versus old style numbers; "lining" having 
no descenders, but sitting on the line.


pnum vs tnum: proportional vs tabulate numbers. As the name suggests, 
the latter look better where numbers are vertically aligned because each 
numeral will take exactly the same space, so tables, but also footnotes 
etc. The former of course will look better in running text.


Add to this that numbers can also be subscript or superscript. Some very 
extensive professional fonts have surprising combinations of these 
features, so in the end, one has to do what you did: fiddle with 
featuresets until the result looks right.


Thomas
___
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] Something smells rotten in the state of luametatex...

2021-10-08 Thread Thomas A. Schmitz via ntg-context


Hi all,

I have a document here for one of my classes: xml processed via context, 
some layers, some two column paragraphs, a bibliography, nothing out of 
the ordinary. With mkiv, it compiles cleanly:


mkiv lua stats  > used engine: luatex version: 1.13, functionality 
level: 7420, banner: this is luatex, version 1.13.0 (tex live 2021)

mkiv lua stats  > used hash slots: 48846 of 65536 + 25
mkiv lua stats  > lua properties: engine: lua 5.3, used memory: 212 MB, 
ctx: 210 MB, max: unknown MB, hash chars: min(64,40), symbol mask: utf (τεχ)
mkiv lua stats  > runtime: 2.775 seconds, 119 processed pages, 119 
shipped pages, 42.883 pages/second

system  | total runtime: 5.996 seconds

When I compile the same document with luametatex, things slow down to a 
crawl:


mkiv lua stats  > used engine: luametatex version: 2.0921, functionality 
level: 20210903, format id: 594, compiler: gcc
mkiv lua stats  > tex properties: 740039 hash slots used of 2097152, 
48372 control sequences, approximate memory usage: 36 MB
mkiv lua stats  > lua properties: engine: lua 5.4, used memory: 100 MB, 
ctx: 93 MB, max: 138 MB, symbol mask: utf (τεχ)
mkiv lua stats  > runtime: 27.509 seconds, 119 processed pages, 119 
shipped pages, 4.326 pages/second

system  | total runtime: 139.458 seconds of 139.493 seconds

So, it takes more than 20 times as long... The CPU of my computer goes 
up to 100 %, and the entire machine sometimes becomes unresponsive 
during the run. Obviously, I can't provide a MWE, but this seems 
bizarre. One thing I see on my terminal: there are hundreds of lines 
like this


Overfull \hbox (0.8pt too wide) in paragraph at lines 18--18
6:17:  [glue][glue][glue][boundary][hlist][penalty][glue][hlist][penalty] >[glue][glue]


It's almost like some debug setting has been triggered. But that may be 
a red herring. Anyway, I just wanted to report this; maybe some bigger 
problem (with the binary or the format?) is lurking somewhere.


All best

Thomas
___
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] metafun: circular arc

2021-10-05 Thread Thomas A. Schmitz via ntg-context


Thank you so much, Hans, that's a neat solution! I was banging my head 
against the wall, but this makes sense.


On 10/5/21 6:38 PM, Hans Hagen wrote:

Because you know how to rotate and scale:

\startuseMPgraphic{empedocless}
path p, q, r ;
pair a ;

p := fullcircle scaled 10cm ;
drawarrow p  withpen pencircle scaled 1mm withcolor red ;
draw    point 0 of p withpen pencircle scaled 1mm withcolor blue ;
q := p cutafter (point .4 along p) ;
drawarrow q  withpen pencircle scaled .5mm withcolor green ;
draw followtext(q, "\strut TEXT ONE") ;

p := fullcircle scaled 8cm ;
drawarrow p  withpen pencircle scaled 1mm withcolor cyan ;
draw    point 0 of p withpen pencircle scaled 1mm withcolor magenta ;
q := p cutafter (point .3 along p) ;
q := q rotated 120 ;
drawarrow q  withpen pencircle scaled .5mm withcolor yellow ;
draw followtext(q, "\strut TEXT TWO") ;

% the real deal: best make a macro for this

p := fullcircle scaled 6cm ;
draw    point 0 of p withpen pencircle scaled 5mm withcolor blue ;
drawarrow p  withpen pencircle scaled 1mm withcolor red ;
a := (point eps of p) rotated 45 ;
draw a withpen pencircle scaled 2mm;
q := p cutafter a ;
q := q rotated 20 ;
drawarrow q  withpen pencircle scaled .5mm withcolor green ;
draw followtext(q, "\strut TEXT TWO") ;

\stopuseMPgraphic

\useMPgraphic{empedocless}

So, just always start at point 0 and then just rotate the cutof piece 
over the angle that you want. The eps in the last case makes that we 
actually have a cut off piece (zero fails here).


So ... solution 4. best suits non math gurus (like you and me).


This is the part of your reply that fails to convince. You don't even 
know how bad I am at math...


Thanks, and all best

Thomas
___
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] metafun: circular arc

2021-10-05 Thread Thomas A. Schmitz via ntg-context


Hi all,

I hope the following example is not too convoluted:

\useMPlibrary [txt]

\define\EmpArrow{\getscaledglyph{1.6}{name:dejavumath}{\char"2B05}}

\setupbodyfont [ss,9pt]

\starttext

\startuseMPgraphic{empedocles}
%numeric a ; a = 6.56cm ;
%numeric b ; b = 1.1 ;
save S; path S[] ;
S[1] = fullcircle scaled 8cm rotated 306 ;
S[2] = S[1] scaled 1.1 ;
S[3] = S[1] scaled 1.23 ;
S[4] = S[1] scaled 1.3 ;
S[5] = S[1] scaled 1.43 ;
S[6] = S[1] scaled 1.5 ;
S[7] = S[1] scaled 1.6 ;
z[1] = point 1 along S[7] ;
z[2] = point 1 along S[1] ;
z[3] = point 0.1 along S[7] ;
z[4] = point 0.1 along S[1] ;
z[5] = point 0.2 along S[7] ;
z[6] = point 0.2 along S[1] ;
z[7] = point 0.3 along S[7] ;
z[8] = point 0.3 along S[1] ;
z[9] = point 0.4 along S[7] ;
z[10] = point 0.4 along S[1] ;
z[11] = point 0.5 along S[7] ;
z[12] = point 0.5 along S[1] ;
z[13] = point 0.6 along S[7] ;
z[14] = point 0.6 along S[1] ;
z[15] = point 0.7 along S[7] ;
z[16] = point 0.7 along S[1] ;
z[17] = point 0.8 along S[7] ;
z[18] = point 0.8 along S[1] ;
S[8] = z[1] -- z[2] ;
S[9] = z[3] -- z[4] ;
S[10] = z[5] -- z[6] ;
S[11] = z[7] -- z[8] ;
S[12] = z[9] -- z[10] ;
S[13] = z[11] -- z[12] ;
S[14] = z[13] -- z[14] ;
S[15] = z[15] -- z[16] ;
S[16] = z[17] -- z[18] ;
z[19] = S[3] intersection_point S[8] ;
z[20] = S[3] intersection_point S[16] ;
S[18] = S[3] cutbefore z[20] cutafter z[19] ;
z[21] = S[5] intersection_point S[8] ;
z[22] = S[5] intersection_point S[16] ;
S[19] = S[5] cutbefore z[22] cutafter z[21] ;
z[23] = S[12] intersection_point S[3] ;
S[20] = S[3] cutbefore z[20] cutafter z[23] ;
for i = 1 upto 16:
draw S[i] withcolor 0.7white ;
endfor ;
draw z[23] -- z[20] withcolor red ;
draw S[20] withcolor blue ;
label.bot(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
20.000 = 0}"), z[10]) ;
label.llft(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
2.000}"), z[8]) ;
label.lft(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
4.000}"), z[6]) ;
label.lft(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
6.000}"), z[4]) ;
label.ulft(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
8.000}"), z[2]) ;
label.urt(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
12.000}"), z[18]) ;
label.rt(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
14.000}"), z[16]) ;
label.rt(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
16.000}"), z[14]) ;
label.lrt(textext("\noexpand\framed[align=middle,frame=off]{Jahr \crlf 
18.000}"), z[12]) ;
draw followtext(S[18], "\strut\hbox to 2em{\EmpArrow}\hskip2em 
RUHEPAUSE\hskip4em\strut") ;
draw followtext(S[19], "\strut\hbox to 2em{\EmpArrow}EINHEIT 
(SPHAIROS)\hskip2em\strut") ;

\stopuseMPgraphic

\useMPgraphic{empedocles}

\stoptext

I have a big problem and some smaller questions, for those who are 
better at math and at metafun than I am:


1. The big problem: for the next followtext, I need the circular arc 
between points z[23] and z[20]. But however I place the cutbefore and 
cutafter, I don't get the proper part of the circle. I'm looking at the 
right intersection points, as the red line shows, but the blue line 
shows that I'm not getting the right section of the circle. How can I 
get this section into the path S[20]?


2. Math... :-) Is there a better way to define three circles that are at 
exactly the same distance than my naive "scaled 1.3" and "scaled 1.5"?


3. TeX and metafun: is there a better way to have the followtext exactly 
centered between the two circles rather than just fiddle with the scale 
factor?


4. Or is there a better approach to my problem altogether? I'm trying to 
reproduce an illustration from a book, so I'm very open to suggestions 
here. I looked at the example in the metafun manual chapter 10.4, but 
I'm not sure if using an overlay and multiple \followtokens would be 
easier. Especially since there is the scary remark "This definition is 
not the right one!" in this chapter without any further explanation.


I hope you all had a wonderful meeting last week. I was sad I couldn't 
come, I was in Paris for a conference, the first after 18 months, so I 
couldn't skip this one.


Thanks and best wishes

Thomas
___
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] Create an enumeration style

2021-08-11 Thread Thomas A. Schmitz via ntg-context

> On 11. Aug 2021, at 10:09, Otared Kavian via ntg-context  
> wrote:
> 
> Thanks for the example and the fix, but I would rather think that the « 
> french » part of ordinals should be
> 
>   french = function(n)
>   if n == 1 then
>   return « er"
>   else
>return « ème"
>   end
>   end,

Except if you have something like “1ère image”… Ah, languages are so messy (no 
pun with recent events in Paris intended).

Thomas
___
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] Harvard bibliography style

2021-08-10 Thread Thomas A. Schmitz via ntg-context
To get you started: the APA standards are defined in publ-imp-apa.mkvi and 
publ-imp-apa.lua. You could try and copy these files to different names 
(beginning with publ-imp-) and then make changes. You’ll have to replace the 
“apa:” prefix with the name you give your own style. From my experience, it is 
easier to start with empty files and then add definitions as you go than to 
modify the APA files; they are very complex and pull in lots of definitions 
from other files. In general: people here will be more willing to help if they 
see you make some effort to help yourself.

> On 10. Aug 2021, at 13:03, Jorge Manuel via ntg-context  
> wrote:
> 
> Alan,
> 
> Sorry for the insistence, but I need some help in setting up my bibliography. 
> I want to continue to use context, but there is no out-of-the-box solution 
> for bibliographic references that are based on the harvard agsm style (this 
> is the standard in my country).

That’s not relevant to your questions, is it?

> 
> 1. Parenthetical citations
> 
>   I need to remove the comma between de name and year. For example, the 
> APA standard produces (Alan, 2021) I want (Alan 2021).
> 

The comma is defined in l. 360-7 in publ-imp-apa.mkvi:

\definebtx
  [apa:\s!cite:authoryear]
  [apa:\s!cite:author]
  [\c!left={(},
   \c!right={)},
   \c!inbetween={\btxcomma},
   \c!separator:names:3={\btxcomma\textampersand\space},
   \c!separator:names:4={\btxspace\textampersand\space}]

So instead of inbetween=\btxcomma, you could try inbetween=\btxspace

> 2. Articles in bibliography
> 
>  I need te remove de parenthesis in year and add single quotes in the 
> article title. 
> 
> The standard are:
> Surname of the author(s) of the article, Initials Year of publication, 
> ‘Article title in single quotes’, Journal title: title complement, Volume 
> number, Issue number, Article pages.
> 
> Example: 
> Higson, R 2010, ‘Conceptual artists’ war on complacency’, Australian, 16 
> November, p. 15. 

The period after the initial is controlled by

\setupbtx [stopper:initials=]

Which you can find in publ-ini.mkxl. The default value is stopper:initials={.}, 
you can simply delete the {.} part, and there will be no period.

The double quotes are defined in publ-imp-default.mkvi, l. 144-8:

\definebtx
  [\s!default:\s!list:title:article]
  [\s!default:\s!list:title]
  [\c!style=, % journal is set in italics
   \c!command=\quotation] 

You can either replace command=\quotation with command=\quote or adapt the 
symbol for quotations for your language, e.g.

\setuplanguage[en]
[leftquotation=\upperleftsinglesixquote,
 rightquotation=\upperrightsingleninequote]

Which would of course set the single quotes for all English text in your 
document.

Once again: bibliographies are infinitely complex (if you read the source, you 
will find a couple of heartfelt outbursts from Hans), you’ll see that some 
changes have undesirable side effects, and it will take time to accomplish what 
you need. I have found it easier to start with very simple definitions and then 
add bells and whistles; the files in the distribution are complex because they 
follow complex standards and try to define all possible cases. This may be a 
bit overwhelming for a relative beginner.

3.Other documents
> 
> I have other changes, but if I understand how can adapte  the article 
> bibliographic style I can make my own changes  for other documents. 

Possible.

Good luck.

Thomas
___
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] Code document and simpleslides and create in one go the document with simpleslides added

2021-07-31 Thread Thomas A. Schmitz via ntg-context


On 7/31/21 4:06 PM, Pablo Rodriguez via ntg-context wrote:

BTW, I cannot get simpleslides working with LMTX.



I had to make some slight adjustments but have been to lazy to upload a 
new and improved version. One reason being that I can't remember my 
username and password for the modules section of the garden... I'll have 
to ask Taco to reset it for me.


Thomas
___
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] Code document and simpleslides and create in one go the document with simpleslides added

2021-07-31 Thread Thomas A. Schmitz via ntg-context


On 7/31/21 3:27 PM, Jeroen via ntg-context wrote:

Is there an easy way to write a Context document and also code simpleslides
in the same document so that the simpleslides are automatically added to
the document as for example an appendix? Ie one tex document with Context
code, perhaps with some \input and something like a two-pass job. I was
thinking if the simpleslides could be saved as a number of png images and
then with the recurse add them to the document with placefigure.


"Easy" is an ambiguous term... I can tell you how I do this (I use xml, 
but with a bit of code, this can be adapted to TeX documents): I have 
the code for the slides and my own comments in the same documents; I 
pass a --mode to the compilation to filter and select content. When I 
have my presentation as a file "presentation.pdf," I save it and then 
have the slides included automatically via a counter, like this:


function xml.functions.combined_slide(t)
i = i + 1
local textwidth = tex.dimen.textwidth
context.page()
	context.framed( { width=number.todimen(textwidth), frame="off", 
align="middle", height="10cm" },
		function() context.externalfigure( { "presentation.pdf" }, { page=i, 
width="13cm" } ) end )

context.blank { "line" }
end

So, as others have said: no need to convert to png. Setting up a 
workflow takes some time and thought, but once it's in place, it works 
very well; I have now used my xml-based workflow for 12 years or so, for 
all my university lectures and talks.


Thomas
___
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] Strange new behaviour of the mailing list

2021-07-31 Thread Thomas A. Schmitz via ntg-context


On 7/31/21 11:41 AM, Denis Maier via ntg-context wrote:

I think so too. Especially since the original sender's address isn't included in 
"reply to all" messages.
I think it's an improvement. I have never understood why the original 
sender needs an additional mail, on top of the one (s)he receives from 
the list.


Thomas
___
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] ligature exceptions

2021-07-28 Thread Thomas A. Schmitz via ntg-context

Hi all,

just two quick questions: a couple of weeks ago, there was a long 
discussion on ligature exceptions in, e.g., German. Hans provided an 
elegant new mechanism (\startlanguageoptions). So my two questions:


1. Is the old mechanism (\replaceword[eg][Auflage][Au{fl}age]) now 
obsolete? I tried using it, but unwanted ligatures still occurred. If it 
is indeed deprecated, I'll add a note to the wiki (this would mean that 
the current texlive version does not have the new mechanism and the 
latest lmtx doesn't use the old one, so that's somewhat problematic).


2. Both mechanisms only work for complete words, is that right? So I 
can't just provide a pattern such as "uf|forder," I have to provide a 
full list with all inflected forms:


auf|fordern
auf|fordert
auf|fordernd
Auf|forderung
Auf|forderungen

and for 1-3 also the forms with a capital letter.

Thank you!

Thomas
___
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] reusableMPgraphic

2021-07-15 Thread Thomas A. Schmitz


On 7/15/21 11:10 PM, Jairo A. del Rio wrote:

Hi, list! Is this already fixed in a new upload? I'm compiling old
documents and having the same problem as Thomas, although Wolfgang's
comment fixes it nicely.

Cordially,


There hasn't been a new upload since I asked my question, so for the 
time being, you have to apply the patch yourself.


Thomas
___
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] reusableMPgraphic

2021-07-12 Thread Thomas A. Schmitz
Hi all,

I don’t know if I’m overlooking something really basic or if this is a bug. The 
following MWE compiles with mkiv, but not with lmtx:

\startreusableMPgraphic{fold}
   fill unitsquare xyscaled (1mm,1mm) withcolor blue ;
\stopreusableMPgraphic

\definelayer[foldingmarkslayer][width=\paperwidth,height=\paperheight]
\setlayer[foldingmarkslayer][y=101mm,x=11mm]{\reuseMPgraphic{fold}}

\setupbackgrounds [page][background=foldingmarkslayer]

\starttext

Test

\stoptext

The error I get:

tex error on line 6 in file ./test.tex: Use of \meta_usempgraphic_nop doesn't 
match its definition

Any pointers? Thanks

Thomas
___
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] font feature

2021-07-09 Thread Thomas A. Schmitz

> On 8. Jul 2021, at 23:33, Hans Hagen  wrote:
> 
> you forgot the 'default' so you basically force basemode which is does 
> permanent features .. add/subtract works only in node mode
> 
> \definefontfeature
>  [f:onum]
>  [onum=yes,pnum=yes]
> 
> \definefontfamily [test] [serif] [AntykwaTorunska] [features={default,f:onum}]
> \definefontfamily [test] [sans]  [Myriad Pro]
> \definefontfamily [test] [mono]  [DejaVu Sans Mono]
> \definefontfamily [test] [math]  [Xits Math]
> 
> \setupbodyfont[test,12pt]
> 
> \starttext
>test 1 2 3 test 1/2 \subtractfeature[f:onum] test 1 2 3 test 1/2
> \stoptext

Thank you, Hans, this works! I’m looking for a place to add this information to 
the “featuresets” page on the wiki, will do this soon!

All best

Thomas
___
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] font feature

2021-07-08 Thread Thomas A. Schmitz


Hi all,

is it possible to subtract a featureset that has been applied to a 
fontfamily? MWE:


\definefontfeature
  [f:frac]
  [frac=yes,onum=no,pnum=no]

\definefontfeature
  [f:onum]
  [onum=yes,pnum=yes]

\definefontfamily [test] [serif] [AntykwaTorunska] [features=f:onum]
\definefontfamily [test] [sans]  [Myriad Pro]
\definefontfamily [test] [mono]  [DejaVu Sans Mono]
\definefontfamily [test] [math]  [Xits Math]

\setupbodyfont[test,12pt]

\starttext

Mozarts erster Satz ist ein
{\subtractfeature[f:test]\addfeature[f:frac]4/4}-Takt, Beethoven wählt 
einen Dreiertakt, Mozarts Romanze ist ein 3/8-Takt, Beethoven wählt 
einen 2/4,
Mozarts Rondo ist eine Gavotte im 2/2-Takt, Beethoven schreibt ein 
Jagdrondo im 6/8-Takt.


\stoptext

If I comment out the part [features=f:onum], I get the fractions that 
I'm looking for, but it seems that I can't get the same effect with 
\subtractfeature and \addfeature. I'm confused...


Thanks and all best

Thomas
___
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] Question about "streams" module

2021-06-22 Thread Thomas A. Schmitz


On 6/22/21 5:43 PM, MANUEL GONZALEZ SUAREZ wrote:

Hello everybody:
  My question is this: Is the "streams" module obsolete? If not, where can I 
find documentation on its use?
Thanks
M. González.


Hans is working on a new mechanism and has recently been thinking about 
integrating (some of) the functionality of this module. As far as I 
remember, it was mkii. (And I was the one who pushed Hans to do work on 
it, but could never really come up with a reasonable interface and 
specifications.) So I would say yes, it is more or less obsolete; I 
wouldn't start a project with it.


Thomas
___
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] LMTX and my custom typescripts

2021-05-28 Thread Thomas A. Schmitz

> On 28. May 2021, at 18:40, Michael Guravage  
> wrote:
> 
> Any encouragement in how to resolve this would be much appreciated.
> 

Hi Michael,

Try renaming it to type-imp-DollyPro.tex (and then of course 
\usetypescriptfile[type-imp-DollyPro]), that should help. This changed a couple 
of months ago and was announced on the list, so shame on you for not following 
our discussions religiously…

Best

Thomas
___
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] TeX capacity exceeded

2021-05-19 Thread Thomas A. Schmitz


On 19.05.21 18:34, Hans Hagen wrote:



Can you check the latest upload? You should be able to go way higher.



Yes, with 2021.05.19 18:22, the file compiles again in lmtx! I'm also 
trying your suggestions for improving the Lua code and rethinking my 
tables for analyzing the vocabulary. Thank you for the quick fix! And I 
hope there won't be any problem for other users - I'm aware that memory 
on computers can differ vastly. I sometimes run ConTeXt on my raspberry 
pi 3, which has just 1 G of RAM, whereas my newish iMac at home has 40 
G. So it's difficult to find the sweet spot that will satisfy everybody...


All best

Thomas
___
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] TeX capacity exceeded

2021-05-17 Thread Thomas A. Schmitz


Hi all,

I have a rather large (almost 120,000 lines) xml file, processing pulls 
in another large xml file. The project compiles under mkiv; with lmtx, I get


tex error   > tex error on line 8 in file : TeX capacity exceeded, 
sorry [reference count=32767]


 \reallanguagetag

just twenty pages shy of the end of the document.

There is an error log with this content:

return {
 ["errortype"]=3,
 ["filename"]="",
 ["lastcontext"]="\n\n\n \\reallanguagetag \n\n 
\\reallanguagetag #1->\\ifcsname \\??languagelinked #1\n\\endcsname 
\\lastnamedcs \\else #1\\fi \n \\setusedlanguage #1->\\edef 
\\currentusedlanguage {\\reallanguagetag {#1}\n}\\ifempty 
\\currentusedlanguage \\let \\currentusedlanguage \\currentlanguage 
\\always\\let \\usedlanguageparameter \\languageparameter \\orelse \\ifx 
\\currentusedlanguage \\v!global \\let \\currentusedlanguage\n\n 
\\typo_delimited_push ...\\currentdelimitedtext {#1}\\edef 
\\m_delimited_argument {#2}\\ifempty \\m_delimited_argument 
\\typo_delimited_set_language_nop \n\\else 
\\typo_delimited_set_language_yes \\fi \\let 
\\currentparentdelimitedtext \\currentdelimitedtext \\global \\advance 
\\c_typo...\n\n \\delimitedtext [#1]#*[#2]->\\dontleavehmode 
\\typo_delimited_push {#1}{#2}\n\\edef \\p_delimited_method 
{\\delimitedtextparameter \\c!method }\\ifx \\p_delimited_method 
\\v!font \\expandafter \\typo_delimited_fontdriven \\else \\expandafter 
\\typo_delimited_other \\fi \n\n \n 
{\n...\n\n \n",

 ["lastluaerror"]="",
 ["lasttexerror"]="TeX capacity exceeded, sorry [reference count=32767]",
 ["lasttexhelp"]="If you really absolutely need more capacity, you can 
ask a wizard to enlarge me.",

 ["linenumber"]=8,
 ["offset"]=10,
 ["skiplinenumber"]=8,
}

 In mkiv, these are the stats at the end of the run:

mkiv lua stats  > used config file: selfautoparent:/texmf/web2c/texmfcnf.lua
mkiv lua stats  > used cache path: 
/mnt/shared/lmtx/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e
mkiv lua stats  > resource resolver: loadtime 0.009 seconds, 1 scans 
with scantime 0.005 seconds, 0 shared scans, 27 found files, scanned 
paths: /home/tas/texmf
mkiv lua stats  > stored bytecode data: 455 modules (0.122 sec), 96 
tables (0.007 sec), 551 chunks (0.130 sec)
mkiv lua stats  > traced context: maxstack: 1422, freed: 2, unreachable: 
1420

mkiv lua stats  > cleaned up reserved nodes: 63 nodes, 9 lists of 442
mkiv lua stats  > node memory usage: 17 attribute, 4 attribute_list, 1 
glue, 51 glue_spec, 3 kern, 2 penalty, 2 temp, 2 user_defined
mkiv lua stats  > node list callback tasks: 8 unique task lists, 9336 
instances (re)created, 177413 calls

mkiv lua stats  > h-node processing time: 4.800 seconds including kernel
mkiv lua stats  > attribute processing time: 0.617 seconds front- and 
backend

mkiv lua stats  > driver time: 0.886 seconds
mkiv lua stats  > used backend: pdf (backend for directly generating pdf 
output)

mkiv lua stats  > jobdata time: 0.161 seconds saving, 0.052 seconds loading
mkiv lua stats  > callbacks: internal: 261417, file: 319, direct: 3, 
late: 31831, function 200128, total: 493698 (464 per page)

mkiv lua stats  > randomizer: resumed with value 0.47143577262518
mkiv lua stats  > positions: 9535 collected, 9535 regular, 0 special
mkiv lua stats  > v-node processing time: 0.401 seconds
mkiv lua stats  > result saved in file: plutarchusvitae.pdf, 
compresslevel 3, objectcompresslevel 1

mkiv lua stats  > loaded patterns: de::3 en::1 la::65, load time: 0.000
mkiv lua stats  > xml load time: 0.648 seconds, 4 files, 4 converted
mkiv lua stats  > lxml preparation time: 0.626 seconds, 233814 nodes, 
578788 lpath calls, 578743 cached calls

mkiv lua stats  > interactive elements: 0 references, 37 destinations
mkiv lua stats  > margin data: 10798 entries, 0 pending
mkiv lua stats  > loaded fonts: 9 files: garamondpremrpro.otf, 
sabonltstd-bold.otf, sabonltstd-italic.otf, sabonltstd-roman.otf, 
kadmosu.otf, oldstandard-bold.otf, oldstandard-italic.otf, 
xitsmath-regular.otf, dejavusansmono.ttf
mkiv lua stats  > font engine: otf 3.113, afm 1.513, tfm 1.000, 17 
instances, 6 shared in backend, 0 common vectors, 6 common hashes, load 
time 0.146 seconds
mkiv lua stats  > used platform: linux-64, type: unix, binary subtree: 
texmf-linux-64
mkiv lua stats  > used engine: luatex version: 1.13, functionality 
level: 7420, banner: this is luatex, version 1.13.0 (tex live 2021)

mkiv lua stats  > used hash slots: 47131 of 65536 + 25
mkiv lua stats  > lua properties: engine: lua 5.3, used memory: 601 MB, 
ctx: 579 MB, max: unknown MB, hash chars: min(64,40), symbol mask: utf (τεχ)
mkiv lua stats  > runtime: 22.310 seconds, 1068 processed pages, 1068 
shipped pages, 47.871 pages/second

system  | total runtime: 213.928 seconds


Is texmfcnf.lua still the configuration file I need to look at for this 
kind of problem? Which variable could I change?


Thanks, and all best

Thomas

Re: [NTG-context] randomize direction of arrow in metafun

2021-05-15 Thread Thomas A. Schmitz

On 5/15/21 2:42 PM, Mikael Sundqvist wrote:

Hi,

you could do something like this:

\startMPpage
for i = 0 upto 10:
  drawarrow if uniformdeviate(1)<0.5: reverse fi ((0,0)--(2cm,0)) yshifted i*cm;
endfor;
\stopMPpage

/Mikael


Hi Mikael,

wonderful, thanks for the quick answer! Yes that works as intended!

Thomas
___
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] randomize direction of arrow in metafun

2021-05-15 Thread Thomas A. Schmitz

Hi all,

for a slide template, I want to draw colored arrows in a randomized 
color (from a list of colors). This works (and the code is far too 
clever for me, I must have copied it somewhere):


save mycolor ; color mycolor[] ;
mycolor[1] := (0.2, 0.3, 0.4) ;
mycolor[2] := (0.6, 0.6, 0.4) ;
mycolor[3] := (0.5, 0.8, 0.5) ;

so I can write

drawarrow p withcolor mycolor[round(uniformdeviate(9))] ;

But I also want the direction of the arrow to be random. My first idea 
was to define a variable that would expand either to "reverse" or the 
empty string right after drawarrow, but that's where I'm stuck. Anyone 
has an idea how to achieve this? (It's probably somewhere in the source, 
but I can't find it.) And is the method of defining the random color OK, 
or could this also be improved.


Thanks, and all best

Thomas
___
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] Fuzzy lines

2021-05-14 Thread Thomas A. Schmitz

> On 13. May 2021, at 21:42, Henning Hraban Ramm  wrote:
> 
> Hi Thomas,
> 
> for my test files you only also need Aditya’s latest mp-sketch.mp, now 
> attached.
> 
> Find also attached my (somewhat simplified) attempt on a cover for a new 
> workbook series.
> In the original I’m using the commercial "Supernett Cn" font family that also 
> looks quite sketchy.
> 
> Hraban

Perfect, thank you, that allowed me to play a bit with it. Would be interested 
to see what you really want to achieve one day…

All best

Thomas
___
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] Fuzzy lines

2021-05-13 Thread Thomas A. Schmitz

On 5/13/21 8:02 PM, Henning Hraban Ramm wrote:

Unfortunately, the deviation of edge points is too big – try my attached test 
file.

Strangely, if I include the MP code in a ConTeXt document,


I find the discussion interesting. Could you send complete documents, 
like Aditya did? When I try to compile your files, I get all sorts of 
errors, so I suspect they are not complete. Would be appreciated if you 
could send a ConTeXt document. I'm still not quite sure what you're 
looking for...


Thomas

\setupbodyfont[20pt]

\showframe

\startuseMPgraphic{fuzzy}

path p ; p := (0,0) -- (0,OverlayHeight) -- (OverlayWidth,OverlayHeight) --
(OverlayWidth,0) -- cycle ;

pickup pencircle scaled .5pt ;

for i=1 upto 20 :
 draw p enlarged -5pt randomized 15pt withcolor blue ;
endfor ;

\stopuseMPgraphic

\defineoverlay [Fuzzy] [\useMPgraphic{fuzzy}]

\startTEXpage


\framed [height=20cm,width=12cm,frame=on,background=Fuzzy,align={middle,lohi}]
{Test}

\stopTEXpage

test.pdf
Description: Adobe PDF document
___
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] Corrupt PDF files with LMTX?

2021-04-24 Thread Thomas A. Schmitz

On 24.04.21 08:03, Jairo A. del Rio wrote:

Hi, list!
When I try to convert a PDF generated by ConTeXt LMTX to PNG using
ImageMagick's convert the following happens:

 Error: stream Length incorrect.
Output may be incorrect.
 Error:  An error occurred while reading an XREF table.
 The file has been damaged.  This may have been caused
 by a problem while converting or transfering the file.
 Ghostscript will attempt to recover the data.
 However, the output may be incorrect.
Error: /ioerror in --runpdf--
Operand stack:
post_eof_count   4096   --nostringval--   4571
Execution stack:
%interp_exit   .runexec2   --nostringval--   runpdf   --nostringval--
2   %stopped_push   --nostringval--   runpdf   runpdf   false   1
%stopped_push   1990   1   3   %oparray_pop   1989   1   3   %oparray_pop
1977   1   3   %oparray_pop   1978   1   3   %oparray_pop   runpdf   runpdf
   runpdf   runpdf   runpdf   runpdf   runpdf
Dictionary stack:
--dict:735/1123(ro)(G)--   --dict:1/20(G)--   --dict:80/200(L)--
--dict:80/200(L)--   --dict:135/256(ro)(G)--   --dict:315/325(ro)(G)--
--dict:28/32(L)--
Current allocation mode is local
GPL Ghostscript 9.50: Unrecoverable error, exit code 1
convert-im6.q16: FailedToExecuteCommand `'gs' -sstdout=%stderr -dQUIET
-dSAFER -dBATCH -dNOPAUSE -dNOPROMPT -dMaxBitmap=5
-dAlignToPixels=0 -dGridFitTT=2 '-sDEVICE=pngalpha' -dTextAlphaBits=4
-dGraphicsAlphaBits=4 '-r300x300'
  '-sOutputFile=/tmp/magick-55690XUwDR8veJQEc%d'
'-f/tmp/magick-55690zbxNvSPCVCYe' '-f/tmp/magick-55690aVvG11u3p8wd'' (1) @
error/pdf.c/InvokePDFDelegate/291.
convert-im6.q16: no images defined `151.png' @
error/convert.c/ConvertImageCommand/3258.

I'd blame ImageMagick, except for the fact that 1) other converters fail
too and 2) it doesn't happen with ConTeXt MkIV (PDF is successfully
converted).

Cordially,

Jairo


Very interesting! I have seen similar behavior these past days (I think 
it's very recent) but thought it was something in my documents. Hans, MWE:


I have two test files, simply with

\starttext

Test

\stoptext

I try to concatenate the resulting pdf files with qpdf:

qpdf test1.pdf --pages test1.pdf test2.pdf -- result.pdf

And I get these warnings (though the resulting file appears to be OK):

WARNING: test1.pdf (xref stream: object 18 0, offset 4154): expected 
endstream
WARNING: test1.pdf (xref stream: object 18 0, offset 4078): attempting 
to recover stream length
WARNING: test1.pdf (xref stream: object 18 0, offset 4078): recovered 
stream length: 64

WARNING: test1.pdf (object 3 0, offset 4179): expected endstream
WARNING: test1.pdf (object 3 0, offset 2982): attempting to recover 
stream length

WARNING: test1.pdf (object 3 0, offset 2982): recovered stream length: 887
WARNING: test2.pdf (xref stream: object 18 0, offset 4215): expected 
endstream
WARNING: test2.pdf (xref stream: object 18 0, offset 4139): attempting 
to recover stream length
WARNING: test2.pdf (xref stream: object 18 0, offset 4139): recovered 
stream length: 65

WARNING: test2.pdf (object 3 0, offset 4241): expected endstream
WARNING: test2.pdf (object 3 0, offset 3050): attempting to recover 
stream length

WARNING: test2.pdf (object 3 0, offset 3050): recovered stream length: 880
qpdf: operation succeeded with warnings; resulting file may have some 
problems




___
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] xml processing in latest

2021-04-21 Thread Thomas A. Schmitz


On 4/21/21 10:34 AM, denis.ma...@ub.unibe.ch wrote:

Hi

What's the exact issue?



You're not using the latest version:

2021.04.20 18:45

Thomas
___
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] xml processing in latest

2021-04-21 Thread Thomas A. Schmitz


Hi all,

the latest has some strange problems with xml processing. The example 
below shows an issue with itemize. In my real file, I also get pages 
that are filled only two thirds and rugged right instead of justified, 
but I haven't been able to reproduce this in a MWE. Maybe this one can 
give a start; I assume it's some fundamental typo somewhere.


All best

Thomas

\startbuffer[test]

  test


one


two



\stopbuffer

\startxmlsetups xml:testsetups
\xmlsetsetup{#1}{*}{-}
\xmlsetsetup{#1}{document|p|numbered|item}{xml:*}
\stopxmlsetups

\xmlregistersetup{xml:testsetups}

\startxmlsetups xml:document
\xmlflush{#1}
\stopxmlsetups

\startxmlsetups xml:p
\xmlflush{#1} \par
\stopxmlsetups

\startxmlsetups xml:numbered
\startitemize [n]
\xmlflush{#1}
\stopitemize
\stopxmlsetups

\startxmlsetups xml:item
\startitem
\xmlflush{#1}
\stopitem
\stopxmlsetups

\starttext
\xmlprocessbuffer{main}{test}{}
\stoptext
___
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] autopdf on MacOS?

2021-04-16 Thread Thomas A. Schmitz

On 4/16/21 10:26 AM, Hans Åberg wrote:

That it doesn’t update in the background is more a feature than a bug, 
otherwise it would complain about broken/unavailable files during the TeX runs.

It is likely a bug: It has worked in some past versions.


It still works for me (I'm on the latest version of macos). The trick is 
to not change the focus to the pdf document in preview until the TeX run 
has finished; otherwise you get a dialogue box complaining about a 
broken pdf document. It also helps that ConTeXt now displays the 
colorful "error" page when something goes wrong; otherwise, preview crashes.


Thomas
___
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] issue field in bibliography

2021-03-29 Thread Thomas A. Schmitz


On 3/29/21 10:45 AM, Damien Thiriet wrote:


I have questions related with a journal named "Documentation
photographque". Each issue is devoted to another theme. How
should I declare this theme in bibliography fields when quoting
articles? It is quite important to get it, because the main article
is always named « Le point sur… » (I don't know exactly how to translate
it in English. Something like "an overview of…") so quoting it makes
only sense if the issue is named, at best after the title or the number.
I thought issue may do it. Am I right? Or would be comment a better
place?


Are you asking about the ConTeXt implementation you want to implement or 
about the actual bibliographic representation you want on the page? If 
the former, we need more information: what style are you using for the 
list, what citation style? Show us some code, make a MWE. In both cases, 
we need an example of what your bibliographic entry should look like. 
Right now, we can only guess.


Thomas
___
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] bug in lmtx

2021-03-09 Thread Thomas A. Schmitz

Hi Hans,

I've found a very interesting bug in lmtx. The following MWE gives the 
expected result in mkiv; in lmtx, one character is missing. Perhaps you 
can figure out what's happening...


All best

Thomas

\setupbodyfont [gentium, 12pt]

\starttext

Test \hskip1em ἀβ

Test \hskip1em ἁβ

\stoptext
___
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] lmtx error: You can't use 'integer 340' in internal vertical mode

2021-02-23 Thread Thomas A. Schmitz


On 2/23/21 6:14 PM, Hans Hagen wrote:
I have no clue because it just works here. I uploaded a new version (no 
real changed in that area) so who knows ...



Are you sure? You have to compile with the --arrange switch. I just 
tested with 2021.02.23 17:47, still same error.


Thomas
___
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] lmtx error: You can't use 'integer 340' in internal vertical mode

2021-02-23 Thread Thomas A. Schmitz

On 20.02.21 17:12, Hans Hagen wrote:
hm, but it still makes sense to know if something fails .. keep en eye 
on it


I just stumbled upon the same error. Arranging is broken in lmtx. MWE:

\setuppapersize[A6][A4]

\setuparranging[2*4]

\starttext

\dorecurse{8}{Test: \recurselevel \page}

\stoptext

Works in mkiv. With lmtx, I get

tex error   > tex error on line 7 in file ./test.tex: You can't use 
'integer 340' in internal vertical mode


All best

Thomas
___
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] Loop?

2021-02-12 Thread Thomas A. Schmitz

On 2/12/21 7:39 PM, Angel M Alganza wrote:

Is it possible to do that with just ConTeXt or would I need to resort to
Lua.  I guess it should be possible both ways, but I haven't figure out
how to do it.  Any pointer, please?


https://wiki.contextgarden.net/Processing_Lists

which wasn't particularly difficult to find.

Thomas
___
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] composing commands

2021-02-05 Thread Thomas A. Schmitz


On 2/5/21 10:30 PM, Hans Hagen wrote:

Is this ok for you?

tex error   > tex error on line 6 in file ./oeps.tex: Undefined 
control sequence


 \v

  4
  5 \starttext
  6 >>  \v
  7 \stoptext
  8


Otared has already replied what I was thinking: would it be possible, 
for a certain period of time, to not stop compilation, but flag the 
issue on the console? When you say that such changes won't happen 
suddenly, this would be a wonderful compromise for me. My consolidated 
bibtex database began its life many many years ago, when bibtex was 
still pure 7bit, and you had to pepper your sources with all sorts of 
silly workarounds in order to get accents and umlauts and whatever you 
wanted. Those were the days - barefoot through the snow, and it was 
uphill both ways...


Thomas
___
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] composing commands

2021-02-05 Thread Thomas A. Schmitz


On 2/5/21 5:38 PM, Hans Hagen wrote:
etc ... the ones that make 'composed characters'. I think that anyone 
who needs them uses utf . They can be in (say) m-oldschool.mkxl or so.


Objections? Hurt feelings? Sentiments?


No hurt feelings, but I know that in my bib files, there are a couple of 
old entries that still have these weird composed characters. So I'm fine 
with upgrading, but it would be nice if this could fail gracefully, with 
a nice and informative error message...


All best

Thomas
___
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] Bib support broken in lmtx

2021-01-30 Thread Thomas A. Schmitz


On 1/30/21 10:50 AM, Philipp A. wrote:

Am I caught in a spam filter somewhere?



Compiles fine here with 2021.01.28 18:22

Thomas
___
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] code 139

2021-01-29 Thread Thomas A. Schmitz


> On 29. Jan 2021, at 17:55, Otared Kavian  wrote:
> 
> Out of curiosity I tested your MWE and I get 
> 
>   mtx-context | fatal error: return code: 11

Maybe lmtx uses the random number generator to produce its return codes? :-)

Thomas
___
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] code 139

2021-01-29 Thread Thomas A. Schmitz

> On 29. Jan 2021, at 16:27, Hans Hagen  wrote:
> 
> fixed in next upload

Thank you for the fix!

Thomas
___
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] code 139

2021-01-29 Thread Thomas A. Schmitz


On 1/29/21 12:56 PM, Hans Hagen wrote:
Hard to say (probably some mem/stack issue) ... you can add a 
\tracingall around the place where the last message to the console 
happens ... i need to know where it happens (or you can themn make a mwe 
of that bit).


OK, here's a minimal example. I defined this environment some years ago 
and have no clue why I did it this particular way (there must have been 
a reason), so don't ask me. But it gives the "return code: 139."


\define[1]\italianpoetry%
{\framed[frame=off,offset=0pt,strut=no,width=10cm]{\framed[frame=off,strut=no,offset=0pt,width=fit,align=right]{\em 
#1}}}


\starttext

\italianpoetry{
Morremo. Il velo indegno a terra sparto,
}

\stoptext

Thomas
___
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] code 139

2021-01-29 Thread Thomas A. Schmitz


Hi all,

a complex file with a metafun background does not compile anymore with 
lmtx. It compiles fine with mkiv. Compilation breaks off after 10 pages 
(maybe that's significant) with this message:


pages   > flushing realpage 10, userpage 10, subpage 10
mtx-context | fatal error: return code: 139

What is code: 139? Where should I start looking for the culprit?

All best

Thomas
___
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] lmtx: new text & math font stuff

2020-12-30 Thread Thomas A. Schmitz


On 12/30/20 4:53 PM, Hans Hagen wrote:

As usual, it opens up possibilities, but of course at the price of testing.


Hans,

I had seen the alignment bug as well; this has been fixed in today's 
upload. I'm in a book project (from xml), so I don't have small examples 
right now, but I want to point out that there are two more areas where 
current lmtx has serious problems that luatex doesn't have:


1. I have a bibliography that is structured in sections. lmtx does not 
respect the scope of these sections, but prints the entire 
bibliographical list at the first occurrence of 
\placelistofpublications. I wasn't sure if I had the right keywords and 
experimented an entire afternoon before I realized this was a bug in lmtx...


2. For some reason, lmtx introduces lots of empty pages into my 
document. When I compile my book with luatex, I get 176 pages at the 
moment, in lmtx, I have 208. Must be something about chapter breaks and 
so on.


I will try in the next days to come up with examples, but right now, I'm 
working on a chapter and don't want to interrupt the flow...


As always, thanks for your work on context, and best wishes for 2021 - 
may it suck less that 2020!


Thomas
___
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] markings in lmtx and luatex

2020-11-23 Thread Thomas A. Schmitz


Hi all,

something has changed in the way markings are handled. Consider the 
following example:


\definemarking[Section]

\setupheadertexts[{\getmarking[Section][top]–\getmarking[Section][bottom]}]

\starttext

A\marking[Section]{A}

B\marking[Section]{B}

C\marking[Section]{C}

\page

D\marking[Section]{D}

E\marking[Section]{E}

F\marking[Section]{F}

\page

G\marking[Section]{G}

H\marking[Section]{H}

I\marking[Section]{I}

\stoptext

Compiled with luatex, the result is not quite as expected, but at least 
it goes into the right direction. Compiled with lmtx, "top" and "bottom" 
are always identical. Something appears to be amiss here.


Best wishes

Thomas
___
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] bizarre bug in xml

2020-11-21 Thread Thomas A. Schmitz

On 11/21/20 11:04 AM, Wolfgang Schuster wrote:
To check whether a stretch or shrink value is set LMTX takes a look at 
the next character (p, P, m or M) before it makes a decision, when you 
have now a word after \hskip which start with one of these characters 
(e.g. Materiam) you trigger the scanner which fails because it didn't 
find a keyword. To avoid such problems always add \relax after the last 
value of \hskip, this is even explained in one of the exercises in the 
TeXbook.


Thank you Wolfgang, now it all makes sense. I will relax more and dust 
off my copy of the TeXbook. I used to read small chapters in the tramway 
on my way to the university, but with the lockdown, I didn't have this 
opportunity. Nah, just kidding, I haven't looked at it in a long time.


Thomas
___
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] bizarre bug in xml

2020-11-20 Thread Thomas A. Schmitz


Hi all,

this is the most bizarre bug I've ever seen in context. I would be 
grateful if others could try to replicate it. Test file:


\startbuffer[test]

Materiam vati da Venus alma tuo.

\stopbuffer

\startxmlsetups xml:testsetups
\xmlsetsetup{#1}{*}{-}
\xmlsetsetup{#1}{document|
hskip}{xml:*}
\stopxmlsetups

\xmlregistersetup{xml:testsetups}

\startxmlsetups xml:document
   \xmlflush{#1}
\stopxmlsetups

\startxmlsetups xml:hskip
\hskip\xmlatt{#1}{width}
\stopxmlsetups

\starttext
\xmlprocessbuffer{main}{test}{}
\stoptext

This gives an error with the latest lmtx (2020.11.19 11:28, linux 64 bit):

tex error   > tex error on line 10 in file ./xmltest.tex: Valid 
keyword expected, likely 'minus'



 Ma
teriam vati da Venus alma tuo.
 \22>:xml:document #1->\xmlflush {#1}

 }


 \22>:xml:process #1->\xmlregistereddocumentsetups 
{#1}{#1}\xmlmain {#1}



 \lxml_process ...ocument {#3}#2{#3}{#4}\setcatcodetable 
\notcatcodes \doifelsenothing {#5}{\xmlsetup 
{#3}{xml:process}}{\xmlsetup {#3}{#5}}

\endgroup

 \xmlprocessbuffer{main}{test}{}

The file compiles cleanly if I give the --luatex switch.

Now for the bizarre part: if you delete the capital M of "Materiam" or 
replace it by any other capital letter, the file compiles. What's going 
on here?


Thanks, and all best

Thomas
___
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] latest lmtx

2020-11-14 Thread Thomas A. Schmitz

On 11/14/20 12:17 AM, j.ha...@xs4all.nl wrote:

Take today's upload.



Hi Hans,

since you mentioned that such buglets may occur, here's another one, but 
in this case, the error message is obscure to me, and I have no clue 
where in the environment file it is triggered (it's an xml-project):


tex error   > tex error on line 8 in file cont-yes.mkiv: ?


lua error:

registered function call [382]: [string "..."]:5: attempt to 
call a nil value (global 'scanintegerargument')

stack traceback:
[string "..."]:5: in function <[string "..."]:4>

Does that ring any bell?

All best

Thomas
___
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] latest lmtx

2020-11-14 Thread Thomas A. Schmitz

> On 14. Nov 2020, at 00:17, j.ha...@xs4all.nl wrote:
> 
> Take today's upload.
> 
> Hans
> 
> 
Hi Hans,

Yes, it works again! Thanks for the quick fix; I’m looking forward to new 
adventures in context land…

All best

Thomas
___
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] latest lmtx

2020-11-13 Thread Thomas A. Schmitz

Hi all,

I hadn't upgraded in a couple of weeks because I was in the middle of a 
project. Now that I'm up to 2020.11.08, I have a problem: I can't load 
my third party modules; they all throw an error.


The error message is

Use of \syst_modules_setup_yes doesn't match its definition

So I guess it's the way I have used setupmodule in my modules. I tried 
to find and understand the new code by comparing file-mod.mkvi vs 
file-mod.mklx, and it should be around l. 117-131 of this file, but I 
don't quite see what needs to be changed. A line such as


\setupmodule [scale=1,font=GreekDidot]

for my t-ancientgreek.mkiv works fine with the --luatex switch; in lmtx, 
context chokes on it. What is the new incantation for modules?


Thomas
___
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] Debug mode for XML processing

2020-09-23 Thread Thomas A. Schmitz

On 9/23/20 1:17 PM, Denis Maier wrote:

Hi,

Is there are debug mode for XML processing? I'm thinking of something 
where the XML mapping gets applied to your XML, and you receive a tex 
file as the output. Could sometimes be easier to see where things go off 
the rails.


Best,
Denis


No, context doesn't produce a tex file from your xml. But you could have 
a look at the trackers (https://wiki.contextgarden.net/Trackers) that 
are concerned with xml handling and knock yourself out.


Thomas
___
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] Extreme tables and XML conflict?

2020-09-21 Thread Thomas A. Schmitz

On 9/21/20 4:38 PM, Denis Maier wrote:

Hi,

I'm a bit confused, but this here won't compile:


xtables manual, chapter 13.

Thomas
___
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] columns yet again

2020-09-20 Thread Thomas A. Schmitz

On 9/17/20 3:23 PM, Hans Hagen wrote:

\setuplayout[width=16cm]

\starttext

\enabledirectives[tabulate.linenumbers]

\showframe

\starttabulate[|p(7cm)|A{verytolerant}i2p(\dimexpr9cm-2em\relax)|]
     \NC
     \startlinenumbering
     \dorecurse{10}{\input ward \par}
     \stoplinenumbering
     \NC
     \dorecurse{3}{\input tufte \par}
     \NC \NR
\stoptabulate

\disabledirectives[tabulate.linenumbers]

\starttabulate[|p(7cm)|A{verytolerant}i2p(\dimexpr9cm-2em\relax)|]
     \NC
     \startlinenumbering
     \dorecurse{10}{\input ward \par}
     \stoplinenumbering
     \NC
     \dorecurse{3}{\input tufte \par}
     \NC \NR
\stoptabulate

\stoptext

I'm not sure why there is no key / value interface ... probably because 
I made it one for someone as fast hack.



Thank you, Hans, I had no idea this existed. It looks very fascinating. 
But as far as I could see in the source, there is no possibility of 
setting things up (font, size, start, etc.)?

___
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] Error setting up ConTeXt in MacTeX 2020

2020-09-18 Thread Thomas A. Schmitz
On 18. Sep 2020, at 12:00, Felix Krause  wrote:
> 
> The directory name luatex-cache suggests it's used for caching.

That doesn’t help a lot.

> I interpret the output like „something happens during the generation of the 
> format file and therefore the file never gets generated“. I don't know much 
> about the internals.

What does 

mtxrun --expand-var TEXMFCACHE

return?

Thomas

___
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] Error setting up ConTeXt in MacTeX 2020

2020-09-18 Thread Thomas A. Schmitz


> On 18. Sep 2020, at 11:35, Felix Krause  wrote:
> 
> Hm. I don't have this directory (not using MacPorts) and my error seems to be 
> quite different (the scripts to be executed seem to be found).
> I dug through the thread but for all I can see, nothing there describes my 
> problem or a solution for solving it.

Then tell us a bit more about your system. What is the output of

which -a context

for example? Is 

/var/folders/

the normal path where mactex would expect a format file? I use a Mac, but I 
have vanilla texlive installed; I never quite understood where mactex was any 
better, so I can’t test on my system.

Thomas
___
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] columns yet again

2020-09-13 Thread Thomas A. Schmitz

Hi all,

I hope everybody made it back home safely after the meeting. It was 
great listening in, even if I couldn't be there in person, unfortunately!


Today's question is an old one, but I'm confused. What I need: two 
columns, of unequal width, the left column has line numbering; two 
column layout starts in the middle of pages. What I tried so far:


1. \defineparagraphs  allows to have two paragraphs of unequal width, 
but the line numbering isn't visible:


\setuppapersize[A4,landscape][A4,landscape]

\setuplayout[grid=yes]

\definelinenumbering
   [original]

[step=2,location=text,align=flushright,distance=0.4cm,style=small,color=magenta]

\defineparagraphs [Half] [n=2]
\setupparagraphs [Half] [before=,after=,align=verytolerant]

\setupparagraphs [Half]
 [1]
 [width=0.45\textwidth]

\starttext

\startlinenumbering [original] [start=4]
Poetry

One

Word

Per

Line

is

Poetic

\stoplinenumbering

\nextHalf

Prose translation

\stopHalf

\stoptext

2. columnsets:\usemodule[old-columnsets]: unequal width, but no line 
numbering:


\usemodule [old-columnsets]

\setuppapersize [A4,landscape][A4,landscape]

\setuplayout [grid=yes]

\definecolumnset [numbered] [n=2]
\setupcolumnset [numbered] [distance=0.5cm,frame=on]
\setupcolumnset [numbered:1] [width=4cm]
\setupcolumnset [numbered:2] [width=10cm]

\starttext

\startcolumnset [numbered]

\startlinenumbering[step=1,location=left]
Poetry

One

Word

Per

Line

is

Poetic\par % needed, otherwise last line is not indented correctly
\stoplinenumbering

\column

Two
\stopcolumnset

\stoptext

3. Same example without the first line: line numbers, but width is 
ignored; both columns are of width 0.5\textwidth.


4. page columns: always start at new page.

5. \startcolumns: like 3.; equal width.

In addition, for reasons that are completely unclear to me, the example 
from the columnsets manual (p. 32) does not compile:


\setuppapersize[A4,landscape][A4,landscape]

\setuplayout[grid=yes]

\showframe
\definecolumnset[example][n=3,page=left]
\setupbackgrounds[text][text][background=contrast]
\setupcolumnset[frame=on,framecolor=color-4,rulethickness=1mm]
\definecolor[fakerulecolor][white]
\setupcolumnset[example:1][width=2cm]
\setupcolumnset[example:2][width=4cm]
\setupcolumnset[example:3][width=3cm]
\setupcolumnset[example:4][width=3cm]
\setupcolumnset[example:5][width=4cm]
\setupcolumnset[example:6][width=6cm]
\starttext
\startcolumnset[example]
\dorecurse{5}{
\dorecurse{3}{\fakewords{10}{15}\par}
\column[yes]
}
\stopcolumnset
\stoptext

ends in "tex error   > tex error on line 23 in file /tmp/test.tex: ! 
Undefined control sequence


So I'm a bit confused: what I should use? What is the current status of 
the diverse columns environments?


Have a nice Sunday!

Thomas
___
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] register entries in footnotes

2020-04-26 Thread Thomas A. Schmitz
A similar question has been asked three years ago, and Rik Kabel posted 
a partial solution, adapted here:


\defineprocessor [Footnote] [right={ n}]

\define[1]
  \fnindex{\index[Footnote->]{#1}}

\starttext

This is a sentence with a term in the index: cat\index{cat}. This 
sentence also has an indexed term, dog\index{dog}, as well as a 
footnote.\footnote{The footnote also contains an indexed term, 
mouse.\fnindex{mouse}}


\page

\placeregister [index]

\stoptext

And about a year ago, Hans made a different suggestion to my own 
question; however, I didn't realize then that it was not what I was 
looking for:


\starttext

  Test1: \index{cat}cat.
\footnote{Test2: \index{mouse}mouse.}
\footnote[note:cat]{Test3: \index[cat]{cat in \in{note}[note:cat]}cat.}

\page

\placeregister [index]
\stoptext

This creates two index entries for cat, which is not the intended result.

My questions are:

1. I would like to have the footnote number appear in the index, so it 
says something like "cat 1 n. 1." Is that possible?


2. Is it necessary to define an extra command for index entries in 
footnotes? Is context clever enough to know that it's processing a 
footnote, so one could write a condition such as (pseudocode):


\define [1]
  \myindex
  {\infinfootnoteelse
{\index[Footnote]->{#1}}
{\index{#1}}}

Thanks a lot, have a good Sunday!

Thomas
___
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] Setting vertical spacing of lines inside a \framed[align=]

2020-04-24 Thread Thomas A. Schmitz


> On 24. Apr 2020, at 18:19, Gerben Wierda  wrote:
> 
> \starttext
> 
> \framed[align=flushright,frame=on,offset=none,width=106.400bp]{\colored[r=0.000,
>  g=0.000,
> b=0.000]{\switchtobodyfont[11.0pt] \setupinterlinespace[20pt] \rm 
> [My]\\Application\\(Component)}}
> 
> \stoptext
> 
> and if I change the value to 0.6, only the first line break gets packed 
> somewhat. But I can’t get the entire paragraph inside the frame packed. I 
> played around with the placing of setupinterlinespace in that snippet above, 
> but nothing really works so far.
> 

At the end of your frame, you need an explicit \par to make the change of 
linespacing work:

\framed[align=flushright,frame=on,offset=none,width=106.400bp]{\colored[r=0.000,
 g=0.000,
b=0.000]{\switchtobodyfont[11.0pt] \setupinterlinespace[14pt] \rm 
[My]\\Application\\(Component)\par }}

https://www.mail-archive.com/ntg-context@ntg.nl/msg45676.html

Thomas
___
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] Basic font question (Optima, but no bold, no italics). Standalone ConTeXt does not work. TeX Live 2019 works

2020-04-24 Thread Thomas A. Schmitz


> On 24. Apr 2020, at 09:21, Gerben Wierda  wrote:
> 
> 
> I altready did that earlier as per the Wiki information (did not report it) 
> and just tried again. No difference.

Steps to happiness:

1. Extract the ttc font to ttf
2. Copy the ttf files to your local texmf directory
3. reload the font cache
4. enrich your vocabulary by learning the words “thank you”
5. never have to deal with stupid people who didn’t read all 10,000 lines of 
the log file you posted
6. profit!

Thomas
___
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] Use a counter in a reference?

2020-04-13 Thread Thomas A. Schmitz

On 4/13/20 10:13 PM, Kevin Kenan wrote:

I have a need to tag elements in a text in a way that they are sequentially 
numbered and can have references to refer to them. Something like:


 Here is some \tag[tagref]{\bf text} that is tagged.
 .
 .
 .
 Refer to tag \tagnumber[tagref] on page \at[tagref].


What is the best way to do this in ConTeXt? I’ve got a counter for tag number, 
but I’m not sure how to use \reference so that it uses my tag number. For 
instance:


 \definecounter[myTagCounter]
 .
 .
 .
 \reference[tagref]{\rawcountervalue[myTagCounter]}


Doesn’t work. But perhaps I’m going about this incorrectly?

Thanks in advance!


Are you looking for this: 
https://wiki.contextgarden.net/Command/definelabel ?


HTH

Thomas
___
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] xhtml export internal command \dostarttaging modify display and other XML/XHTML attributes

2020-04-10 Thread Thomas A. Schmitz


> On 10. Apr 2020, at 14:49, Christoph Hintermüller  
> wrote:
> 
> Please increase the USB of ConTeXt by improoving the xml/xhtml exporter
> backend by allowing modules to hook into it, defining how the contotent
> should be processed and what css attributes the corresponding tags
> should receive. 
> 
> Second i noticed that even in verbatim the line numbers are not on the
> line they number but are, due to late injections printed on an empty
> line in xhtml. Needs improvement here too.
> 
> 
> All the above and some more forces me to push my plans to publish my
> lecture notes on programming as pdf and epub to likely next year. And
> helping in Improvement is for now not an option too me for now, exempt
> maybe lateron in testing.
> 
> 
> Happy Easter.

What, precisely, was the point of this long message? 

Thomas
___
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] Using Lua files in project structure

2020-04-05 Thread Thomas A. Schmitz

On 05.04.20 15:00, Jairo A. del Rio wrote:
I'm writing a project in ConTeXt MKIV and I want to load some (pure) Lua 
libraries and bindings (defining \ctxlua and the like). For instance, I 
have the file foo.lua with some macros and I want to use them in my 
project. Something like this:


\startproject project
%\component foo.lua %This does not work
%\environment foo.lua %This does not work
%\input foo.lua %This does not work
%\directlua{dofile("foo.lua")} %This does not work even when the project 
file and foo.lua are in the same folder.

\stopproject

What should I do? Thank you in advance.


Have you tried

\registerctxluafile{foo}{} ?

That's the way context loads its lua files.

Thomas
___
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] Customizing \cite alternatives

2020-02-20 Thread Thomas A. Schmitz

On 20.02.20 14:16, Philipp A. wrote:
Makes sense, seems like no default is defined anymore, so it won’t 
render without using a style.

I use apa, and the attached screenshot shows my problem.


If you use APA, you have to set up the APA cite options. The manual is a 
bit on the short side here, but all the options are mentioned. If you 
want to change the way et al. is displayed (for APA, the default is 
\btxcomma\btxlabeltext{others}), you can do this:


\setupbtx [apa:cite] [otherstext={ et al.}]

The number of authors displayed is defined by the key etaldisplay, so 
you would do this:


\setupbtx [apa:cite] [etaldisplay=4]

Thomas
___
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] Customizing \cite alternatives

2020-02-19 Thread Thomas A. Schmitz
It is difficult to answer your question because we don't know which 
specifications you use for your citations. You will have to provide a 
minimal example that allows us to see what you're doing.


Thomas

On 2/17/20 6:26 PM, Philipp A. wrote:

Hi List,

I want the comma gone from “et al.” citations, and modify the cite 
alternatives:


  * [authoryear]: (Surname, et al., 2018) → (Surname et al., 2018)
  * [authoryears]: Surname, et al. (2018) → Surname et al. (2018)

Also I’d like to configure how many names are the maximum before all 
except the first are replaced by “et al.”
i.e. \setupcitething[maxauthors=3]: (One, Two, Three, & Four, 2018) → 
(One et al., 2018)


How can I do this? I didn’t find anything in the publications manual: 
http://pragma-ade.nl/general/manuals/mkiv-publications.pdf


Best, Philipp

___
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] math font

2020-02-07 Thread Thomas A. Schmitz


> On 7. Feb 2020, at 15:14, Wolfgang Schuster 
>  wrote:
> 
> Does this also happen when you use \definetypeface to set the math font?
> 
> \definetypeface [thomas] [mm] [math] [xits] [default]

No, with this change, the warnings are gone. New syntax? Or user error?

Thomas
___
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] math font

2020-02-07 Thread Thomas A. Schmitz
Hi all, 

in my environment file, I have defined a math font:

\definefontfamily [thomas] [math]  [XITS Math]

and as far as I can see in the log file, this font is found:

system  >9: filename=xits-math.lfg filetype=tex 
foundname=/Users/lmtx/tex/texmf-context/tex/context/fonts/mkiv/xits-math.lfg 
fullname=/Users/lmtx/tex/texmf-context/tex/context/fonts/mkiv/xits-math.lfg 
usedmethod=database

system  >   14: filename=XITSMath-Regular.otf filetype=otf format=otf 
foundname=/Users/lmtx/tex/texmf/fonts/opentype/public/xits/XITSMath-Regular.otf 
fullname=/Users/lmtx/tex/texmf/fonts/opentype/public/xits/XITSMath-Regular.otf 
usedmethod=database

mkiv lua stats  > loaded fonts: 16 files: texgyretermes-bold.otf, 
texgyretermes-italic.otf, texgyretermes-regular.otf, xitsmath-regular.otf, 
dejavusansmono.ttf, gentiumalt-i.ttf, gentiumalt-r.ttf, myriadpro-it.otf, 
myriadpro-regular.otf, kadmosu.otf, monotype  - timesnrmtpro-bold.otf, monotype 
 - timesnrmtpro-italic.otf, monotype  - timesnrmtpro.otf, timesbold.ttf, 
timesitalic.ttf, times-roman.ttf

nevertheless, on the terminal and in the log file, I get dozens of lines with 
this message

fonts   > math: unset for global bodyfont thomas at 11pt

This is with the latest 2020.01.26 19:19. I have a slight suspicion that this 
behavior is new, but I’m not totally sure. It’s just a small nuisance, but 
something is wrong here, I would say?

All best

Thomas
___
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] line numbering within frame

2020-01-26 Thread Thomas A. Schmitz

On 25.01.20 19:17, Wolfgang Schuster wrote:

Before I give the answer to the question we have to go back to a few 
TeX/ConTeXt basics.


Wolfgang, thank you for this careful and helpful reply. It really made 
me understand what is going on here. At the same time, I also feel a bit 
more incompetent now because linenumbering behaves in unexpected ways: 
you can set some values (like the starting number) with the simple 
\startlinenumbering command but not all values. And there's this strange 
difference between luatex and luametatex... Without this mailing list, 
I'd be really lost. So thanks again, and I'm waiting for the official fix!


Thomas
___
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] line numbering within frame

2020-01-24 Thread Thomas A. Schmitz


> On 23. Jan 2020, at 12:45, Tomas Hala  wrote:
> 
> Hi Thomas,
> 
> move definitions and setups for Three and Four before the use of \framed.
> (With TL2019 works.)
> 
> Wishes,
> 
> Tomáš

Thank you for the hint - we’re still waiting for an answer to Wolfgang’s bonus 
question. But I have continued testing and discovered what is certainly a bug. 
Here’s a new example:

\setbreakpoints [compound]

\definelinenumbering
   [original]
   [style=\tx\ss,distance=-1ex,step=5,location=inleft,start=10,color=darkred]

\definelinenumbering
   [translation]
   [style=\tx\ss,distance=-1ex,step=5,location=inleft,start=50,color=darkblue]

\starttext

\framed 
  [background=color,
   backgroundcolor=gray,
   align={normal},
   frame=off,
   loffset=6ex,
   width=\textwidth,
   foregroundstyle=\ss]
{\startlinenumbering[original]
 \input knuth 
 \stoplinenumbering
  \blank [line]
   \startlinenumbering[translation]
   \input klein
   \stoplinenumbering}

\stoptext

If you compile it, you will see that the “color” key of the two defined 
linenumbering environments is not followed. If you comment out the first line 
\setbreakpoints [compound], you will get two colors, as expected. I leave it as 
an exercise for Hans and Wolfgang to explain what’s going on here :-)

Thomas
___
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] line numbering within frame

2020-01-23 Thread Thomas A. Schmitz


> On 23. Jan 2020, at 22:32, Wolfgang Schuster 
>  wrote:
> 
> 
> Bonus question: Why is it necessary to put \definelinenumbering before 
> \framed?
> 
> Wolfgang

I would be grateful for an answer because I have no clue ;-) In my real life 
case, I fetch the content of the frame from an xml file. Since not every frame 
has line numbering, I am already inside the frame when I have to define and set 
up the line numbering environment. I can probably code around it, but it makes 
my life definitely more difficult…

Thomas
___
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] line numbering within frame

2020-01-23 Thread Thomas A. Schmitz
Hi all,

I want line numbering within a framed environment, and I need two (at least) 
independent numbering systems. I hit a similar problem in 2016, and Wolfgang 
provided a solution (defining different numbering environment). However, this 
does not work within a frame. The example shows the problem:

\starttext

% This works:
\definelinenumbering[One]
   \setuplinenumbering[One]
   [style=\ss,
  distance=-2ex,
  step=2,
  location=inleft,
  start=20,
  color=darkblue]
 \startlinenumbering[One]
 \input knuth 
 \stoplinenumbering
  
 \blank [line]

   \definelinenumbering[Two]
   \setuplinenumbering[Two]
   [style=\bf,
  distance=-2ex,
  step=3,
  location=inleft,
  start=4,
  color=darkred]
 \startlinenumbering[Two]
 \input klein
 \stoplinenumbering

% This fails:
\framed 
   [background=color,
  backgroundcolor=gray,
  align={normal,hanging,stretch,tolerant},
  frame=off,
  loffset=6ex,
  width=\textwidth,
  foregroundstyle=\ss]
{\definelinenumbering[Three]
   \setuplinenumbering[Three]
   [style=\ss,
  distance=-2ex,
  step=2,
  location=inleft,
  start=20,
  color=darkblue]
 \startlinenumbering[Three]
 \input knuth 
 \stoplinenumbering
   \blank [line]

   \definelinenumbering[Four]
   \setuplinenumbering[Four]
   [style=\bf,
  distance=-2ex,
  step=3,
  location=inleft,
  start=4,
  color=darkred]
 \startlinenumbering[Four]
 \input klein
 \stoplinenumbering}

\stoptext

The framed environment fails with the error message "Missing number, treated as 
zero.” Does anyone know how this can be fixed?

All best

Thomas
___
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] Hyphenation LuaTeX

2020-01-17 Thread Thomas A. Schmitz

On 17.01.20 12:55, Henning Hraban Ramm wrote:

I suspect "patterns" understands only one file, as far as I understood the 
source, but don’t trust me on this.

When you mark your Greek passages with {\agr ἡ Ἑλληνικὴ γλῶσσα} (or 
\language[agr] instead of \agr), you should get the right pattern without that 
setup.


No, since the patterns for Spanish and Greek are utf8, they can 
co-exist, there's no need to mark the Greek passages.




The module simplefonts is obsolete since 2013.


Yes, that's right.

I get both Spanish and Greek hyphenation in a test file:

\mainlanguage[es]
\setuplanguage[es][patterns={es,agr}]
\setupbodyfont[gentium,11pt]

\starttext
\hyphenatedword{ἄνθρωπος selección}
\stoptext

If this fails for OP, he will have to produce a real example, taking out 
irrelevant parts and telling us which version he uses. In the original 
example, there was only "..." which of course doesn't hyphenate.


Thomas
___
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] beta 2019.12.02 18:38 fails to build format

2019-12-04 Thread Thomas A. Schmitz


> On 4. Dec 2019, at 15:33, Hans Hagen  wrote:
> 
> it means that your binary doesn't match the tex files (it is a new feature, 
> mentioned a few days before at this list)

OK, I see - after wiping everything and a fresh download, lmtx works again - 
there is a problem with line breaks, I’ll try to come up with an example. But 
shouldn’t install.sh keep binaries and tex file in sync? 

Thomas
___
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] beta 2019.12.02 18:38 fails to build format

2019-12-04 Thread Thomas A. Schmitz
Hi all,

has this already been reported? On my macOS machine, the latest lmtx beta fails 
to build the format with this error:

tex error   > tex error on line 99 in file hand-ini.mkxl: ! Undefined 
control sequence

 ...ansion :\currentexpansion }{\adjustspacingstep 
  \expansionparameter \c!ste...
\define_expansion ...i \the \everydefineexpansion 
  \let \currentexpansion \sa...
 \syst_helpers_triple_empty_two_nop 
\par 
l.99 
   
I have looked at the file, but couldn’t find the source of the error.

All best

Thomas
___
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] How to get attribute value from xml tag?

2019-10-20 Thread Thomas A. Schmitz


> On 20. Oct 2019, at 16:05, Geert Verhaag  wrote:
> 
> The \xmlfirst{#1}{distance} yields 20, but how can the unit attribute value 
> km be accessed?
> 
> Gerard
> 
> 

\xmlattribute{#1}{/distance}{unit}

(probably, you need to make a real example. See xml-mkiv.pdf, chapter 3.6)

Thomas
___
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] arrows in FLOW charts

2019-10-07 Thread Thomas A. Schmitz
Hi all,

I may be missing something really obvious: is it possible to change the shape 
of single connection lines in the flowchart module? Let’s say in the following 
example, I want the connection between test2 and test3 dashed and blue. Can 
this be done?

Thanks, and best wishes

Thomas

\usemodule[chart]

\setupFLOWcharts [nx=1,
ny=3]

\setupFLOWlines [color=red]

\startFLOWchart [example]
  \startFLOWcell
\name {test1}
\location {1,1}
\shape {action}
\text {test 1}
\connection [bt] {test2}
  \stopFLOWcell
  \startFLOWcell
\name {test2}
\location {1,2}
\shape {action}
\text {test 2}
\connection [bt] {test3}
  \stopFLOWcell
  \startFLOWcell
\name {test3}
\location {1,3}
\shape {action}
\text {test 3}
  \stopFLOWcell
\stopFLOWchart

\starttext
\FLOWchart [example]
\stoptext
___
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] beta

2019-09-30 Thread Thomas A. Schmitz

On 29.09.19 16:31, Hans Hagen wrote:

Hi,

A week ago we had the (nice and pleasant) annual context meeting and as 
usual some new stuff has been presented there which was not yet in the 
distribution at that moment. Some pending code is now being moved into 
the distribution. Part is font related (lmtx only, not relevant for most 
users), most is metafun (luametafun or metafun xl or whatever name 
suits) related (including a new preliminary manual) which uses some new 
interfaces and therefore (currently) is lmtx only.


Hi Hans,

I just updated. I had to delete the cache for context to work again, got 
weird errors compiling a file that works normally. So my question: since 
creating a new cache and format takes only a few seconds, wouldn't it 
make sense to include it in install.sh ?


All best, thanks for the new version

Thomas
___
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] Size of the font (Metapost + xtable)

2019-09-23 Thread Thomas A. Schmitz



On 9/23/19 4:12 PM, Fabrice Couvreur wrote:

Hello,
I can not change the font size of my figures in the table.
Thank you
Fabrice



Does changing

\usecolors [xwi]

to

\usecolors [ema]

help?

All best

Thomas
___
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] about SimpleSlides

2019-08-02 Thread Thomas A. Schmitz

On 7/30/19 8:06 AM, Atsuhito Kohda wrote:

Hi all,
SimpleSlides is very useful for novice users so I do use it.
But I encountered few problems which, I'm afraid, might be known.


Hi,

sorry, I'm on my vacation right now; I'll look into this in two weeks, 
when I'm back home.


All best

Thomas
___
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] mapping seeregister command to xml

2019-07-04 Thread Thomas A. Schmitz

Hi,

I'm having trouble mapping the seeregister command to an xml setup. 
Example (looks somewhat messy, but explains why I need it):


\startbuffer[test]

  This is a test. IGRR 4, 988sort="IGRR4+988" target="TAM 2 677">IGRR 
4+988 = TAM 2, 677sort="TAM2+677">TAM 2+677


\stopbuffer

\startxmlsetups xml:testsetups
\xmlsetsetup{#1}{*}{-}

\xmlsetsetup{#1}{document|p|inscription|seeinscription|emph|index}{xml:*}
\stopxmlsetups

\xmlregistersetup{xml:testsetups}

\startxmlsetups xml:document
\xmlflush{#1}
\stopxmlsetups

\startxmlsetups xml:p
\xmlflush{#1} \par
\stopxmlsetups

\startxmlsetups xml:emph
{\em \xmlflush{#1}}
\stopxmlsetups

\startxmlsetups xml:inscription
\expanded{\inscription[\xmlatt{#1}{sort}]{\xmlflush{#1}}}
\stopxmlsetups

\startxmlsetups xml:seeinscription

\expanded{\seeinscription[\xmlatt{#1}{sort}]{\xmlflush{#1}}{\xmlatt{#1}{target}}}
\stopxmlsetups

\defineregister[inscription][inscriptions]

\setupregister[inscription][pagestyle=,
textstyle=,
location=right,
prefix=none,
indicator=no]

\starttext
\xmlprocessbuffer{main}{test}{}
\blank [line]
\placeregister[inscription]
\stoptext

Maybe my problem is with expansion in index entries? I must admit that I 
haven't really grasped why the \expanded was necessary and what it does...


All best

Thomas
___
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] two (2) questions about footnotes

2019-05-27 Thread Thomas A. Schmitz

On 05/27/2019 09:35 AM, Hans Hagen wrote:


   Test1: \index{Adam}Adam.
\footnote{Test2: \index{Eve}Eve.}
\footnote[note:abel]{Test3: \index[Abel]{Abel in 
\in{note}[note:abel]}Abel.}


\page

\placeregister [index]
\stoptext


Ah excellent, thanks a lot, that makes everything clear!

All best

Thomas
___
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] two (2) questions about footnotes

2019-05-27 Thread Thomas A. Schmitz

Hi all,

I have two questions/problems about footnotes. Here is a minimal 
example, which does not compile in this form:


\unexpanded\def\MyRule{\blackrule[width=\textwidth,height=3pt]}
\setupfootnotes[rule=\MyRule]

\starttext
Test1: \index{Adam}Adam.\footnote{Test2: \index{Eve}Eve.}
\page
\placeregister [index]
\stoptext

(1) In my current project, the publisher wants the rule separating text 
and notes to extend across the entire text width. I found the \blackrule 
command and its use in the setup on the mailing list, many years ago, 
proposed by Steffen Wolfrum, but it doesn't work (anymore?); I get "tex 
error on line 3 in file /tmp/test.tex: ! Missing \endcsname inserted." 
Any hints?


(2) Again, something that has been asked on the mailing list, but not 
received any replies: would it be possible to have the index report that 
"Eve" occurs inside a footnote? So it says "Eve 1 n. 1" or something 
like that?


Thanks a lot, and all best

Thomas
___
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] Remove italics from bibliography list

2019-05-17 Thread Thomas A. Schmitz

On 5/17/19 12:41 PM, Dmitry Starostin wrote:

I tried several variants, but I cannot find where exactly the switch
happens.

\definebtx[apa:list:title:incollection][apa:list:title][style=]
\definebtx[apa:list:title:book][apa:list:title][style=]

\definebtx[apa:list:journal][apa:list][style=]


Since a number of questions about custom bibliographic styles came up 
during the past few days, I have created a section on the wiki that 
explains how one can get started with creating their own custom setups 
from scratch; it's at 
https://wiki.contextgarden.net/Bibliography_mkiv#Custom_bibliographical_styles


For further questions, please remember that it is considered polite to 
create complete minimal working examples, not just send code snippets 
that leave everybody guessing what it is you want to achieve.


All best

Thomas
___
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] PDF output routine in lmtx

2019-04-30 Thread Thomas A. Schmitz
> On 29. Apr 2019, at 11:46, Christian Prim  wrote:
> 
> Hi
> 
> in lmtx the pdf output routine has changed afaik. I just wanted to report, 
> that in lmtx our printer/copier (Ricoh 8200S or Ricoh 8110S) doesn't print 
> any character. A standard document as the MWE prints well under mkiv. Under 
> lmtx, there is no output (blank sheet). In a document with a tikz-figure, the 
> tikz-figure (without labels, as they are text) is printed. Something with 
> text output must have changed, that makes it incompatible with the copier at 
> our school. I tried to print with different drivers and also used the 
> printers interface (direct print via usb-stick). No success. Are they some 
> flags I can play with (like other pdf-version or so) to find a solution to 
> this problem? This "bug" prevents me to use lmtx at out school.
> 
> MWE:
> 
> \starttext
> That is a test.
> \stoptext
> 
> Of course there is no problem with the preview and the output works on a 
> HP-Printer.

I have no solution, unfortunately, but I can add that I see similar problems. 
In my case, the printer is a HP LaserJet 1320. The page looks perfectly fine on 
screen; when I print it out, several Greek letters are replaced by questions 
marks in a small rectangular box. When I compile the same file with regular 
context mkiv, everything is printed as intended. So I’m at a loss…

Thomas
___
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] index "compress" option / collapsing of page numbers

2019-04-03 Thread Thomas A. Schmitz


> On 3. Apr 2019, at 10:56, Henning Hraban Ramm  wrote:
> 
> Thank you – it’s not only a German habit, even if we pronounce it “folgende”, 
> “f.” stems from Latin “folio”, and “ff.” is a duplicated abbreviation, as was 
> usual in mediaeval Latin.
> So, this is at least used in English, German, Norwegian and Swedish, as far 
> as I could find. In French they seem to use “sq.” and “sqq.” (sequens).

I’m not sure the abbreviation for “folio” has anything to do with our German 
“folgende”; if you have a link for this, I would like to know. And for the 
record: “ff.” for page ranges is now discouraged in most scholarly 
publications; journals and publishers now say f. for x - x+1, or exact page 
numbers.

Thomas
___
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] Welcome to LMTX

2019-04-02 Thread Thomas A. Schmitz

On 02.04.19 11:34, Rudolf Bahr wrote:

whereis mtxrun gives:
mtxrun: /home/sam/context/tex/texmf-linux-64/bin/mtxrun

whereis context gives:
context: /usr/local/context /home/sam/context/tex/texmf-linux-64/bin/context


Hmm - you're still using your old context, it should say 
/home/sam/context-lmtx/tex/texmf-linux-64/bin/mtxrun


Which shell are you running?
___
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] environment variable for runtime

2019-02-27 Thread Thomas A. Schmitz

Hi,

I would like to typeset the runtime information that context displays at 
the end of typesetting:


mkiv lua stats  > runtime: 174.639 seconds, 913 processed pages, 913 
shipped pages, 5.228 pages/second

system  | total runtime: 526.583 seconds

Is this stored in any environment key? How could I access it?

Thanks

Thomas
___
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] New logo proposal

2019-01-30 Thread Thomas A. Schmitz

On 1/30/19 1:50 PM, Willi Egger wrote:

I would say, that the multicolor version is dissecting the word ConTeXT to 
unidentifiable crumbles. It is to my taste to less connected to typesetting, 
herewith agreeing partly with Clyde.


It is useless to argue about taste, but it may be of interest to see how 
users react. I would agree with Willi. The colors look too random to me. 
A fine-tuned palet with  a smaller range of colors that are visually and 
intuitively related would be preferable, IMHO. But again: de gustibus 
non est disputandum; if Paul likes this look, he should by all means use 
it in his presentations and documents.  And of course, thanks for 
sharing your design with us!


Thomas
___
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] Sorting registers method for "uppercase like lowercase, diacritics ignored"

2019-01-20 Thread Thomas A. Schmitz

On 20.01.19 21:59, Marcus Vinicius Mesquita wrote:

Well, I tried all possible permutations thereof, and also the predefined
methods, and none gives what my editor wants, which is just "uppercase like
lowercase, diacritics ignored".
See MWE attached.
Please, would somebody help me achieve the desired result?


Your example doesn't contain any uppercase letters. Which makes it a bit 
difficult to test what you're looking for. I must admit that I'm not 
very familiar with register "methods," I assume that Wolfgang or Hans 
will be able to tell you how to use them. For your case, if you merely 
want to get rid of all distinctions between upper- and lowercase, 
accents, etc., you could use

Lua (slightly modified example):

\mainlanguage[pt]
\defineregister [nome]
\setupregister  [nome] [
  language=pt,
  n=1,
]

\startluacode
  userdata = userdata or { }
  function userdata.indexing(s)
t = characters.lower(characters.shaped(s))
context.nome( { t }, s)
  end
\stopluacode

\def\mynome#1%
  {\ctxlua{userdata.indexing([==[#1]==])}}

\starttext

\mynome{árvore}árvore \mynome{Äard}Äard \mynome{água}água 
\mynome{Água}Água  \mynome{abnegação}abnegação \mynome{alegria}alegria 
\mynome{agrilhoado}agrilhoado \mynome{anjo}anjo \mynome{ódio}ódio 
\mynome{orgulho}orgulho \mynome{Åz}Åz \mynome{Åaaa}Åaaa \mynome{Özz}Özz 
\mynome{Öaa}Öaa


\page[yes]

\placeregister [nome]

\stoptext
___
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] final thoughts on experiments with lua

2019-01-09 Thread Thomas A. Schmitz
I've finished testing my lua script, and it does exactly what I need. I 
think I'll write a small article about it for one of the next context 
group proceedings, but wanted to just give a very brief summary that 
might be of interest to some:


Pure Lua is wonderful, but as the language is deliberately kept very 
small, one sometimes has to find rather cumbersome workarounds. If you 
run Lua under ConTeXt (with mtxrun --script), you get a version with 
batteries included, which is perfect for manipulating and analyzing 
text. Some areas that I found particularly impressive:


1. I've tried several times to make use of lpegs. Hans' code is full of 
it, and I know that it's fast and extremely versatile, but I found it 
difficult to wrap my head around its functioning and write useful code 
with lpegs. The ConTeXt wrapper makes this extremely easy; this is lpeg 
for the rest of us. It's really a delight to build patterns and see them 
work immediately!


2. The utf library and string manipulation with characters.(...) is 
absolutely necessary if you want to handle non-ASCII text because pure 
Lua gives very unexpected results in this area. These operations work 
wonderfully with the context libraries.


3. Lua's handling of tables is very efficient and fast. For analyzing my 
Greek texts, I have to use huge tables for morphological parsing, with 
more than 900,000 entries. Looking up words in these tables is around 3x 
faster in Lua than in python!


One final thought: one limitation that I still find cumbersome to work 
around is the fact that associative arrays ("pairs" in Lua speak) do not 
have an order. When I analyze my texts, I want book numbers, chapters, 
paragraphs preserved in the order in which they are read (entered into 
the table). In many cases, it is not possible (or extremely awkward) to 
sort these numbers, since chapters may be numbered something like 2, 2a, 
3, 3α, 3β etc. python has the OrderedDict() in its collections module. 
In Lua, the best I could find was entering the chapter numbers into an 
array (ipair) and then retrieve it from there. Maybe there is a better way?


All of this just to say how grateful I am for the way Hans, Taco, 
Wolfgang, Luigi, and the other developers have enhanced Lua. Thanks 
guys, you make my work much more pleasant and efficient!


Thomas
___
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] further experiments with lua

2019-01-09 Thread Thomas A. Schmitz

On 1/9/19 9:47 AM, Hans Hagen wrote:
mtxrun has al the basic modules in it but not the character ones 
(thinking of it, i can add an autoload for that, maybe i should do that)


so you need:

require "char-ini"


Hans, Luigi,

thanks a lot, that solves it! Maybe autoload or at least a small hint in 
cld-mkiv.pdf?


Thomas
___
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] further experiments with lua

2019-01-08 Thread Thomas A. Schmitz

Hi Hans,

I'm doing some further experiments with the utf and lpeg libraries. This 
code fails, and I don't understand why:


local s = "Ä"

print(characters.uccode(s))

mtxrun --script test.lua


./test.lua:3: attempt to index global 'characters' (a nil value)

Thomas
___
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] papersize problem with latest beta

2019-01-07 Thread Thomas A. Schmitz


> On 7. Jan 2019, at 17:07, Hans Hagen  wrote:
> 
> i uploaded a fix

Sorry, didn’t see the new upload. Thanks, issue is fixed!

Thomas
___
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] papersize problem with latest beta

2019-01-07 Thread Thomas A. Schmitz
Hi Hans,

the latest and greatest (2019.01.07 10:07) has a problem with papersizes. MWE:

\setuppapersize[A6]

\showframe

\starttext

Hello world

\stoptext

All best

Thomas
___
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] lua lpeg + utf8

2019-01-06 Thread Thomas A. Schmitz

On 06.01.19 23:08, Hans Hagen wrote:

what do you mean with "running luatex alone" ; you can run scripts with

mtxrun --script yourscript foo.txt

(or do you mean something different)


Hi Hans,

thanks, this is what I meant! I guess I was trying to reinvent the wheel 
and doing things in pure Lua, but processing utf8 is indeed much easier 
with all the context functions. So thanks, I hope I can take it from here!


Thomas
___
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] lua lpeg + utf8

2019-01-06 Thread Thomas A. Schmitz

On 06.01.19 19:20, Wolfgang Schuster wrote:

\starttext

\startluacode

print("abcdeφὴὰabcde")

local remap = utf.remapper { a = "y", c = "z", ὴ = "ή", ὰ = "ά" }

print(remap("abcdeφὴὰabcde"))

\stopluacode

\stoptext


Wolfgang, thank you, I should have looked into this manual! Is there an 
easy way to load the necessary additional libraries if I'm running 
luatex alone, outside of mtxrun?


Thomas
___
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] lua lpeg + utf8

2019-01-06 Thread Thomas A. Schmitz

Hi everybody,

best wishes for (the still new) 2019! My question is not strictly a 
ConTeXt problem, but about the way luatex (and pure Lua) can handle utf8 
in lpeg. Here is my Lua example:


mystring = "abcdeφὴὰabcde"

local replace_table = {
  a = "y",
  c = "z",
  ὴ = "ή",
  ὰ = "ά",
}

function replace(s)
local patt = (lpeg.Cs(1)) / replace_table
local parser = lpeg.Cs((patt + 1)^0)
t = parser:match(s)
return t
end

newstring = replace(mystring)

print(newstring)

This will successfully replace "a" and "c," but not "ὴ" or "ὰ" because 
lpeg.Cs(1) sees only the first byte of these multibyte characters. Pure 
Lua complains with an error message; luatex runs, but does not do the 
replacement. What would be a good way to work around this limitation?


All best

Thomas
___
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] book

2018-12-20 Thread Thomas A. Schmitz

On 12/16/18 2:45 PM, Andrea Valle wrote:

sorry
https://www.logos-verlag.de/cgi-bin/engbuchmid?isbn=4466  



This looks very interesting, from a typographical point of view. How did 
you create the music notation examples? Would it be possible to showcase 
a few pages that are particularly complex, on the wiki, for example?


Thomas
___
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] Issues using publications subsystem for non-bibliographic database

2018-12-08 Thread Thomas A. Schmitz

On 08.12.18 20:50, Alan Braslau wrote:

In my incremental development, I place a bibliography at the end of a chapter, 
part, or even section - there is no need for this to be backmatter. Using 
modes, these then can remain or not be rendered as design advances.


I've been following this thread somewhat distractedly... From a 
systematic point of view, Alan is of course right: a reference should 
refer to something, which is normally a list. However, I find myself in 
situations where I want a reference, but this list should not be 
included in the document. Example: you distribute a bibliographical list 
on your handout and want your slides to display the numeric reference, 
but not the list itself. So I wonder if one possible solution would be 
to provide the possibility to have the list calculated but not typeset 
(hidden). In a naive way, I tried something like


\hbox to width 0cm{\placelistofpublications}

but that doesn't work. But I'm sure this should be easily doable? As for 
something like full citation information in the footnote, with 
crossreference (something like "above, n. XXX"): the format seems 
obsolete, I agree, but at least in the humanities, it is still often 
used and would be very handy to have.


All best

Thomas
___
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] regression in bib system

2018-12-05 Thread Thomas A. Schmitz

Hans, Alan,

I'm experiencing a regression with bibliographies in the latest beta 
(2018.12.01 13:20). I haven't been able to reduce it to a MWE yet, but 
here's what I get from my bibliographic files: compilation hangs with 
this message:


close source> level 2, order 8, name 
'/mnt/shared/Documents/excerpts.tex'
close source> level 1, order 8, name 
'/mnt/shared/context/tex/texmf-context/tex/context/base/mkiv/cont-yes.mkiv'

backend > info > no date/time but fake id information will be added

? ^\/mnt/shared/context/tex/texmf-linux-64/bin/context: line 2: 18125

When I hit enter, I get

mtx-context | fatal error: return code: 1

but the produced pdf appears to be correct. The same file compiles fine 
with version 2018.10.02 23:17. I don't have any version in between. I'll 
see if I can produce a MWE, but I wanted to give you a heads up in advance.


All best

Thomas
___
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] ConTeXt source from XML

2018-10-23 Thread Thomas A. Schmitz

> On 23. Oct 2018, at 10:43, Hans Hagen  wrote:
> 
> examples ... i thought that there is a kind of error message on the console 
> (at least in a tex run)

Yes, I often get errors like “can’t close tag  with  on line .” 
But I don’t know in which situations these messages pop up and when context 
simply bails out.

Thomas
___
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] wrong hyphenation in ancient Greek?

2018-10-13 Thread Thomas A. Schmitz

On 13.10.2018 10:05, Pablo Rodriguez wrote:

As far as I know, two consonants in ancient Greek aren’t hyphenated,
when they may begin a word.

Γν may be the beginning of word in Greek (such as γνῶσις), but even LSJ
has no word that begins with γμ.

Am I missing something or should this be improved in the hyphenation
patterns?


You're right, this shouldn't happen. I tried in vain to find the culprit 
in lang-agr.lua and to see more with


\enabletrackers[hyphenator.visualize,hyphenator.steps,languages.patterns]

but failed. Arthur is the guru here, so maybe he has a suggestion?

Thomas
___
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] tex-gyre fonts missing in 2018.07.02 14:39

2018-07-04 Thread Thomas A. Schmitz
Hi Hans,

is it possible that you forgot to include the texgyre fonts in the latest beta? 
I just realized that the directory 
experimental/tex/texmf/fonts/opentype/public/tex-gyre is missing… (and my 
documents are in latin modern)

All best

Thomas
___
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] xml, language, btx problems

2018-06-18 Thread Thomas A. Schmitz



sometimes you need to do

\starttexcode
   ...
\stoptexcode

when inside some special caocode regime (which happens in xml)

Hans


Hans, thank you - that was the golden hint! It works now as I've always 
wanted! And I realize once again that I know far less about ConTeXt than 
I wished and thought...


Wolfgang: thanks for your suggestions, too! I had thought about loading 
the xml document twice, the first time just for extracting the 
"language" information, but felt it was less than elegant and maybe not 
quite efficient (my lecture course xmls tend to have more thah 25,000 
lines). But I didn't provide enough information for you to see the 
easiest solution.


Thanks, I'm a happy camper again (I have to prepare the handout for a 
talk I'm giving next week in Israel...)


Thomas
___
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] xml, language, btx problems

2018-06-18 Thread Thomas A. Schmitz

Hi Alan,

thanks for joining the discussion! Just to answer your two queries about 
my setup:


On 06/18/2018 12:58 AM, Alan Braslau wrote:

Thomas,

Why would the definitions need to be loaded before \starttext?
The bibliographic data can be loaded independent of any rendering or
use definitions.


That's what I deduced from my experiments. When I load the definitions 
in the xml setup of the root element, they are not loaded, but printed 
verbatim to the pdf file. My deduction may be wrong - this is a pretty 
complex setup, in which I produce slides, manuscript (in different 
formats), handout, and bibliography all from the same xml source. So it 
may be some interference/interaction of these complex parts that I don't 
quite understand. I'll continue experimenting...


Also, why don't you write your custom definitions to

handle languages, rather than writing new definition sets based on
language?

There is one stumbling block that made me think I had to have two 
separate setups (in addition to the fact that it makes the source 
cleaner and easier to maintain): I copied publ-imp-apa.* and modified it 
to suit my needs. Now for apa, editors and authors are included in one 
set, e.g., in line 169-171:


categories.book = {
sets = {
author = { "author", "editor", "publisher", "title" },
}

In my German bibliography file, I distinguish between authored volumes 
and edited volumes both for the presentation and for the sorting:


Author, Firstname: Title ...

as opposed to

Edited Volume, hrsg. von Firstname Editor ...

and I found that as long as I had this "set" line in my 
publ-imp-style.lua file, I would always get


Editor, Firstname: Edited Volume, hrsg. von Firstname Editor ...

When I deleted the line, I could get what I wanted. So my inference was 
that for my German bibliography, I needed a different lua and a 
different publ-imp-.tex file. But maybe I was wrong and you have an 
easier approach?


All best and thanks!

Thomas


___
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
___

  1   2   3   4   5   6   7   8   9   10   >