Re: [NTG-context] Fine tuning an index

2020-10-08 Thread jbf
Duncan, have you looked at 
https://wiki.contextgarden.net/Command/setinjector?



You might also need \showinjector. But it should work for indexes 
(register).


Julian

On 9/10/20 2:58 am, Duncan Hothersall wrote:
Fine tuning column and page breaking in an index. This is tricky, 
because there are usually very few "good" places to break an index, 
and automatic breaking seems to alter slightly depending on whether 
interactions are set up or not, but is there a way to manually insert 
a column or page break into the register before or after a certain 
entry, the way there is for a table of contents?
___
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] Hyphenation patterns

2020-10-08 Thread Denis Maier

Hi,

where can I find the hyphenation patterns used by ConTeXt? I have two 
wrongly hyphenated words, and I want to check whether this is due to 
incorrect patterns. (I tried the source browser... not much luck so 
far.) The words are:

1. applicable => hyphenated as applic-able
2. obligated => hyphenated as oblig-ated

I know I can use \hyphenation to correct that, but I wanted to check the 
patterns nevertheless.


Best,
Denis
___
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 patterns

2020-10-08 Thread Henning Hraban Ramm

> Am 08.10.2020 um 17:41 schrieb Denis Maier :
> 
> where can I find the hyphenation patterns used by ConTeXt? I have two wrongly 
> hyphenated words, and I want to check whether this is due to incorrect 
> patterns. (I tried the source browser... not much luck so far.) The words are:
> 1. applicable => hyphenated as applic-able
> 2. obligated => hyphenated as oblig-ated
> 
> I know I can use \hyphenation to correct that, but I wanted to check the 
> patterns nevertheless.

I guess it’s just a valid option.
You can check possible hyphenations like this:

\starttext

{EN: \en\hyphenatedcoloredword{applicable}}

{DE: \de\hyphenatedcoloredword{applicable}}

\stoptext


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

2020-10-08 Thread Tomas Hala
Hi,

you can find patterns on this directory:

texlive/2020/texmf-dist/tex/context/patterns/mkiv/

Best wishes,

Tomáš 

Thu, Oct 08, 2020 ve 05:41:09PM +0200 Denis Maier napsal(a):
# Hi,
# 
# where can I find the hyphenation patterns used by ConTeXt? I have
# two wrongly hyphenated words, and I want to check whether this is
# due to incorrect patterns. (I tried the source browser... not much
# luck so far.) The words are:
# 1. applicable => hyphenated as applic-able
# 2. obligated => hyphenated as oblig-ated
# 
# I know I can use \hyphenation to correct that, but I wanted to check
# the patterns nevertheless.
# 
# Best,
# Denis
# 
___
# 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
# 
___

 Tomáš Hála

Mendelova univerzita, Provozně ekonomická fakulta, ústav informatiky
Zemědělská 1, CZ-613 00 Brno,  tel. +420 545 13 22 28

http://akela.mendelu.cz/~thala
___
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] Fine tuning an index

2020-10-08 Thread Duncan Hothersall
I'm doing my first mkiv index (it took me a long time to upgrade from
mkii!) and I really like the processor feature to format elements
differently. But there are a couple of things I would really like to
achieve that I'm struggling with:

   1. Elided numbers in an index range entry. For example if I have a
   \startregister - \stopregister pair resulting in an index entry like

   entry 354--356

   I would like to be able to make this read

   entry 354--6

   There are different conventions for number span elision but usually
   teens aren't elided so

   entry 314--316

   would become

   entry 314-16.

   It strikes me that if I could set up a processor specifically for page
   number ranges I could possibly write a macro to do elision; but I don't
   think that's currently possible? Maybe it's possible in lua to write code
   which both identifies range page numbers and carries out the elision. I'm
   not quite sure where to start.

   2. Fine tuning column and page breaking in an index. This is tricky,
   because there are usually very few "good" places to break an index, and
   automatic breaking seems to alter slightly depending on whether
   interactions are set up or not, but is there a way to manually insert a
   column or page break into the register before or after a certain entry, the
   way there is for a table of contents?

