Felix schrieb am 05.09.2024 um 22:58:
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