ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* m-units questions...
@ 2002-03-15  7:09 Daniel Pittman
  2002-03-15  8:23 ` Peter Jander
                   ` (2 more replies)
  0 siblings, 3 replies; 12+ messages in thread
From: Daniel Pittman @ 2002-03-15  7:09 UTC (permalink / raw)


I am using the m-units module to typeset "degrees Celsius" and "degrees
Fahrenheit" in my cookbook.

The Fahrenheit character and the degrees look very nice together with
the default Computer Modern fonts in ConTeXt.

The Celsius character, on the other hand, looks only passably good.

I think that both of them would benefit from additional kerning, the C
more than the F. Is this something that should be done in the m-units
module or should I continue to use my local hack?

I typeset them at 8pt with:

\Degrees\kern-0.9pt\Celsius
\Degrees\kern-.5pt\Fahrenheit

Also, what is the "correct" way of loading a module with ConTeXt? I used
\input m-units, which works fine. I just wondered if there was some
higher level way of doing this.

        Daniel

-- 
Every violation of truth is not only a sort of suicide in the liar, but is a
stab at the health of human society.
        -- Emerson, _Prudence_, (Essays)


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
@ 2002-03-15  8:23 ` Peter Jander
  2002-03-15  8:41   ` Hans Hagen
  0 siblings, 1 reply; 12+ messages in thread
From: Peter Jander @ 2002-03-15  8:23 UTC (permalink / raw)


You can define your own units (after loading m-units) with

\unit[DegC]{\Deg\kern-0.9pt\Celsius}{Degree Celsius}

then you can type 10\DegC\ and so on.
This helps to keep your source readable and is easily changed if 
you need to.
> 
> I typeset them at 8pt with:
> 
> \Degrees\kern-0.9pt\Celsius
> \Degrees\kern-.5pt\Fahrenheit
> 
> 

\usemodule[units]
> Also, what is the "correct" way of loading a module with ConTeXt? I used
> \input m-units, which works fine. I just wondered if there was some
> higher level way of doing this.

Hope this helps,
Peter


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  7:09 m-units questions Daniel Pittman
  2002-03-15  8:23 ` Peter Jander
@ 2002-03-15  8:39 ` Hans Hagen
  2002-03-15  8:54 ` Taco Hoekwater
  2 siblings, 0 replies; 12+ messages in thread
From: Hans Hagen @ 2002-03-15  8:39 UTC (permalink / raw)
  Cc: ntg-context

At 06:09 PM 3/15/2002 +1100, you wrote:
>I am using the m-units module to typeset "degrees Celsius" and "degrees
>Fahrenheit" in my cookbook.
>
>The Fahrenheit character and the degrees look very nice together with
>the default Computer Modern fonts in ConTeXt.
>
>The Celsius character, on the other hand, looks only passably good.
>
>I think that both of them would benefit from additional kerning, the C
>more than the F. Is this something that should be done in the m-units
>module or should I continue to use my local hack?
>
>I typeset them at 8pt with:
>
>\Degrees\kern-0.9pt\Celsius
>\Degrees\kern-.5pt\Fahrenheit

I have to think that over, since it is font dependent; one way to handle 
this is by defining a font handler

>Also, what is the "correct" way of loading a module with ConTeXt? I used
>\input m-units, which works fine. I just wondered if there was some
>higher level way of doing this.

\usemodule[units]

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-ade.nl
-------------------------------------------------------------------------


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  8:23 ` Peter Jander
@ 2002-03-15  8:41   ` Hans Hagen
  2002-03-15 23:02     ` Daniel Pittman
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2002-03-15  8:41 UTC (permalink / raw)
  Cc: ntg-context

At 08:23 AM 3/15/2002 +0000, Peter Jander wrote:
>You can define your own units (after loading m-units) with
>
>\unit[DegC]{\Deg\kern-0.9pt\Celsius}{Degree Celsius}
>
>then you can type 10\DegC\ and so on.

maybe it's better to use "em" as unit, something -.05em or so, or 
.08\bodyfontsize or so; makes it scalable

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-ade.nl
-------------------------------------------------------------------------


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  7:09 m-units questions Daniel Pittman
  2002-03-15  8:23 ` Peter Jander
  2002-03-15  8:39 ` Hans Hagen
