Make names more explicit

This commit is contained in:
be5invis 2020-08-09 19:22:55 -07:00
parent 4d20f8e655
commit 5382b324c3
5 changed files with 30 additions and 23 deletions

View file

@ -5,8 +5,8 @@ const Point = require("./point");
const Anchor = require("./anchor");
module.exports = class Glyph {
constructor(name) {
this._m_dependentName = name;
constructor(_identifier) {
this._m_identifier = _identifier;
this.contours = [];
this.advanceWidth = 500;
this.autoRefPriority = 0;
@ -36,7 +36,7 @@ module.exports = class Glyph {
}
// Dependency
dependsOn(glyph) {
if (glyph._m_dependentName) this.dependencies.push(glyph._m_dependentName);
if (glyph._m_identifier) this.dependencies.push(glyph._m_identifier);
if (glyph.dependencies) for (const dep of glyph.dependencies) this.dependencies.push(dep);
}
// Contour Tagging