Mmmh. I found out this, too.
FYI:
I have a main Chapter to be put to the Document. Within this Chapter I put
an arbitrary number of Sections (which may contain subsections) to get a
simple numbering like 1. aaa, 2. bbb, 3. ccc, ... The sections are build in
their own methods and in the calling method (the method which calls the
methods to build each section) I put the Chapter to the Document after
adding all sections to the chapter.
The first statements in the method to build the section to be shown in
landscape orientation are:
mainChapter.add(Chunk.NEXTPAGE);
document.setPageSize(Pagesize.A4.rotate());
but it rotates the prior section created in a different method in
landscape, too, althought this should be shown in portrait.
I use Helper classes on PageEvents (onEndPage as well as onGenericTag).
Could this cause problems?
So: How can i tell iText to switch from one orientation to another within a
single Chapter?
Dirk
>
> -------- Original-Nachricht --------
> Datum: Thu, 04 Jan 2007 10:49:05 +0100
> Von: Bruno Lowagie <[EMAIL PROTECTED]>
> An: Post all your questions about iText here
> <[email protected]>
> Betreff: Re: [iText-questions] Section breaks
>
> Dirk Ulrich wrote:
>
> > document.newPage() seems not to be regarded and thus the prior section
> > is written to the document in landscape, too.
>
> No, document.newPage() is triggered BEFORE you add
> the Chapter you have been building to the document.
> It's quite elementary if you think about it.
> If you want a page break inside a section, you need
> to add a page break chunk:
>
> section.add(Chunk.NEXTPAGE);
>
> br,
> Bruno
>
> -------------------------------------------------------------------------
> Take Surveys. Earn Cash. Influence the Future of IT
> Join SourceForge.net's Techsay panel and you'll get the chance to share
> your
> opinions on IT & business topics through brief surveys - and earn cash
> http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> Buy the iText book: http://itext.ugent.be/itext-in-action/
>
--
Mit freundlichen Grüßen
Dirk Ulrich
Jansenstraße 21
13437 Berlin
fon:0++49-(0)30-40 999 087
mobil:++49-(0)174/948 87 39
Der GMX SmartSurfer hilft bis zu 70% Ihrer Onlinekosten zu sparen!
Ideal für Modem und ISDN: http://www.gmx.net/de/go/smartsurfer
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/