@ 2002-03-15  8:54 ` Taco Hoekwater
  2002-03-15  9:17   ` Hans Hagen
  2002-03-16  7:07   ` Daniel Pittman
  2 siblings, 2 replies; 12+ messages in thread
From: Taco Hoekwater @ 2002-03-15  8:54 UTC (permalink / raw)
  Cc: ntg-context

On Fri, 15 Mar 2002 18:09:11 +1100
"Daniel Pittman" <daniel@rimspace.net> wrote:

> I think that both of them would benefit from additional kerning, the C
> more than the F. Is this something that should be done in the m-units
> module or should I continue to use my local hack?

I agree that it could be better, esp. the Celcius. For the hack:
it is better to use ".1em" instead of ".9pt", that way you won't have
to adjust the value for other pointsizes. But it should go in the
module, I guess.

> Also, what is the "correct" way of loading a module with ConTeXt? I used
> \input m-units, which works fine. I just wondered if there was some
> higher level way of doing this.

The \usemodule command, as in \usemodule[units]

It accepts a list of modules, and it prefers local (that is: from the 
parent dir) modules to systemwide modules, which is often handy for
project-specific patches.

-- 
groeten,

Taco


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  8:54 ` Taco Hoekwater
@ 2002-03-15  9:17   ` Hans Hagen
  2002-03-15 10:07     ` Taco Hoekwater
  2002-03-16  7:07   ` Daniel Pittman
  1 sibling, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2002-03-15  9:17 UTC (permalink / raw)
  Cc: ntg-context

At 09:54 AM 3/15/2002 +0100, you wrote:
>On Fri, 15 Mar 2002 18:09:11 +1100
>"Daniel Pittman" <daniel@rimspace.net> wrote:
>
> > I think that both of them would benefit from additional kerning, the C
> > more than the F. Is this something that should be done in the m-units
> > module or should I continue to use my local hack?
>
>I agree that it could be better, esp. the Celcius. For the hack:
>it is better to use ".1em" instead of ".9pt", that way you won't have
>to adjust the value for other pointsizes. But it should go in the
>module, I guess.

taco: i sometimes wonder when to use em and when \bodyfontsize, how 
consistent is em defined inside fonts?

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-ade.nl
-------------------------------------------------------------------------


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  9:17   ` Hans Hagen
@ 2002-03-15 10:07     ` Taco Hoekwater
  0 siblings, 0 replies; 12+ messages in thread
From: Taco Hoekwater @ 2002-03-15 10:07 UTC (permalink / raw)
  Cc: ntg-context

On Fri, 15 Mar 2002 10:17:09 +0100
"Hans Hagen" <pragma@wxs.nl> wrote:

> taco: i sometimes wonder when to use em and when \bodyfontsize, how 
> consistent is em defined inside fonts?

I prefer to use 'em' for horizontal stuff; special purpose fonts tend to 
have em values that are quite different from the pointsize, and generally 
in the horizontal case the em value is the one you really need. For
vertical things, I generally use the pointsize, but sometimes 'ex' is 
better (e.g. for positioning accents).

-- 
groeten,

Taco


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  8:41   ` Hans Hagen
@ 2002-03-15 23:02     ` Daniel Pittman
  0 siblings, 0 replies; 12+ messages in thread
From: Daniel Pittman @ 2002-03-15 23:02 UTC (permalink / raw)


On Fri, 15 Mar 2002, Hans Hagen wrote:
> At 08:23 AM 3/15/2002 +0000, Peter Jander wrote:
>>You can define your own units (after loading m-units) with
>>
>>\unit[DegC]{\Deg\kern-0.9pt\Celsius}{Degree Celsius}
>>
>>then you can type 10\DegC\ and so on.
> 
> maybe it's better to use "em" as unit, something -.05em or so, or
> .08\bodyfontsize or so; makes it scalable

I considered doing that but figured that, for a font with no explicit
"degree" symbol, kerning would vary dramatically based on font size as
well as between related styles.

At some point I will probably look into the TeX and ConTeXt font
mechanisms and see if I can use the "degree" symbol from fonts that
actually feature it. They should have correct kerning information,
eliminating the need to use the $^\circ$ hack.

        Daniel

-- 
Sweet desert rose
This memory of Eden haunts us all
This desert flower, this rare perfume
Is the sweet intoxication of the fall
        -- Sting, _Desert Rose_


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-15  8:54 ` Taco Hoekwater
  2002-03-15  9:17   ` Hans Hagen
@ 2002-03-16  7:07   ` Daniel Pittman
  2002-03-17 11:19     ` Hans Hagen
  1 sibling, 1 reply; 12+ messages in thread
From: Daniel Pittman @ 2002-03-16  7:07 UTC (permalink / raw)


On Fri, 15 Mar 2002, Taco Hoekwater wrote:
> On Fri, 15 Mar 2002 18:09:11 +1100
> "Daniel Pittman" <daniel@rimspace.net> wrote:

[...]

>> Also, what is the "correct" way of loading a module with ConTeXt? I
>> used \input m-units, which works fine. I just wondered if there was
>> some higher level way of doing this.
> 
> The \usemodule command, as in \usemodule[units]

This responds with:

system         : no macros found in module m-units

The ConTeXt run then dies with:

! Undefined control sequence.
\DoDoTemperature #1#2->{#1}\Degrees 

So, while the right way to load the "m-units" module may be \usemodule,
it does not seem to work for me. :(

        Daniel

-- 
When we want to infuse new ideas, to modify or better the habits and customs
of a people, to breathe new vigour into its national traits, we must use the
child as our vehicle; for so little can be accomplished with adults.
        -- Maria Montessori, _The Absorbent Mind_, 1949


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-16  7:07   ` Daniel Pittman
@ 2002-03-17 11:19     ` Hans Hagen
  2002-03-18  9:34       ` Daniel Pittman
  0 siblings, 1 reply; 12+ messages in thread
