Copy and paste plain text only in OSX?
My problem: I copy something from a webpage or Illustrator, then paste it into an email or another Illustrator document and the styles are carried over from the original doc when I just want the text to conform to the format of the new document.
Is there a way to force OSX to copy and paste to only read the the plaintext of my selection?
Usually, OS X applications allow you to paste without style using ⇧⌥⌘V. This is not necessarily supported everywhere though.
If you simply want to get plain text from whatever was in the clipboard, and then put it in the clipboard again, you could for example run the following command from a Terminal:
pbpaste | pbcopy
This will get rid of rich text formatting. You could probably wrap this in a Service using Automator.app to have it accessible via keyboard shortcut.
I'm extremely happy to have found a way to do it without using crazy shortcuts (that would annoy me more than the formatted text).
As mmdei is writing at http://ask.metafilter.com/187733/OSX-How-to-copy-plaintext-always-everywhere-without-exception
Open 'System Preferences'
Select 'Keyboard'
Select tab 'Keyboard Shortcuts'
Select 'Application Shortcuts' from the left listbox Click '+' below right listbox
Select 'All Applications' for 'Application' input box Type 'Paste and Match Style' into the 'Menu Title' input box In the 'Keyboard Shortcut' input box, pretend that you are about to paste something by typing command-v. There should now be the cloverleaf command sign followed by a -v in this box. Click add.
Victory! Thanks. I should have done this myself a decade ago. =)
ADDITION
in case you need to paste formatted text, use right click - Paste.
As @slhck pointed out, ⇧⌥⌘V is a useful key combination that will "Paste and Match Style" in a number of apps, such as Safari, TextEdit, Mail, Messages, Notes, and even Microsoft Word (well, it does a "Paste and Match Formatting" in Word, but the result is identical as far as I can tell). One annoyance of Word's approach is that if the text you've copied is not itself styled, the ⇧⌥⌘V combination does nothing. So that's an obstacle to relying on ⇧⌥⌘V to always paste unstyled text. (In Apple apps, ⇧⌥⌘V will conveniently mimic ⌘V if the text is unstyled.)
As far as I can tell, of Adobe CS 6, only InDesign has a "Paste without Formatting" option (⇧⌘V; it uses ⇧⌥⌘V for "Paste in Place"). Although you could change those keystrokes with the help of System Preferences > Keyboard > Keyboard Shortcuts, that won't help you in Illustrator.
Thus, for a more all-inclusive solution, here are two methods, the first fast and graceful and the other quick and dirty.
- Install a program that offers clipboard management (of which there are many). For example, I use the free, simple, open-source app FlyCut, which as far as I can tell always pastes unstyled text. If you adopt this solution, it sounds like you might be interested in turning off the "Sticky bezel" (in FlyCut Preferences > General) and setting your hotkey to something like ⌥V (that's option+V) or CtrlV (in FlyCut Preferences > Hotkeys). As long as those keystrokes aren't already in use for another app, the result will be that your new two-key combination will paste unstyled text system-wide. (I could not get ⌘V to work properly with FlyCut, however, but other clipboard manager apps may do better—you could try Alfred, Quicksilver, ClipMenu, or others, though I don't know that all paste unstyled text only as with FlyCut.)
- For a quick-and-dirty way of clearing the styles from copied text, you can paste copied text with styles into a web browser's address bar and then copy/cut out of the address bar (although this trick should work with any field that only accepts plain text only). This works with the Safari, Chrome, and Firefox address bars (at least). Of course, this approach is far less elegant and more time-consuming than relying on a solution like #1, but it has the advantage of being easy and feasible on nearly any computer, even one you can't / don't want to install new software on.
Hope that helps!