X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=scm%2Fflag-styles.scm;h=2b52f44cb23516eb2ce7924dda97ac37b376231c;hb=ca848f7df661cdaf710b3293a2a81bf20c41e3ef;hp=98ec0e4d80b1a742e9b4e96844152e0c321b2e05;hpb=99b6f3aa3558b01c9d4158b19a1f1794c534f89c;p=lilypond.git diff --git a/scm/flag-styles.scm b/scm/flag-styles.scm index 98ec0e4d80..2b52f44cb2 100644 --- a/scm/flag-styles.scm +++ b/scm/flag-styles.scm @@ -1,6 +1,6 @@ ;;;; This file is part of LilyPond, the GNU music typesetter. ;;;; -;;;; Copyright (C) 2008--2014 Reinhold Kainhofer +;;;; Copyright (C) 2008--2015 Reinhold Kainhofer ;;;; ;;;; LilyPond is free software: you can redistribute it and/or modify ;;;; it under the terms of the GNU General Public License as published by @@ -90,17 +90,10 @@ All lengths are scaled according to the font size of the note." (thickness-offset (cons 0 (* -1 thickness dir))) (spacing (* -1 flag-spacing factor dir )) (start (cons (- half-stem-thickness) (* half-stem-thickness dir))) - ;; The points of a round-filled-polygon need to be given in clockwise - ;; order, otherwise the polygon will be enlarged by blot-size*2! - (points (if stem-up - (list start - flag-end - (offset-add flag-end thickness-offset) - (offset-add start thickness-offset)) - (list start - (offset-add start thickness-offset) - (offset-add flag-end thickness-offset) - flag-end))) + (points (list start + flag-end + (offset-add flag-end thickness-offset) + (offset-add start thickness-offset))) (stencil (ly:round-filled-polygon points half-stem-thickness)) ;; Log for 1/8 is 3, so we need to subtract 3 (flag-stencil (buildflag stencil (- log 3) stencil spacing)) @@ -214,11 +207,12 @@ a flag always touches a staff line." -(define-public ((glyph-flag flag-style) grob) +(define ((glyph-flag flag-style) grob) "Simulatesthe default way of generating flags: Look up glyphs @code{flags.style[ud][1234]} from the feta font and use it for the flag stencil." (create-glyph-flag flag-style "" grob)) +(export glyph-flag)