From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/29032 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: BPJ Newsgroups: gmane.text.pandoc Subject: Re: How do I control and embed the fonts in my pdfs? Date: Mon, 16 Aug 2021 10:25:46 +0200 Message-ID: References: <543536ca-7ced-4033-ad1a-ecdd3fedaf44n@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000028a6bd05c9a8f3e2" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="13601"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBCWMVYEK54FRBFGC5CEAMGQEFSTZJTA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mon Aug 16 10:26:00 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-lj1-f184.google.com ([209.85.208.184]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mFXwV-0003Ao-GJ for gtp-pandoc-discuss@m.gmane-mx.org; Mon, 16 Aug 2021 10:25:59 +0200 Original-Received: by mail-lj1-f184.google.com with SMTP id c39-20020a2ebf270000b029019c5777f07fsf5688578ljr.1 for ; Mon, 16 Aug 2021 01:25:59 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1629102358; cv=pass; d=google.com; s=arc-20160816; b=SXqz6bqiRFN+lv0dHiW0wbU+zZJkygBcn0hEZKJ/4vV3QLR7+JnfVzGbVQYq6gw9i2 W1DudATs2D16kpRVYYfskpDQgr6gXNQBRe4IZmxULF9C5rB8tIeP7gvwgFMB7iy9MyXy 38a80dwXuAwP2kzHATz8NCE2l2pt55KJUxUYIXivLwibz8tjcjdVlzV6xXfM70WCZhXs hD9jroFV4YjpJuNp9zdT8TgC1N+W3zD10q0ofX0Uz3d7ZqD46ma+pgUVDH874NwhVGAm EAY72C5oTGyYuK5zsEa9QnIZmfyTh2yLM+YQGC/ns8/jBDA9hPZpOolRlCKT/W3fBPVo 9aQA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:to:subject:message-id:date:from :reply-to:in-reply-to:references:mime-version:sender:dkim-signature; bh=2FLNMuBoD21MFtM6Pw+ffBSH0hFoU90Mpl8X4reQpbs=; b=guz3l/h15/3IGSTIyl9y1htQEm3gl594cIKb96kNbfD/wUyHbNjrDaPvK9ZqHq1drG m4zwLooZaieKbsVOrWFHN83zlesZc2hbY1IE8wODb8C3MlMmuYahv7lszL09FI2Iw/Lk dDvEeM6KYeGK90X0liwhRJXf+Cm0z1LbBwBp53DnjjodQvvLl9bPB88n7Kc5hJzJzQaK dfnivTW1FR85MC3dsVJ08vKc374aCW29erBWzr7SHJdD5GjAUUF9r/u9TaI4832lxqfC ih6mkc1poCNgnkNdHZkKzu4mCNWfGkIE8o4zhijq14ok/WWQTHXlWkpEeEkEL1UOoF9W rqUA== ARC-Authentication-Results: i=2; gmr-mx.google.com; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 209.85.208.177 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20161025; h=sender:mime-version:references:in-reply-to:reply-to:from:date :message-id:subject:to:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=2FLNMuBoD21MFtM6Pw+ffBSH0hFoU90Mpl8X4reQpbs=; b=RI0RCnW1sbvkMeljihOnP4zJPM2HNjz+Im0GOkI12sZl6Y9x21JyV4D+sjHE09/kcO GJXNKxzJL3PaKct4mpcbVb2lbQFcPjSQAWzrXZMUTHhKLJoOP4LvzRNadvGPi9ifkSXM 2mfrjxZcmu8qqrrcRSCmbFgsEgW0vfXxl5kwt5WqihPUJPIO0eosFT8C+ncafAfp49Z+ lODPXB4FR07XEMBhJH/rR6RUGJ+xD7wSpjQdZMMCHIAsIElkI0emjyVknNXUFMh3lBfA s9r8yvuCcZ5bE7UUbt7Yzs72B1o6uuMlq10iZGjt+Dbkw8breVgvFQq6CVbg22WmM9I4 wzPw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:mime-version:references:in-reply-to :reply-to:from:date:message-id:subject:to:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=2FLNMuBoD21MFtM6Pw+ffBSH0hFoU90Mpl8X4reQpbs=; b=TpAF8pLF7xGNes6BtIY0q0fXj6joFxeg3KQa96KlwNyO4iR3hfQh1YxxKN5wvSYnm/ TyZwaYMZe+o0TXfDPh5pf9V7Co6brO9HFxv2k22tbRJdYnOp49RGpj6nLrWPpAn+4DYf vdJaYmeOv6ijpZj/c6pYijzD7bfr5HOA6gKdjDBz4BTyOs8hzCSNEA7+PIwkgrr65qkA xX/rRWRfQpcJhMu07MiZAsDcv6LRoI6aa++mrPCh+AzF4/uj4fj3N5K53XCsR5tqX+pF +Do+zlEE9vhkK44TITcwsnJXHgjeTlmsJYeSkzGwL/OwQ93bVLZorQhFP0i57sTaju5H +fZw== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM532rOLgdWvV0BcmXkpO9rJKWUFQVl8K9xCM3xvhHQ5/kzy/V3afG t4Iq0Mh1gdH0/QE1Mq9XAEE= X-Google-Smtp-Source: ABdhPJzDzUY1kY3nqttgB8i37JelY2mqwq/BahcOHsh0103L2AckkUczF1jRE9tH3VaLdHB112tCRA== X-Received: by 2002:a19:ad03:: with SMTP id t3mr10902115lfc.183.1629102358654; Mon, 16 Aug 2021 01:25:58 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6512:b24:: with SMTP id w36ls535840lfu.1.gmail; Mon, 16 Aug 2021 01:25:55 -0700 (PDT) X-Received: by 2002:a05:6512:a90:: with SMTP id m16mr1344211lfu.349.1629102355202; Mon, 16 Aug 2021 01:25:55 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629102355; cv=none; d=google.com; s=arc-20160816; b=00NOBZsTMsJkHIWZ+csV8xYCpcNrUGsaXZqePI95+uMLQbG1j828OK+pakzxiXSooO e64dWz6AG9sJETotDnLIl2Xk3lpXKULBh9T1HsFQrPs9Nnju0UbNDbM+oW4hTMCAotdt AGeO5tnD0XBKMFfSBMpw7gWEALceyo3uWgMqptvtaTqlnmwDlOi6uedstRre2KW/0lfo 2xsuysoP7BV2PVISzqYU4j7bcCT+ZNgrhV/yXYFKMUjTan8RbuCzfxC3tvW+cpgr/e6n 4O7PHuN7z4VEqk3VzScwM7ic6cUjmWj93/Ns05N9Fnv3eWa9Rxrklh8mEDn8D7Hsmr0P G8Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:subject:message-id:date:from:reply-to:in-reply-to:references :mime-version; bh=GcULdTOeFFszeERT7glAXmWnnjlzk/Mpd+j2mt193is=; b=N4J78W+FvbQffIh9+vbllrThI8JVjPGrmBOamYx9Du6yf2EOdy16F0rLhHnp8R/Zy0 zy+yq0J95zHRj6S1m1or1EJlIhydR/WXkOg5t961QeCRc08LE48Fan85/QcQiQS2O6dv 1P4pT9wuJK6S6iXjhTtQF6XA7oV+zjf0IEWqHqVDaK/OpZuVynZ55Bdobza1maw4DdT5 NrwhjvfyHXZ1Nbvhi0OJi0i3MkuQcZHXRu7RRsFpiefi01WUbgOT2TipH6l9pHHqZCfv nSlYes9x4yKkprNjbvpyDverD1voBq7iyz9/cf4iB7HFKui9uZui/afnxYXCngTkByU9 sTWw== ARC-Authentication-Results: i=1; gmr-mx.google.com; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 209.85.208.177 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Original-Received: from mail-lj1-f177.google.com (mail-lj1-f177.google.com. [209.85.208.177]) by gmr-mx.google.com with ESMTPS id q8si541035ljm.2.2021.08.16.01.25.55 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Mon, 16 Aug 2021 01:25:55 -0700 (PDT) Received-SPF: pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 209.85.208.177 as permitted sender) client-ip=209.85.208.177; Original-Received: by mail-lj1-f177.google.com with SMTP id h17so25866222ljh.13 for ; Mon, 16 Aug 2021 01:25:55 -0700 (PDT) X-Received: by 2002:a2e:2417:: with SMTP id k23mr8252966ljk.256.1629102354768; Mon, 16 Aug 2021 01:25:54 -0700 (PDT) In-Reply-To: <543536ca-7ced-4033-ad1a-ecdd3fedaf44n-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> X-Original-Sender: melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 209.85.208.177 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:29032 Archived-At: --00000000000028a6bd05c9a8f3e2 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable You use the `mainfont`, `sansfont`, `monofont`, `mathfont`, `CJKmainfont` variables for the font names and the corresponding `mainfontoptions` etc. variables. The latter are lists of strings with raw fontspec[^1] options in the format `'Option=3DValue'` or `'Option=3D{Multi-word value}'`. The easiest way is to specify them is in a defaults file[^2] like this: from: markdown to: latex pdf-engine: xelatex variables: mainfont: Noto Serif sansfont: Noto Sans monofont: Noto Mono monofontoptions: - 'Scale=3DMatchLowercase' For some reason the default latex template[^3] does not contain any variable for `defaultfontfeatures` but `\defaultfontfeatures{Scale=3DMatchLowercase}` is hard coded. In my custom template I have added that variable[^4]: $if(defaultfontfeatures)$ \mainfontfeatures{$for(mainfontfeatures)$$mainfontfeatures$$sep$,$endfor$} $else$ \defaultfontfeatures{Scale=3DMatchLowercase} $endif$ Font embedding depends on your XeTeX/LuaTeX settings. Usually it Just Works= . [^1]: https://ctan.org/pkg/fontspec [^2]: https://pandoc.org/MANUAL.html#default-files [^3]: https://pandoc.org/MANUAL.html#templates [^4]: https://git.io/J0UJS Den m=C3=A5n 16 aug. 2021 06:56Hugh Esco skrev: > My tests seem to indicate that the fonts which are available to me are a > function of the value of the `--latex-engine=3D` switch. > > If I set that switch to pdflatex (which seems to be the default), I can > choose any font installed as a .sty file at this path: > `/usr/share/texlive/texmf-dist/tex/latex/psnfss/`, by setting a value to > the fontenc key at the top of my markdown source file. > > But I have not been able to sort out how to access other fonts installed > at `/usr/share`, by setting the `--latex-engine` to `lualatext` or > `xelatex`. > > All my tests seem to look alike, and changing my fonts has no impact on > how the resulting pdf looks. > > Can someone please point me to some documentation which would help me > understand how to use the full range of fonts available on this system, > suitable for which ever value I set to the `--latext-engine` switch? > > Thanks, > -- Hugh Esco > > -- > You received this message because you are subscribed to the Google Groups > "pandoc-discuss" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > To view this discussion on the web visit > https://groups.google.com/d/msgid/pandoc-discuss/543536ca-7ced-4033-ad1a-= ecdd3fedaf44n%40googlegroups.com > > . > --=20 You received this message because you are subscribed to the Google Groups "= pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/CADAJKhCkmKrY%2B-ZUzZg3W4hW%3DtLsa4irz4KP-_-dzJsB%2BtUfUA%40= mail.gmail.com. --00000000000028a6bd05c9a8f3e2 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
You use the `mainfont`, `sansfont`, `mo= nofont`, `mathfont`, `CJKmainfont`
variables for the= font names and the corresponding `mainfontoptions` etc.
variables. The latter are lists of strings with raw fontspec[^1] optio= ns in the format `'Option=3DValue'` or `'Option=3D{Multi-word v= alue}'`. The
easiest way is to specify them is i= n a defaults file[^2] like this:

