[gcompris-devel] Better font sets

Fòram na Gàidhlig fios at foramnagaidhlig.net
Sun May 26 10:32:42 UTC 2013


I have now created fontsets for Andika and documentation in the WIKI

http://gcompris.net/wiki/Fontsets

We still need good fontsets for non-Latin languages, maybe we can raid 
SIL for more fonts?

http://scripts.sil.org/cms/scripts/page.php?cat_id=FontDownloads

It's hard for me to judge which fonts are best though, since I don't 
speak any of those languages.

=====================================================

The new files are in boards/fontsets, and I modified src/gcompris/skin.c 
and skin.h

https://github.com/gunchleoc/GCompris/tree/master/boards/fontsets
https://github.com/gunchleoc/GCompris/blob/master/src/gcompris/skin.c
https://github.com/gunchleoc/GCompris/blob/master/src/gcompris/skin.h

What we now need are installers for the TTF fonts for the various 
operating systems. This is completely over my head, so I will need 
somebody else to take this on.

I tried to do a bit of legwork, and for NSIS we would need something 
like this in gcompris-installer.nsi.in:

;--------------------------------
;Fonts Section

!include FontReg.nsh
!include FontName.nsh

Section "Fonts"
; Alternate for older versions of NSIS: pre NSIS v2.0rc1
;  push $1
;  System::Call "Shell32::SHGetSpecialFolderLocation(i $HWNDPARENT, i 
${CSIDL_FONTS}|${CSIDL_FLAG_CREATE}, *i .r0)"
;  System::Call "Shell32::SHGetPathFromIDList(i r0, t .r1)"
;  System::Call 'shell32::SHGetMalloc(*i . r2)' ; IMalloc
;  System::Call '$2->5(i r0)' ; ->Free
;  System::Call '$2->2()' ; ->Release
;  StrCpy $FONT_DIR $1
;  pop $1

   StrCpy $FONT_DIR $FONTS

   !insertmacro InstallTTFFont 'boards/fontsets/fonts/AndikaBritish-R.ttf'
   !insertmacro InstallTTFFont 
'boards/fontsets/fonts/AndikaContinental-R.ttf'
   !insertmacro InstallTTFFont 'boards/fontsets/fonts/Ruluko-Regular.ttf'

   SendMessage ${HWND_BROADCAST} ${WM_FONTCHANGE} 0 0 /TIMEOUT=5000
SectionEnd

;--------------------------------

Documentation and the scripts to include are located at:

http://nsis.sourceforge.net/Register_Fonts




More information about the Gcompris-devel mailing list