ststeiger / PdfSharpCore

Port of the PdfSharp library to .NET Core - largely removed GDI+ (only missing GetFontData - which can be replaced with freetype2)
Other
1.08k stars 237 forks source link

What is the default font? #340

Open akorchev opened 1 year ago

akorchev commented 1 year ago

Hi,

What is the default font that MigraDoc is using? I am having trouble displaying Japanese characters. On my mac (macOS 13.2.1) without setting up any custom font Japanese characters display just fine. Bold and italic don't work however. When I deploy to a docker container which has fonts installed Japanes characters render as boxes (but bold and italic do work). This makes me believe a different font is used and I wonder what the defaults are. I see it is set to PlatformDefault but I couldn't find what this resolves to on different operating systems.

For reference I use the following command to install fonts (got it from a different issue):

RUN echo "deb http://deb.debian.org/debian stable main contrib non-free" > /etc/apt/sources.list \
    && echo "ttf-mscorefonts-installer msttcorefonts/accepted-mscorefonts-eula select true" | debconf-set-selections \
    && apt-get update \
    && apt-get install -y \
        ttf-mscorefonts-installer \
    && apt-get clean \
    && apt-get autoremove -y \
    && rm -rf /var/lib/apt/lists/*