ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: (hindi) font questions
Date: Thu, 9 Apr 2015 14:52:48 +0200	[thread overview]
Message-ID: <A3F8C078-4073-42AE-8047-381F8935D1AA@gmail.com> (raw)
In-Reply-To: <20150408214749.GA22068@hl.fritz.box>

[-- Attachment #1: Type: text/plain, Size: 1464 bytes --]


> Am 08.04.2015 um 23:47 schrieb Harald Koenig <koenig@tat.physik.uni-tuebingen.de>:
> 
> Hi,
> 
> I'd like to type set a single hindi/devanagari word in a chapter heading (using standalone MkVI),
> where I need your help for some questions/problems:
> 
> - which (free) font do you suggest ?  right now I'm using "Lohit-Devanagari". 
>  text font is 11pt Palatino, Lohit doesn't match too good, and a bold version
>  would be nice for the chapter head.
> 
> - font size: how do I define this font to get automatic/matching font sizes
>  for both the chapter head and the title of contents ?
> 
> right now I use
> 
>      \definefont [hindib] [Lohit-Devanagari at 24pt]
>      ...
>      \mychapter{Danke -- {\hindib  धन्यवाद}}
> 
> which gives a reaosonable font size for the chapter title,
> but of course that's way too large for the TOC:-(
> 
> 
> what's the right way to define a "scalable" single font (or two, if you have a suggestion
> for a normal+bold devanagari font) in ConTeXt ?


You can use the fallback mechanism to use a different font for characters which aren’t available in the main font.

\definefallbackfamily [mainface] [rm] [Devanagari MT] [range=devanagari,scale=1.2]
\definefontfamily     [mainface] [rm] [TeX Gyre Pagella]

\definefontfamily     [mainface] [mm] [TeX Gyre Pagella Math]

\setupbodyfont[mainface]

\starttext
Danke – धन्यवाद
\stoptext

Wolfgang

[-- Attachment #2: test.pdf --]
[-- Type: application/pdf, Size: 12005 bytes --]

[-- Attachment #3: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

  reply	other threads:[~2015-04-09 12:52 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-04-08 21:47 Harald Koenig
2015-04-09 12:52 ` Wolfgang Schuster [this message]
2015-04-10  6:43   ` Harald Koenig
2015-04-10  8:59     ` Wolfgang Schuster
2015-04-13 19:20       ` Harald Koenig
2015-04-09 18:28 ` 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=A3F8C078-4073-42AE-8047-381F8935D1AA@gmail.com \
    --to=schuster.wolfgang@gmail.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).