=C2=A0 =C2=A0 from: markdown
=C2=A0 =C2=A0= to: latex
=C2=A0 =C2=A0 pdf-engine: xelatex
=C2=A0 =C2=A0 variables:
=C2=A0 =C2= =A0 =C2=A0 mainfont: Noto Serif
=C2=A0 =C2=A0 =C2=A0= sansfont: Noto Sans
=C2=A0 =C2=A0 =C2=A0 monofont: = Noto Mono
=C2=A0 =C2=A0 =C2=A0 monofontoptions:
=C2=A0 =C2=A0 =C2=A0 =C2=A0 - 'Scale=3DMatchLowercas= e'

For some reason t= he default latex template[^3] does not contain any
v= ariable for `defaultfontfeatures` but
`\defaultfontf= eatures{Scale=3DMatchLowercase}` is hard coded. In my custom
template I have added that variable[^4]:
<= br>
=C2=A0 =C2=A0 $if(defaultfontfeatures)$
=C2=A0 =C2=A0 =C2=A0 \mainfontfeatures{$for(mainfontfeatures= )$$mainfontfeatures$$sep$,$endfor$}
=C2=A0 =C2=A0 $e= lse$
=C2=A0 =C2=A0 =C2=A0 \defaultfontfeatures{Scale= =3DMatchLowercase}
=C2=A0 =C2=A0 $endif$