Sorry for no MWE, for obvious reasons. Any pointers to what might be able
to be done on these would be much appreciated.

Thanks.

Duncan
___
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] Split Table, don't repeat caption

2020-10-08 Thread Denis Maier



Am 07.10.2020 um 18:00 schrieb Denis Maier:

Am 07.10.2020 um 17:46 schrieb Wolfgang Schuster:

Denis Maier schrieb am 07.10.2020 um 17:39:

Hi,

is there a way not to repeat the caption of a multipage natural 
table? I've searched the list archive and it looks the question came 
up a couple of times, but I couldn't find an answer.


If this doesn't help you have to provide a example.
[...]



Ok:

=
\setupcaption[table]
    [location=top]
\starttext

\startplacetable[location=split,title={Title\footnote{footnote}}]
    \bTABLE[split=yes]
    \bTABLEhead
    \bTR \bTD Header 1 \eTD \bTD Header 2 \eTD \eTR
    \eTABLEhead
    \bTABLEbody
    \dorecurse{100}{\bTR \bTD Column 1 \eTD \bTD Column 2 \eTD \eTR}
    \eTABLEbody
    \eTABLE
\stopplacetable
\stoptext


So, the caption appears on each page, and the footnote is attached to 
the last caption. Ideally, the footnote should be attached to the 
first caption. (And, actually, I want the caption only once.)


Ok, I've found a solution:

```
\setupcaption[table][location=top]
\starttext


\startplacetable[location={none,split}]
    \startalignment[middle]
    \placefloatcaption[table][title={Title\footnote{footnote}}]
    \stopalignment
    \bTABLE[split=yes]
    \bTABLEhead
    \bTR \bTD Header 1 \eTD \bTD Header 2 \eTD \eTR
    \eTABLEhead
    \bTABLEbody
    \dorecurse{100}{\bTR \bTD Column 1 \eTD \bTD Column 2 \eTD \eTR}
    \eTABLEbody
    \eTABLE
\stopplacetable
\stoptext
```

That works, but isn't there an easier solution yet? An 
automatic/parameter-based solution would be great. Something like:


=
\setupcaption[table]
    [location=top]
\starttext

\startplacetable[location={split,captiononcefirst},title={Title\footnote{footnote}}] 


   [...]
\stopplacetable
\stoptext



Best,
Denis

___
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] Hyperref-style borders around clickable links

2020-10-08 Thread Pablo Rodriguez
On 10/8/20 12:03 PM, Denis Maier wrote:
> Am 08.10.2020 um 11:49 schrieb Henning Hraban Ramm:
>> [...]
>> And that this is PDF (viewer) styling, not TeX/MP, so there’s
>> probably no further interface, even if it’s possible to set several
>> properties of link borders in e.g. Acrobat.
>
> Anyplace where I can find out more about this?
Hi Denis,

the PDF reference
(https://www.adobe.com/content/dam/acom/en/devnet/pdf/PDF32000_2008.pdf#nameddest=G11.1696585)
contains the information about border styles (also for link annotations).

But ConTeXt hasn’t those styles implemented.

Just in case it helps,

Pablo
--
http://www.ousia.tk
___
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] Hyperref-style borders around clickable links

2020-10-08 Thread Pablo Rodriguez
On 10/8/20 11:40 AM, Denis Maier wrote:
> Am 08.10.2020 um 11:36 schrieb Henning Hraban Ramm:
>>> Am 08.10.2020 um 10:41 schrieb Denis Maier :
>>>
>>> Ok, found a (partial) solution myself in Pablo's question from yesterday...
>>>
>>>  \setupinteraction[state=start]
>>>  \enabledirectives[references.border]
>>>
>>> does that. But how do I configure the borders? Color? Style and so? 
>>> Couldn't find anything on the Wiki.
>> \setupinteraction[color=,contrastcolor=,]
>> lets all links use the basic text color (usually black).
>> You can also set the style.
> Yep, I have that already in my settings.
>>
>> The frames are meant for debugging, probably you can redefine the color;
> So, you would advice against using these frames?

Sorry, Hraban, these link rectangles are always there. Otherwise there
would be no link annotations.

