[NTG-context] rendering arabic diacritics

2024-05-09 Thread seyal . zavira
Hi all,

when i want to use the linked font for arabic texts it doesn't render 
diacritics properly
i doesn't have problem with this font in inkscape or libreoffice
what featureset should i apply?

font link:
https://drive.google.com/file/d/1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr/view?usp=sharing

this is my MWE:
\definefontfeature [arabis]
 [mode=node,language=dflt,script=arab,
   init=yes,medi=yes,fina=yes,isol=yes,
   liga=yes,dlig=yes,rlig=yes,clig=yes,
   mark=yes,mkmk=yes,kern=yes,curs=yes]
\definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
\setupalign[r2l]
\starttext
{\Ahang تَشْكِيل  كَسْرَة}
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: rendering arabic diacritics

2024-05-09 Thread Hans Hagen

On 5/9/2024 10:03 AM, seyal.zav...@gmail.com wrote:

Hi all,

when i want to use the linked font for arabic texts it doesn't render 
diacritics properly
i doesn't have problem with this font in inkscape or libreoffice
what featureset should i apply?

font link:
https://drive.google.com/file/d/1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr/view?usp=sharing

this is my MWE:
\definefontfeature [arabis]
  [mode=node,language=dflt,script=arab,
init=yes,medi=yes,fina=yes,isol=yes,
liga=yes,dlig=yes,rlig=yes,clig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
\definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
\setupalign[r2l]
\starttext
{\Ahang تَشْكِيل  كَسْرَة}
\stoptext


\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]

but there is an issue with widths, ill send you a patch to test

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 / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: weird \inlinetypebuffer interaction

2024-05-09 Thread Wolfgang Schuster

Pablo Rodriguez via ntg-context schrieb am 08.05.2024 um 18:05:

On 5/7/24 22:37, Wolfgang Schuster wrote:

[...]
\typebuffer disables automatic \endash and \emdash with the
\nohyphencollapsing command
but the command isn't used for \typeinlinebuffer.

Many thanks for your explanation, Wolfgang.

Since \type doesn’t collapse hyphens, wouldn’t it be possible to add
\nohyphencollapsing to \typeinlinebuffer just for the sake of output
consistency?


You can make \typeinlinebuffer behave like \type by adding a second 
initializer which besides other things prevents hyphen collapsing.



buff-ver.mkxl:

