[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [pygame] Bltting numerous lines of text easily



From the pygame docs for Font.Render:
"The text can only be a single line: newline characters are not rendered."
and:
"If you render '\n' a unknown char will be rendered. Usually a
rectangle. Instead you need to handle new lines yourself."

you can read it here:
http://www.pygame.org/docs/ref/font.html#Font.render

you can blit each line seperately yourself. You can call "splitlines"
on the string with multiple lines to turn it into a list of lines, and
then iterate the list

On 8/2/06, Joseph Quigley <cpu.crazy@xxxxxxxxx> wrote:
I'm trying to create a file that displays credits (movie style) but I
can not figure out how to blit more than 1 line of text at a time (\n
doesn't work). Is there a special pygame trick for this?
Thanks,
Joe

--
All Your Base Are Belong To Us!!! chown -r us ./base

"After three days without programming, life becomes meaningless.'' --
Tao of Programming Book 2