What "\enabledirectives[references.border]" is width to border and color
(so they can be displayed).

See
https://www.adobe.com/content/dam/acom/en/devnet/pdf/PDF32000_2008.pdf#nameddest=G11.1951136.

Just in case it helps,

Paboo
--
http://www.ousia.tk
___
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] Hyperref-style borders around clickable links

2020-10-08 Thread Denis Maier



Am 08.10.2020 um 11:49 schrieb Henning Hraban Ramm:

Am 08.10.2020 um 11:40 schrieb Denis Maier :

Am 08.10.2020 um 11:36 schrieb Henning Hraban Ramm:

Am 08.10.2020 um 10:41 schrieb Denis Maier :

Ok, found a (partial) solution myself in Pablo's question from yesterday...

 \setupinteraction[state=start]
 \enabledirectives[references.border]

The frames are meant for debugging, probably you can redefine the color;

So, you would advice against using these frames?

I thought it might have side effects.

Does anyone know?


But I found in the ML archive:
\enabledirectives[references.border=red]

Thanks., I'll try with this.



And that this is PDF (viewer) styling, not TeX/MP, so there’s probably no 
further interface, even if it’s possible to set several properties of link 
borders in e.g. Acrobat.

Anyplace where I can find out more about this?

Denis
___
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] Disappearing characters with nolig-german-wordlist

2020-10-08 Thread Denis Maier

Hi,

I do as adviced on the Wiki and input the nolig-german-wordlist.tex to 
suppress wrong ligatures. However, I'm seeing strange results:


```
\input nolig-german-wordlist.tex

\starttext
auffasste
auffasse
\stoptext
```

gives me "auffasse auffasse" (see attachment.)

I don't really understand what is happening here. Why is the t 
disappearing.


```
\replaceword[eka][auffasse][au{ff}asse]
\replaceword[eka][auffasste][au{ff}asste]
\setreplacements[eka]

\starttext
auffasste
auffasse
\stoptext
```

This example gives correct results.

Denis



___
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] Hyperref-style borders around clickable links

2020-10-08 Thread Denis Maier

Am 08.10.2020 um 11:36 schrieb Henning Hraban Ramm:

Am 08.10.2020 um 10:41 schrieb Denis Maier :

Ok, found a (partial) solution myself in Pablo's question from yesterday...

 \setupinteraction[state=start]
 \enabledirectives[references.border]

does that. But how do I configure the borders? Color? Style and so? Couldn't 
find anything on the Wiki.

\setupinteraction[color=,contrastcolor=,]
lets all links use the basic text color (usually black).
You can also set the style.

Yep, I have that already in my settings.


The frames are meant for debugging, probably you can redefine the color;

So, you would advice against using these frames?

Denis
___
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] Disappearing characters with nolig-german-wordlist

2020-10-08 Thread Denis Maier

Ok,
I've commented the whole nolig-german-wordlist out piece by piece, and 
it looks like it comes down to this:


```
\replaceword[eka][auffasse][au{ff}asse]
\replaceword[eka][auffasst][au{ff}asst]

\setreplacements[eka]

\starttext
auffasste
auffasse
\stoptext
```

Uncommenting one of the \replacewords makes the wrong replacement disappear.
But I don't see why "auffasste" should trigger an replacement. What is 
happening here?


Best,
Denis
___
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] playing with Windows drag & drop

2020-10-08 Thread context

Hello Pablo,

On 2020-10-07 19:10, Pablo Rodriguez wrote:

On 10/7/20 4:45 PM, cont...@vivaldi.net wrote:

Hello Pablo,

slight correction:

 .bat
call lua.exe -e "os.execute('echo context --purgeall
--arguments=PDFdocument=' .. ([[%1]]):gsub([[\]], '/') .. ' b.tex')"



Many thanks for your reply, Lukas.

I found another workaround at the ConTeXt file (b.tex).

  \cldcontext{string.gsub([[\env{PDFdocument}]], "", "/")}

I don’t know why I needed to add "" instead of "\\". (otherwise, I


I guess that's as Ctx translates "\\" into "\", and you need to have 
"\\" in Lua code.


You could alse write (not tested):

  \cldcontext{string.gsub([[\env{PDFdocument}]], [[\\]], "/")}

Best,

Lukas

kept getting "C://Users//username//Desktop//document.pdf" and similar 
ones).


