### A.10.5 Instrument Specific Markup

`\fret-diagram` definition-string (string)

  Make a (guitar) fret diagram. For example, say

  >     \markup \fret-diagram #"s:0.75;6-x;5-x;4-o;3-2;2-3;1-2;"

  for fret spacing 3/4 of staff space, D chord diagram

  Syntax rules for definition-string:

  Used properties:

  - `thickness` (0.5)
  - `fret-diagram-details`
  - `size` (1.0)
  - `align-dir` (-0.4)
`\fret-diagram-terse` definition-string (string)

  Make a fret diagram markup using terse string-based syntax.

  Here is an example

  >     \markup \fret-diagram-terse #"x;x;o;2;3;2;"

  for a D chord diagram.

  Syntax rules for definition-string:

  - Strings are terminated by semicolons; the number of semicolons is the number of strings in the diagram.
  - Mute strings are indicated by ‘`x`’.
  - Open strings are indicated by ‘`o`’.
  - A number indicates a fret indication at that fret.
  - If there are multiple fret indicators desired on a string, they should be separated by spaces.
  - Fingerings are given by following the fret number with a `-`, followed by the finger indicator, e.g. ‘`3-2`’ for playing the third fret with the second finger.
  - Where a barre indicator is desired, follow the fret (or fingering) symbol with `-(` to start a barre and `-)` to end the barre.

  Used properties:

  - `thickness` (0.5)
  - `fret-diagram-details`
  - `size` (1.0)
  - `align-dir` (-0.4)
`\fret-diagram-verbose` marking-list (pair)

  Make a fret diagram containing the symbols indicated in marking-list.

  For example,

  >     \markup \fret-diagram-verbose
  >       #'((mute 6) (mute 5) (open 4)
  >          (place-fret 3 2) (place-fret 2 3) (place-fret 1 2))

  produces a standard D chord diagram without fingering indications.

  Possible elements in marking-list:

  `(mute string-number)`

    Place a small ‘x’ at the top of string string-number.

  `(open string-number)`

    Place a small ‘o’ at the top of string string-number.

  `(barre start-string end-string fret-number)`

    Place a barre indicator (much like a tie) from string start-string to string end-string at fret fret-number.

  `(capo fret-number)`

    Place a capo indicator (a large solid bar) across the entire fretboard at fret location fret-number. Also, set fret fret-number to be the lowest fret on the fret diagram.

  `(place-fret string-number fret-number [finger-value [color-modifier]])`

    Place a fret playing indication on string string-number at fret fret-number with an optional fingering label finger-value, and an optional color modifier color-modifier. By default, the fret playing indicator is a solid dot. This can be globally changed by setting the value of the variable dot-color. Setting color-modifier to `inverted` inverts the dot color for a specific fingering. If the finger part of the `place-fret` element is present, finger-value will be displayed according to the setting of the variable finger-code. There is no limit to the number of fret indications per string.

  Used properties:

  - `thickness` (0.5)
  - `fret-diagram-details`
  - `size` (1.0)
  - `align-dir` (-0.4)
`\harp-pedal` definition-string (string)

  Make a harp pedal diagram.

  Possible elements in definition-string:

  `^`

    pedal is up

  `-`

    pedal is neutral

  `v`

    pedal is down

  `|`

    vertical divider line

  `o`

    the following pedal should be circled (indicating a change)

  The function also checks if the string has the typical form of three pedals, then the divider and then the remaining four pedals. If not it prints out a warning. However, in any case, it will also print each symbol in the order as given. This means you can place the divider (even multiple dividers) anywhere you want, but you’ll have to live with the warnings.

  The appearance of the diagram can be tweaked inter alia using the size property of the TextScript grob (`\override Voice.TextScript #'size = #0.3`) for the overall, the thickness property (`\override Voice.TextScript #'thickness = #3`) for the line thickness of the horizontal line and the divider. The remaining configuration (box sizes, offsets and spaces) is done by the harp-pedal-details list of properties (`\override Voice.TextScript #'harp-pedal-details #'box-width = #1`). It contains the following settings: `box-offset` (vertical shift of the box center for up/down pedals), `box-width`, `box-height`, `space-before-divider` (the spacing between two boxes before the divider) and `space-after-divider` (box spacing after the divider).

  >     \markup \harp-pedal #"^-v|--ov^"

  Used properties:

  - `thickness` (0.5)
  - `harp-pedal-details` (’())
  - `size` (1.2)
`\woodwind-diagram` instrument (symbol) user-draw-commands (list)

  Make a woodwind-instrument diagram. For example, say

  >     \markup \woodwind-diagram
  >       #'oboe #'((lh . (d ees)) (cc . (five3qT1q)) (rh . (gis)))

  for an oboe with the left-hand d key, left-hand ees key, and right-hand gis key depressed while the five-hole of the central column effectuates a trill between 1/4 and 3/4 closed.

  The following instruments are supported:

  To see all of the callable keys for a given instrument, include the function `(print-keys 'instrument)` in your .ly file, where instrument is the instrument whose keys you want to print.

  Certain keys allow for special configurations. The entire gamut of configurations possible is as follows:

  Additionally, these configurations can be used in trills. So, for example, `three3qTR` effectuates a trill between 3/4 full and ring depressed on the three hole. As another example, `threeRT` effectuates a trill between R and open, whereas `threeTR` effectuates a trill between open and shut. To see all of the possibilities for all of the keys of a given instrument, invoke `(print-keys-verbose 'instrument)`.

  Lastly, substituting an empty list for the pressed-key alist will result in a diagram with all of the keys drawn but none filled, for example:

  >     \markup \woodwind-diagram #'oboe #'()

  Used properties:

  - `graphical` (#t)
  - `thickness` (0.1)
  - `size` (1)

其他语言：deutsch, español, français, italiano, 日本語。
About automatic language selection.

#### LilyPond — Notation Reference v2.18.2 (稳定分支).