* [NTG-context] ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
@ 2024-09-05 20:58 Felix
2024-09-05 22:02 ` [NTG-context] " Marcus Vinicius Mesquita
2024-09-07 13:00 ` Wolfgang Schuster
0 siblings, 2 replies; 9+ messages in thread
From: Felix @ 2024-09-05 20:58 UTC (permalink / raw)
To: ntg-context
https://pastebin.com/245uwYj4
I have this setup for my fonts, called myfonts.
I assume that `\definefontfeature [default] [default] [trep=yes,dlig=yes,itlc=yes]` will affect every single font that goes into my preamble (Forgive me if I seem incompetent, I am a beginner at ConTeXt)
I have dlig and trep on so that works with single quotations like don't have a directional quote, and so that I get the Times New Roman ligatures via dlig and not just liga. itlc is enabled since I read some documentation and they sometimes mention enabling it
is there some stuff like the extrafeatures option or anything that you would recommend i enable? might there be options for extrakerns that would be seen as something that one should enable?
also, how can I see all the options available? dlig is something I discovered by accident that was not in the options list in the documentation.
i use the latest version of ConTeXt LMTX on Windows
___________________________________________________________________________________
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-05 20:58 [NTG-context] ConTeXt beginner, What should I enable within font features? And how do I see all the options possible? Felix
@ 2024-09-05 22:02 ` Marcus Vinicius Mesquita
2024-09-05 22:19 ` Hans Hagen
2024-09-07 13:00 ` Wolfgang Schuster
1 sibling, 1 reply; 9+ messages in thread
From: Marcus Vinicius Mesquita @ 2024-09-05 22:02 UTC (permalink / raw)
To: mailing list for ConTeXt users
Hi, Felix
In linux, to find the GSUB/GPOS features of a opentype face you can
use the command
otfinfo -f fontname.ttf
otfinfo is part of the lcdf-typetools package
Regards
Marcus Vinicius
Marcus Vinicius
On Thu, Sep 5, 2024 at 6:02 PM Felix <fm117575@students.panola.edu> wrote:
>
> https://pastebin.com/245uwYj4
>
> I have this setup for my fonts, called myfonts.
>
> I assume that `\definefontfeature [default] [default] [trep=yes,dlig=yes,itlc=yes]` will affect every single font that goes into my preamble (Forgive me if I seem incompetent, I am a beginner at ConTeXt)
>
> I have dlig and trep on so that works with single quotations like don't have a directional quote, and so that I get the Times New Roman ligatures via dlig and not just liga. itlc is enabled since I read some documentation and they sometimes mention enabling it
>
> is there some stuff like the extrafeatures option or anything that you would recommend i enable? might there be options for extrakerns that would be seen as something that one should enable?
>
> also, how can I see all the options available? dlig is something I discovered by accident that was not in the options list in the documentation.
>
> i use the latest version of ConTeXt LMTX on Windows
> ___________________________________________________________________________________
> 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
> ___________________________________________________________________________________
--
Todas as coisas fatigam o corpo, salvo a música, que não fatiga nem o
corpo nem seus membros, por ser descanso da alma, primavera do
coração, distração do aflito, entretenimento do solitário, e viático
do viajante.
Kunnâsh al-Hâ'ik (Cancioneiro de al-Hâ'ik)
___________________________________________________________________________________
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-05 22:02 ` [NTG-context] " Marcus Vinicius Mesquita
@ 2024-09-05 22:19 ` Hans Hagen
2024-09-13 6:12 ` Felix
0 siblings, 1 reply; 9+ messages in thread
From: Hans Hagen @ 2024-09-05 22:19 UTC (permalink / raw)
To: ntg-context
On 9/6/2024 12:02 AM, Marcus Vinicius Mesquita wrote:
> Hi, Felix
>
>
> In linux, to find the GSUB/GPOS features of a opentype face you can
> use the command
>
> otfinfo -f fontname.ttf
>
> otfinfo is part of the lcdf-typetools package
context always shipped with this:
mtxrun --script font --info --all --list --pattern=pagella*
which also can generate the font database.
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-05 20:58 [NTG-context] ConTeXt beginner, What should I enable within font features? And how do I see all the options possible? Felix
2024-09-05 22:02 ` [NTG-context] " Marcus Vinicius Mesquita
@ 2024-09-07 13:00 ` Wolfgang Schuster
2024-09-13 6:02 ` Felix
1 sibling, 1 reply; 9+ messages in thread
From: Wolfgang Schuster @ 2024-09-07 13:00 UTC (permalink / raw)
To: mailing list for ConTeXt users, Felix
Felix schrieb am 05.09.2024 um 22:58:
> https://pastebin.com/245uwYj4
>
> I have this setup for my fonts, called myfonts.
>
> I assume that `\definefontfeature [default] [default] [trep=yes,dlig=yes,itlc=yes]` will affect every single font that goes into my preamble (Forgive me if I seem incompetent, I am a beginner at ConTeXt)
It is applied to all fonts which use the "default" feature set and which
enabled after you made the changes.
In the following example only pagella uses the "trep" feature because
modern was loaded before the settings was added to the default feature set.
%%%% begin example
\starttext
\setupbodyfont[modern]
a'b
\definefontfeature [default] [default] [trep=yes]
\setupbodyfont[pagella]
a'b
\stoptext
%%%% end example
To be on the save side create custom feature set where you add
additional settings and apply these to your fonts.
%%%% begin example
\definefontfeature [MyFeatures] [default] [trep=yes]
\definefontfamily [OldTimes] [rm] [Times New Roman]
\definefontfamily [NewTimes] [rm] [Times New Roman] [features=MyFeatures]
\starttext
\setupbodyfont[OldTimes]
a'b
\setupbodyfont[NewTimes]
a'b
\stoptext
%%%% end example
> I have dlig and trep on so that works with single quotations like don't have a directional quote, and so that I get the Times New Roman ligatures via dlig and not just liga. itlc is enabled since I read some documentation and they sometimes mention enabling it
It shouldn't be necessary to add "itlc" anymore to get italic correction
for \em etc.
> is there some stuff like the extrafeatures option or anything that you would recommend i enable? might there be options for extrakerns that would be seen as something that one should enable?
>
> also, how can I see all the options available? dlig is something I discovered by accident that was not in the options list in the documentation.
Unless you know the effect of a feature you shouldn't add or enable it.
You even have to know what is supported by the fonts in your document
which can differ between certain versions of a font, take Times New
Roman which is included with Windows as an example.
1. For a long time ligatures weren't supported by the font at all and
the first mention of the support it is from 2022.
2. The font uses the "dlig" feature to enable the f ligatures even
though the normal tag for it is "liga". My guess why they made this
decision is backwards compatibility with existing document to avoid them
from using these ligatures.
3. You shouldn't enable "dlig" by default for all fonts because the
results of the feature can vastly for the fonts which provide it, take
the following two fonts as example.
%%%% begin example
\definefontfeature [discretionary-ligatures] [dlig=yes]
\starttext
\startbuffer[pagella]
\starttabulate[|||]
\NC \type{----} \EQ ---- \NC\NR
\NC \type{--} \EQ -- \NC\NR
\NC \type{!`} \EQ !` \NC\NR
\NC \type{!‘} \EQ !‘ \NC\NR
\NC \type{?`} \EQ ?` \NC\NR
\NC \type{?‘} \EQ ?‘ \NC\NR
\NC \type{,,} \EQ ,, \NC\NR
\NC \type{‘‘} \EQ ‘‘ \NC\NR
\NC \type{’’} \EQ ’’ \NC\NR
\NC \type{---} \EQ --- \NC\NR
\stoptabulate
\stopbuffer
\setupbodyfont[pagella]
\start \nohyphencollapsing
\getbuffer[pagella]
\stop
\start \nohyphencollapsing \feature[+][discretionary-ligatures]
\getbuffer[pagella]
\stop
\startbuffer[dejavuserif]
\starttabulate[|||]
\NC \type{ſt} \EQ ſt \NC\NR
\NC \type{st} \EQ st \NC\NR
\stoptabulate
\stopbuffer
\setupbodyfont[dejavu]
\start
\getbuffer[dejavuserif]
\stop
\start \feature[+][discretionary-ligatures]
\getbuffer[dejavuserif]
\stop
\stoptext
%%%% end example
The only additional features which can be added without problems are
"expansion" and "protrusion" because until you enable them with
\setupalign nothing changes in your document.
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-07 13:00 ` Wolfgang Schuster
@ 2024-09-13 6:02 ` Felix
2024-09-13 6:03 ` Felix
2024-09-13 14:21 ` Wolfgang Schuster
0 siblings, 2 replies; 9+ messages in thread
From: Felix @ 2024-09-13 6:02 UTC (permalink / raw)
To: ntg-context
Hello Wolfgang, so if I follow your code examp,e what if I were to edit my code to be like this:
\definefontfeature[generalfeatures][default][
kern=yes, % enables kerning
extrakerns=yes, % enables extra kerning
trep=yes, % Enables single and double quotes to show up correctly in text, perhaps does more
liga=yes, % Enables ligatures.
itlc=yes, % Activates italic correction.
mark=yes, % Used for positioning diacritical marks (accents, dots, etc.) relative to base characters.
mkmk=yes, % positions diacritical marks relative to other marks
locl=yes,
ccmp=yes, % Composes multiple characters into a single glyph or breaks down ligatures.
mode=node,
protrusion=yes,
expansion=yes,
language=dflt,
]
\definefontfamily [myfonts] [rm] [Times New Roman] [features=generalfeatures,dlig=yes,cpsp=yes,% dlig enables times new roman ligatures, and cpsp is used by tnr, not aptos]
\definefontfamily [myfonts] [ss] [Aptos] [features=generalfeatures,]
\definetypeface [myfonts] [mm] [math] [stixtwo] [features=generalfeatures,]
\setupbodyfont[myfonts,12pt]
do you think this code is flawed?
Also, do you think you could explain how locl and extrakerns works? do I need to have kern=yes for it to enable? how can I test if extrakerns Is working? when I just have kern=yes enable, and then enable extra, a pdf that has a paragraph using both in code looks the same. locl is something I'm completely unsure about.
___________________________________________________________________________________
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-13 6:02 ` Felix
@ 2024-09-13 6:03 ` Felix
2024-09-13 14:21 ` Wolfgang Schuster
1 sibling, 0 replies; 9+ messages in thread
From: Felix @ 2024-09-13 6:03 UTC (permalink / raw)
To: ntg-context
\definefontfamily [myfonts] [rm] [Times New Roman] [features=generalfeatures,dlig=yes,cpsp=yes,] % dlig enables times new roman ligatures, and cpsp is used by tnr, not aptos
is the correct code
___________________________________________________________________________________
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-05 22:19 ` Hans Hagen
@ 2024-09-13 6:12 ` Felix
0 siblings, 0 replies; 9+ messages in thread
From: Felix @ 2024-09-13 6:12 UTC (permalink / raw)
To: ntg-context
Hans, hello. I have a question regarding a new version of my font setup in context:
\definefontfeature[generalfeatures][default][
kern=yes, % enables kerning
extrakerns=yes, % enables extra kerning
trep=yes, % Enables single and double quotes to show up correctly in text, perhaps does more
liga=yes, % Enables ligatures.
itlc=yes, % Activates italic correction.
mark=yes, % Used for positioning diacritical marks (accents, dots, etc.) relative to base characters.
mkmk=yes, % positions diacritical marks relative to other marks
locl=yes,
ccmp=yes, % Composes multiple characters into a single glyph or breaks down ligatures.
mode=node,
protrusion=yes,
expansion=yes,
language=dflt,
]
\definefontfamily [myfonts] [rm] [Times New Roman] [features=generalfeatures,dlig=yes,cpsp=yes,] % dlig enables times new roman ligatures, and cpsp is used by tnr, not aptos
\definefontfamily [myfonts] [ss] [Aptos] [features=generalfeatures,]
\definetypeface [myfonts] [mm] [math] [stixtwo] [features=generalfeatures,]
\setupbodyfont[myfonts,12pt]
1. is extrakerns setup correctly? how can I tell if extrakerns will work? Since only kerns shows up in the OpenType features for TNR and Aptos. I wonder if it is like trep, which seems to be a context option for fonts.
2. What exactly does locl do if in tnr and aptos the option supports the latin script? (aptos also supports cyrl, and tnr also supports arab)
3. mode=node. I see that base is also an option in the settings sig page in context wiki, and ChatGPT told me node is the more 'complete', accurate, glyph based option that is typographically better, but takes more time to produce when used in a doc. Is this the case?
___________________________________________________________________________________
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-13 6:02 ` Felix
2024-09-13 6:03 ` Felix
@ 2024-09-13 14:21 ` Wolfgang Schuster
2024-09-13 15:16 ` Henning Hraban Ramm
1 sibling, 1 reply; 9+ messages in thread
From: Wolfgang Schuster @ 2024-09-13 14:21 UTC (permalink / raw)
To: mailing list for ConTeXt users, Felix
Felix schrieb am 13.09.2024 um 08:02:
> Hello Wolfgang, so if I follow your code examp,e what if I were to edit my code to be like this:
>
> \definefontfeature[generalfeatures][default][
> kern=yes, % enables kerning
> extrakerns=yes, % enables extra kerning
> trep=yes, % Enables single and double quotes to show up correctly in text, perhaps does more
> liga=yes, % Enables ligatures.
> itlc=yes, % Activates italic correction.
> mark=yes, % Used for positioning diacritical marks (accents, dots, etc.) relative to base characters.
> mkmk=yes, % positions diacritical marks relative to other marks
> locl=yes,
> ccmp=yes, % Composes multiple characters into a single glyph or breaks down ligatures.
> mode=node,
> protrusion=yes,
> expansion=yes,
> language=dflt,
> ]
>
> \definefontfamily [myfonts] [rm] [Times New Roman] [features=generalfeatures,dlig=yes,cpsp=yes,% dlig enables times new roman ligatures, and cpsp is used by tnr, not aptos]
> \definefontfamily [myfonts] [ss] [Aptos] [features=generalfeatures,]
> \definetypeface [myfonts] [mm] [math] [stixtwo] [features=generalfeatures,]
>
> \setupbodyfont[myfonts,12pt]
>
> do you think this code is flawed?
Stay with the following basic setups and add only expansion or
protrusion when you use the features in your document, otherwise there
is no need for them.
\definefontfeature [times] [default] [trep=yes,dlig=yes]
\definefontfeature [aptos] [default] [trep=yes]
\definefontfamily [myfonts] [rm] [Times New Roman] [features=times]
\definefontfamily [myfonts] [ss] [Aptos] [features=aptos]
\definefontfamily [myfonts] [tt] [Aptos Mono] [features=none]
\definetypeface [myfonts] [mm] [math] [stixtwo]
\setupbodyfont[myfonts,12pt]
\starttext
\samplefile{lorem}
\stoptext
> Also, do you think you could explain how locl and extrakerns works? do I need to have kern=yes for it to enable? how can I test if extrakerns Is working? when I just have kern=yes enable, and then enable extra, a pdf that has a paragraph using both in code looks the same. locl is something I'm completely unsure about.
1. Many features above are part of the default set.
2. When you don't know what the effect of an opentype feature is (look
at https://www.preusstype.com/techdata/features.php for a few examples)
don't enable it because you can get an unexpected output in your
document. It is also important to know what your font makes with the
feature because like I previously mentioned Times New Roman uses dlig to
produce standard ligatures which isn't what you expect here.
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] 9+ messages in thread
* [NTG-context] Re: ConTeXt beginner, What should I enable within font features? And how do I see all the options possible?
2024-09-13 14:21 ` Wolfgang Schuster
@ 2024-09-13 15:16 ` Henning Hraban Ramm
0 siblings, 0 replies; 9+ messages in thread
From: Henning Hraban Ramm @ 2024-09-13 15:16 UTC (permalink / raw)
To: ntg-context
Am 13.09.24 um 16:21 schrieb Wolfgang Schuster:
> 2. When you don't know what the effect of an opentype feature is (look
> at https://www.preusstype.com/techdata/features.php for a few examples)
Also this list:
https://en.wikipedia.org/wiki/List_of_typographic_features
Hraban
___________________________________________________________________________________
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] 9+ messages in thread
end of thread, other threads:[~2024-09-13 15:22 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-09-05 20:58 [NTG-context] ConTeXt beginner, What should I enable within font features? And how do I see all the options possible? Felix
2024-09-05 22:02 ` [NTG-context] " Marcus Vinicius Mesquita
2024-09-05 22:19 ` Hans Hagen
2024-09-13 6:12 ` Felix
2024-09-07 13:00 ` Wolfgang Schuster
2024-09-13 6:02 ` Felix
2024-09-13 6:03 ` Felix
2024-09-13 14:21 ` Wolfgang Schuster
2024-09-13 15:16 ` Henning Hraban Ramm
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).