ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Aditya Mahajan <adityam@umich.edu>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: orphans and widows in poems
Date: Sun, 16 Jun 2013 22:29:57 -0400 (EDT)	[thread overview]
Message-ID: <alpine.DEB.2.02.1306162228340.4417@nqv-guvaxcnq> (raw)
In-Reply-To: <51BE5A23.1010809@meahan.net>

[-- Attachment #1: Type: TEXT/PLAIN, Size: 1233 bytes --]

On Sun, 16 Jun 2013, Bill Meahan wrote:

> On 6/16/2013 3:46 AM, Pablo Rodríguez wrote:
>> 
>> 
>> I'm afraid that I get widow lines in the lines environment.
>> 
>> Is there no way to avoid orphans and widows in the lines environment?
> It's a bit ugly, but if the poem consists of individual stanzas, you can put 
> each stanza in an non-bordered frame.
>
> e.g.:
> % Set up the lines environment to put the contained lines in a frame so they 
> are kept together
> \setuplines[indenting={yes,small,even},       <--  whatever options you want
>   before={\startframedtext[frame=off]},
>   after=\stopframedtext]
>
> % Then wrap your stanzas in individual line environments
>          \startlines
>            A maiden fair was seated there,
>            Her hair of fine-spun gold.
>            Azure eyes so clear and bright,
>            So wondrous to behold.
>          \stoplines
>
> A frame will never be split across pages.
>
> BTW this "trick"is on the wiki on the "Verse" page.

If the poem consists of stanzas with fixed number of lines, say 4, then 
you could also try:

\setuplines[inbetween={\testpage[4]\blank}]

This will ensure that a stanza does not break across pages.

Aditya

[-- Attachment #2: 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:[~2013-06-17  2:29 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-06-16  7:46 Pablo Rodríguez
2013-06-16 19:03 ` Wolfgang Schuster
2013-06-17 17:18   ` Pablo Rodríguez
2013-06-17 21:05     ` Wolfgang Schuster
2013-06-17 21:21       ` Hans Hagen
2013-06-17 20:28   ` Pablo Rodríguez
2013-06-17  0:36 ` Bill Meahan
2013-06-17  2:29   ` Aditya Mahajan [this message]
2013-06-17  5:39   ` Wolfgang Schuster
2013-06-17 13:50     ` Bill Meahan
2013-06-17 21:02       ` Wolfgang Schuster
2013-06-17 17:23     ` Pablo Rodríguez

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=alpine.DEB.2.02.1306162228340.4417@nqv-guvaxcnq \
    --to=adityam@umich.edu \
    --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).