You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-users@xmlgraphics.apache.org by Luis Ferro <lf...@teladigital.pt> on 2006/08/25 00:11:48 UTC

Font Symbol

I've found a weird bug...

When i use the font "Symbol" (which is built it), all works well... except
if i try to use the "font-style='italic'" with it... it gives an error:

missing font (or something like that): 'Symbol, italic, 400' replacing with
default (or something like that).

Can others replicate the problem? (i sorted it out by forcing all symbols to
be "normal" but i think this should be sorted out)

Cheers
LF

P.S.- The more i know of FOP, the greater my admiration and respect for all
the hard work put into it... you guys certainly did (and are doing) a great
work!
-- 
View this message in context: http://www.nabble.com/Font-Symbol-tf2161582.html#a5973915
Sent from the FOP - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Setting configuration of fonts in java code?

Posted by Peter Neu <pe...@gmx.net>.
Hello,

is it possible to set configuration details for custom fonts in the java
code?

On a win box userconfig.xml looks like this: 

  <font metrics-file="C:/lib/ttfcm.xml" kerning="no"
embed-file="c:/lib/verdana.ttf">
.....


On a linux box userconfig.xml looks like this:

  <font metrics-file="/usr/local/fonts/ttfcm.xml" kerning="no"
embed-file="/usr/local/fonts/verdana.ttf">
.....

Is there a way to avoid this by doing it the execution code with an os test?


Cheers,
Pete



---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Chris Bowditch <bo...@hotmail.com>.
Andreas L Delmelle wrote:

> A little later than promised, but here goes:
> http://svn.apache.org/viewvc?rev=438251&view=rev
> 
> As Chris suggested, the notifyFontReplacement() method has been  altered 
> to show which triplet will be used instead.
> Note: I'm not sure if this suffices. If the default is used, the  
> message will now read
> "... replacing with 'any,normal,400'." Is that enough?

Thanks Andreas - I'm happy with that :)

Chris




---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Luis Ferro <lf...@teladigital.pt>.
For me is perfect, because this way we know what was used in each time a font
isn't found.

Gratz,
Luis Ferro



Andreas L Delmelle wrote:
> 
> On Aug 25, 2006, at 01:04, Andreas L Delmelle wrote:
> 
>> <snip />
>> Anyway, I'll give other devs a chance to chime in before I start  
>> fiddling with it. If no objections arise, I'll probably commit this  
>> small change during the weekend.
> 
> A little later than promised, but here goes:
> http://svn.apache.org/viewvc?rev=438251&view=rev
> 
> As Chris suggested, the notifyFontReplacement() method has been  
> altered to show which triplet will be used instead.
> Note: I'm not sure if this suffices. If the default is used, the  
> message will now read
> "... replacing with 'any,normal,400'." Is that enough?
> 
> 
> Later,
> 
> Andreas
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Font-Symbol-tf2161582.html#a6048927
Sent from the FOP - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Andreas L Delmelle <a_...@pandora.be>.
On Aug 25, 2006, at 01:04, Andreas L Delmelle wrote:

> <snip />
> Anyway, I'll give other devs a chance to chime in before I start  
> fiddling with it. If no objections arise, I'll probably commit this  
> small change during the weekend.

A little later than promised, but here goes:
http://svn.apache.org/viewvc?rev=438251&view=rev

As Chris suggested, the notifyFontReplacement() method has been  
altered to show which triplet will be used instead.
Note: I'm not sure if this suffices. If the default is used, the  
message will now read
"... replacing with 'any,normal,400'." Is that enough?


Later,

Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Jeremias Maerki <de...@jeremias-maerki.ch>.
On 25.08.2006 11:53:28 Chris Bowditch wrote:
> Andreas L Delmelle wrote:
> 
> > On Aug 25, 2006, at 00:11, Luis Ferro wrote:
> > 
> 
> <snip/>
> 
> > It doesn't seem too difficult to alter FontInfo.java to make it first  
> > look for a font with the same name/weight, but with default font-style.
> > 
> > Anyway, I'll give other devs a chance to chime in before I start  
> > fiddling with it. If no objections arise, I'll probably commit this  
> > small change during the weekend.
> 
> This change sounds like a good idea. If you decide to do it make sure 
> you update the message "replacing with default font" to reflect exactly 
> which font was used instead.

Well, it depends. :-) You could also say that you want to find a similar
font (PANOSE matching [1] which we don't have) but in the same variant,
i.e. italic in this case. It really depends what is more important to
you: that the font is similar but italic or that it's the same font but
you fall back to non-italic. That said, I'm ok with the change. It's
just that the decision should not be done just so.

[1] http://en.wikipedia.org/wiki/PANOSE


Jeremias Maerki


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Chris Bowditch <bo...@hotmail.com>.
Andreas L Delmelle wrote:

> On Aug 25, 2006, at 00:11, Luis Ferro wrote:
> 

<snip/>

> It doesn't seem too difficult to alter FontInfo.java to make it first  
> look for a font with the same name/weight, but with default font-style.
> 
> Anyway, I'll give other devs a chance to chime in before I start  
> fiddling with it. If no objections arise, I'll probably commit this  
> small change during the weekend.

This change sounds like a good idea. If you decide to do it make sure 
you update the message "replacing with default font" to reflect exactly 
which font was used instead.

Chris




---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Luis Ferro <lf...@teladigital.pt>.
It seams so... some symbols which doesn't exist in normal fonts (weird
unicodes to start with) just disapear from the text and are replaced with a
"#"... After i switched the italic to normal, the characters reapeared.

(this is in the somewhat new thrunk-svn of the start of August)

This didn't happened in the older version...

Cheers,
LF


Andreas L Delmelle wrote:
> 
> On Aug 25, 2006, at 00:11, Luis Ferro wrote:
> 
> Hi Luis,
> 
>> When i use the font "Symbol" (which is built it), all works well...  
>> except
>> if i try to use the "font-style='italic'" with it... it gives an  
>> error:
>>
>> missing font (or something like that): 'Symbol, italic, 400'  
>> replacing with
>> default (or something like that).
> 
> Seems correct more or less, but now that you mention it: it does  
> switch the whole font, right? While it is actually only the font- 
> style component that makes it impossible to locate the font.
> 
> It doesn't seem too difficult to alter FontInfo.java to make it first  
> look for a font with the same name/weight, but with default font-style.
> 
> Anyway, I'll give other devs a chance to chime in before I start  
> fiddling with it. If no objections arise, I'll probably commit this  
> small change during the weekend.
> 
> 
> Cheers,
> 
> Andreas
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org
> 
> 
> 

-- 
View this message in context: http://www.nabble.com/Font-Symbol-tf2161582.html#a5974770
Sent from the FOP - Users forum at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Andreas L Delmelle <a_...@pandora.be>.
On Aug 25, 2006, at 00:11, Luis Ferro wrote:

Hi Luis,

> When i use the font "Symbol" (which is built it), all works well...  
> except
> if i try to use the "font-style='italic'" with it... it gives an  
> error:
>
> missing font (or something like that): 'Symbol, italic, 400'  
> replacing with
> default (or something like that).

Seems correct more or less, but now that you mention it: it does  
switch the whole font, right? While it is actually only the font- 
style component that makes it impossible to locate the font.

It doesn't seem too difficult to alter FontInfo.java to make it first  
look for a font with the same name/weight, but with default font-style.

Anyway, I'll give other devs a chance to chime in before I start  
fiddling with it. If no objections arise, I'll probably commit this  
small change during the weekend.


Cheers,

Andreas


---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org


Re: Font Symbol

Posted by Chris Bowditch <bo...@hotmail.com>.
Luis Ferro wrote:

> I've found a weird bug...

Its not weird and not a bug ;)

> 
> When i use the font "Symbol" (which is built it), all works well... except
> if i try to use the "font-style='italic'" with it... it gives an error:
> 
> missing font (or something like that): 'Symbol, italic, 400' replacing with
> default (or something like that).
> 
> Can others replicate the problem? (i sorted it out by forcing all symbols to
> be "normal" but i think this should be sorted out)

Symbol, Normal is one of the built in 14 fonts.
Symbol, Italic is not!

Roughly list of 14 built in fonts is:

Times, Normal, Normal
Times, Bold, Normal
Times, Normal, Italic
Times, Bold, Italic
Helvetica, Normal, Normal
Helvetica, Bold, Normal
Helvetica, Normal, Italic
Helvetica, Bold, Italic
Courier, Normal, Normal
Courier, Bold, Normal
Courier, Normal, Italic
Courier, Bold, Italic
Symbol, Normal, Normal
ZapfDingbats, Normal, Normal

<snip/>

Chris




---------------------------------------------------------------------
To unsubscribe, e-mail: fop-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: fop-users-help@xmlgraphics.apache.org