Extracting text from markup: Difference between revisions
Appearance
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 |
No edit summary |
||
| Line 22: | Line 22: | ||
[[Category:Text]] | [[Category:Text]] | ||
[[Category:Text]] | [[Category:Text]] | ||
[[Category:Scheme]] | [[Category:Scheme]][[Category:Snippet]] | ||
Revision as of 22:52, 21 November 2025
This scheme function extracts a string from markup, removing any formatting information.
\version "2.24"
%% http://lsr.di.unimi.it/LSR/Item?id=747
#(define-markup-command (plain-text layout props arg)(markup?)
(interpret-markup layout props (markup (markup->string arg))))
ttt = \markup {
\normal-text { good day and \concat { hello \bold { world } } \italic { and moon } }
}
\header {
title = \ttt
subtitle = \markup { \normal-text { \italic { \plain-text \ttt } } }
}
\relative c' {
c
}