From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/91967 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: Math - how to mix fonts? Date: Fri, 17 Jul 2015 15:15:38 +0200 Message-ID: <55A8FFFA.1030806@gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0232361371==" X-Trace: ger.gmane.org 1437139087 27482 80.91.229.3 (17 Jul 2015 13:18:07 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 17 Jul 2015 13:18:07 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Fri Jul 17 15:17:53 2015 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1ZG5WS-0008Jf-Nd for gctc-ntg-context-518@m.gmane.org; Fri, 17 Jul 2015 15:17:52 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id DD49110229 for ; Fri, 17 Jul 2015 15:17:51 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id Y5DLA5OKqE6a for ; Fri, 17 Jul 2015 15:17:50 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 5E90210233 for ; Fri, 17 Jul 2015 15:17:23 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 9A4E9101FB for ; Fri, 17 Jul 2015 15:17:19 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id EGXUIEJmRF5D for ; Fri, 17 Jul 2015 15:17:18 +0200 (CEST) Original-Received: from filter3-til.mf.surf.net (filter3-til.mf.surf.net [194.171.167.219]) by balder.ntg.nl (Postfix) with ESMTP id 8D1A3101E6 for ; Fri, 17 Jul 2015 15:17:18 +0200 (CEST) Original-Received: from mail-wg0-x232.google.com (mail-wg0-x232.google.com [IPv6:2a00:1450:400c:c00::232]) by filter3-til.mf.surf.net (8.14.4/8.14.4/Debian-4) with ESMTP id t6HDHHMJ018546 (version=TLSv1/SSLv3 cipher=AES128-GCM-SHA256 bits=128 verify=NOT) for ; Fri, 17 Jul 2015 15:17:17 +0200 Original-Received: by wgxm20 with SMTP id m20so82073438wgx.3 for ; Fri, 17 Jul 2015 06:17:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:subject:references :in-reply-to:content-type; bh=0h7K3K/AHHuNlNVGo+3cigpproCwXzE8CfQ9IwsfxUc=; b=aTcPMO8/NcHhHnhFOG1OZoa0GJAzpnsb2u5ToBTJWnMG/kehYz4i9/I5Htfyx3omQN 0WzVmQ6KLuIXCOhFS5mLvIFg1OEHB0u1rFusbbGcMLWUoqNt3sJHD75zSx/zzp32apX6 g+LTKw9q540rIh45XN+RkbDVX7dWRClk8ki7TzcS45SWnVWURyX1YlIPfaKrUrr9XGM+ 0k6yx4ud90aqAJlrpl2siVqHMK2QUifz/XNkhy2ohWHQBisOL/R1KlAbN1x1Y0TUEVW0 ZXQqlDafkoCT0aD50A7hTRti4vwy/omL4pAktlbE3/gYSEaNOrcDVHCygnfO1D5ay6b9 bvEQ== X-Received: by 10.180.77.193 with SMTP id u1mr15364192wiw.50.1437139036927; Fri, 17 Jul 2015 06:17:16 -0700 (PDT) Original-Received: from keima.localdomain (x2f28615.dyn.telefonica.de. [2.242.134.21]) by smtp.googlemail.com with ESMTPSA id i6sm18330394wje.33.2015.07.17.06.15.39 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 17 Jul 2015 06:15:40 -0700 (PDT) User-Agent: Postbox 4.0.1 (Macintosh/20150514) In-Reply-To: X-Bayes-Prob: 0.0001 (Score 0, tokens from: ntg-context@ntg.nl, base:default, @@RPTN) X-CanIt-Geo: ip=2a00:1450:400c:c00::232; country=BE; region=Brussels Capital; city=Brussels; latitude=50.8466; longitude=4.3528; http://maps.google.com/maps?q=50.8466,4.3528&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 06ORphhto - 9b376c529684 - 20150717 (trained as not-spam) Received-SPF: pass (filter3-til.mf.surf.net: domain of schuster.wolfgang@gmail.com designates 2a00:1450:400c:c00::232 as permitted sender) receiver=filter3-til.mf.surf.net; client-ip=2a00:1450:400c:c00::232; envelope-from=; helo=mail-wg0-x232.google.com; identity=mailfrom X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.org gmane.comp.tex.context:91967 Archived-At: This is a multi-part message in MIME format. --===============0232361371== Content-Type: multipart/alternative; boundary="------------070408010207050906080907" This is a multi-part message in MIME format. --------------070408010207050906080907 Content-Type: text/plain; charset=ISO-8859-2; format=flowed Content-Transfer-Encoding: quoted-printable > Proch=E1zka Luk=E1=B9 Ing. - Pontex s. r. o. > 17. Juli 2015 10:30 > Hello, > > I am not very familiar with mixing fonts in math. I would need to mix=20 > several font styles: > > 1. "normal" (default - slanted, serif) for general variables, > 2. slanted serif bold for vectors, > 3. slanted sans bold for varieties. > > In the following snippet, the right fonts are displayed in the \text=20 > scope, but not in the math: > > ---- > \definetypeface[boldmath][mm][boldmath][latin-modern][default] > > \starttext > \startformula > \text{\sl 1. Normal:}\quad Abcd \alpha > \stopformula > > \startformula > \text{\bs 2. Bold:}\quad\boldmath{Abcd \alpha} > \stopformula > > \startformula > \text{\bs\ss 3. SansBold:}\quad\ss\boldmath{Abcd \alpha} > \stopformula > \stoptext > ---- > > You can see that \boldmath has no effect (although=20 > "\definetypeface[boldmath][mm][boldmath][latin-modern][default]" was=20 > used, as described on http://wiki.contextgarden.net/Bold_Math ). > > So - what is the best way to define (enable) and use fonts styles=20 > 1.-3. in math? > > ( > Notes: > - The font must allow to type Greek letters - \alpha. > - Other font(s) than LatinModern may be used for math, if it enables=20 > bold and sans switching. > ) You can use the normal font switching commands (e.g. \it or \ss) to=20 change the math alphabet. %\setupbodyfont[xits] \setupmathematics[lcgreek=3Dnone,ucgreek=3Dnone] \starttext \startformula abcdef \quad {\tf abcdef} \quad {\it abcdef} \quad {\bf abcdef} \quad {\bi abcdef} \stopformula \startformula {\ss abcdef} \quad {\ss\it abcdef} \quad {\ss\bf abcdef} \quad {\ss\bi abcdef} \stopformula \startformula \alpha\beta\gamma \quad {\rm\alpha\beta\gamma} \quad {\it\alpha\beta\gamma} \quad {\bf\alpha\beta\gamma} \quad {\bi\alpha\beta\gamma} \stopformula \startformula \Alpha\Beta\Gamma \quad {\rm\Alpha\Beta\Gamma} \quad {\it\Alpha\Beta\Gamma} \quad {\bf\Alpha\Beta\Gamma} \quad {\bi\Alpha\Beta\Gamma} \quad \stopformula \stoptext Wolfgang --------------070408010207050906080907 Content-Type: text/html; charset=ISO-8859-2 Content-Transfer-Encoding: quoted-printable
= =20 17. Juli 2015=20 10:30
Hello,