From: Hans Hagen @ 2002-03-17 11:19 UTC (permalink / raw)
  Cc: ntg-context

At 06:07 PM 3/16/2002 +1100, you wrote:
>On Fri, 15 Mar 2002, Taco Hoekwater wrote:
> > On Fri, 15 Mar 2002 18:09:11 +1100
> > "Daniel Pittman" <daniel@rimspace.net> wrote:
>
>[...]
>
> >> Also, what is the "correct" way of loading a module with ConTeXt? I
> >> used \input m-units, which works fine. I just wondered if there was
> >> some higher level way of doing this.
> >
> > The \usemodule command, as in \usemodule[units]
>
>This responds with:
>
>system         : no macros found in module m-units
>
>The ConTeXt run then dies with:
>
>! Undefined control sequence.
>\DoDoTemperature #1#2->{#1}\Degrees
>
>So, while the right way to load the "m-units" module may be \usemodule,
>it does not seem to work for me. :(

Quite strange, can you run

   mktexlsr

and say

   kpsewhich m-units.tex

and see if the file is found?

Hans

-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-ade.nl
-------------------------------------------------------------------------


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-17 11:19     ` Hans Hagen
@ 2002-03-18  9:34       ` Daniel Pittman
  2002-03-18 10:54         ` Hans Hagen
  0 siblings, 1 reply; 12+ messages in thread
From: Daniel Pittman @ 2002-03-18  9:34 UTC (permalink / raw)


On Sun, 17 Mar 2002, Hans Hagen wrote:
> At 06:07 PM 3/16/2002 +1100, you wrote:
>>On Fri, 15 Mar 2002, Taco Hoekwater wrote:
>> > On Fri, 15 Mar 2002 18:09:11 +1100
>> > "Daniel Pittman" <daniel@rimspace.net> wrote:

[...]

>> > The \usemodule command, as in \usemodule[units]
>>
>>This responds with:
>>
>>system         : no macros found in module m-units

[...]

>>So, while the right way to load the "m-units" module may be
>>\usemodule, it does not seem to work for me. :(
> 
> Quite strange, can you run

[...]

>    kpsewhich m-units.tex

/home/daniel/texmf/tex/context/base/m-units.tex

> and see if the file is found?

That's my private install of the current beta.

Speaking of current beta, would it be possible for the ConTeXt website
to have a "release date" next to the documentation and ConTeXt
downloads?  It's very hard to tell when a new beta or updated
documentation[1] is released at the moment...

        Daniel

Footnotes: 
[1]  Which is the more interesting of the two.

-- 
Sweet is pleasure after pain.
        -- John Dryden,  _Alexander's Feast_, 1697


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: m-units questions...
  2002-03-18  9:34       ` Daniel Pittman
@ 2002-03-18 10:54         ` Hans Hagen
  0 siblings, 0 replies; 12+ messages in thread
From: Hans Hagen @ 2002-03-18 10:54 UTC (permalink / raw)
  Cc: ntg-context

At 08:34 PM 3/18/2002 +1100, Daniel Pittman wrote:

>Speaking of current beta, would it be possible for the ConTeXt website
>to have a "release date" next to the documentation and ConTeXt
>downloads?  It's very hard to tell when a new beta or updated
>documentation[1] is released at the moment...

working on that (taco already made some suggestions)

hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-ade.nl
-------------------------------------------------------------------------


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2002-03-18 10:54 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-03-15  7:09 m-units questions Daniel Pittman
2002-03-15  8:23 ` Peter Jander
2002-03-15  8:41   ` Hans Hagen
2002-03-15 23:02     ` Daniel Pittman
2002-03-15  8:39 ` Hans Hagen
2002-03-15  8:54 ` Taco Hoekwater
2002-03-15  9:17   ` Hans Hagen
2002-03-15 10:07     ` Taco Hoekwater
2002-03-16  7:07   ` Daniel Pittman
2002-03-17 11:19     ` Hans Hagen
2002-03-18  9:34       ` Daniel Pittman
2002-03-18 10:54         ` Hans Hagen

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).