Use current font for accents (#2066)

* Use current font for accents

Fix #353 using `buildCommon.makeSymbol` to automatically determine font
for the accent symbol.

* Fix screenshots

* Fix flow error

* Fix file permissions
This commit is contained in:
Erik Demaine
2019-08-20 09:40:40 -04:00
committed by ylemkimon
parent 96e1156764
commit 081b44ab57
9 changed files with 3 additions and 2 deletions

View File

@@ -94,8 +94,9 @@ export const htmlBuilder: HtmlBuilderSupSub<"accent"> = (grp, options) => {
accent = buildCommon.staticSvg("vec", options);
width = buildCommon.svgData.vec[1];
} else {
accent = buildCommon.makeSymbol(
group.label, "Main-Regular", group.mode, options);
accent = buildCommon.makeOrd({mode: group.mode, text: group.label},
options, "textord");
accent = assertSymbolDomNode(accent);
// Remove the italic correction of the accent, because it only serves to
// shift the accent over to a place we don't want.
accent.italic = 0;

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 11 KiB

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 10 KiB

After

Width:  |  Height:  |  Size: 10 KiB