Font embedding depends on your XeTe= X/LuaTeX settings. Usually it Just Works.

=



=
Den m= =C3=A5n 16 aug. 2021 06:56Hugh Esco <hresco3-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:
= My tests seem to indicate that the fonts which are available to me are a fu= nction of the value of the `--latex-engine=3D` switch.=C2=A0

If I s= et that switch to pdflatex (which seems to be the default), I can choose an= y font installed as a .sty file at this path: `/usr/share/texlive/texmf-dis= t/tex/latex/psnfss/`, by setting a value to the fontenc key at the top of m= y markdown source file.=C2=A0

But I have not been a= ble to sort out how to access other fonts installed at `/usr/share`, by set= ting the `--latex-engine` to `lualatext` or `xelatex`.=C2=A0

All my tests seem to look alike, and changing my fonts has = no impact on how the resulting pdf looks.=C2=A0

Can someone please point me to some documentation which would help me un= derstand how to use the full range of fonts available on this system, suita= ble for which ever value I set to the `--latext-engine` switch?=C2=A0
<= br>Thanks,
-- Hugh Esco

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh4Ykp1iOSErHA@public.gmane.org= m.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/543536ca-7= ced-4033-ad1a-ecdd3fedaf44n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://g= roups.google.com/d/msgid/pandoc-discuss/CADAJKhCkmKrY%2B-ZUzZg3W4hW%3DtLsa4= irz4KP-_-dzJsB%2BtUfUA%40mail.gmail.com.
--00000000000028a6bd05c9a8f3e2--