1 posts
Posted 19 March 2013 - 12:58 AM
Hey, Recently i have started working on a printer program, a close friend and i are working on a computer craft university server, and we need to be able to print multiple sheets the same, without having to CTRL + Print Everytime! So i started working on this program! I Have gotten everything running apart from one problem, when i use the printer.write(variable), the users input which is text = read() if its longer than the screen, when it prints it out, the text is going off the page. Is there any way to fix this?
Thanks :)/>
8543 posts
Posted 19 March 2013 - 03:45 AM
Split into new topic.
Please provide your code and any error message(s) you are seeing.
7508 posts
Location
Australia
Posted 19 March 2013 - 03:57 AM
Someone can correct me if I'm wrong, but iirc unlike the terminal the content is no wrapped when printing, so it will not move onto the next line until it gets a \n character. This means you will have to make your own text wrap function. (note you can get the pages size so you know the width)
997 posts
Location
Wellington, New Zealand
Posted 19 March 2013 - 01:37 PM
Text isn't wrapped with term.write or monitor.write either.
7508 posts
Location
Australia
Posted 19 March 2013 - 01:58 PM
Text isn't wrapped with term.write or monitor.write either.
write and print are wrapped, and they are the common ones people use
2217 posts
Location
3232235883
Posted 19 March 2013 - 02:27 PM
write is wrapped and print uses write
i NEVER use write for GUIS because it can glitch out if you try to write something outside the screen