Skip to content

Commit

Permalink
fix(chord chart): apply the font family to the chord chart title
Browse files Browse the repository at this point in the history
  • Loading branch information
omnibrain committed Oct 26, 2019
1 parent a00d2dc commit 390ec57
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/svguitar.ts
Original file line number Diff line number Diff line change
Expand Up @@ -589,14 +589,15 @@ export class SVGuitarChord {
private drawTitle(size: number): number {
const color = this.settings.color || defaultSettings.color
const titleBottomMargin = this.settings.titleBottomMargin || defaultSettings.titleBottomMargin
const fontFamily = this.settings.fontFamily || defaultSettings.fontFamily

// draw the title
const text = this.svg
.text(this.settings.title || '')
.fill(color)
.move(constants.width / 2, 5)
.font({
family: this.settings.fontFamily,
family: fontFamily,
size,
anchor: 'middle'
})
Expand Down

0 comments on commit 390ec57

Please sign in to comment.