Remove Border Line of HeaderFooter Class

View: New views
3 Messages — Rating Filter:   Alert me  

Remove Border Line of HeaderFooter Class

by bzhang-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message


Dear Sir / Madam,

When I use HeaderFooter class to generate a header and footer text, there are top and bottom border line around the text. For example:

-------------------------------------------------------------------------------
header text
-------------------------------------------------------------------------------

body text .....

-------------------------------------------------------------------------------
footer text
-------------------------------------------------------------------------------

Is it possible to remove the top border line for header text and bottom border line for footer text? So the above picture become:

header text
-------------------------------------------------------------------------------

body text .....

-------------------------------------------------------------------------------
footer text


Regards,

Byron Zhang
System Administrator
Vectra Corporation Limited
MMAL – Infrastructure Services Team

Mitsubishi Motors Australia Ltd.
1284 South Road
Clovelly Park  SA  5042

Head Office: 38 Sir Donald Bradman Drive
Mile End  SA  5031
Phone:  +61 8 82752530
Mobile:  0433180529
Fax:  
www.vectra-corp.com

Leaders in Information Security & Infrastructure – Adelaide, Sydney, Brisbane, Singapore

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
iText-questions mailing list
iText-questions@...
https://lists.sourceforge.net/lists/listinfo/itext-questions

Do you like iText?
Buy the iText book: http://www.1t3xt.com/docs/book.php
Or leave a tip: https://tipit.to/itexttipjar

Re: Remove Border Line of HeaderFooter Class

by Bruno Lowagie (iText) :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

bzhang@... wrote:
>
> Dear Sir / Madam,

Please subscribe to the mailing list if you want to receive answers.

> When I use HeaderFooter class to generate a header and footer text,
> there are top and bottom border line around the text.

First of all: the use of HeaderFooter is discouraged.
The book, the online tutorial,... advise the use of page events.
(...)
> Is it possible to remove the top border line for header text and bottom
> border line for footer text?

Remove the borders: header.setBorder(Rectangle.NO_BORDER);
Add a bottom border: header.setBorder(Rectangle.BOTTOM);
Add a top border: footer.setBorder(Rectangle.TOP);
Add a top and bottom border (the default):
footer.setBorder(Rectangle.TOP | Rectangle.BORDER);

But as I said before: you shouldn't use class HeaderFooter.
br,
Bruno

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
iText-questions mailing list
iText-questions@...
https://lists.sourceforge.net/lists/listinfo/itext-questions

Do you like iText?
Buy the iText book: http://www.1t3xt.com/docs/book.php
Or leave a tip: https://tipit.to/itexttipjar

Parent Message unknown Re: Remove Border Line of HeaderFooter Class

by Bruno Lowagie (iText) :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

bzhang@... wrote:
>
> Hi Bruno,
>
> Thanks for your reply.

Please don't answer to me personally,
reply to the mailing list address only!

> I could not find the example for Page Event. Could you please give me
> some hint such as the Chapter number?

If you're referring to the book, that would be chapter 14.
All the examples are available online here:
http://1t3xt.info/examples/browse/?page=toc&id=19

If you're referring to the free, only tutorial, you need this page:
http://itextdocs.lowagie.com/tutorial/directcontent/pageevents/index.php

As I have just explained to somebody else on the mailing list,
you should use Google before asking questions with trivial answers.
It's not as we do an extra effort to hide the examples, is it?
br,
Bruno

-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/
_______________________________________________
iText-questions mailing list
iText-questions@...
https://lists.sourceforge.net/lists/listinfo/itext-questions

Do you like iText?
Buy the iText book: http://www.1t3xt.com/docs/book.php
Or leave a tip: https://tipit.to/itexttipjar