On 20/02/2012 14:44, Reinhold Kainhofer wrote: > On 20/02/2012 14:18, Nils wrote: >> my pusblisher wants baroque figured bass gylphs. They have the strokes in >> different places than the Lilypond versions. >> I guess nobobdy did this so far, so I have to do it myself. > Yes, we have a feature request > (http://code.google.com/p/lilypond/issues/detail?id=2042 ), but no one > has done any work on it. > >> Where is the point in the code where I have to start? I want to do it right >> and use the same lilypond syntax like 4\+ or 6\\. > I suppose that the proper way would be to create new glyphs in our fonts > (using metafont, source file mf/feta-numbers.mf) and then adjust the > format-bass-figure function (in scm/translation-functions.scm) to use > those glyphs for the slashed figures.
Despite my lack of metafont knowledge, I have started tweaking some of the glyphs: http://codereview.appspot.com/5683051 That patch simply takes the digits 2, 4 and 5 of the feta font, stretches the one line that will be slashed, and adds a vertical box as a slash through it. These glyphs are not yet used by the figured bass formatting functions, but you can already use them via the musicglyph markup function. Attached is a simple test file showing the glyphs. Some issues: -) I have no idea how to properly implement the 6+ (the upper arc should have much less curvature and the slash is drawn through it. I would like the flare to have less turning angle, but with beta != +-90 it is no circle any more). -) Currently I place the slashes at more or less hardcoded positions and they are straight vertical. In particular for the 2 it might make sense to calculate the real intersection of the slash with the lower wavy line, so the slash is vertically centered. It might also be slanted to be perpendicular to the line it slashes through. Similarly, I'm not sure if the 5 should get a slightly slanted slash... -) I have no idea whether I should adjust the height of the boxes to include the slash. -) etc. It would be great if someone with more metafont knowledge could improve those issues. Cheers, Reinhold -- ------------------------------------------------------------------ Reinhold Kainhofer, reinh...@kainhofer.com, http://reinhold.kainhofer.com/ * Financial & Actuarial Math., Vienna Univ. of Technology, Austria * http://www.fam.tuwien.ac.at/, DVR: 0005886 * LilyPond, Music typesetting, http://www.lilypond.org
figured-bass-slashed-figures-test.preview.pdf
Description: Adobe PDF document
\version "2.15.31" \header { texidoc = "Examples of dedicated slashed bass figure glyphs." } \paper { ragged-right = ##t } << \context Voice { c'4 c' c' c' } \figures { \bassFigureExtendersOn <2\+ \markup { \fontsize #-2 \musicglyph #"twoplus" } 2 > <4\+ \markup { \fontsize #-2 \musicglyph #"fourplus" } 4 > <5\+ \markup { \fontsize #-2 \musicglyph #"fiveplus" } 5 > % <6\+ 6\\ 6/ \markup { \fontsize #-2 \musicglyph #"sixplus" 6} > } >>
_______________________________________________ lilypond-devel mailing list lilypond-devel@gnu.org https://lists.gnu.org/mailman/listinfo/lilypond-devel