dasch-swiss / beol

Bernoulli-Euler OnLine
https://beol.dasch.swiss
GNU Affero General Public License v3.0
0 stars 1 forks source link

Meditationes webfonts #145

Closed SepidehAlassi closed 4 years ago

SepidehAlassi commented 5 years ago

This pullrequest adds the icons for the svg files created by Cornelia for the Meditationes

SepidehAlassi commented 5 years ago

@tobiasschweizer Please try these icons in your data.

tobiasschweizer commented 5 years ago

@SepidehAlassi Thanks a lot for this PR!

I deployed this PR's version of the beol GUI on iml-leonhard. Does the XML source have to be changed? So far, special chars are replaced by combinations of characters.

SepidehAlassi commented 5 years ago

@tobiasschweizer in the xml files you have to replace the placeholders with the fonts. Ex: In the goldbach letter L065 the special character which was denoted in LaTeX as "\fxFk" is replaced with <font fontType="icon-fxFk"/> Then in the mapping I have defined:

<mappingElement>
        <tag>
            <name>font</name>
            <class>noClass</class>
            <namespace>noNamespace</namespace>
            <separatesWords>true</separatesWords>
        </tag>
        <standoffClass>
            <classIri>http://www.knora.org/ontology/0801/beol#StandoffFontTag</classIri>
            <attributes>
                <attribute>
                    <attributeName>fontType</attributeName>
                    <namespace>noNamespace</namespace>
                    <propertyIri>http://www.knora.org/ontology/0801/beol#standoffFontType</propertyIri>
                </attribute>
            </attributes>
        </standoffClass> 
    </mappingElement>

In this way the webfont is considered in the html rendering of the letter content with the special character. I hope this helps you.

tobiasschweizer commented 5 years ago

I found this in the docs of MathJax: http://docs.mathjax.org/en/latest/font-support.html#adding-new-fonts:

As mentioned, MathJax needs pre-generated font data to support a fonts. This font data can be generated using the MathJax development tools.

-> https://github.com/mathjax/MathJax-dev