Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(86)

Unified Diff: scm/define-markup-commands.scm

Issue 236480043: add stencil-whiteout-outline function (Closed)
Patch Set: Narrow convert-ly rule, edit changes entry Created 9 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Please Sign in to add in-line comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « scm/define-grobs.scm ('k') | scm/output-lib.scm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: scm/define-markup-commands.scm
diff --git a/scm/define-markup-commands.scm b/scm/define-markup-commands.scm
index 4844dcd75e321d60b5adec7849900bbfdf1be344..5a08facce20b7d8c040c43722028b010cfa82b35 100644
--- a/scm/define-markup-commands.scm
+++ b/scm/define-markup-commands.scm
@@ -707,6 +707,7 @@ Rotate object with @var{ang} degrees around its center.
(define-markup-command (whiteout layout props arg)
(markup?)
#:category other
+ #:properties ((thickness 3))
"
@cindex adding a white background to text
@@ -716,10 +717,30 @@ Provide a white background for @var{arg}.
\\markup {
\\combine
\\filled-box #'(-1 . 10) #'(-3 . 4) #1
- \\whiteout whiteout
+ \\override #'(thickness . 1.5) \\whiteout whiteout
}
@end lilypond"
- (stencil-whiteout (interpret-markup layout props arg)))
+ (stencil-whiteout
+ (interpret-markup layout props arg)
+ (* thickness
+ (ly:output-def-lookup layout 'line-thickness))))
+
+(define-markup-command (whiteout-box layout props arg)
+ (markup?)
+ #:category other
+ "
+@cindex adding a rounded rectangular white background to text
+
+Provide a rounded rectangular white background for @var{arg}.
+
+@lilypond[verbatim,quote]
+\\markup {
+ \\combine
+ \\filled-box #'(-1 . 10) #'(-3 . 4) #1
+ \\whiteout-box whiteout-box
+}
+@end lilypond"
+ (stencil-whiteout-box (interpret-markup layout props arg)))
(define-markup-command (pad-markup layout props amount arg)
(number? markup?)
« no previous file with comments | « scm/define-grobs.scm ('k') | scm/output-lib.scm » ('j') | no next file with comments »

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b