[vtkusers] [vtk-developers] Using system fonts on Windows (fontconfig equivalent?)

David Lonie david.lonie at kitware.com
Tue Apr 11 12:43:19 EDT 2017


AFAIK, the only option on windows would be to load the font file
directly using vtkTextProperty::SetFontFamily(VTK_FONT_FILE) and
vtkTextProperty::SetFontFile(...). I've never heard of FontConfig
being used on Windows, but I haven't really looked into it, either.

Good luck!

Dave

On Tue, Apr 11, 2017 at 4:45 AM, Elvis Stansvik
<elvis.stansvik at orexplore.com> wrote:
> Hi all,
>
> Cross-posting since I'm not sure if vtkusers@ or vtk-developers@ is
> most appropriate for this.
>
> On Linux, I'm using the vtkRendereringFreeTypeFontConfig module, so
> that I can use system fonts (e.g. for charts labels et.c). The goal is
> to make VTK fonts match those used by Qt, so I'm using
> QFontDatabase::system(...) to query for the user's preferred font, and
> then use that in my VTK code. This is all working quite well.
>
> I'm now porting the application to Windows. Does VTK have any support
> for loading system fonts on Windows? Something similar to the
> vtkRendereringFreeTypeFontConfig, but for whatever font backend
> Windows uses?
>
> If not, has anyone had luck in building fontconfig for Windows, and
> using the vtkRendereringFreeTypeFontConfig module there? (I'm not even
> sure if fontconfig has support for hooking into Windows' font backend,
> so this may not be a solution at all).
>
> Many thanks in advance,
> Elvis
> _______________________________________________
> Powered by www.kitware.com
>
> Visit other Kitware open-source projects at http://www.kitware.com/opensource/opensource.html
>
> Search the list archives at: http://markmail.org/search/?q=vtk-developers
>
> Follow this link to subscribe/unsubscribe:
> http://public.kitware.com/mailman/listinfo/vtk-developers
>


More information about the vtkusers mailing list