Caio,

On 8/28/2015 9:14 AM, Caio Barros [via Lilypond] wrote:
> Hello!
>
> I want to print a double percent repeat inside a markup so I can use 
> it as a graphic in a footnote. How can I do that?
>
> I read in the manual - 
> lilypond.org/doc/v2.19/Documentation/notation/short-repeats  under 
> "/Isolated percent repeats" /- that it is possible to print a single 
> percent as a note but that doesn't seems to help.
>
> any hints?

Try this one out (solutions for single and double percent repeat symbols):

%%%%%%%%%%%%

percentRepeat = \markup {
   \lower #0.05
   \with-dimensions #'(-0.25 . 2.25) #'(0 . 1.6)
   \postscript #"
   % left slash
   0.25 setlinewidth
   0 0 newpath moveto
   1.65 1.6 lineto
   2 1.6 lineto
   0.35 0 lineto
   closepath
   gsave
   0 setgray fill
   grestore
   stroke

   % left dot
   0.3 1.3 0.23 0 360 arc closepath
   0 setgray fill

   % right dot
   1.95 0.3 0.23 0 360 arc closepath
   0 setgray fill"
}

doublePercentRepeat = \markup {
   \lower #0.05
   \with-dimensions #'(-0.25 . 3.3) #'(0 . 1.6)
   \postscript #"
   % left slash
   0.25 setlinewidth
   0 0 newpath moveto
   1.65 1.6 lineto
   2 1.6 lineto
   0.35 0 lineto
   closepath
   gsave
   0 setgray fill
   grestore
   stroke

   % right slash
   0.25 setlinewidth
   1.05 0 newpath moveto
   2.7 1.6 lineto
   3.05 1.6 lineto
   1.4 0 lineto
   closepath
   gsave
   0 setgray fill
   grestore
   stroke

   % left dot
   0.3 1.3 0.23 0 360 arc closepath
   0 setgray fill

   % right dot
   3 0.3 0.23 0 360 arc closepath
   0 setgray fill"
}

\markup { The OE is missing \percentRepeat and \doublePercentRepeat 
symbols. }

%%%%%%%%%%%%

The result:



I tried some other things using a \score block within a \markup, but 
they just kept throwing "programming errors" (and logically so). If 
anyone is interested in seeing them, I'll gladly share, but using the 
above code is probably the best option what you need.

- Abraham


hhfifbce.png (5K) 
<http://lilypond.1069038.n5.nabble.com/attachment/180317/0/hhfifbce.png>




--
View this message in context: 
http://lilypond.1069038.n5.nabble.com/Print-Double-Percent-Repeat-inside-a-markup-tp180309p180317.html
Sent from the User mailing list archive at Nabble.com.
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to