I am not very familiar with mixing fonts in math. I would need to=20 mix several font styles:

1. "normal" (default - slanted, serif) for general variables,
2. slanted serif bold for vectors,
3. slanted sans bold for varieties.

In the following snippet, the right fonts are displayed in the \text scope, but not in the math:

----
\definetypeface[boldmath][mm][boldmath][latin-modern][default]

\starttext
=A0 \startformula
=A0=A0=A0 \text{\sl 1. Normal:}\quad Abcd \alpha
=A0 \stopformula

=A0 \startformula
=A0=A0=A0 \text{\bs 2. Bold:}\quad\boldmath{Abcd \alpha}
=A0 \stopformula

=A0 \startformula
=A0=A0=A0 \text{\bs\ss 3. SansBold:}\quad\ss\boldmath{Abcd \alpha}
=A0 \stopformula
\stoptext
----

You can see that \boldmath has no effect (although=20 "\definetypeface[boldmath][mm][boldmath][latin-modern][default]" was=20 used, as described on http://wiki.contextgarden.net/Bold_Math<= /a> ).

So - what is the best way to define (enable) and use fonts styles=20 1.-3. in math?

(
Notes:
- The font must allow to type Greek letters - \alpha.
- Other font(s) than LatinModern may be used for math, if it enables bold and sans switching.
)
You can use the normal font switching commands (e.g. \it or \ss) to=20 change the math alphabet.

%\setupbodyfont[xits]

\setupmathematics[lcgreek=3Dnone,ucgreek=3Dnone]

\starttext

\startformula
=A0=A0=A0 =A0=A0=A0=A0 abcdef=A0 \quad
=A0=A0=A0 {\tf abcdef} \quad
=A0=A0=A0 {\it abcdef} \quad
=A0=A0=A0 {\bf abcdef} \quad
=A0=A0=A0 {\bi abcdef}
\stopformula

\startformula
=A0=A0=A0 {\ss=A0=A0=A0 abcdef} \quad
=A0=A0=A0 {\ss\it abcdef} \quad
=A0=A0=A0 {\ss\bf abcdef} \quad
=A0=A0=A0 {\ss\bi abcdef}
\stopformula

\startformula
=A0=A0=A0 =A0=A0=A0 \alpha\beta\gamma=A0 \quad
=A0=A0=A0 {\rm\alpha\beta\gamma} \quad
=A0=A0=A0 {\it\alpha\beta\gamma} \quad
=A0=A0=A0 {\bf\alpha\beta\gamma} \quad
=A0=A0=A0 {\bi\alpha\beta\gamma}
\stopformula

\startformula
=A0=A0=A0 =A0=A0=A0 \Alpha\Beta\Gamma=A0 \quad
=A0=A0=A0 {\rm\Alpha\Beta\Gamma} \quad
=A0=A0=A0 {\it\Alpha\Beta\Gamma} \quad
=A0=A0=A0 {\bf\Alpha\Beta\Gamma} \quad
=A0=A0=A0 {\bi\Alpha\Beta\Gamma} \quad
\stopformula

\stoptext

Wolfgang
--------------070408010207050906080907-- --===============0232361371== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly90ZXguYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHA6Ly9mb3VuZHJ5LnN1cGVsZWMu ZnIvcHJvamVjdHMvY29udGV4dHJldi8Kd2lraSAgICAgOiBodHRwOi8vY29udGV4dGdhcmRlbi5u ZXQKX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX18= --===============0232361371==--