Jump to content

Putting parentheses around a single note: Difference between revisions

From LilyPond wiki
Import snippet from LSR
 
m Replace version="2.24.0" with version="2.24" now that the LilyWiki extension supports auto-selecting the latest release in a stable series
Line 3: Line 3:
This only functions inside chords; to parenthesize a single note it must be enclosed with <code>&lt;&gt;</code> as if it is a chord.
This only functions inside chords; to parenthesize a single note it must be enclosed with <code>&lt;&gt;</code> as if it is a chord.


<lilypond version="2.24.0">
<lilypond version="2.24">
%% http://lsr.di.unimi.it/LSR/Item?id=318
%% http://lsr.di.unimi.it/LSR/Item?id=318



Revision as of 18:56, 16 November 2025

Objects may be parenthesized by prefixing \parenthesize to the music event: in other words, the note has to be put after the \parenthesize command.

This only functions inside chords; to parenthesize a single note it must be enclosed with <> as if it is a chord.

\version "2.24"

%% http://lsr.di.unimi.it/LSR/Item?id=318

\relative c'' {
  a4
  < \parenthesize b >
  c d
}