If you’re one of those who know how to make good documents and you do make good documents then this post is trivial for you. Or wait maybe you think you make good documents! Anyway, this post is dedicated to all my college friends who make lab files which I shamelessly copy and print. This post will introduce you to Page Break!
If you don’t know what Page Breaks are, sorry to say but you should be ashamed of yourself. I’ve very good experience of using my friends lab files. When I say good experience, I mean really good experience. In fact I never make my lab file. (I hope my professor isn’t reading this post). Why I don’t make lab files myself is different story and I do have pretty good reason, but lets not talk about it now.
From Wikipedia -
A page break is a marker in an electronic document that tells the document interpreter that the content which follows is part of a new page. A page break causes a form feed to be sent to the printer during spooling of the document to the printer.
So anyway, the reason I made this post is because in 99.99% cases there was one common and huge and frustrating and fatal problem with the documents (in Microsoft Word format). They never used Page Breaks.
In our lab files, we have several program codes. Each program code should start with a fresh new page. To start the program on a fresh new page, people add dozens of newlines to reach the new page. This is something that you should never do because of following reasons -
- In case you make some changes to other parts of your document, the structure of your document will be changed and it will get bad. Content will overflow to your so called fresh new page. And you will end up removing and adding a new set of newlines.
- If you change your page layout, yet again your document will be broken.
- Well, its really frustrating to read, write and modify such documents.
Anyway, lets see how to do this. If you are not that hopeless, you would have have googled it by now. Anyway, the solution is obviously Page Break. A page break will move text after that to a new page.
LibreOffice/OpenOffice
- Simply press Ctrl+Enter. Check this. Or
- Goto Insert > Manual Break > (Select Page Break Option) > Ok
Microsoft Word
- Check this link.
- I dunno for sure, but Ctrl+Enter might work. I don’t have Microsoft Office.
Text Documents
I’m a fan of Text Documents. I write most of my stuff in plain text whenever possible, including documents, presentations, emails and almost anything I can. In the world of plain text its called Form Feed. Its an ASCII Control character with ASCII code 12(0x0C). I you are writing a program, its escape sequence is \f. You can insert this character in your text editor(if it allows) by pressing Ctrl+L. I never used it, because I never had to, so I really cant tell if it will work everywhere.
HTML/CSS
Ok. Most of you might not be interested but this can be useful. I’m a geek and I just cant let an opportunity to post some code go! In good old days, when I used to make my lab files myself, I made this stupid script to generate my lab file.
What you are supposed to do is add this CSS property to the element after which you want a page break.
page-break-after: always; /* or */ page-break-before: always;
Conclusion
So, I’m done. I hope you find this post useful and for god’s sake actually start using Page Breaks if you haven’t uptil now. And my college mates, its a request PLEASE!
lol now you are posting this!!! When my engineering is about to get over!! Lol,
but great stuff, very very useful….
need to check the ms word thing though….
btw, how to add this thing in a normal text file, like in vim or emacs or any regular editor???
posting this on my pictpunetechgroup
Thanks! That was very useful.