* Nice guillemots
@ 2001-10-23 14:32 Giuseppe Bilotta
2001-10-23 15:55 ` Hans Hagen
0 siblings, 1 reply; 2+ messages in thread
From: Giuseppe Bilotta @ 2001-10-23 14:32 UTC (permalink / raw)
[-- Attachment #1: Type: text/plain, Size: 705 bytes --]
Hello,
Attached to this mail are two small symbol modules I wrote,
temporary called symb-wnc and symb-lsy, that redefine the left and
right guillemots using respectively the wncyr fonts and the LaTeX
Symbol (LaSy) fonts. The latter are nicer but slower.
Two question:
(1) should they be named differently?
(2) can they be merged? Is there a way to pass options to module
so that they can select a certain predefined behaviour, and change
it when appropriate commands are issued? That is, I can do it 'the
TeX way', but I wonder if ConTeXt shouldn't provide a default
interface for this. something like
\usemodule[whatever][starting options]
\setmoduleoption[something]
--
Giuseppe "Oblomov" Bilotta
[-- Attachment #2: symb-lsy.tex --]
[-- Type: application/octet-stream, Size: 1647 bytes --]
%D \module
%D [ file=symb-lsy,
%D version=2001.10.23,
%D title=\CONTEXT\ Symbol Libraries,
%D subtitle=Guillemots from LaTeX Symbols,
%D author=Giuseppe Bilotta,
%D date=\currentdate,
%D copyright={PRAGMA / Giuseppe Bilotta}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
\unprotect
%D First of all, define the font file. TODO: how to choose the
%D appropriate font design size?
\definefontsynonym [LasySerif] [lasy10]
\def\Lasy#1{\getglyph{Lasy}{\char#1}}
%D The LaSy font doesn't have double guillemots, but only left
%D and right single guillemots; we build the double ones by
%D duplicating the single one, shifted by half their size
\newdimen\LeftLazyShift
\newdimen\RightLazyShift
%D Since different sizes require different shifts, we have to
%D calculate it each time. Another way would be to plug into the
%D typescript stuff, and recalculate only at size-change time.
%D This way is slower but doesn't mess with internal stuff
\def\SetLeftLazyShift%
{\setbox\scratchbox\hbox{\Lasy{40}}%
\LeftLazyShift=.5\wd\scratchbox}
\def\SetRightLazyShift%
{\setbox\scratchbox\hbox{\Lasy{41}}%
\RightLazyShift=.5\wd\scratchbox}
%D Here we define the quick-access commands
\def\leftguillemot%
{\dontleavehmode\hbox{\SetLeftLazyShift%
\Lasy{40}\kern-\LeftLazyShift\Lasy{40}}}
\def\rightguillemot%
{\hbox{\SetRightLazyShift%
\Lasy{41}\kern-\RightLazyShift\Lasy{41}}}
\def\leftsubguillemot{\Lasy{40}}
\def\rightsubguillemot{\Lasy{41}}
\protect
\endinput
[-- Attachment #3: symb-wnc.tex --]
[-- Type: application/octet-stream, Size: 813 bytes --]
%D \module
%D [ file=symb-wnc,
%D version=2001.10.23,
%D title=\CONTEXT\ Symbol Libraries,
%D subtitle=Guillemots from the Cyrillic fonts,
%D author=Giuseppe Bilotta,
%D date=\currentdate,
%D copyright={PRAGMA / Giuseppe Bilotta}]
%C
%C This module is part of the \CONTEXT\ macro||package and is
%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
%C details.
\unprotect
\definefontsynonym [GuillsSerif] [wncyr10]
\definefontsynonym [GuillsSerifBold] [wncyb10]
\definefontsynonym [GuillsSerifItalic] [wncyi10]
\definefontsynonym [GuillsSerifCaps] [wncysc10]
\definefontsynonym [GuillsSans] [wncyss10]
\def\Guill#1{\getglyph{Guills}{\char#1}}
\def\leftguillemot{\Guill{60}}
\def\rightguillemot{\Guill{62}}
\protect
\endinput
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Nice guillemots
2001-10-23 14:32 Nice guillemots Giuseppe Bilotta
@ 2001-10-23 15:55 ` Hans Hagen
0 siblings, 0 replies; 2+ messages in thread
From: Hans Hagen @ 2001-10-23 15:55 UTC (permalink / raw)
Cc: ntg-context
At 04:32 PM 10/23/2001 +0200, you wrote:
>Hello,
>
>Attached to this mail are two small symbol modules I wrote,
>temporary called symb-wnc and symb-lsy, that redefine the left and
>right guillemots using respectively the wncyr fonts and the LaTeX
>Symbol (LaSy) fonts. The latter are nicer but slower.
i come back to that later
(2) can they be merged? Is there a way to pass options to module
>so that they can select a certain predefined behaviour, and change
>it when appropriate commands are issued? That is, I can do it 'the
>TeX way', but I wonder if ConTeXt shouldn't provide a default
>interface for this. something like
>
>\usemodule[whatever][starting options]
actually there is something like that (at least in my version), based on
modes, so sections can be marked with \startmode[starting options] and so.
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
-------------------------------------------------------------------------
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2001-10-23 15:55 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-10-23 14:32 Nice guillemots Giuseppe Bilotta
2001-10-23 15:55 ` 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).