ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Pagebreak only after stanzas
@ 2007-04-14 20:13 Bert Trüger
  2007-04-14 21:31 ` luigi scarso
  2007-04-14 21:36 ` Aditya Mahajan
  0 siblings, 2 replies; 6+ messages in thread
From: Bert Trüger @ 2007-04-14 20:13 UTC (permalink / raw)
  To: ntg-context


[-- Attachment #1.1: Type: text/plain, Size: 384 bytes --]

Hi,

i am a fresh convert to Context from Latex and deeply impressed by
it's ability to set multiple pages on one page, even doublesided
ones.
For setting a collection of poems I use \obeylines and \smallskip
to arrange them on the page. Pagebreaks should only be possible
between stanzas at the \smallskip-mark. Could somebody tell me, how
to achieve this?

Thanks in advance

Chris

[-- Attachment #1.2: Type: text/html, Size: 433 bytes --]

[-- Attachment #2: Type: text/plain, Size: 139 bytes --]

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

* Re: Pagebreak only after stanzas
  2007-04-14 20:13 Pagebreak only after stanzas Bert Trüger
@ 2007-04-14 21:31 ` luigi scarso
  2007-04-14 21:36 ` Aditya Mahajan
  1 sibling, 0 replies; 6+ messages in thread
From: luigi scarso @ 2007-04-14 21:31 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On 4/14/07, Bert Trüger <xulxer@gmail.com> wrote:
> Hi,
>
> i am a fresh convert to Context from Latex and deeply impressed by
> it's ability to set multiple pages on one page, even doublesided
> ones.
> For setting a collection of poems I use \obeylines and \smallskip
> to arrange them on the page. Pagebreaks should only be possible
> between stanzas at the \smallskip-mark. Could somebody tell me, how
> to achieve this?
Can you post a small example ?

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

* Re: Pagebreak only after stanzas
  2007-04-14 20:13 Pagebreak only after stanzas Bert Trüger
  2007-04-14 21:31 ` luigi scarso
@ 2007-04-14 21:36 ` Aditya Mahajan
  2007-04-15 13:27   ` Bert Trüger
  2007-04-17  8:40   ` Hans Hagen
  1 sibling, 2 replies; 6+ messages in thread
From: Aditya Mahajan @ 2007-04-14 21:36 UTC (permalink / raw)
  To: mailing list for ConTeXt users

On Sat, 14 Apr 2007, Bert Trüger wrote:

> Hi,
>
> i am a fresh convert to Context from Latex and deeply impressed by
> it's ability to set multiple pages on one page, even doublesided
> ones.
> For setting a collection of poems I use \obeylines and \smallskip
> to arrange them on the page. Pagebreaks should only be possible
> between stanzas at the \smallskip-mark. Could somebody tell me, how
> to achieve this?

Probably, the easiest way to do that will be to add a bit of a markup. 
Something like (untested)

\setuplines[after={\blank[small]}] %or after=\smallskip
\defineframedtext[stanza][width=\textwidth,before=\startlines,after=\stoplines]

\startstanza
....
....
\stopstanza

Since framedtext is a box, it will not break across pages.

Aditya

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

* Re: Pagebreak only after stanzas
  2007-04-14 21:36 ` Aditya Mahajan
@ 2007-04-15 13:27   ` Bert Trüger
  2007-04-15 14:06     ` Wolfgang Schuster
  2007-04-17  8:40   ` Hans Hagen
  1 sibling, 1 reply; 6+ messages in thread
From: Bert Trüger @ 2007-04-15 13:27 UTC (permalink / raw)
  To: mailing list for ConTeXt users


[-- Attachment #1.1: Type: text/plain, Size: 4422 bytes --]

Hi again,

I have tried to implement Adityas suggestions. Now pagebreaks are correct.
But how can I minimize the whitespace between stanzas. There shouldn't be
much more than a \smallskip.  I tried to look it up in the contextgarden
wiki, but an entry on verses seems to be missing, so I could wikify the
solutions.

Thanks in advance

Chris

A minimal example looks like:

\setuppapersize[A6][A6]
\setuplayout[
topspace=1cm,backspace=1cm,header=0pt,footer=0pt,margin=.5cm,height=middle,width=middle,]

\usetypescriptfile[type-gyr]
\usetypescript[times][texnansi]
\mainlanguage[de]
\enableregime[utf]
\setupbodyfont[times,9pt]

\setupindenting[medium, no]

\setupframedtexts[width=\textwidth,height=fit,frame=on]

\starttext
\subsection{Novalis—An Tieck}
\obeylines
\startframedtext
Ein Kind voll Wehmut und voll Teue,
Verstoßen in ein fremdes Land,
Ließ gern das Glänzende und Neue,
Und blieb dem Alten zugewandt.
\stopframedtext
\startframedtext
Nach langem Suchen, langem Warten,
Nach manchem mühevollen Gang,
Fand es in einem öden Garten
Auf einer längst verfallenen Bank
\stopframedtext
\startframedtext
Ein altes Buch mit Gold verschlossen,
Und nie gehörte Worte drin;
Und, wie des Frühlings zarte Sprossen,
So wuchs in ihm ein innrer Sinn.
\stopframedtext
\startframedtext
Und wie es sitzt, und liest, und schauet
In den Kristall der neuen Welt,
An Gras und Sternen sich erbaut,
Und dankbar auf die Kniee fällt:
\stopframedtext
\startframedtext
So hebt sich sacht aus Gras und Kräutern
Bedächtiglich ein alter Mann,
Im schlichten Rock, und kommt mit heiterm
Gesicht ans fromme Kind heran.
\stopframedtext
\startframedtext
Bekannt, doch heimlich sind die Züge
So kindlich und so wunderbar;
Es spielt die Frühlingsluft der Wiege
Gar seltsam mit dem Silberhaar.
\stopframedtext
\startframedtext
Das Kind fasst bebend seine Hände,
Es ist des Buches hoher Geist,
Der ihm der sauren Wallfahrt Ende
Und seines Vaters Wohnung weist.
\stopframedtext
\startframedtext
Du kniest auf meinem öden Grabe,
So öffnet sich der heilge Mund,
Du bist der Erbe meiner Habe,
Dir werde Gottes Tiefe kund.
\stopframedtext
\startframedtext
Auf jenem Berg als armer Knabe
Hab ich ein himmlisch Buch gesehn,
Und konnte nun durch diese Gabe
In alle Kreaturen sehn.
\stopframedtext
\startframedtext
Es sind an mir durch Gottes Gnade
Der höchsten Wunder viel geschehn;
Des neuen Bunds geheime Lade
Sahn meine Auge offen stehn.
\stopframedtext
\startframedtext
Ich habe treulich aufgeschrieben,
Was innre Lust mir offenbart,
Und bin verkannt und arm geblieben,
Bis ich zu Gott gerufen ward.
\stopframedtext
\startframedtext
Die Zeit ist da, und nicht verborgen
Soll das Mysterium mehr sein.
In diesem Buche bricht der Morgen
Gewaltig in die Zeit hinein.
\stopframedtext
\startframedtext
Verkündiger der Morgenröte,
Des Friedens Bote sollst du sein.
Sanft wie die Luft in Harf und Flöte
Hauch ich dir meinen Atem ein.
\stopframedtext
\startframedtext
Gott sei mit dir, geh hin und wasche
Die Augen dir mir Morgentau.
Sei treu dem Buch und meiner Asche,
Und bade dich im ewgen Blau.
\stopframedtext
\startframedtext
Du wirst das letzte Reich verkünden,
Das tausend Jahre soll bestehen;
Wirst überschwänglich Wesen finden,
Und Jakob Böhmen wieder sehn.
\stopframedtext

\stoptext


On 4/14/07, Aditya Mahajan <adityam@umich.edu> wrote:
>
> On Sat, 14 Apr 2007, Bert Trüger wrote:
>
> > Hi,
> >
> > i am a fresh convert to Context from Latex and deeply impressed by
> > it's ability to set multiple pages on one page, even doublesided
> > ones.
> > For setting a collection of poems I use \obeylines and \smallskip
> > to arrange them on the page. Pagebreaks should only be possible
> > between stanzas at the \smallskip-mark. Could somebody tell me, how
> > to achieve this?
>
> Probably, the easiest way to do that will be to add a bit of a markup.
> Something like (untested)
>
> \setuplines[after={\blank[small]}] %or after=\smallskip
>
> \defineframedtext[stanza][width=\textwidth,before=\startlines,after=\stoplines]
>
> \startstanza
> ....
> ....
> \stopstanza
>
> Since framedtext is a box, it will not break across pages.
>
> Aditya
> _______________________________________________
> ntg-context mailing list
> ntg-context@ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>

[-- Attachment #1.2: Type: text/html, Size: 5108 bytes --]

[-- Attachment #2: Type: text/plain, Size: 139 bytes --]

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

* Re: Pagebreak only after stanzas
  2007-04-15 13:27   ` Bert Trüger
@ 2007-04-15 14:06     ` Wolfgang Schuster
  0 siblings, 0 replies; 6+ messages in thread
From: Wolfgang Schuster @ 2007-04-15 14:06 UTC (permalink / raw)
  To: ntg-context

On Sun, 15 Apr 2007 15:27:20 +0200
"Bert Trüger" <xulxer@gmail.com> wrote:

> Hi again,
> 
> I have tried to implement Adityas suggestions. Now pagebreaks are correct.
> But how can I minimize the whitespace between stanzas. There shouldn't be
> much more than a \smallskip.  I tried to look it up in the contextgarden
> wiki, but an entry on verses seems to be missing, so I could wikify the
> solutions.
> 
> Thanks in advance
> 
> Chris
> 
> A minimal example looks like:
> 
> \setuppapersize[A6][A6]
> \setuplayout[
> topspace=1cm,backspace=1cm,header=0pt,footer=0pt,margin=.5cm,height=middle,width=middle,]
> 
> \usetypescriptfile[type-gyr]
> \usetypescript[times][texnansi]
> \mainlanguage[de]
> \enableregime[utf]
> \setupbodyfont[times,9pt]
> 
> \setupindenting[medium, no]
> 
> \setupframedtexts[width=\textwidth,height=fit,frame=on]
> 
> \starttext
> \subsection{Novalis—An Tieck}
> \obeylines
> \startframedtext
> Ein Kind voll Wehmut und voll Teue,
> Verstoßen in ein fremdes Land,
> Ließ gern das Glänzende und Neue,
> Und blieb dem Alten zugewandt.
> \stopframedtext
> \startframedtext
> Nach langem Suchen, langem Warten,
> Nach manchem mühevollen Gang,
> Fand es in einem öden Garten
> Auf einer längst verfallenen Bank
> \stopframedtext
> 
> \stoptext

Hi Bert,

can you file with these settings

\setupframedtexts
  [framedtext]
  [width=\textwidth,
   height=fit,
   before=,
   after=]

\setuplines
  [before=\startframedtext,
   after=\stopframedtext]

\starttext

\subsection{Novalis--An Tieck}

\startlines
Ein Kind voll Wehmut und voll Teue,
Verstoßen in ein fremdes Land,
Ließ gern das Glänzende und Neue,
Und blieb dem Alten zugewandt.
\stoplines

\startlines
Nach langem Suchen, langem Warten,
Nach manchem mühevollen Gang,
Fand es in einem öden Garten
Auf einer längst verfallenen Bank
\stoplines

\stoptext

Wolfgang
_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

* Re: Pagebreak only after stanzas
  2007-04-14 21:36 ` Aditya Mahajan
  2007-04-15 13:27   ` Bert Trüger
@ 2007-04-17  8:40   ` Hans Hagen
  1 sibling, 0 replies; 6+ messages in thread
From: Hans Hagen @ 2007-04-17  8:40 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Aditya Mahajan wrote:
> On Sat, 14 Apr 2007, Bert Tr�ger wrote:
>
>   
>> Hi,
>>
>> i am a fresh convert to Context from Latex and deeply impressed by
>> it's ability to set multiple pages on one page, even doublesided
>> ones.
>> For setting a collection of poems I use \obeylines and \smallskip
>> to arrange them on the page. Pagebreaks should only be possible
>> between stanzas at the \smallskip-mark. Could somebody tell me, how
>> to achieve this?
>>     
>
> Probably, the easiest way to do that will be to add a bit of a markup. 
> Something like (untested)
>
> \setuplines[after={\blank[small]}] %or after=\smallskip
> \defineframedtext[stanza][width=\textwidth,before=\startlines,after=\stoplines]
>
> \startstanza
> .....
> .....
> \stopstanza
>   
\start
\interlinepenalty\plustenthousand
stanze
\par
\stop

 \keeplinestogether{4} 
stanza 

may also work (untested) 

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

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

end of thread, other threads:[~2007-04-17  8:40 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-04-14 20:13 Pagebreak only after stanzas Bert Trüger
2007-04-14 21:31 ` luigi scarso
2007-04-14 21:36 ` Aditya Mahajan
2007-04-15 13:27   ` Bert Trüger
2007-04-15 14:06     ` Wolfgang Schuster
2007-04-17  8:40   ` 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).