baseline-skip
(interpret-markup-list layout props args)))
-(define-builtin-markup-command (center-align layout props args)
+(define (general-column align-dir baseline mols)
+ "Stack @var{mols} vertically, aligned to @var{align-dir} horizontally."
+
+ (let* ((aligned-mols (map (lambda (x) (ly:stencil-aligned-to x X align-dir)) mols)))
+ (stack-lines -1 0.0 baseline aligned-mols)))
+
+(define-builtin-markup-command (center-column layout props args)
(markup-list?)
align
((baseline-skip))
@lilypond[verbatim,quote]
\\markup {
- \\center-align {
+ \\center-column {
+ one
+ two
+ three
+ }
+}
+@end lilypond"
+ (general-column CENTER baseline-skip (interpret-markup-list layout props args)))
+
+(define-builtin-markup-command (left-column layout props args)
+ (markup-list?)
+ align
+ ((baseline-skip))
+ "
+@cindex text columns, left-aligned
+
+Put @code{args} in a left-aligned column.
+
+@lilypond[verbatim,quote]
+\\markup {
+ \\left-column {
+ one
+ two
+ three
+ }
+}
+@end lilypond"
+ (general-column LEFT baseline-skip (interpret-markup-list layout props args)))
+
+(define-builtin-markup-command (right-column layout props args)
+ (markup-list?)
+ align
+ ((baseline-skip))
+ "
+@cindex text columns, right-aligned
+
+Put @code{args} in a right-aligned column.
+
+@lilypond[verbatim,quote]
+\\markup {
+ \\right-column {
one
two
three
}
}
@end lilypond"
- (let* ((mols (interpret-markup-list layout props args))
- (cmols (map (lambda (x) (ly:stencil-aligned-to x X CENTER)) mols)))
- (stack-lines -1 0.0 baseline-skip cmols)))
+ (general-column RIGHT baseline-skip (interpret-markup-list layout props args)))
(define-builtin-markup-command (vcenter layout props arg)
(markup?)
(let* ((mol (interpret-markup layout props arg)))
(ly:stencil-aligned-to mol Y CENTER)))
-(define-builtin-markup-command (hcenter layout props arg)
+(define-builtin-markup-command (center-align layout props arg)
(markup?)
align
()
\\markup {
\\column {
one
- \\hcenter
+ \\center-align
two
three
}
(make-pad-to-box-markup
(cons (/ length -2) (/ length 2))
'(0 . 0)
- (make-hcenter-markup arg))))
+ (make-center-align-markup arg))))
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
;; property
;; fonts.
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-(define-builtin-markup-command (bigger layout props arg)
- (markup?)
- font
- ()
- "Increase the font size relative to current setting.
-
-@lilypond[verbatim,quote]
-\\markup {
- \\huge {
- huge
- \\hspace #2
- \\bigger {
- bigger
- }
- \\hspace #2
- huge
- }
-}
-@end lilypond"
- (interpret-markup layout props
- `(,fontsize-markup 1 ,arg)))
(define-builtin-markup-command (smaller layout props arg)
(markup?)
(markup?)
font
()
- "Copy of the @code{\\bigger} command.
+ "Increase the font size relative to current setting.
@lilypond[verbatim,quote]
\\markup {
larger
}
@end lilypond"
- (interpret-markup layout props (make-bigger-markup arg)))
+ (interpret-markup layout props
+ `(,fontsize-markup 1 ,arg)))
(define-builtin-markup-command (finger layout props arg)
(markup?)