Many thanks for your help,

Pablo

___
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] Disappearing characters with nolig-german-wordlist

2020-10-08 Thread Denis Maier

Am 08.10.2020 um 13:04 schrieb Hans Hagen:

On 10/8/2020 12:02 PM, Denis Maier wrote:

Hi,

I do as adviced on the Wiki and input the nolig-german-wordlist.tex 
to suppress wrong ligatures. However, I'm seeing strange results:


```
\input nolig-german-wordlist.tex

\starttext
auffasste
auffasse
\stoptext
```

gives me "auffasse auffasse" (see attachment.)

I don't really understand what is happening here. Why is the t 
disappearing.


who knows ... i don't have that file
I took it from the wiki: 
http://wiki.contextgarden.net/images/b/be/nolig-german-wordlist.tex
That's why I didn't attached it to the mail (and, it's too big to post 
here).



```
\replaceword[eka][auffasse][au{ff}asse]
\replaceword[eka][auffasste][au{ff}asste]
\setreplacements[eka]

\starttext
auffasste
auffasse
\stoptext
```

This example gives correct results.

so we're okay
Yes, but it looks like there's something strange going on with that list 
of replacements. (And it's most likely not the works that is getting 
replaced.)


Best,
Denis
___
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] Disappearing characters with nolig-german-wordlist

2020-10-08 Thread Hans Hagen

On 10/8/2020 12:02 PM, Denis Maier wrote:

Hi,

I do as adviced on the Wiki and input the nolig-german-wordlist.tex to 
suppress wrong ligatures. However, I'm seeing strange results:


```
\input nolig-german-wordlist.tex

\starttext
auffasste
auffasse
\stoptext
```

gives me "auffasse auffasse" (see attachment.)

I don't really understand what is happening here. Why is the t 
disappearing.


who knows ... i don't have that file


```
\replaceword[eka][auffasse][au{ff}asse]
\replaceword[eka][auffasste][au{ff}asste]
\setreplacements[eka]

\starttext
auffasste
auffasse
\stoptext
```

This example gives correct results.

so we're okay

Hans

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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] Hyperref-style borders around clickable links

2020-10-08 Thread Henning Hraban Ramm

> Am 08.10.2020 um 10:41 schrieb Denis Maier :
> 
> Ok, found a (partial) solution myself in Pablo's question from yesterday...
> 
> \setupinteraction[state=start]
> \enabledirectives[references.border]
> 
> does that. But how do I configure the borders? Color? Style and so? Couldn't 
> find anything on the Wiki.

\setupinteraction[color=,contrastcolor=,]
lets all links use the basic text color (usually black).
You can also set the style.

The frames are meant for debugging, probably you can redefine the color; ATM 
I’m not patient enough for searching the sources for this (and Wolfgang 
probably knows it from heart anyway).

Hraban
___
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] Hyperref-style borders around clickable links

2020-10-08 Thread Denis Maier

Ok, found a (partial) solution myself in Pablo's question from yesterday...

    \setupinteraction[state=start]
    \enabledirectives[references.border]

does that. But how do I configure the borders? Color? Style and so? 
Couldn't find anything on the Wiki.


Best,
Denis

Am 08.10.2020 um 10:34 schrieb Denis Maier:

Hi,

I prefer links to be styled as normal text, but I'd nevertheless to 
highlight them somehow on screen. The LaTeX package Hyperref adds red 
frames to clickable content. Is something like that possible with 
ConTeXt?


Best,
Denis

___ 

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


maillist : ntg-context@ntg.nl / 
http://www.ntg.nl/mailman/listinfo/ntg-context

webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___ 



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

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] Hyperref-style borders around clickable links

2020-10-08 Thread Denis Maier

Hi,

I prefer links to be styled as normal text, but I'd nevertheless to 
highlight them somehow on screen. The LaTeX package Hyperref adds red 
frames to clickable content. Is something like that possible with ConTeXt?


Best,
Denis

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