3.1.57 FretBoard

A fretboard diagram.

FretBoard objects are created by the following engraver(s): Fretboard_engraver.

Standard settings:

after-line-breaking (boolean):

ly:chord-name::after-line-breaking

Dummy property, used to trigger callback for after-line-breaking.

extra-spacing-height (pair of numbers):
'(0.2 . -0.2)

In the horizontal spacing problem, we increase the height of each item by this amount (by adding the ‘car’ to the bottom of the item and adding the ‘cdr’ to the top of the item). In order to make a grob infinitely high (to prevent the horizontal spacing problem from placing any other grobs above or below this grob), set this to (-inf.0 . +inf.0).

extra-spacing-width (pair of numbers):
'(-0.5 . 0.5)

In the horizontal spacing problem, we pad each item by this amount (by adding the ‘car’ on the left side of the item and adding the ‘cdr’ on the right side of the item). In order to make a grob take up no horizontal space at all, set this to (+inf.0 . -inf.0).

fret-diagram-details (alist, with symbols as keys):
'((finger-code . below-string))

An alist of detailed grob properties for fret diagrams. Each alist entry consists of a (property . value) pair. The properties which can be included in fret-diagram-details include the following:

  • barre-type – Type of barre indication used. Choices include curved, straight, and none. Default curved.
  • capo-thickness – Thickness of capo indicator, in multiples of fret-space. Default value 0.5.
  • dot-color – Color of dots. Options include black and white. Default black.
  • dot-label-font-mag – Magnification for font used to label fret dots. Default value 1.
  • dot-position – Location of dot in fret space. Default 0.6 for dots without labels, 0.95-dot-radius for dots with labels.
  • dot-radius – Radius of dots, in terms of fret spaces. Default value 0.425 for labeled dots, 0.25 for unlabeled dots.
  • finger-code – Code for the type of fingering indication used. Options include none, in-dot, and below-string. Default none for markup fret diagrams, below-string for FretBoards fret diagrams.
  • fret-count – The number of frets. Default 4.
  • fret-distance – Multiplier to adjust the distance between frets. Default 1.0.
  • fret-label-custom-format – The format string to be used label the lowest fret number, when number-type equals to custom. Default "~a".
  • fret-label-font-mag – The magnification of the font used to label the lowest fret number. Default 0.5.
  • fret-label-vertical-offset – The offset of the fret label from the center of the fret in direction parallel to strings. Default 0.
  • fret-label-horizontal-offset – The offset of the fret label from the center of the fret in direction orthogonal to strings. Default 0.
  • handedness – Print the fret-diagram left- or right-handed. -1, LEFT for left ; 1, RIGHT for right. Default RIGHT.
  • paren-padding – The padding for the parenthesis. Default 0.05.
  • label-dir – Side to which the fret label is attached. -1, LEFT, or DOWN for left or down; 1, RIGHT, or UP for right or up. Default RIGHT.
  • mute-string – Character string to be used to indicate muted string. Default "x".
  • number-type – Type of numbers to use in fret label. Choices include arabic, roman-ij-lower, roman-ij-upper, roman-lower, roman-upper, arabic and custom. In the last case, the format string is supplied by the fret-label-custom-format property. Default roman-lower.
  • open-string – Character string to be used to indicate open string. Default "o".
  • orientation – Orientation of fret-diagram. Options include normal, landscape, and opposing-landscape. Default normal.
  • string-count – The number of strings. Default 6.
  • string-distance – Multiplier to adjust the distance between strings. Default 1.0.
  • string-label-font-mag – The magnification of the font used to label fingerings at the string, rather than in the dot. Default value 0.6 for normal orientation, 0.5 for landscape and opposing-landscape.
  • string-thickness-factor – Factor for changing thickness of each string in the fret diagram. Thickness of string k is given by thickness * (1+string-thickness-factor) ^ (k-1). Default 0.
  • top-fret-thickness – The thickness of the top fret line, as a multiple of the standard thickness. Default value 3.
  • xo-font-magnification – Magnification used for mute and open string indicators. Default value 0.5.
  • xo-padding – Padding for open and mute indicators from top fret. Default value 0.25.
stencil (stencil):

fret-board::calc-stencil

The symbol to print.

Y-extent (pair of numbers):

#<unpure-pure-container #<procedure ly:grob::stencil-height (_)> >

Extent (size) in the Y direction, measured in staff-space units, relative to object’s reference point.

This object supports the following interface(s): chord-name-interface, font-interface, fret-diagram-interface, grob-interface, item-interface, outside-staff-interface and rhythmic-grob-interface.

This object is of class Item (characterized by item-interface).


LilyPond Internals Reference v2.25.20 (development-branch).