Pasting text from an external application

Microsoft Word gibberish

Copying text from another application and pasting it into RapidWeaver is a huge timesaver and saves you tons of typing. But there’s one thing to remember: never, ever, paste text that contains styles. Did I say never? Yes, and I meant it. Never.

At first glance, it looks like a good idea. You think ‘Ah, I can paste this text that I styled in Word and it’ll come out looking the same, and it’s much easier to style in Word, so I don’t have to bother styling it in RapidWeaver; cool!’. Well my advice is: bother. Take a look at these screenshots. One of them is a Microsoft Word document opened directly in a text editor; the other is an Apple Pages document opened the same way, just so I don’t get accused of knocking Microsoft (although it’s such fun, isn’t it?). That gibberish is the control code that tells Word or Pages how to present your document to you when you open it or print it. It’s there for a good reason; it’s how these applications work. But you never ordinarily see it, it’s hidden behind the scenes.

But when you paste from Word or Pages directly into RapidWeaver, there’s an excellent chance you’ll pick up some of this crap along with what you’re pasting. And if you look at the Pages one, there’s quite a lot of words there that look as though a browser might, just, understand them. It’s not like HTML, but there are certain key words there which a browser might try to interpret, and possibly get itself into a spot of bother while doing so.

Pages gibberish

And to be honest, a lot of the time you’ll get away with it and you’ll wonder what all the fuss is about. But Web design is such a complex business, with so many little glitches that have to be put right; why add to the confusion? If you write to a forum for help with your site, you can easily cause a lot of people to spend a lot of time trying to figure out what’s going wrong until that time, about thirty posts into the thread, that you just happen to say ‘Oh, and I pasted the text in straight from Word’, and everyone smacks their forehead and goes ‘Ahhhhh …’ as the lightbulb comes on. Pasting styled text from another application sounds like a real time-saver. But in the time it takes to sort out one of those ‘tearing your hair out’ problems, you can style the text in RapidWeaver ten times over.

Here’s how to do it: if you’re pasting something into RapidWeaver, go to the Edit menu and choose ‘Paste as Plain Text’. While you’re there, note that the keyboard shortcut for that is Apple-Alt-V, so you don’t have to keep going back to the menu. This ensures that you’re pasting just the plain text, without the formatting. And bear this in mind: if you paste direct from Word without removing the styles, it may appear to work fine. None of that gobbledegook above will be visible but it can still do the damage; it may be a combination of things so that it looks fine, until you do x, whatever x is.

There’s another option in the Edit menu too: ‘Paste and Match Style’. Similar keyboard shortcut to the other one, but with the Shift key added. This will often look as though it’s doing exactly the same thing as ‘Paste as Plain Text’. The difference is, ‘Paste as Plain Text’ will mean that the text you’re pasting in will take on the default style of the theme you’re using, whereas ‘Paste and Match Style’ will take on a style that you may have applied, that overrides the default style of the theme.

To sum up: paste all the text you want, but never do it direct, by hitting Apple-V.

Try to do it the same way that you indicate when you make a turn in a car—even if you’re at a lonely crossroads at 3am and you can see for miles and there’s nothing coming, you still indicate, don’t you? Because it’s ingrained in you, you don’t even have to think to do it, it just happens. Muscle memory. Try to get like that with pasting text, and you’ll save yourself a lot of time in the long run.

The information on this page is completely free, but if you want to make a small donation it will be greatly appreciated …