File: ArbitraryKeySignature.scm

package info (click to toggle)
denemo 2.6.49-0.2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 66,916 kB
  • sloc: ansic: 94,587; lisp: 38,713; xml: 22,675; python: 1,930; sh: 1,239; makefile: 642; yacc: 288; sed: 93
file content (36 lines) | stat: -rw-r--r-- 1,472 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
;;;ArbitraryKeySignature
(let ((tag "ArbitraryKeySignature")(accs #f)(note #f)(acc #f))
    (let loop ()
        (set! note (RadioBoxMenu
                      (cons (_ "C") "0")
                      (cons (_ "D") "1")
                      (cons (_ "E") "2")
                      (cons (_ "F") "3")
                      (cons (_ "G") "4")
                      (cons (_ "A") "5")
                      (cons (_ "B") "6")
                      
                      (cons (_ "Finish") #f)))
        (if note 
            (begin
                (set! acc (RadioBoxMenu
                  (cons (_ "Natural") ",NATURAL")
                  (cons (_ "Flat")   ",FLAT")   
                  (cons (_ "Sharp") ",SHARP")
                  (cons (_ "Double Sharp") ",DOUBLE-SHARP")
                  (cons (_ "Double Flat") ",DOUBLE-FLAT")))
                (if acc
                    (begin
                        (if (not accs)
                            (set! accs ""))
                        (set! accs (string-append accs "(" note " . " acc 
                                    ")"))
                        (loop))))))
    (if accs
        (begin
            (d-SetSaved #f)
            (d-Directive-standalone tag)
            (d-DirectivePut-standalone-graphic tag "\nK\nDenemo\n40")
            (d-DirectivePut-standalone-minpixels tag 40)
            (d-DirectivePut-standalone-postfix tag  (string-append "\\set Staff.keyAlterations = #`(" accs ")")))))