www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | README

commit a16ae7a5ebc97cfb610a2143254393918fd0650d
parent e4d2d933afc9bd5dd2ddbf5fac69d4bab225c873
Author: Mathijs Henquet <mathijs.henquet@gmail.com>
Date:   Sun, 18 Sep 2016 02:22:01 +0200

Ignore `font' groups when determining base elements, fixes #390 (#469)

* Ignore `font' groups when determining base elements, fixes #390

* fix ===

* Added testcase

Diffstat:
Msrc/buildHTML.js | 2++
Mtest/screenshotter/images/SupSubCharacterBox-chrome.png | 0
Mtest/screenshotter/images/SupSubCharacterBox-firefox.png | 0
Mtest/screenshotter/ss_data.yaml | 2+-
4 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/buildHTML.js b/src/buildHTML.js @@ -135,6 +135,8 @@ var getBaseElem = function(group) { } else { return group; } + } else if (group.type === "font") { + return getBaseElem(group.value.body); } else { return group; } diff --git a/test/screenshotter/images/SupSubCharacterBox-chrome.png b/test/screenshotter/images/SupSubCharacterBox-chrome.png Binary files differ. diff --git a/test/screenshotter/images/SupSubCharacterBox-firefox.png b/test/screenshotter/images/SupSubCharacterBox-firefox.png Binary files differ. diff --git a/test/screenshotter/ss_data.yaml b/test/screenshotter/ss_data.yaml @@ -104,7 +104,7 @@ Sqrt: | ^{\sqrt{\sqrt{\sqrt{x}}}}} SqrtRoot: | 1+\sqrt[3]{2}+\sqrt[1923^234]{2^{2^{2^{2^{2^{2^{2^{2^{2^{2^{2^2}}}}}}}}}}} -SupSubCharacterBox: a_2f_2{f}_2{aa}_2{af}_2 +SupSubCharacterBox: a_2f_2{f}_2{aa}_2{af}_2\mathbf{y}_Ay_A SupSubHorizSpacing: | x^{x^{x}}\Big|x_{x_{x_{x_{x}}}}\bigg|x^{x^{x_{x_{x_{x_{x}}}}}}\bigg| SupSubLeftAlignReset: |