Here we are so far :
\version "2.18.2"
#(define (general-column align-dir baseline mols)
(let* ((aligned-mols (map (lambda (x) (ly:stencil-aligned-to x X align-dir)) mols)))
(stack-lines -1 0.0 baseline aligned-mols)))
#(define-markup-command (textCenter layout props args)(markup-list?)
#:properties ((baseline-skip))
(general-column CENTER baseline-skip (wordwrap-internal-markup-list layout props #f args)))
shortIncipit =
#(define-music-function (parser location InstrName ) (markup?)
#{
\set Staff.instrumentName = \markup {
\override #'(line-width . 12)
#InstrName
}
#})
myInst = \markup\textCenter { Cantus primi chori }
\layout {
indent = 30
}
{ \shortIncipit\myInst c' }
What we would like is to integrate
\textCenter in the
shortIncipit function in order to be able to write :
{ \shortIncipit #"Cantus primi chori" c' }