3.2.3 HTML

lilypond-book は楽譜を HTML ファイルに組み込むために以下のコマンドと環境を提供します:

入力ファイルの中では、楽譜は以下のコマンドのいずれかで特定されます:

<lilypond options go here>
  YOUR LILYPOND CODE
</lilypond>

<lilypond options go here: YOUR LILYPOND CODE />

<lilypondfile options go here>filename</lilypondfile>

<musicxmlfile options go here>filename</musicxmlfile>

記述例を挙げます:

<lilypond fragment relative=2>
\key c \minor c4 es g2
</lilypond>

上記のコードから lilypond-book は楽譜断片に対する適切な画像タグを持つ HTML ファイルを作り出します:

[image of music]

インライン画像を得るには、<lilypond … /> を使います。以下のように、コロン : でオプションと楽譜コードを区切ります:

Some music in <lilypond relative=2: a b c/> a line of text.

HTML ファイルとは別に記述した lilypond ファイルを組み込むには以下のようにします:

<lilypondfile option1 option2 …>filename</lilypondfile>

<musicxmlfile><lilypondfile> と同じ構文を使い、LilyPond ファイルではなく MusicXML ファイルを参照します。

lilypond タグや lilypondfile タグで使用するオプションのリストは、楽譜断片オプション を参照してください。

さらに、<lilypondversion/> は lilypond のバージョン番号を表示します。


LilyPond — 使用方法 v2.24.3 (安定版).