On Thu, 2004-06-24 at 03:12, Jan Nieuwenhuizen wrote:

> 
> AFAICS your patches were not yet applied; if it's not too much
> trouble could you please send a full cvs diff (ie: all patches together?)
> 
> Jan.

Oops!!! Now with the patch attached, I hope.

Here's the patch for all files based on the current CVS.

Carl
Index: ChangeLog
===================================================================
RCS file: /cvsroot/lilypond/lilypond/ChangeLog,v
retrieving revision 1.2291
diff -r1.2291 ChangeLog
0a1,19
> 2004-06-29  Carl Sorensen  <[EMAIL PROTECTED]>
>                                                                                 
>         * scm/fret-diagrams.scm (draw-dots): default values for dot size
>         and dot-position now depend on finger-code value; in-dot makes
>         dots larger and centered.
>               (draw-barre): added straight-barre indicator option
>               (draw-dots): made fontify-text-white work.
>                                                                                
>         * music-drawing-routines.ps: added /draw_white_text
> 
>         * scm/output-tex.scm:  added white-text
> 
>         * scm/output-ps.scm:  added white-text
> 
>         * scm/lily.scm (ly:all-stencil-expressions): Added white-text to 
>         list of stencil expressions
> 
>         * scm/stencil.scm: Added fontify-text-white
> 
Index: scm/fret-diagrams.scm
===================================================================
RCS file: /cvsroot/lilypond/lilypond/scm/fret-diagrams.scm,v
retrieving revision 1.7
diff -r1.7 fret-diagrams.scm
8d7
< (define fontify-text-white fontify-text)  ;  temporary until fontify-text-white works properly (see draw-dots for usage)
149d147
<          (white-dot-font-mag (* scale-dot-radius (chain-assoc-get 'white-dot-font-mag props 1.8))) 
180,182d177
< ; deprecated font interface
<          (white-dot-font (ly:paper-get-font paper `(((font-magnification . ,white-dot-font-mag)
<                                                       (font-name . ,label-font-name)))))
264a260,261
>             (barre-type (chain-assoc-get 'barre-type props 'curved))
>             (scale-dot-radius (* size dot-radius))
267c264,265
<             (bottom (+ (* size (- (+ 2 (- (cadr fret-range) fret))dot-position) ) (* size barre-vertical-offset dot-radius)))
---
>             (dot-center-y (* size (- (+ 2 (- (cadr fret-range) fret))dot-position) ))
>             (bottom (+  dot-center-y (* barre-vertical-offset scale-dot-radius)))
273,275c271,277
<             (sandwich-stencil (ly:make-stencil (list 'bezier-sandwich `(quote ,bezier-list) (* size bezier-thick) )
<                                   (cons 0 right)
<                                   (cons 0 (+ bottom (* size bezier-height))))))
---
>             (barre-stencil (if (eq? barre-type 'straight)
>                               (ly:make-stencil (list 'draw-line (* size dot-radius) left dot-center-y right dot-center-y)
>                                                (cons left right)
>                                                (cons (- dot-center-y scale-dot-radius) (+ dot-center-y scale-dot-radius))) 
>                               (ly:make-stencil (list 'bezier-sandwich `(quote ,bezier-list) (* size bezier-thick) )
>                                   (cons left right)
>                                   (cons bottom (+ bottom (* size bezier-height)))))))
277c279
<             (ly:stencil-add sandwich-stencil
---
>             (ly:stencil-add barre-stencil
280c282
<             sandwich-stencil ))))
---
>             barre-stencil ))))
352,353d353
<          (dot-position (chain-assoc-get 'dot-position props 0.6)) ; needed for both draw-dots and draw-barre
<          (dot-radius (chain-assoc-get 'dot-radius props 0.25))  ; needed for both draw-dots and draw-barre
354a355,358
>          (default-dot-radius (if (eq? finger-code 'in-dot) 0.45 0.25))  ; bigger dots if labeled
>          (default-dot-position (if (eq? finger-code 'in-dot) 0.5 0.6))  ; move up to make room for bigger if labeled
>          (dot-radius (chain-assoc-get 'dot-radius props default-dot-radius))  ; needed for both draw-dots and draw-barre
>          (dot-position (chain-assoc-get 'dot-position props default-dot-position)) ; needed for both draw-dots and draw-barre
Index: scm/lily.scm
===================================================================
RCS file: /cvsroot/lilypond/lilypond/scm/lily.scm,v
retrieving revision 1.265
diff -r1.265 lily.scm
414a415
>     white-text
568d568
< 
Index: scm/output-ps.scm
===================================================================
RCS file: /cvsroot/lilypond/lilypond/scm/output-ps.scm,v
retrieving revision 1.84
diff -r1.84 output-ps.scm
41a42
> 	     white-text
253a255,259
> 
> (define (white-text s)
>    (let ((mystring (string-append "(" s ")" " /Helvetica-bold" " draw_white_text")))
>   mystring))
> 
273c279
<   "")
\ No newline at end of file
---
>   "")
Index: scm/output-tex.scm
===================================================================
RCS file: /cvsroot/lilypond/lilypond/scm/output-tex.scm,v
retrieving revision 1.64
diff -r1.64 output-tex.scm
44a45
> 	     white-text
172c173,175
< 
---
> (define (white-text s)
>    (embedded-ps (list 'white-text s)))
>    
Index: scm/stencil.scm
===================================================================
RCS file: /cvsroot/lilypond/lilypond/scm/stencil.scm,v
retrieving revision 1.7
diff -r1.7 stencil.scm
83c83,88
< 
---
>      
> (define-public (fontify-text-white font-metric text)
>   "Set TEXT with font FONT-METRIC, in color white, returning a stencil."
>   (let* ((b  (ly:text-dimension font-metric text))
>          (c  `(white-text ,text)))
>     (ly:make-stencil c  (car b) (cdr b))))  ;urg -- extent is not from ps font, but we hope it's close
Index: ps/music-drawing-routines.ps
===================================================================
RCS file: /cvsroot/lilypond/lilypond/ps/music-drawing-routines.ps,v
retrieving revision 1.20
diff -r1.20 music-drawing-routines.ps
155a156,165
> /draw_white_text % text font
> {
>   %font
>   findfont 0.8 scalefont setfont
>   1 setgray
>   0 0 moveto
>   % text
>   show
> } bind def
> 
Index: input/test/fret-diagram.ly
===================================================================
RCS file: /cvsroot/lilypond/lilypond/input/test/fret-diagram.ly,v
retrieving revision 1.3
diff -r1.3 fret-diagram.ly
30,31c30
<    % the chord below won't label on frets, because dot-color is black
<    c' ^\markup \fret-diagram #"f:1;c:5-1-3;6-x;5-3-1;4-5-2;3-5-3;2-5-4;1-3-1;"
---
>    c' ^\markup \override #'(barre-type . straight) \fret-diagram #"f:1;c:5-1-3;6-x;5-3-1;4-5-2;3-5-3;2-5-4;1-3-1;"
_______________________________________________
lilypond-devel mailing list
[EMAIL PROTECTED]
http://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to