[gsharp-cvs] CVS update: gsharp/drawing.lisp gsharp/measure.lisp

Robert Strandh rstrandh at common-lisp.net
Tue Nov 29 04:22:22 UTC 2005


Update of /project/gsharp/cvsroot/gsharp
In directory common-lisp.net:/tmp/cvs-serv30924

Modified Files:
	drawing.lisp measure.lisp 
Log Message:
Improved the computation of the bulge of a lyrics element.  This
improvement will allow me to test that the gaps between elements is
calculated correctly.

Also fixed a spelling error (was compute-bar-parameter, should be
compute-bar-parameters) that made Gsharp fail on a score with lyrics.


Date: Tue Nov 29 05:22:21 2005
Author: rstrandh

Index: gsharp/drawing.lisp
diff -u gsharp/drawing.lisp:1.36 gsharp/drawing.lisp:1.37
--- gsharp/drawing.lisp:1.36	Tue Nov 29 04:05:24 2005
+++ gsharp/drawing.lisp	Tue Nov 29 05:22:20 2005
@@ -110,8 +110,16 @@
 (defmethod left-bulge ((element element) pane)
   (score-pane:staff-step 1))
 
+(defmethod left-bulge ((element lyrics-element) pane)
+  (+ (score-pane:staff-step 0.5)
+     (/ (text-size pane (map 'string 'code-char (text element))) 2)))
+
 (defmethod right-bulge ((element element) pane)
   (score-pane:staff-step 1))
+
+(defmethod right-bulge ((element lyrics-element) pane)
+  (+ (score-pane:staff-step 0.5)
+     (/ (text-size pane (map 'string 'code-char (text element))) 2)))
 
 (defun compute-gaps-adjacent-timelines (bars method pane)
   (declare (ignore method))


Index: gsharp/measure.lisp
diff -u gsharp/measure.lisp:1.16 gsharp/measure.lisp:1.17
--- gsharp/measure.lisp:1.16	Mon Nov 28 05:25:34 2005
+++ gsharp/measure.lisp	Tue Nov 29 05:22:20 2005
@@ -621,7 +621,7 @@
 ;;; compute some important parameters of a bar
 (defgeneric compute-bar-parameters (bar))
 
-(defmethod compute-bar-parameter (bar)
+(defmethod compute-bar-parameters (bar)
   nil)
 
 (defmethod compute-bar-parameters ((bar melody-bar))




More information about the Gsharp-cvs mailing list