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

Re: CUPS in Action (need help :)



--- Ahmad Khalifa <ahmad at khalifa dot ws> wrote:
> Nadim Shaikli wrote:
> > OK, this all sounds simple enough (ie. sounds like you've gone through
> > this pain once or twice :-).  So let's find a monospaced TTF convert it
> > to .pfa and verify the CUPS patch.
> 
> a __Freely distributed__ Monospaced Font please :)
> 
> > BTW: I get the feeling this is really secondary to what you've done to
> >      CUPS, so beyond all the .PS file mangling would it be possible for
> >      me to print things or can I bypass this hurdle to verify things a 
> >      different way (doubt it, but thought I'd ask).
> 
> well, no you cant print! because cups's backend would read the .PS file
> just like GV, GGV would. and I doubt that CUPS would look for the font
> in the same folder as the .PS
> 
> > Wait a second.  So CUPS requires you to use monospaced fonts to print
> > even in latin/english characters ?  This seems like a rather hefty
> > limitation, no ?  Meaning, if/when we get this going - we'll have
> 
> Yes, monospaced for all languages, but only for text files.
> you can use something like gedit to generate a .PS with a different font
> and it will take care of all the coordinates info.

Very strange - I'm not sure I understand but I don't think this is the
time for a lesson :-)  Let's verify the work you have done (and are doing)
and leave the lessons for later (on IRC hopefully).

> > one font we can use to print things and from the sound of it we won't
> > be able to print both latin and Arabic due to the 256 entries
> > limitation (maybe), right ?  Sorry for all this confusion, just trying
> > to understand what the heck is going on.
> 
> No, you can have multiple fonts in a .PS file, and thats what happens
> CUPS' texttops filter copies all the fonts it has in the .PS file
> try opening the .PS with emacs you'll see them.
> the problem is in the .PS arabic font, other languages get displayed
> fine.

Ah, I see - odd then that the .pfa file was not being picked-up from
within the .PS file and it needed to be in the dir I was invoking
'gv' from.  I think the "why" should be directed to someone that
knows abit more about .PS files.

Ahmed, I took our infamous 10x20.bdf [1] monospaced font in hopes
of converting it into TTF and looks like the process noted below
works.  I read the BDF into fontforge and wrote out a TTF.  I then
took this TTF and was able to generate a PFA via 'ttf2pt1'.

Here are the steps,

 1. Generate a TTF
    $ fontforge 10x20.bdf
      - File->Generate Fonts
      - Make sure TTF is select in bottom-right pull-down menu
      - Click 'Save'
 2. Generate a PFA
    $ ttf2pt1 -e 10x20.ttf
    -or-
    $ ttf2pt1 10x20.ttf
    $ cat 10x20.t1a | t1asm --pfa > new_font.pfa

I would have loved to generate the file for ya, but I don't know how
to deal with that 256 limitation thing and I wasn't sure which glyph
names I was to use.  So apologies in advance for this short-coming
but I thought it would be faster/easier in your hands.

[1] http://www.arabeyes.org/~nadim/10x20.bdf

Hope that helps and let me know if I can be of assistance.

 - Nadim



		
__________________________________ 
Do you Yahoo!? 
Check out the new Yahoo! Front Page. 
www.yahoo.com