help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: print/save Liberation font


From: Pantxo
Subject: Re: print/save Liberation font
Date: Thu, 4 Feb 2016 07:08:07 -0800 (PST)

samuel WEBER wrote
> Sorry for the spam.
> The
> 
> set (0, "defaultaxesfontname", "LiberationSans")
> 
> set (0, "defaultaxesfontsize", 12)
> 
> set (0, "defaulttextfontname", "LiberationSans")
> 
> set (0, "defaulttextfontsize", 12)
> 
> work perfectly. Sorry.
> 
> On 04/02/2016 10:31, samuel WEBER wrote:
>> Hi all,
>>
>> I am using the fltk graphic toolkit and octave 4.0.0 on archlinux.
>> I try to print a figure with an other font than "Helvetica" which is not
>> available in my system for Inkscape. I successfully set the font to the
>> figure with :
>>
>>>> allAxes = findall(0,'type','axes');
>>>> set(allAxes, 'FontName', 'LiberationSans')
>> but when I try to print it out, it's still 'Helvetica'. I use
>>
>>>> print filename.pdf -dpdf
>> but the result is the same in png or eps.
>>
>> It appears that the font is not in the GhostScript path, because when i
>> set the font to Times/Arial or whatever in
>> http://ghostscript.com/doc/current/Fonts.htm#Fontmap, it works. Isn't it
>> weird that the Liberation Font are not in the path?
>> How could I print the figure with Liberation font? Should I go to the
>> GhostScript config' or is it a way directly in Octave?
>>
>> Also, how to set the default font to Liberation? I try the following
>> lines (found in a post in 2009):
>>
>> set (0, "defaultaxesfontname", "LiberationSans")
>>
>> set (0, "defaultaxesfontsize", 12)
>>
>> set (0, "defaulttextfontname", "LiberationSans")
>>
>> set (0, "defaulttextfontsize", 12)
>>
>> without success.
>>
>> Bests,
>> Samuel
>>
>>
> 
> Hi,
> 
> Unfortunately, gl2ps, the library we use to print opengl based figures
> (from fltk ot qt toolkits), doesn't allow us to use any other font than
> Helvetica, Courier, Times, Symbol an Zapfdingbats. The reason is that
> those fonts don't have to be embeded for pdf documents to be portable:
> they are defined as base pdf fonts, thus necessarily available (or a
> replacement) in any viewers/printers.
> 
> That is why Octave will fallback to Helvetica for printing when any other
> font is chosen. 
> 
> We could argue that we already use ghostscript (which is able to embed any
> font from your system) to convert figures and it would thus be possible to
> embed fonts in documents. 
> 
> So in short : the workaround is to print to eps, replace Helvetica by any
> font you like and then use ghosscript to embed the font (and eventually
> convert to another format). Keep in mind though that if the font you
> choose is too different from Helvetica, the extent of the text will be
> wrong, i.e. legend boxes won't fit anymore with the text. 
> 
> 
> Pantxo 
> 
> _______________________________________________
> Help-octave mailing list

> Help-octave@

> https://lists.gnu.org/mailman/listinfo/help-octave





--
View this message in context: 
http://octave.1599824.n4.nabble.com/print-save-Liberation-font-tp4674636p4674642.html
Sent from the Octave - General mailing list archive at Nabble.com.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]