-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
3 changed files
with
106 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,23 +1,23 @@ | ||
// A simple 2D vector type | ||
export interface Vec extends Array<number> {} | ||
|
||
// Another for line (array of Vec) | ||
// A line (array of Vec) | ||
export interface Line extends Array<Vec> {} | ||
|
||
// Another for letter (array of Line) | ||
// A glyph/letter (array of Line) | ||
export interface Glyph extends Array<Line> {} | ||
|
||
// An array of diacritics key (two or three letters) | ||
export interface DiaGroup extends Array<keyof Font> {} | ||
|
||
// Table to dupplicate existing glyph with diacriticals marks | ||
// The key is used to defined a diacriticized letter (à,ê,ï), | ||
// the first item of the array define the base letter w/out diacritics (a, e, i), | ||
// the last item is an array of diacricts name (described in diacritics/glyph.ts) | ||
export interface ExtendedTable { | ||
[key: string]: [string, string[]]; | ||
} | ||
|
||
// And finally a type for the whole font | ||
// where each glyph is defined in an object | ||
// with the char as a key | ||
// with the char as a key { a: [], b: []... } | ||
export interface Font { | ||
[key: string]: Glyph; | ||
} |