\protected\def\buff_verbatim_type_buffer_indeed_inline#1#2%
  {\cdef\currenttype{#1}%
   \buff_verbatim_initialize_type_one
+  \buff_verbatim_initialize_type_two
   \dostarttaggedchained\t!verbatim\currenttype\??type
   \clf_typebuffer
 name   {#2}%
 strip  {\v!yes}%
 regime {\currentregime}%
 method {\p_buff_option}%
 nature {inline}% is default anyway
   \relax
   \dostoptagged}

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

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: rendering arabic diacritics

2024-05-09 Thread Hamid,Idris
Hi Seyal,

See below:

-- Original Message --
From "Hans Hagen" mailto:j.ha...@xs4all.nl>>
To "seyal.zav...@gmail.com" 
mailto:seyal.zav...@gmail.com>>; "mailing list for 
ConTeXt users" mailto:ntg-context@ntg.nl>>
Date 5/9/2024 3:31:45 AM
Subject [NTG-context] Re: rendering arabic diacritics

** Caution: EXTERNAL Sender **

On 5/9/2024 10:03 AM, seyal.zav...@gmail.com 
wrote:
Hi all,

when i want to use the linked font for arabic texts it doesn't render 
diacritics properly
i doesn't have problem with this font in inkscape or libreoffice
what featureset should i apply?

font link:
https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Ffile%2Fd%2F1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr%2Fview%3Fusp%3Dsharing&data=05%7C02%7CIdris.Hamid%40ColoState.EDU%7C8e2b7a1a4eaf46f6b10808dc700b7b2a%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C638508441848485171%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=51bK7I53UxZOK0PcbrYlpX2s%2Bdy%2BK83SslQZ%2BvhnvwU%3D&reserved=0

this is my MWE:
\definefontfeature [arabis]
[mode=node,language=dflt,script=arab,
init=yes,medi=yes,fina=yes,isol=yes,
liga=yes,dlig=yes,rlig=yes,clig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
\definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
\setupalign[r2l]
\starttext
{\Ahang تَشْكِيل كَسْرَة}
\stoptext

\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]

but there is an issue with widths, ill send you a patch to test

The provided "*arabic" featureset should suffice for this font. Also TEXpage is 
useful for this kind of MWE:

\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
\setupalign[r2l]
\startTEXpage[offset=1em]
{\Ahang تَشْكِيل  كَسْرَة}
\stopTEXpage

In prehistoric ConTeXt version

   2023.09.26 18:19

the diacritics look fine in both ConTeXt and unicode editor MS Notepad.

So if there is something wrong, it must be in a more recent version.

For comparison: Before applying Hans' patch, could you kindly send your pdf of 
the MWE that shows the error? Mine is attached.

Best wishes
Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80523


ahang.pdf
Description: ahang.pdf
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: rendering arabic diacritics

2024-05-09 Thread Hans Hagen

On 5/9/2024 2:17 PM, Hamid,Idris wrote:

Hi Seyal,

See below:

-- Original Message --
 From "Hans Hagen" mailto:j.ha...@xs4all.nl>>
To "seyal.zav...@gmail.com " 
mailto:seyal.zav...@gmail.com>>; "mailing list 
for ConTeXt users" mailto:ntg-context@ntg.nl>>

Date 5/9/2024 3:31:45 AM
Subject [NTG-context] Re: rendering arabic diacritics


** Caution: EXTERNAL Sender **
On 5/9/2024 10:03 AM, seyal.zav...@gmail.com 
 wrote:

Hi all,
when i want to use the linked font for arabic texts it doesn't render 
diacritics properly

i doesn't have problem with this font in inkscape or libreoffice
what featureset should i apply?
font link:
https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Ffile%2Fd%2F1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr%2Fview%3Fusp%3Dsharing&data=05%7C02%7CIdris.Hamid%40ColoState.EDU%7C8e2b7a1a4eaf46f6b10808dc700b7b2a%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C638508441848485171%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=51bK7I53UxZOK0PcbrYlpX2s%2Bdy%2BK83SslQZ%2BvhnvwU%3D&reserved=0
 
this is my MWE:
\definefontfeature [arabis]
[mode=node,language=dflt,script=arab,
init=yes,medi=yes,fina=yes,isol=yes,
liga=yes,dlig=yes,rlig=yes,clig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
\definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
\setupalign[r2l]
\starttext
{\Ahang تَشْكِيل كَسْرَة}
\stoptext

\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
but there is an issue with widths, ill send you a patch to test


The provided "*arabic" featureset should suffice for this font. Also 
TEXpage is useful for this kind of MWE:


\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
\setupalign[r2l]
\startTEXpage[offset=1em]
{\Ahang تَشْكِيل  كَسْرَة}
\stopTEXpage

In prehistoric ConTeXt version

    2023.09.26 18:19

the diacritics look fine in both ConTeXt and unicode editor MS Notepad.

So if there is something wrong, it must be in a more recent version.

For comparison: Before applying Hans' patch, could you kindly send your 
pdf of the MWE that shows the error? Mine is attached.
Ahang-Regular has no width settings for the marks so we need to zero 
them. Tahrir_Regular has widths but these we explictly need to zero with 
a pseudo feature then. (What are the assumptions when we do arabic? That 
marks are to have zero width?)


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 / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: rendering arabic diacritics

2024-05-09 Thread Hamid,Idris


-- Original Message --
From "Hans Hagen" mailto:j.ha...@xs4all.nl>>
To "ntg-context@ntg.nl" 
mailto:ntg-context@ntg.nl>>
Date 5/9/2024 6:29:40 AM
Subject [NTG-context] Re: rendering arabic diacritics

** Caution: EXTERNAL Sender **

On 5/9/2024 2:17 PM, Hamid,Idris wrote:
Hi Seyal,

See below:

-- Original Message --
From "Hans Hagen" mailto:j.ha...@xs4all.nl> 
>
To "seyal.zav...@gmail.com 
"
mailto:seyal.zav...@gmail.com> 
>; "mailing list
for ConTeXt users" mailto:ntg-context@ntg.nl> 
>
Date 5/9/2024 3:31:45 AM
Subject [NTG-context] Re: rendering arabic diacritics

** Caution: EXTERNAL Sender **
On 5/9/2024 10:03 AM, seyal.zav...@gmail.com
 wrote:
Hi all,
when i want to use the linked font for arabic texts it doesn't render
diacritics properly
i doesn't have problem with this font in inkscape or libreoffice
what featureset should i apply?
font link:
https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Ffile%2Fd%2F1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr%2Fview%3Fusp%3Dsharing&data=05%7C02%7CIdris.Hamid%40ColoState.EDU%7Cc8b63025b08545aa636308dc70244f52%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C638508548453863256%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=a2qMEGD0wo%2FhM6oNJ7AvfFyRPMEJuu0bFeceX4PPnsg%3D&reserved=0
 
>
this is my MWE:
\definefontfeature [arabis]
[mode=node,language=dflt,script=arab,
init=yes,medi=yes,fina=yes,isol=yes,
liga=yes,dlig=yes,rlig=yes,clig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
\definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
\setupalign[r2l]
\starttext
{\Ahang تَشْكِيل كَسْرَة}
\stoptext
\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
but there is an issue with widths, ill send you a patch to test

The provided "*arabic" featureset should suffice for this font. Also
TEXpage is useful for this kind of MWE:

\definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
\setupalign[r2l]
\startTEXpage[offset=1em]
{\Ahang تَشْكِيل كَسْرَة}
\stopTEXpage

In prehistoric ConTeXt version

2023.09.26 18:19

the diacritics look fine in both ConTeXt and unicode editor MS Notepad.

So if there is something wrong, it must be in a more recent version.

For comparison: Before applying Hans' patch, could you kindly send your
pdf of the MWE that shows the error? Mine is attached.
Ahang-Regular has no width settings for the marks so we need to zero
them. Tahrir_Regular has widths but these we explictly need to zero with
a pseudo feature then. (What are the assumptions when we do arabic? That
marks are to have zero width?)

Yes, marks should have zero-width but Uniscribe (and Harbuzz?/its successor?) 
provide support for legacy fonts with non-zero width.

But sometimes font designers imitate legacy behavior..

So it used to be often the case that a font with diacritics that worked in 
Uniscribe etc. (e.g., Deja Vu Arabic) would show marks with widths in ConTeXt.

In order to be more helpful, I should update to the latest beta, run some 
tests, and get current on the status of these matters..

Idris
--
Idris Samawi Hamid, Professor
Department of Philosophy
Colorado State University
Fort Collins, CO 80523
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: weird \inlinetypebuffer interaction

2024-05-09 Thread Pablo Rodriguez via ntg-context
On 5/9/24 12:57, Wolfgang Schuster wrote:
> Pablo Rodriguez via ntg-context schrieb am 08.05.2024 um 18:05:
>> [...]
>> Since \type doesn’t collapse hyphens, wouldn’t it be possible to add
>> \nohyphencollapsing to \typeinlinebuffer just for the sake of output
>> consistency?
>
> You can make \typeinlinebuffer behave like \type by adding a second
> initializer which besides other things prevents hyphen collapsing.
>
> buff-ver.mkxl:
>
> \protected\def\buff_verbatim_type_buffer_indeed_inline#1#2%
>{\cdef\currenttype{#1}%
> \buff_verbatim_initialize_type_one
> +  \buff_verbatim_initialize_type_two

Many thanks for your improvement, Wolfgang.

It would be great to have it included in standard ConTeXt.

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 / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] Re: rendering arabic diacritics

2024-05-09 Thread seyal zavira
Of course!

i attached output file before and after applying new patch

On Thu, May 9, 2024 at 9:08 AM Hamid,Idris 
wrote:

>
>
> -- Original Message --
> From "Hans Hagen" 
> To "ntg-context@ntg.nl" 
> Date 5/9/2024 6:29:40 AM
> Subject [NTG-context] Re: rendering arabic diacritics
>
> ** Caution: EXTERNAL Sender **
>
> On 5/9/2024 2:17 PM, Hamid,Idris wrote:
>
> Hi Seyal,
>
> See below:
>
> -- Original Message --
> From "Hans Hagen" mailto:j.ha...@xs4all.nl
> >>
> To "seyal.zav...@gmail.com  >"
> mailto:seyal.zav...@gmail.com
> >>; "mailing list
> for ConTeXt users" mailto:ntg-context@ntg.nl
> >>
> Date 5/9/2024 3:31:45 AM
> Subject [NTG-context] Re: rendering arabic diacritics
>
>
> ** Caution: EXTERNAL Sender **
> On 5/9/2024 10:03 AM, seyal.zav...@gmail.com
>  wrote:
>
> Hi all,
> when i want to use the linked font for arabic texts it doesn't render
> diacritics properly
> i doesn't have problem with this font in inkscape or libreoffice
> what featureset should i apply?
> font link:
>
> https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Ffile%2Fd%2F1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr%2Fview%3Fusp%3Dsharing&data=05%7C02%7CIdris.Hamid%40ColoState.EDU%7Cc8b63025b08545aa636308dc70244f52%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C638508548453863256%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=a2qMEGD0wo%2FhM6oNJ7AvfFyRPMEJuu0bFeceX4PPnsg%3D&reserved=0
> 
> <
> https://nam10.safelinks.protection.outlook.com/?url=https%3A%2F%2Fdrive.google.com%2Ffile%2Fd%2F1hCcv6wqWjd-5GEKnaowh8E8YVbTgGqQr%2Fview%3Fusp%3Dsharing&data=05%7C02%7CIdris.Hamid%40ColoState.EDU%7Cc8b63025b08545aa636308dc70244f52%7Cafb58802ff7a4bb1ab21367ff2ecfc8b%7C0%7C0%7C638508548453873437%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C0%7C%7C%7C&sdata=%2FLAHOebc2kdBEl4rBsEnp7gV4f6ZpXMWNt4FoUptSus%3D&reserved=0
> 
> >
> this is my MWE:
> \definefontfeature [arabis]
> [mode=node,language=dflt,script=arab,
> init=yes,medi=yes,fina=yes,isol=yes,
> liga=yes,dlig=yes,rlig=yes,clig=yes,
> mark=yes,mkmk=yes,kern=yes,curs=yes]
> \definefont [Ahang] [file:Ahang-Regular.otf*arabis at 18pt]
> \setupalign[r2l]
> \starttext
> {\Ahang تَشْكِيل كَسْرَة}
> \stoptext
>
> \definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
> but there is an issue with widths, ill send you a patch to test
>
>
> The provided "*arabic" featureset should suffice for this font. Also
> TEXpage is useful for this kind of MWE:
>
> \definefont [Ahang] [file:Ahang-Regular.otf*arabic at 18pt]
> \setupalign[r2l]
> \startTEXpage[offset=1em]
> {\Ahang تَشْكِيل كَسْرَة}
> \stopTEXpage
>
> In prehistoric ConTeXt version
>
> 2023.09.26 18:19
>
> the diacritics look fine in both ConTeXt and unicode editor MS Notepad.
>
> So if there is something wrong, it must be in a more recent version.
>
> For comparison: Before applying Hans' patch, could you kindly send your
> pdf of the MWE that shows the error? Mine is attached.
>
> Ahang-Regular has no width settings for the marks so we need to zero
> them. Tahrir_Regular has widths but these we explictly need to zero with
> a pseudo feature then. (What are the assumptions when we do arabic? That
> marks are to have zero width?)
>
>
> Yes, marks should have zero-width but Uniscribe (and Harbuzz?/its
> successor?) provide support for legacy fonts with non-zero width.
>
> But sometimes font designers imitate legacy behavior..
>
> So it used to be often the case that a font with diacritics that worked in
> Uniscribe etc. (e.g., Deja Vu Arabic) would show marks with widths in
> ConTeXt.
>
> In order to be more helpful, I should update to the latest beta, run some
> tests, and get current on the status of these matters..
>
> Idris
> --
> Idris Samawi Hamid, Professor
> Department of Philosophy
> Colorado State University
> Fort Collins, CO 80523
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
> webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
> archive  : https://github.com/contextgarden/context
> wiki : https://wiki.contextgarden.net
>
> ___
>


test.pdf
Description: Adobe PDF document


test2.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 / 
https://mailma

[NTG-context] no effect of \definefontfeature for adobevariablefontprototype

2024-05-09 Thread garulfo
Hi,

trying to work with variable fonts, I am stuck at the very beginning.

I can't see any effect of weight parameter.
Using adobevariablefontprototypebold and adobevariablefontprototypelight is 
working.

\starttext

\definefontfeature[whatever][axis={weight:150}]%
\definedfont[name:adobevariablefontprototype*whatever]foo@bar

\definefontfeature[whatever][axis={weight:350}]%
\definedfont[name:adobevariablefontprototype*whatever]foo@bar

\definefontfeature[whatever][axis={weight:550}]%
\definedfont[name:adobevariablefontprototype*whatever]foo@bar

\definefontfeature[whatever][axis={weight:750}]%
\definedfont[name:adobevariablefontprototype*whatever]foo@bar

\stoptext

Can it be something from with my font file ? 

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

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___


[NTG-context] How to place text, but make it completely hidden from viewers?

2024-05-09 Thread Joel via ntg-context
I have found a few situations is confusing/breaking ConTeXt:
- Footnotes inside tables, figures, frames, margins (won't render the cited 
item).
- Custom index items inside those items (displays "entry not flushed").
My workaround has been to define a size 0 font \tfz, then put it in a block 
like this:

    {\tfz%    \starteffect[hidden]%
    \cite[author1912]    \stopeffect%
    }%
The problem this seems to create, is sometimes if placed between two passages, 
it interprets a need to create two paragraph breaks:
\input knuth
    {\tfz%    \starteffect[hidden]%
    \cite[author1912]    \stopeffect%
    }%
\input knuth
It creates a paragraph break after the first knuth, then another after the 
hidden text, thereby creating a "double spaced" break between two paragraphs. 
Note the above code is used in many macros, so I don't have full control always 
where it appears, but its making the double-spaced break everywhere.

Is there either (1) something can enter before this code that essentially has 
the effect of "backup to the previous paragraph" or (2) some other method of 
hiding text that makes it present on the page, but just not visible to the 
reader, that won't create a double spaced break, or take up any space 
what-so-ever?
--Joel
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___