[NTG-context] how to insert symbols into document?

Hans Hagen pragma at wxs.nl
Sat Apr 18 16:53:24 CEST 2015


On 4/18/2015 4:09 PM, Wolfgang Schuster wrote:
>
>> Am 18.04.2015 um 13:51 schrieb Hans Hagen <pragma at wxs.nl
>> <mailto:pragma at wxs.nl>>:
>>
>> On 4/18/2015 1:21 PM, Csikos Bela wrote:
>>>
>>> Before answering I wanted to find out how to make this fallback:
>>> Using a given font
>>> and fall back to only one (or a few) specific characters in another
>>> font. For example
>>> using Tex Gyre Pagella and fall back to Dejavu's black diamond, but
>>> not to any other
>>> characters.
>>>
>>> To learn how to do this, in the last few days I read most of (if not
>>> all) the related pages on
>>> the wiki site, and browsed the indicated pdf documents too.
>>> Unfortunately I find the wiki
>>> pages confusing, and I couldn't find out how to solve the problem
>>> yet, but I did not want
>>> to wait longer with the answer. I will study further the docs.
>>
>> search for 'fallbacks' in the test suite
>>
>> (you can have fallback ranges but also individual characters)
>
> Fallbacks don’t work when you use \iffontchar to check if the character
> is in the font
> even though it is available in the fallback font.
>
> \definefallbackfamily [testfont] [rm] [DejaVu Serif] [range=0x25C6]
> \definefontfamily     [testfont] [rm] [TeX Gyre Pagella]
>
> \setupbodyfont[dejavu]
>
> \starttext
>
> ◆ : \checkedtextchar{"25C6}{{\tttf ??}}
>
> \switchtobodyfont[testfont]
>
> ◆ : \checkedtextchar{"25C6}{{\tttf ??}}
>
> \stoptext

ok, i'll include the fallback sin the test (next beta)

Hans


-- 

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------


More information about the ntg-context mailing list