More:
For this test i used “twapi-bin-4.1.27.zip ” and extracted it to pd\lib.
Mensaje telepatico asistido por maquinas.
From: Pd-list pd-list-bounces@lists.iem.at on behalf of Lucas Cordiviola lucarda27@hotmail.com Sent: Monday, February 13, 2017 4:40 PM To: Dan Wilcox; Miller Puckette Cc: Pd-List Subject: Re: [PD] cross platforms issues with displaying fonts in vanilla but not in Purr Data
Ok,
Following Dan`s suggestion to ship & use a font without installing it, I came to a very straight-forward method for w32.
Tested & working.
It uses a Tcl Windows API extension. (600KB)
twapi web: http://twapi.sourceforge.net/v4.1/installation.html
twapi package: https://sourceforge.net/projects/twapi/files/Current%20Releases/Tcl%20Window...
added lines on "pd-gui.tcl" @line 24:
# adding dejavu fonts on mswindows package require twapi twapi::AddFontResourceEx DejaVuSansMono.ttf twapi::AddFontResourceEx DejaVuSansMono-Bold.ttf
0000000
Don't know how to exclude this "package require" for the other OSs. The .ttf were placed on pd/bin for simplicity.
Mensaje telepatico asistido por maquinas.
From: Dan Wilcox danomatika@gmail.com Sent: Monday, February 13, 2017 5:06 AM To: Lucas Cordiviola Cc: Jonathan Wilkes; Alexandre Torres Porres; Pd-List; Miller Puckette Subject: Re: [PD] cross platforms issues with displaying fonts in vanilla but not in Purr Data
On Feb 12, 2017, at 6:49 PM, Lucas Cordiviola <lucarda27@hotmail.commailto:lucarda27@hotmail.com> wrote:
Another issue is that, for many, the rendering of a bolded DVSM will simply look *ulgy* to those used to a normal-weight Monaco, especially if they never used an earlier version of Pd or Pd on Linux.
IMO the default cross platform font should NOT be Bold. As Dan said OSX users will most likely find it ugly, and it was not bold in Pd-extended nor is in Purr-Data.
I tested with bold as that is the default font weight for vanilla on Linux AFAICT.
How difficult is to deploy DejaVu on Mac?
Typically, add a key to the app bundle Info.plist and include the font in the app bundle's Resource folder. This means the font does not have to be installed system- or user- wide but only used by the app itself. This assumes Tk’s handling of app bundles picks up on registered fonts from the plist (it should).
As for Windows, it looks like it’s possible to load a font that comes with the app (the Windows API alls this a:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms533820(v=vs.85).a...
http://code.activestate.com/lists/tcl-core/8158/#sthash.qJEhQALT.dpuf
@Dan:
The Tcl thing is just for Windows?
Yes as it’s using the Window’s API.
Or Cross-platform?
No. See above.
I know the Mac solution. Deja Vu is usually installed on Linux systems and, if not, can be an install requirement by whatever package manager is being used. There is no need to distribute and install a copy of the font on Linux.
Dan Wilcox @danomatikahttp://twitter.com/danomatika danomatika.comhttp://danomatika.com robotcowboy.comhttp://robotcowboy.com