From: Hans Hagen <j.hagen@xs4all.nl>
To: Juraj Fiala <jurajfiala@protonmail.com>,
mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: Abstracting styles
Date: Wed, 27 Nov 2019 10:08:56 +0100 [thread overview]
Message-ID: <d6d86bfc-cce1-c7c7-01e6-02d03de0efea@xs4all.nl> (raw)
In-Reply-To: <Jdhc5p_0mheg51mJTZuGR0iY1O6-1JpE56yvTjt_KNRzz_EiZsh1inuJyC-w67CEmEBKguz_ZVcR006HayBQC2bdz-r60w4Pf8DczikWnM8=@protonmail.com>
On 11/26/2019 8:00 PM, Juraj Fiala wrote:
> Hi,
>
> I’m trying to learn ConTeXt, but I’m discovering a few hurdles along the
> way. Essentially what I currently want to do is to emulate paragraph
> styles found in other software, e.g. Scribus. After several hours of
> research all I have in my head is a complete mess of conflicting
> approaches, so I’d like to get some sane present-day advice. :-)
>
> Say I wanted to achieve this (as a rough example, the point is mixing
> weights and OpenType features in different contexts):
>
> Heading 1: Source Serif Semibold, smcp=yes, 12% letter-spacing
> Heading 2: Source Serif Semibold
> Emphasis: Source Serif Regular, smcp=yes, 8% letter-spacing
>
> What is the most straightforward way should I load the fonts and set the
> ‘styles’?
Something:
\definefontfamily[mainface][serif][Source Serif Pro]
\setupbodyfont[mainface]
\definecharacterkerning [LittleMoreA] [factor=0.12]
\definecharacterkerning [LittleMoreB] [factor=0.08]
\setuphead
[chapter]
[distance=2em,
style=\tfd,
textstyle={\smallcaps\setcharacterkerning[LittleMoreA]}]
\definehighlight
[emphasis]
[style={\setcharacterkerning[LittleMoreA]}]
\starttext
\startchapter[title=Something Small]
test \emphasis {test} test
\stopchapter
but the font has no smallcaps
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 / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage : http://www.pragma-ade.nl / http://context.aanhet.net
archive : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2019-11-27 9:08 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-11-26 19:00 Juraj Fiala
2019-11-27 9:08 ` Hans Hagen [this message]
2019-11-27 13:52 ` Juraj Fiala
2019-11-28 13:50 ` Pablo Rodriguez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=d6d86bfc-cce1-c7c7-01e6-02d03de0efea@xs4all.nl \
--to=j.hagen@xs4all.nl \
--cc=jurajfiala@protonmail.com \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).