Page LayoutLong /newfloat problem

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
fajdes
Posts: 2
Joined: Tue Nov 10, 2009 12:02 pm

Long /newfloat problem

Post by fajdes »

Hi,

I have a problem with float package. When I define new float:

Code: Select all

\floatstyle{ruled} 
\newfloat{udcode}{H}{loc}[chapter]
\floatname{udcode}{Kod programu}
and then in document insert:

Code: Select all

\begin{udcode}

very long code (longer than one page)

\end{udcode}
it overrides margin of the page.

Is it possible to divide it into two pages?

Thanks

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Long /newfloat problem

Post by localghost »

I assume that you want to format programming code in a certain language. If so, try the listings package and read in its manual how to format listings and customize their layout. Floating listings are possible, too.


Best regards and welcome to the board
Thorsten¹
fajdes
Posts: 2
Joined: Tue Nov 10, 2009 12:02 pm

Re: Long /newfloat problem

Post by fajdes »

Not exactly. When my udcode enviroment is longer than one A4 page latex don't move part of it to the next page. Everything is on one page. So it ovverides bottom margin.

But anyway thanks for reply
User avatar
localghost
Site Moderator
Posts: 9202
Joined: Fri Feb 02, 2007 12:06 pm

Long /newfloat problem

Post by localghost »

fajdes wrote:[...] When my udcode enviroment is longer than one A4 page latex don't move part of it to the next page. Everything is on one page. So it ovverides bottom margin. [...]
It is absolutely unclear which contents the udcode environment will have. From my point of view the declaration as a float is the wrong direction. Prepare a concrete example.
Post Reply