ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@gmail.com>
To: Sanjoy Mahajan <sanjoy@olin.edu>
Cc: "dev-context@ntg.nl Context" <dev-context@ntg.nl>,
	mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: [dev-context] palatino at 10.5pt bold not found when using project structure w/ MkIV
Date: Sun, 7 Jul 2013 22:38:50 +0200	[thread overview]
Message-ID: <C4A06BE9-2D23-49BE-9C78-318FAC7D9240@gmail.com> (raw)
In-Reply-To: <87wqp46krg.fsf@approx.mit.edu>


Am 06.07.2013 um 12:33 schrieb Sanjoy Mahajan <sanjoy@olin.edu>:

> Wolfgang,
> 
> Thank you for all your solutions!
> 
>> 2. You can omit the \usetypescript line.
> 
> Good to know.  Does the "palatino" keyword in \setupbodyfont
> automatically do that now (in Mark IV)?
> 
> Should I wikify that bit of information (as MkIV-only)?  (Since I don't
> really understand how the fonts work, I am hesitant to wikify much about
> it and put up incorrect information.)

The normal way to load a new font from a external typescript is

\usetypescriptfile[<name>]
\usetypescript[<name>]
\setupbofyfont[<name>]

In MkII you don’t need \usetypescriptfile to load the default fonts (times,
palatino etc.) because context loads them when it generates the format
but MkIV loads them the fonts are used to save memory.

Because in many cases the name of the file is the same (with a “type-” prefix)
as the font context tries to load the file itself when you enable the font with
\setupbodyfont, even the \usetypescript call (the second argument isn’t needed
because we aren’t restricted to 256 anymore with LuaTeX) isn’t necessary
because this is also done by \setupbodyfont.

>> 3. Move the \setupbodyfont setting *before* \startcomponent.
> 
> Right, I found that by experiment.  But how should you do that with
> projects?  The \setupbodyfont is usually part of an environment file,
> which is loaded by the project file.  Should the "\project project_file"
> line be placed before the "\startcomponent"?  Like this:
> 
>  \project project_file
>  \startcomponent component_name
> 
> If that's the recommended way, I can update
> <http://wiki.contextgarden.net/Project_structure>

You can do this. It’s always better to make the setup of the document before
\starttext, startcomponent etc. because some values are set/reset with \starttext.

>> 4. Add \definebodyfontenvironment[10.5pt] to your document.
> 
> Thanks, that fixes everything.  On the theory of teaching a man to fish,
> how did you learn so much about making ConTeXt do just the right thing?
> 
>> 1. Use the normal and not the developer list for such a question.
> 
> I thought it was a bug (and it might be, though your
> definebodyfontenvironment solution makes me wonder if it is just my not
> knowing enough).  In general, should bug reports go to the regular list?


The only things which are posted on the developer list nowadays are bug reports
with possible fixes or extensions to the context programing language.

Wolfgang
___________________________________________________________________________________
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:[~2013-07-07 20:38 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <8738rs8wi3.fsf@approx.mit.edu>
2013-07-06  6:11 ` Wolfgang Schuster
2013-07-06 10:33   ` [dev-context] " Sanjoy Mahajan
2013-07-07 20:38     ` Wolfgang Schuster [this message]
2013-07-08 20:29       ` Sanjoy Mahajan

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=C4A06BE9-2D23-49BE-9C78-318FAC7D9240@gmail.com \
    --to=schuster.wolfgang@gmail.com \
    --cc=dev-context@ntg.nl \
    --cc=ntg-context@ntg.nl \
    --cc=sanjoy@olin.edu \
    /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).