Skip to content

Instantly share code, notes, and snippets.

@TysonRayJones
Last active June 19, 2023 15:07
Show Gist options
  • Save TysonRayJones/1795c4734536ad792a8f6321e759d673 to your computer and use it in GitHub Desktop.
Save TysonRayJones/1795c4734536ad792a8f6321e759d673 to your computer and use it in GitHub Desktop.
How to quickly and easily insert syntax-highlighted code snippets into Microsoft powerpoint

Simply write your code in an editor which supports copying code with formatting (e.g. as RTF), such as WordPad, Visual Studio, TextMate and Notepad++. You can then copy the code directly into Powerpoint, preserving the formatting and syntax highlighting.

I prefer using TextMate on OSX. In TextMate, simply highlight a section of code, then click Bundles > TextMate > Copy Selection as RTF and paste this straight into Powerpoint. This will preserve the highlighting used by your TextMate theme, which you can change via View > Theme >

You can further mimic the font, which you can view in TextMate by View > Font >

@yuqianma
Copy link

After reading your suggestion, I suddenly thought of opening vscode.dev. It works! So the easiest way is to open vscode.dev now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment