Skip to content
| Marketplace
Sign in
Visual Studio Code>Extension Packs>LyTeX Language PackNew to Visual Studio Code? Get it now.
LyTeX Language Pack

LyTeX Language Pack

bncummings

|
1 install
| (0) | Free
All-in-one LyTeX setup: syntax highlighting and PDF rendering for LaTeX with embedded LilyPond.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

LyTeX Language Support

Language support for LyTeX — LaTeX with embeded LilyPond — providing syntax highlighting for documents that combine musical notation and typeset text.

Features

  • Syntax Highlighting for LyTeX files (.lytex):
    • Recognizes LaTeX commands and environments.
    • Highlights embedded lilypond blocks (see: lilypond-book documentation).

Planned Features:

  • Error highlighting for LaTeX and LilyPond code.
  • IntelliSense and autocompletion for commands and environments.

Example Lytex Snippet

\documentclass{article}
\usepackage{lilypond}

\begin{document}
    Here’s a simple melody:

    \begin{lilypond}
        \relative c' { c d e f g a b c }
    \end{lilypond}

\end{document}

Lytex Preview: LaTeX + LilyPond Rendering

Render LaTeX documents with embedded LilyPond snippets directly to PDF, all from within VS Code.

Prerequisites

NOTE: This extension is currently MacOS exclusive. LyTeX Compilation depends requires the following tools to be installed:

  • lilypond - includes lilypond-book which can embed lilypond in LaTeX.
  • latexit - For rendering latex.
  brew install lilypond
  brew install --cask latexit

How to use

  • Render LaTeX with LilyPond - Embed LilyPond in a LaTeX and save the file with a .lytex extension.

    \documentclass{article}
    \usepackage{lilypond}
    
    \begin{document}
      Here’s a simple melody:
    
      \begin{lilypond}
        \relative c' { c d e f g a b c }
      \end{lilypond}
    
    \end{document}
    

    See lilypond-book documentation for more information.

  • Compile Straight To PDF — Compile .lytex files containing lilypond environments directly to PDF.

    LyTeX compile demo
  • Lytex Preview Session — Recompile automatically on save. LyTeX preview demo

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2025 Microsoft