ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Initials / DroppedCaps
@ 2011-12-13 12:08 Henning Hraban Ramm
  2011-12-13 12:28 ` Wolfgang Schuster
  2011-12-13 12:38 ` Hans Hagen
  0 siblings, 2 replies; 10+ messages in thread
From: Henning Hraban Ramm @ 2011-12-13 12:08 UTC (permalink / raw)
  To: mailing ConTeXt users list for

For a book of fairy tales, I used (working!):

\def\Initial{\DroppedCaps%
{\color[red]} {Serif} {2.5\baselineskip} {3pt} {2\baselineskip} {3}}

\starttext
\Initial Once upon a time... \input tufte
\stoptext


But that gives now:

<to be read again>
                    \unskip
\\->\ifhmode \unskip
                      \prewordbreak \crlfplaceholder \ifcase  
\raggedstatus \h...
\somefontsize ->2.5\\
                      baselineskip
\lowleveldefinefont ...aledfontsize \somefontsize
                                                   \or \scaledfontsize  
\local...
\dododefinefont ...inefont {#2}\rawfontidentifier
                                                   \csname  
\rawfontidentifier...
\dodefinedfont ...nedfont][#1]\fi \thedefinedfont
                                                   \the  
\everydefinedfont
...
l.7 \Initial O
               nce upon a time... \input tufte


It works, if I use absolute values for font size and vertical offset,  
like

\def\Initial{\DroppedCaps%
{\color[red]} {Serif} {36pt} {3pt} {28pt} {3}}


I also tried \setupinitial / \placeinitial like below; I got my  
defined font, but only ever in base font size.

%\definefontsynonym[Initial][WieynkInitialen]
\setupinitial[font=WieynkInitialen,n=3,state=start,command=\Initial] %

I also tried \NiceDroppedCaps and \LineDroppedCaps that I found in the  
sources, but didn’t get further.


So, what’s the preferred way to get dropped capitals / initials?
I’d like to wikify that, since it seems nowhere documented.


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 12:08 Initials / DroppedCaps Henning Hraban Ramm
@ 2011-12-13 12:28 ` Wolfgang Schuster
  2011-12-13 13:17   ` Henning Hraban Ramm
  2011-12-13 12:38 ` Hans Hagen
  1 sibling, 1 reply; 10+ messages in thread
From: Wolfgang Schuster @ 2011-12-13 12:28 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 13.12.2011 um 13:08 schrieb Henning Hraban Ramm:

> For a book of fairy tales, I used (working!):
> 
> \def\Initial{\DroppedCaps%
> {\color[red]} {Serif} {2.5\baselineskip} {3pt} {2\baselineskip} {3}}
> 
> \starttext
> \Initial Once upon a time... \input tufte
> \stoptext

\setupbodyfont[pagella]

\setupinitial
  [color=red]

\starttext
\placeinitial Once upon a time... \input tufte
\stoptext

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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 12:08 Initials / DroppedCaps Henning Hraban Ramm
  2011-12-13 12:28 ` Wolfgang Schuster
@ 2011-12-13 12:38 ` Hans Hagen
  2011-12-13 14:15   ` Idris Samawi Hamid ادريس   سماوي حامد
  1 sibling, 1 reply; 10+ messages in thread
From: Hans Hagen @ 2011-12-13 12:38 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Henning Hraban Ramm

On 13-12-2011 13:08, Henning Hraban Ramm wrote:
> For a book of fairy tales, I used (working!):
 > ...
> So, what’s the preferred way to get dropped capitals / initials?
> I’d like to wikify that, since it seems nowhere documented.

Initials have been rewritten (they also no longer pick up an argument 
which is more robust). The old macros will probably be removed (or end 
up in a module).

\setupinitial[font=Bold at 48pt,state=start]

\starttext

     \placeinitial \input tufte

     \placeinitial \input ward

\stoptext


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 12:28 ` Wolfgang Schuster
@ 2011-12-13 13:17   ` Henning Hraban Ramm
  2011-12-13 13:22     ` Wolfgang Schuster
  0 siblings, 1 reply; 10+ messages in thread
From: Henning Hraban Ramm @ 2011-12-13 13:17 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2011-12-13 um 13:28 schrieb Wolfgang Schuster:

> \setupbodyfont[pagella]
>
> \setupinitial
>  [color=red]
>
> \starttext
> \placeinitial Once upon a time... \input tufte
> \stoptext

Grmbl, I would have sworn that didn’t work before! But it does. Thank  
you!


Am 2011-12-13 um 13:38 schrieb Hans Hagen:

> Initials have been rewritten (they also no longer pick up an  
> argument which is more robust). The old macros will probably be  
> removed (or end up in a module).
>
> \setupinitial[font=Bold at 48pt,state=start]

Ok, but how can I set the font size relative to bodyfontsize/ 
baselineskip?

"state=start" doesn’t seem necessary, it works without.


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 13:17   ` Henning Hraban Ramm
@ 2011-12-13 13:22     ` Wolfgang Schuster
  2011-12-13 13:42       ` Henning Hraban Ramm
  0 siblings, 1 reply; 10+ messages in thread
From: Wolfgang Schuster @ 2011-12-13 13:22 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 13.12.2011 um 14:17 schrieb Henning Hraban Ramm:

> Am 2011-12-13 um 13:38 schrieb Hans Hagen:
> 
>> Initials have been rewritten (they also no longer pick up an argument which is more robust). The old macros will probably be removed (or end up in a module).
>> 
>> \setupinitial[font=Bold at 48pt,state=start]
> 
> Ok, but how can I set the font size relative to bodyfontsize/baselineskip?

\setupinitial[font=Bold sa 4]

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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 13:22     ` Wolfgang Schuster
@ 2011-12-13 13:42       ` Henning Hraban Ramm
  2011-12-13 13:50         ` Wolfgang Schuster
  0 siblings, 1 reply; 10+ messages in thread
From: Henning Hraban Ramm @ 2011-12-13 13:42 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2011-12-13 um 14:22 schrieb Wolfgang Schuster:

>> Ok, but how can I set the font size relative to bodyfontsize/ 
>> baselineskip?
>
> \setupinitial[font=Bold sa 4]

Thank you, I feel stupid.
Works for me, but not in the wiki (I can’t get colors there, too).
http://wiki.contextgarden.net/Initials

Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 13:42       ` Henning Hraban Ramm
@ 2011-12-13 13:50         ` Wolfgang Schuster
  2011-12-13 15:34           ` Henning Hraban Ramm
  0 siblings, 1 reply; 10+ messages in thread
From: Wolfgang Schuster @ 2011-12-13 13:50 UTC (permalink / raw)
  To: mailing list for ConTeXt users


Am 13.12.2011 um 14:42 schrieb Henning Hraban Ramm:

> Am 2011-12-13 um 14:22 schrieb Wolfgang Schuster:
> 
>>> Ok, but how can I set the font size relative to bodyfontsize/baselineskip?
>> 
>> \setupinitial[font=Bold sa 4]
> 
> Thank you, I feel stupid.
> Works for me, but not in the wiki (I can’t get colors there, too).
> http://wiki.contextgarden.net/Initials

The wiki use MkII and you have to enable colors first.

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
___________________________________________________________________________________


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

* Re: Initials / DroppedCaps
  2011-12-13 12:38 ` Hans Hagen
@ 2011-12-13 14:15   ` Idris Samawi Hamid ادريس   سماوي حامد
  2011-12-13 14:35     ` Hans Hagen
  0 siblings, 1 reply; 10+ messages in thread
From: Idris Samawi Hamid ادريس   سماوي حامد @ 2011-12-13 14:15 UTC (permalink / raw)
  To: mailing list for ConTeXt users; +Cc: Hans Hagen, hraban

On Tue, 13 Dec 2011 05:38:09 -0700, Hans Hagen <pragma@wxs.nl> wrote:

>
> On 13-12-2011 13:08, Henning Hraban Ramm wrote:
>> For a book of fairy tales, I used (working!):
>  > ...
>> So, what’s the preferred way to get dropped capitals / initials?
>> I’d like to wikify that, since it seems nowhere documented.
>
> Initials have been rewritten (they also no longer pick up an argument  
> which is more robust). The old macros will probably be removed (or end  
> up in a module).
>
> \setupinitial[font=Bold at 48pt,state=start]
>
> \starttext
>
>      \placeinitial \input tufte
>
>      \placeinitial \input ward
>
> \stoptext

Hmm, I did not realize that dropped caps were still supported in MkIV base  
so I've been using

\usemodule[lettrine]

which also lets you set not only dropped caps but the next couple of words  
or so in another font -- such as small caps.

Hans: Does the \setupinitial also allow to set the words immediately after  
in \sc etc?

Henning: Maybe you can try lettrines as well and compare them, see which  
works best for what you're trying to do ... Here is a sample for you to  
play with

===========
\usemodule[lettrine]
\def \LettrineStyle{\definefontsynonym[LettrineFont][Italic]}
\setuplettrine  
[A][Lines=2,Findent=0.2em,Nindent=0.01em,FontHook={\LettrineStyle}]
\setuplettrine  
[T][Lines=2,Findent=0.35em,Nindent=0.01em,FontHook={\LettrineStyle},Hang=.25]
\setuplettrine  
[I][Lines=2,Findent=0.3em,Nindent=0.01em,FontHook={\LettrineStyle},Hang=.25]
\setuplettrine  
[O][Lines=2,Findent=0.2em,Nindent=0.01em,FontHook={\LettrineStyle}]
\setuplettrine  
[C][Lines=2,Findent=0.3em,Nindent=0.01em,FontHook={\LettrineStyle}]
\setuplettrine  
[W][Lines=2,Findent=0.3em,Nindent=0.01em,FontHook={\LettrineStyle},Hang=.34]

\starttext
\lettrine{A}{fter the three} \input ward
\stoptext
===========

Best wishes
Idris

-- 
Professor Idris Samawi Hamid, Editor-in-Chief
International Journal of Shīʿī Studies
Department of Philosophy
Colorado State University
Fort Collins, CO 80523
___________________________________________________________________________________
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
___________________________________________________________________________________

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

* Re: Initials / DroppedCaps
  2011-12-13 14:15   ` Idris Samawi Hamid ادريس   سماوي حامد
@ 2011-12-13 14:35     ` Hans Hagen
  0 siblings, 0 replies; 10+ messages in thread
From: Hans Hagen @ 2011-12-13 14:35 UTC (permalink / raw)
  To: Idris Samawi Hamid ادريس
	سماوي حامد
  Cc: mailing list for ConTeXt users, hraban

On 13-12-2011 15:15, Idris Samawi Hamid ادريس   سماوي حامد wrote:

> Hmm, I did not realize that dropped caps were still supported in MkIV
> base so I've been using

it is but not as pure macro but a lua hybrid

> which also lets you set not only dropped caps but the next couple of
> words or so in another font -- such as small caps.
>
> Hans: Does the \setupinitial also allow to set the words immediately
> after in \sc etc?

no, but it's doable (need a good reason for it)

Hans

-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                              | 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://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

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

* Re: Initials / DroppedCaps
  2011-12-13 13:50         ` Wolfgang Schuster
@ 2011-12-13 15:34           ` Henning Hraban Ramm
  0 siblings, 0 replies; 10+ messages in thread
From: Henning Hraban Ramm @ 2011-12-13 15:34 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Am 2011-12-13 um 14:50 schrieb Wolfgang Schuster:

>> Works for me, but not in the wiki (I can’t get colors there, too).
>> http://wiki.contextgarden.net/Initials
> The wiki use MkII and you have to enable colors first.

I did enable colors, but don’t get any. Maybe the color switch is not  
in the MkII version.


Am 2011-12-13 um 15:15 schrieb Idris Samawi Hamid ادريس سماوي  
حامد:

> Hmm, I did not realize that dropped caps were still supported in  
> MkIV base so I've been using
> \usemodule[lettrine]
> which also lets you set not only dropped caps but the next couple of  
> words or so in another font -- such as small caps.
>
> Henning: Maybe you can try lettrines as well and compare them, see  
> which works best for what you're trying to do ... Here is a sample  
> for you to play with

Thank you for the hint, but I only need that one dropped cap. Even if  
the first line/sentence in small caps looks very classical, I don’t  
really like it.
I added your example to the wiki page: http://wiki.contextgarden.net/Initials


Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://wiki.contextgarden.net
https://www.cacert.org (I'm an assurer)

___________________________________________________________________________________
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
___________________________________________________________________________________

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

end of thread, other threads:[~2011-12-13 15:34 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-12-13 12:08 Initials / DroppedCaps Henning Hraban Ramm
2011-12-13 12:28 ` Wolfgang Schuster
2011-12-13 13:17   ` Henning Hraban Ramm
2011-12-13 13:22     ` Wolfgang Schuster
2011-12-13 13:42       ` Henning Hraban Ramm
2011-12-13 13:50         ` Wolfgang Schuster
2011-12-13 15:34           ` Henning Hraban Ramm
2011-12-13 12:38 ` Hans Hagen
2011-12-13 14:15   ` Idris Samawi Hamid ادريس   سماوي حامد
2011-12-13 14:35     ` 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).