summaryrefslogtreecommitdiff
path: root/scripts/lib/fontbuild/anchors.py
diff options
context:
space:
mode:
Diffstat (limited to 'scripts/lib/fontbuild/anchors.py')
-rw-r--r--scripts/lib/fontbuild/anchors.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/scripts/lib/fontbuild/anchors.py b/scripts/lib/fontbuild/anchors.py
index 622d52a..a617b2f 100644
--- a/scripts/lib/fontbuild/anchors.py
+++ b/scripts/lib/fontbuild/anchors.py
@@ -27,15 +27,18 @@ def getAnchorByName(g,anchorName):
if a.name == anchorName:
return a
-
def moveMarkAnchors(f, g, anchorName, accentName, dx, dy):
if "top"==anchorName:
anchors = f[accentName].anchors
for anchor in anchors:
if "mkmktop_acc" == anchor.name:
+ for anc in g.anchors:
+ if anc.name == "top":
+ g.removeAnchor(anc)
+ break
g.appendAnchor("top", (anchor.x + int(dx), anchor.y + int(dy)))
- elif "bottom"==anchorName:
+ elif anchorName in ["bottom", "bottomu"]:
anchors = f[accentName].anchors
for anchor in anchors:
if "mkmkbottom_acc" == anchor.name: