-(define (text font string)
- (define (pango-font-name font)
- (let ((name (ly:font-name font)))
- (if name
- (regexp-substitute/global #f "^GNU-(.*)-[.0-9]*$" name 'pre 1 'post)
- (begin
- (stderr "font-name: ~S\n" (ly:font-name font))
- ;; TODO s/filename/file-name/
- (stderr "font-filename: ~S\n" (ly:font-filename font))
- (stderr "pango-font-size: ~S\n" (pango-font-size font))
- ;;"ecrm12"))))
- (ly:font-filename font)))))
-
- (define (pango-font-size font)
- (let* ((designsize (ly:font-design-size font))
- (magnification (* (ly:font-magnification font)))
-
-
- ;;font-name: "GNU-LilyPond-feta-20"
- ;;font-filename: "feta20"
- ;;pango-font-name: "lilypond-feta, regular 32"
- ;;OPS:2.61
- ;;scaling:29.7046771653543
- ;;magnification:0.569055118110236
- ;;design:20.0
-
- ;; experimental sizing:
- ;; where does factor ops come from?
- ;; Hmm, design size: 26/20
- (ops 2.60)
-
- (scaling (* ops magnification designsize)))
- (debugf "OPS:~S\n" ops)
- (debugf "scaling:~S\n" scaling)
- (debugf "magnification:~S\n" magnification)
- (debugf "design:~S\n" designsize)
-
- scaling))
-