pygmentize -f rtf FILE | pbcopy
- Paste into TextEdit (in rich text mode: Format → Make Rich Text before pasting), and copy to clipboard again.
- In PowerPoint, Edit → Paste Special… → Styled Text.
(Pasting RTF directly into PowerPoint doesn't work correctly, at least with PowerPoint 2008 — it extends colour spans longer than it should, and sometimes removes line breaks. Going via TextEdit seems to solve the problem.)
WHOW... this definitely makes my day. Need to prepare dozens of slides with (cucumber) code - your tipp saved hours! Thanx.