You might not do it today or tomorrow, but you'll do it someday. You'll need to paste some content from a Web page, or a Word document, or something else that's got some goofiness embedded in it, into your Writer document.
Don't do it.
That is, don't just do a plain paste. Copy > Paste from here
gives you this.
Lots of cleanup.
Plus, when you paste from outside sources you sometimes get lots of sections. Sections are indicated, when you have nonprinting characters and text boundaries showing under the View menu, like this.
Choose Format > Sections and you'll see allllllll the little sections and how complex they are.
Why do you care? It's just icky and unnecessary, the sections will behave differently, you'll pull out your hair. Here's one example. I'm changing the left margin for the whole document, but only the section my cursor was in behaves.
So not to get into too much detail, but a plain paste will not give you what you want.
Choose Copy, then choose Edit > Paste Special (or Ctrl Shift V) and choose Unformatted Text.
And then you get this as your pasted result. MUCH better.
Many thanks. Very helpful article. Carry on, please.
Posted by: Oleg | November 13, 2008 at 08:47 AM
It's good to know about this ability within OpenOffice. However, I use a little "freeware" application called PureText which does essentially the same thing with fewer clicks. It's only a 13K download.
Posted by: Harold | November 13, 2008 at 11:39 AM
PureText sounds great! And hopefully doesn't do the nasty carriage return stuff midline that you get with Notepad.
Posted by: Solveig | November 13, 2008 at 12:49 PM
Hi Solveig,
Do you know of any way to add Paste Special - Unformatted Text to the context menu? Like the way you can "Paste without Formatting" from the context menu in a Thunderbird email message body?
Thanks!
Andy Prough
Posted by: Andy Prough | November 14, 2008 at 01:16 AM
Hi Andy,
I think it's possible with a macro but that's where my knowledge ends. ;> Try oooforum.org.
Posted by: Solveig | November 17, 2008 at 05:33 AM
Thanks, this is going to save me a lot of time the next time I have to do my bank statement.
Posted by: Paul | December 01, 2008 at 06:05 AM
If you use Firefox, think extension like 'copy plain text" or "extended copy menu" : select what you want, right clic and choice html or text paste. Nevertheless, thanks to have teached me a use of paste special.
Posted by: blurag | December 01, 2008 at 08:00 AM
I modified a tool bar to add "Paste Special." Once it's there, click the drop down and click paste unformatted.
Posted by: Layne | December 01, 2008 at 09:04 AM
I have tried using a standard paste into MS Word 2003 from the sample Web Page and it pastes fairly well retaining most of the formatting. When I use a standard paste into Writer in OpenOffice 3 it not only messes up the formatting but also does not bring through the images. OpenOffice still has some way to go to match with MS Word in this area which is a shame as I would like to use OpenOffice for all documents.
Posted by: Kevin Warrington | December 01, 2008 at 02:50 PM
Hi Kevin,
I just went to the Gap site, selected all, and pasted into OOo and Word 2003. Looks pretty much the same, and the graphics for both were brought in.
Pasting HTML, with all its potential style sheet complexities etc., is always a crap shoot at best, regardless of what you paste into. It might be as simple as compatbility between how the Heading1 Heading2 Text Body etc. styles are defined in each application, and of course style definitions are easily changeable.
Posted by: solveigh | December 01, 2008 at 03:13 PM
Hi Solveigh,
I'll email you the Word and OOo documents as a comparison. These will be unedited just as I pasted from the Web Site. Maybe you can suggest why the OOo document is so much different on my computer which just has a standard, unchanged, installation of OOo. I have noted in the past that pasting Web Pages into OOo that contain graphics can sometimes have a delayed response in displaying the graphics (if I move the mouse pointer over the graphic it sometimes displays).
Posted by: Kevin Warrington | December 01, 2008 at 04:10 PM
Thanks for the info. Do have another related question. Sometimes documentation for an application is only available by visiting the web-site. How can I copy and paste this HTML documentation and retain the inserted "pictures"? I would like to put this on-line information into a PDF still document (not necessarily a PDF file) so I do not have to visit the web-site everytime I have a question about the application.
Posted by: Michael | December 01, 2008 at 05:47 PM
Since my original comment #4, I found a little Windows program called ClipText (http://www.cliptext.co.uk/). It is similar to PureText in that it allows you to paste unformatted text into any Windows application. However, my understanding is that PureText still requires you to hit a hot-key combination on the keyboard. I was searching for a utility that allowed me to copy anything and paste unformatted text into an OpenOffice document without taking my hand off the mouse, and without searching through the main menu. ClipText actually replaces your Windows clipboard copy and paste function with a "paste unformatted text" option for all copied text. It can be enabled or disabled easily. This seems to be doing the trick for me. I also found a Firefox add-on called Copy Plain Text which allows a context menu copy from the Firefox window to strip any formatting before placing text on the clipboard when browsing the internet.
Andy Prough
Posted by: Andy Prough | December 09, 2008 at 07:04 AM
Hello Solveig,
I am wondering when a new edition of your book: "OpenOffice guide book" will be available to buy it. This, naturally, in order to have this and other articles to read.
I suppose the book will be based on OpenOffice 3.
Thanks a lot and keep up the wonderful blog!
Silvio
Posted by: silvio | December 16, 2008 at 10:22 AM
Many thanks. Very helpful article. Carry on, please.
Posted by: vcgold | December 30, 2008 at 02:23 AM
To mmoinn.com purchase wow gold it! Give ourselves a chance to relax, enjoy the game of Warcraft to your fun! We provide you with cheap wow gold and wow power leveling , so you do eliminate trouble!
Posted by: wow gold | January 16, 2009 at 12:57 AM
Thank you so much for posting this information! I was pulling my hair out and spending so much time trying to figure out how to remove those boxes.
Posted by: TC | November 22, 2009 at 08:47 AM