Skip to content

Commit

Permalink
Merge pull request #1212 from ronyeh/font/glyphs-and-metrics-files
Browse files Browse the repository at this point in the history
Run prettier / eslint on the font data files, to improve consistency and editability of the files.
  • Loading branch information
0xfe committed Nov 3, 2021
2 parents 365e81e + f537711 commit 5113a69
Show file tree
Hide file tree
Showing 15 changed files with 10,781 additions and 9,040 deletions.
2 changes: 0 additions & 2 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,3 +1 @@
fonts
tests/support/*
node_modules/*
6 changes: 3 additions & 3 deletions src/fonts/bravura.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { BravuraFont } from "./bravura_glyphs";
import { BravuraMetrics } from "./bravura_metrics";
import { BravuraFont } from './bravura_glyphs';
import { BravuraMetrics } from './bravura_metrics';

const Bravura = {
const Bravura = {
fontData: BravuraFont,
metrics: BravuraMetrics,
};
Expand Down
6,356 changes: 3,178 additions & 3,178 deletions src/fonts/bravura_glyphs.ts

Large diffs are not rendered by default.

8 changes: 7 additions & 1 deletion src/fonts/bravura_metrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,15 @@ export const BravuraMetrics = {
padding: 12,
endPaddingMax: 10,
endPaddingMin: 5,
unalignedNotePadding: 10
unalignedNotePadding: 10,
},

accidental: {
noteheadAccidentalPadding: 1,
leftPadding: 2,
accidentalSpacing: 3,
},

clef: {
default: {
point: 32,
Expand Down Expand Up @@ -80,6 +82,7 @@ export const BravuraMetrics = {
'4': { point: 23, shiftY: -12 },
},
},

pedalMarking: {
up: {
point: 40,
Expand Down Expand Up @@ -128,6 +131,9 @@ export const BravuraMetrics = {
},
},

// noteHead: {
// },

stem: {
heightAdjustmentForFlag: -3,
// These are stem (Y) offsets to the note heads. To shift the
Expand Down
130 changes: 65 additions & 65 deletions src/fonts/custom_glyphs.ts

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/fonts/custom_metrics.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export const CustomMetrics = {
name: 'Vexflow-Custom',
name: 'VexFlowCustom',
smufl: false,
glyphs: {}
glyphs: {},
};
1,778 changes: 889 additions & 889 deletions src/fonts/gonville_glyphs.ts

Large diffs are not rendered by default.

11 changes: 10 additions & 1 deletion src/fonts/gonville_metrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,17 +5,20 @@
export const GonvilleMetrics = {
name: 'Gonville',
smufl: false,

stave: {
padding: 12,
endPaddingMax: 10,
endPaddingMin: 5,
unalignedNotePadding: 10
unalignedNotePadding: 10,
},

accidental: {
noteheadAccidentalPadding: 1,
leftPadding: 2,
accidentalSpacing: 3,
},

clef: {
default: {
point: 40,
Expand Down Expand Up @@ -90,6 +93,9 @@ export const GonvilleMetrics = {
},
},

// articulation: {
// },

tremolo: {
default: {
point: 25,
Expand All @@ -109,6 +115,9 @@ export const GonvilleMetrics = {
},
},

// noteHead: {
// },

// These are for numeric digits, such as in time signatures
digits: {
point: 40,
Expand Down
6,356 changes: 3,178 additions & 3,178 deletions src/fonts/petaluma_glyphs.ts

Large diffs are not rendered by default.

10 changes: 6 additions & 4 deletions src/fonts/petaluma_metrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,15 @@ export const PetalumaMetrics = {
padding: 15,
endPaddingMax: 15,
endPaddingMin: 7,
unalignedNotePadding: 12
unalignedNotePadding: 12,
},

accidental: {
noteheadAccidentalPadding: 1,
leftPadding: 2,
accidentalSpacing: 3,
},

clef: {
default: {
point: 32,
Expand Down Expand Up @@ -302,13 +304,13 @@ export const PetalumaMetrics = {
minPadding: 2,
standard: {
noteheadBlackStemUp: {
shiftX: 0.5
shiftX: 0.5,
},
noteheadHalfStemUp: {
shiftX: 0.725
shiftX: 0.725,
},
noteheadWholeStemUp: {
shiftX: 1
shiftX: 1,
},
},
custom: {
Expand Down
Loading

0 comments on commit 5113a69

Please sign in to comment.