vcl/win/gdi/salfont.cxx | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-)
New commits: commit 026345eeb2aa9fca02bc055f28ebd34abd7ad680 Author: Khaled Hosny <khaledho...@eglug.org> Date: Thu Feb 9 00:18:10 2017 +0200 Donât look for bundled fonts relative to executable path on Windows Just do like other platforms, so that the fonts are avialble to unit tests since cppunittester is not run from instdir. Change-Id: Ib209473f5b6b07a154fecb430dca45b32e8fa556 Reviewed-on: https://gerrit.libreoffice.org/34048 Tested-by: Jenkins <c...@libreoffice.org> Reviewed-by: Khaled Hosny <khaledho...@eglug.org> diff --git a/vcl/win/gdi/salfont.cxx b/vcl/win/gdi/salfont.cxx index 0461f31..b6b4915 100644 --- a/vcl/win/gdi/salfont.cxx +++ b/vcl/win/gdi/salfont.cxx @@ -1302,14 +1302,11 @@ void WinSalGraphics::GetDevFontList( PhysicalFontCollection* pFontCollection ) // since we are only interested in fonts that could not be // registered before because of missing administration rights // only the font path of the user installation is needed - OUString aPath; - osl_getExecutableFile( &aPath.pData ); - aPath = aPath.copy( 0, aPath.lastIndexOf('/') ); - OUString aFontDirUrl = aPath.copy( 0, aPath.lastIndexOf('/') ); - aFontDirUrl += "/" LIBO_SHARE_FOLDER "/fonts/truetype"; + OUString aPath("$BRAND_BASE_DIR"); + rtl_bootstrap_expandMacros(&aPath.pData); // collect fonts in font path that could not be registered - osl::Directory aFontDir( aFontDirUrl ); + osl::Directory aFontDir(aPath + "/" LIBO_SHARE_FOLDER "/fonts/truetype"); osl::FileBase::RC rcOSL = aFontDir.open(); if( rcOSL == osl::FileBase::E_None ) {
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits