Re: comments on Unicode printing patch


Subject: Re: comments on Unicode printing patch
From: Tomas Frydrych (tomas@frydrych.uklinux.net)
Date: Sun Feb 11 2001 - 16:54:59 CST


Hi Vlad,
thanks for taking your time on this. What does your m_fontfile
contain? My contains something like
/usr/local/AbiSuite/fonts//tahoma.ttf -- note the double slash
between the font name and the path. I have initially tried to do
exactly what you do in the else branch, but ended up trying to open
/usr/local/AbiSuite/fonts//tahoma.u2g, which it would refuse to
open because of the double slash. That's why I went looking for
"//"; the else branch was meant to try to open the file in current
directory, since I concluded that if there is no "//" then the the font
name is unqualified. We can, of course add an extra else if ... else
to test for a single slash to, but what puzzles me is why on my
machine the font name is separated from the path by "//" and on
yours by single '/'. Any ideas?

I will make a small change so that we can satisfy both cases for
the time being.

Tomas

> else
> {
> - full_name = new char[20];
> - *full_name = 0;
> + full_name = new char[strlen(m_fontfile)+50];
> + strcpy(full_name,m_fontfile);
> + strrchr(full_name,'/')[1]=0;
> }



This archive was generated by hypermail 2b25 : Sun Feb 11 2001 - 17:01:29 CST