* [NTG-context] Bug report about \definefallbackfamily and other questions
@ 2025-04-18 11:59 Sylvain Hubert
2025-04-18 18:00 ` [NTG-context] " Hans Hagen via ntg-context
` (2 more replies)
0 siblings, 3 replies; 11+ messages in thread
From: Sylvain Hubert @ 2025-04-18 11:59 UTC (permalink / raw)
To: mailing list for ConTeXt users
[-- Attachment #1.1: Type: text/plain, Size: 2501 bytes --]
Hello,
1 bug report + 3 questions:
___
# Bug report: \definefallbackfamily ignoring font features
```tex
\definefallbackfamily[mainface][rm][Noto Serif][preset=range:greek,
sl={style:tf, features:slanted}]
\definefontfamily[mainface][rm][latinmodernroman]
\setupbodyfont[mainface]
\starttext
\sl something αβγ
\stoptext
```
The three greek letters are slanted when compiled with older ConTeXt LMTX
(before Oct.19, 2024), but they remain upright under the latest version.
___
# Question: ad-hoc font features
I tried to specify ad-hoc font features (see below) in `\definefontfamily`
like slant+bold, without naming the feature with `\definefontfeature` since
they're not supposed to be reused. But the resulting fonts are always
thicker than expected. Then I found that, even with empty effects,
`features:{effect={}}` itself makes the font ultra bold.
```tex
\definefontfamily[mainface][rm][Noto Serif][sl={style:tf,
features:{effect={}}}]
\setupbodyfont[mainface]
\starttext
\sl something αβγ
\stoptext
```
Is this a bug, or is there any justification behind it?
___
# Question: feature inheritance of `\definefontfamily`
When I customize fonts with \definefontfamily, e.g:
```tex
% some other customization with \definefallbackfamily ...
\definefontfamily[mainface][rm][latinmodernroman]
\definefontfamily[mainface][tt][latinmodernmono]
\setupbodyfont[mainface]
\starttext
\tt\sl something
\stoptext
```
the slanted monospace becomes some kind of italic. To recover the default
behavior, the slant variant must be explicitly specified:
```tex
% some other customization with \definefallbackfamily ...
\definefontfamily[mainface][rm][latinmodernroman]
\definefontfamily[mainface][tt][latinmodernmono][sl=lmmonoslant10regular]
\setupbodyfont[mainface]
\starttext
\tt\sl something
\stoptext
```
But it's unproductive to copy-paste full specification (slanted, bold, ...)
of the builtin latin modern. Is there any way to avoid this by somehow
inheriting the default specification?
___
# Question: ConTeXt LMTX version control
Where can one find older releases of ConTeXt LMTX when encountering
problems like the bug above? https://github.com/contextgarden/context looks
promising, but it doesn't provide release artifacts, nor build
instructions. I could help add a workflow for automated release to it if
someone kindly provides a built instruction.
___
Best regards,
Sylvain
[-- Attachment #1.2: Type: text/html, Size: 2731 bytes --]
[-- Attachment #2: Type: text/plain, Size: 511 bytes --]
___________________________________________________________________________________
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-18 11:59 [NTG-context] Bug report about \definefallbackfamily and other questions Sylvain Hubert
@ 2025-04-18 18:00 ` Hans Hagen via ntg-context
2025-04-18 18:07 ` Hans Hagen via ntg-context
2025-04-18 21:09 ` Wolfgang Schuster
2 siblings, 0 replies; 11+ messages in thread
From: Hans Hagen via ntg-context @ 2025-04-18 18:00 UTC (permalink / raw)
To: ntg-context; +Cc: Hans Hagen
On 4/18/2025 1:59 PM, Sylvain Hubert wrote:
> # Question: ConTeXt LMTX version control
>
> Where can one find older releases of ConTeXt LMTX when encountering
> problems like the bug above? https://github.com/contextgarden/context
> <https://github.com/contextgarden/context> looks promising, but it
> doesn't provide release artifacts, nor build instructions. I could help
> add a workflow for automated release to it if someone kindly provides a
> built instruction.
just run the build script in source and move the result
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-18 11:59 [NTG-context] Bug report about \definefallbackfamily and other questions Sylvain Hubert
2025-04-18 18:00 ` [NTG-context] " Hans Hagen via ntg-context
@ 2025-04-18 18:07 ` Hans Hagen via ntg-context
2025-04-18 18:24 ` Wolfgang Schuster
2025-04-18 21:09 ` Wolfgang Schuster
2 siblings, 1 reply; 11+ messages in thread
From: Hans Hagen via ntg-context @ 2025-04-18 18:07 UTC (permalink / raw)
To: Sylvain Hubert, mailing list for ConTeXt users; +Cc: Hans Hagen
On 4/18/2025 1:59 PM, Sylvain Hubert wrote:
> Hello,
>
> 1 bug report + 3 questions:
These are for Wolfgang but shouldn't you set the style to sl?
\definefallbackfamily
[mainface]
[rm]
[Noto Serif]
[preset=range:greek,sl={style:sl,features:slanted}]
I'm not sure if selectfont has been adapted to compact fonts so you can
try to run with
--nocompactfonts
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-18 18:07 ` Hans Hagen via ntg-context
@ 2025-04-18 18:24 ` Wolfgang Schuster
2025-04-23 17:07 ` Pablo Rodriguez via ntg-context
0 siblings, 1 reply; 11+ messages in thread
From: Wolfgang Schuster @ 2025-04-18 18:24 UTC (permalink / raw)
To: mailing list for ConTeXt users, Sylvain Hubert
Am 18.04.2025 um 20:07 schrieb Hans Hagen via ntg-context:
> On 4/18/2025 1:59 PM, Sylvain Hubert wrote:
>> Hello,
>>
>> 1 bug report + 3 questions:
>
> These are for Wolfgang but shouldn't you set the style to sl?
>
> \definefallbackfamily
> [mainface]
> [rm]
> [Noto Serif]
> [preset=range:greek,sl={style:sl,features:slanted}]
>
> I'm not sure if selectfont has been adapted to compact fonts so you can
> try to run with
>
> --nocompactfonts
The same result can be reproduced without \definefontfamily and is
limited to compact fonts.
\definefontfallback [FallbackRegular]
[file:notoserifregular*default,slanted] [greekandcoptic]
\definefontsynonym [MainfaceRegular] [SerifSlanted]
[features=default,fallbacks=FallbackRegular]
\starttext
\definedfont[MainfaceRegular]something αβγ
\stoptext
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-18 11:59 [NTG-context] Bug report about \definefallbackfamily and other questions Sylvain Hubert
2025-04-18 18:00 ` [NTG-context] " Hans Hagen via ntg-context
2025-04-18 18:07 ` Hans Hagen via ntg-context
@ 2025-04-18 21:09 ` Wolfgang Schuster
2 siblings, 0 replies; 11+ messages in thread
From: Wolfgang Schuster @ 2025-04-18 21:09 UTC (permalink / raw)
To: ntg-context
Am 18.04.2025 um 13:59 schrieb Sylvain Hubert:
> Hello,
>
> 1 bug report + 3 questions:
>
> ___
>
> # Bug report: \definefallbackfamily ignoring font features
>
> ```tex
> \definefallbackfamily[mainface][rm][Noto Serif][preset=range:greek,
> sl={style:tf, features:slanted}]
> \definefontfamily[mainface][rm][latinmodernroman]
> \setupbodyfont[mainface]
>
> \starttext
> \sl something αβγ
> \stoptext
> ```
>
> The three greek letters are slanted when compiled with older ConTeXt
> LMTX (before Oct.19, 2024), but they remain upright under the latest
> version.
>
> ___
>
> # Question: ad-hoc font features
>
> I tried to specify ad-hoc font features (see below) in
> `\definefontfamily` like slant+bold, without naming the feature with
> `\definefontfeature` since they're not supposed to be reused. But the
> resulting fonts are always thicker than expected. Then I found that,
> even with empty effects, `features:{effect={}}` itself makes the font
> ultra bold.
>
> ```tex
> \definefontfamily[mainface][rm][Noto Serif][sl={style:tf, features:
> {effect={}}}]
> \setupbodyfont[mainface]
>
> \starttext
> \sl something αβγ
> \stoptext
> ```
>
> Is this a bug, or is there any justification behind it?
1. \definefontfamily just passes the features argument to the next stage
of ConTeXt's font mechanism.
2. It looks like "effect=" produces the same results as
"effect={effect=both}" with a thick outline.
%%%% begin example
\starttext
\definedfont[file:NotoSerif-Regular.ttf*default]something αβγ
\definedfont[file:NotoSerif-Regular.ttf*effect=,default]something αβγ
\definedfont[file:NotoSerif-Regular.ttf*effect={effect=inner},default]something
αβγ
\definedfont[file:NotoSerif-Regular.ttf*effect={effect=outer},default]something
αβγ
\definedfont[file:NotoSerif-Regular.ttf*effect={effect=both},default]something
αβγ
\stoptext
%%%% end example
> # Question: feature inheritance of `\definefontfamily`
>
> When I customize fonts with \definefontfamily, e.g:
>
> ```tex
> % some other customization with \definefallbackfamily ...
> \definefontfamily[mainface][rm][latinmodernroman]
> \definefontfamily[mainface][tt][latinmodernmono]
> \setupbodyfont[mainface]
>
> \starttext
> \tt\sl something
> \stoptext
> ```
>
> the slanted monospace becomes some kind of italic. To recover the
> default behavior, the slant variant must be explicitly specified:
>
> ```tex
> % some other customization with \definefallbackfamily ...
> \definefontfamily[mainface][rm][latinmodernroman]
> \definefontfamily[mainface][tt][latinmodernmono][sl=lmmonoslant10regular]
> \setupbodyfont[mainface]
>
> \starttext
> \tt\sl something
> \stoptext
> ```
>
> But it's unproductive to copy-paste full specification (slanted,
> bold, ...) of the builtin latin modern. Is there any way to avoid this
> by somehow inheriting the default specification?
\definefontfamily searches for the files based on the family name which
is stored in the font and Latin Modern Mono as a font family includes
only an italic style but not an oblique one. The slanted version of
Latin Modern Mono has been put in a separate family and is therefore
ignored because it can't be found when \definefontfamily is looking for
files.
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-18 18:24 ` Wolfgang Schuster
@ 2025-04-23 17:07 ` Pablo Rodriguez via ntg-context
2025-04-23 18:33 ` Wolfgang Schuster
2025-04-24 15:39 ` Wolfgang Schuster
0 siblings, 2 replies; 11+ messages in thread
From: Pablo Rodriguez via ntg-context @ 2025-04-23 17:07 UTC (permalink / raw)
To: ntg-context; +Cc: Pablo Rodriguez
On 4/18/25 20:24, Wolfgang Schuster wrote:
> [...]
> The same result can be reproduced without \definefontfamily and is
> limited to compact fonts.
>
> \definefontfallback [FallbackRegular]
> [file:notoserifregular*default,slanted] [greekandcoptic]
>
> \definefontsynonym [MainfaceRegular] [SerifSlanted]
> [features=default,fallbacks=FallbackRegular]
>
> \starttext
> \definedfont[MainfaceRegular]something αβγ
> \stoptext
Hi Hans and Wolfgang,
I reproduce the result when compiling source.tex with:
context source.tex
But I get slanted Greek glyphs using source.tex as environment:
context --environment=source.tex whatever.tex
For your information, just in case it might 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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-23 17:07 ` Pablo Rodriguez via ntg-context
@ 2025-04-23 18:33 ` Wolfgang Schuster
2025-04-24 14:50 ` Pablo Rodriguez via ntg-context
2025-04-24 15:39 ` Wolfgang Schuster
1 sibling, 1 reply; 11+ messages in thread
From: Wolfgang Schuster @ 2025-04-23 18:33 UTC (permalink / raw)
To: mailing list for ConTeXt users; +Cc: Pablo Rodriguez
Am 23.04.2025 um 19:07 schrieb Pablo Rodriguez via ntg-context:
> On 4/18/25 20:24, Wolfgang Schuster wrote:
>> [...]
>> The same result can be reproduced without \definefontfamily and is
>> limited to compact fonts.
>>
>> \definefontfallback [FallbackRegular]
>> [file:notoserifregular*default,slanted] [greekandcoptic]
>>
>> \definefontsynonym [MainfaceRegular] [SerifSlanted]
>> [features=default,fallbacks=FallbackRegular]
>>
>> \starttext
>> \definedfont[MainfaceRegular]something αβγ
>> \stoptext
>
> Hi Hans and Wolfgang,
>
> I reproduce the result when compiling source.tex with:
>
> context source.tex
>
> But I get slanted Greek glyphs using source.tex as environment:
>
> context --environment=source.tex whatever.tex
>
> For your information, just in case it might help,
What is the content of both files?
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-23 18:33 ` Wolfgang Schuster
@ 2025-04-24 14:50 ` Pablo Rodriguez via ntg-context
0 siblings, 0 replies; 11+ messages in thread
From: Pablo Rodriguez via ntg-context @ 2025-04-24 14:50 UTC (permalink / raw)
To: ntg-context; +Cc: Pablo Rodriguez
On 4/23/25 20:33, Wolfgang Schuster wrote:
> Am 23.04.2025 um 19:07 schrieb Pablo Rodriguez via ntg-context:
> [...]
>
> What is the content of both files?
The contents of "source.tex" read:
\definefontfallback [FallbackRegular]
[file:NotoSerif.ttf*default,slanted] [greekandcoptic]
\definefontsynonym [MainfaceRegular] [SerifSlanted]
[features=default,fallbacks=FallbackRegular]
\starttext
\definedfont[MainfaceRegular]something αβγ
\stoptext
"whatever.tex" is a non-existing file.
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-23 17:07 ` Pablo Rodriguez via ntg-context
2025-04-23 18:33 ` Wolfgang Schuster
@ 2025-04-24 15:39 ` Wolfgang Schuster
2025-04-24 17:40 ` Pablo Rodriguez via ntg-context
1 sibling, 1 reply; 11+ messages in thread
From: Wolfgang Schuster @ 2025-04-24 15:39 UTC (permalink / raw)
To: ntg-context
Am 23.04.2025 um 19:07 schrieb Pablo Rodriguez via ntg-context:
> On 4/18/25 20:24, Wolfgang Schuster wrote:
>> [...]
>> The same result can be reproduced without \definefontfamily and is
>> limited to compact fonts.
>>
>> \definefontfallback [FallbackRegular]
>> [file:notoserifregular*default,slanted] [greekandcoptic]
>>
>> \definefontsynonym [MainfaceRegular] [SerifSlanted]
>> [features=default,fallbacks=FallbackRegular]
>>
>> \starttext
>> \definedfont[MainfaceRegular]something αβγ
>> \stoptext
>
> Hi Hans and Wolfgang,
>
> I reproduce the result when compiling source.tex with:
>
> context source.tex
>
> But I get slanted Greek glyphs using source.tex as environment:
>
> context --environment=source.tex whatever.tex
>
> For your information, just in case it might help,
Doesn't work for me because ConTeXt complains about the missing file.
runtime error : input file './whatever.tex' is not found, quitting
mtx-context | fatal error: return code: 1
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-24 15:39 ` Wolfgang Schuster
@ 2025-04-24 17:40 ` Pablo Rodriguez via ntg-context
2025-04-24 18:29 ` Wolfgang Schuster
0 siblings, 1 reply; 11+ messages in thread
From: Pablo Rodriguez via ntg-context @ 2025-04-24 17:40 UTC (permalink / raw)
To: ntg-context; +Cc: Pablo Rodriguez
On 4/24/25 17:39, Wolfgang Schuster wrote:
> [...]
> Doesn't work for me because ConTeXt complains about the missing file.
>
> runtime error : input file './whatever.tex' is not found, quitting
> mtx-context | fatal error: return code: 1
Weird, I only get a warning:
context --purgeall --environment=source.tex whatever.tex
mtx-context | warning: no (local) file './whatever.tex', proceeding
I’m on Linux-64bit, but I thought macOS wouldn’t be that different.
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
* [NTG-context] Re: Bug report about \definefallbackfamily and other questions
2025-04-24 17:40 ` Pablo Rodriguez via ntg-context
@ 2025-04-24 18:29 ` Wolfgang Schuster
0 siblings, 0 replies; 11+ messages in thread
From: Wolfgang Schuster @ 2025-04-24 18:29 UTC (permalink / raw)
To: ntg-context
Am 24.04.2025 um 19:40 schrieb Pablo Rodriguez via ntg-context:
> On 4/24/25 17:39, Wolfgang Schuster wrote:
>> [...]
>> Doesn't work for me because ConTeXt complains about the missing file.
>>
>> runtime error : input file './whatever.tex' is not found, quitting
>> mtx-context | fatal error: return code: 1
>
> Weird, I only get a warning:
>
> context --purgeall --environment=source.tex whatever.tex
> mtx-context | warning: no (local) file './whatever.tex', proceeding
I tested your example in a different folder and it works now.
The reason why using the environment works is because compact fonts
haven't been enabled yet at this point and the font is therefore loaded
with the old mode.
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
___________________________________________________________________________________
^ permalink raw reply [flat|nested] 11+ messages in thread
end of thread, other threads:[~2025-04-24 18:34 UTC | newest]
Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-04-18 11:59 [NTG-context] Bug report about \definefallbackfamily and other questions Sylvain Hubert
2025-04-18 18:00 ` [NTG-context] " Hans Hagen via ntg-context
2025-04-18 18:07 ` Hans Hagen via ntg-context
2025-04-18 18:24 ` Wolfgang Schuster
2025-04-23 17:07 ` Pablo Rodriguez via ntg-context
2025-04-23 18:33 ` Wolfgang Schuster
2025-04-24 14:50 ` Pablo Rodriguez via ntg-context
2025-04-24 15:39 ` Wolfgang Schuster
2025-04-24 17:40 ` Pablo Rodriguez via ntg-context
2025-04-24 18:29 ` Wolfgang Schuster
2025-04-18 21:09 ` Wolfgang Schuster
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).