home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #26 / NN_1992_26.iso / spool / comp / sys / amiga / applicat / 8404 < prev    next >
Encoding:
Internet Message Format  |  1992-11-05  |  6.3 KB

  1. Xref: sparky comp.sys.amiga.applications:8404 comp.sys.amiga.programmer:15408
  2. Newsgroups: comp.sys.amiga.applications,comp.sys.amiga.programmer
  3. Path: sparky!uunet!news.univie.ac.at!chx400!josef!avalon.physik.unizh.ch!matija
  4. From: matija@avalon.physik.unizh.ch (Matija Milostnik)
  5. Subject: Re: *REAL* Scalable Font Support for the Amiga?
  6. Message-ID: <1992Nov5.140126.6028@ifi.unizh.ch>
  7. Summary: CG fonts have more info than other fonts
  8. Keywords: CG fonts, printing
  9. Sender: news@ifi.unizh.ch (USENET News Admin)
  10. Nntp-Posting-Host: avalon
  11. Organization: Informatik Club d. Universitaet, Zuerich
  12. References: <1992Oct30.073744.10089@leland.Stanford.EDU> <1992Nov2.154658.27726@ifi.unizh.ch> <1992Nov3.130525.4926@ida.liu.se>
  13. Date: Thu, 5 Nov 1992 14:01:26 GMT
  14. Lines: 112
  15.  
  16. In article <1992Nov3.130525.4926@ida.liu.se> micja@ida.liu.se (Michael Jansson) writes:
  17. >
  18. >In article <1992Nov2.154658.27726@ifi.unizh.ch>, matija@avalon.physik.unizh.ch (Matija Milostnik) writes:
  19. >> Hello
  20. >> In article <1992Oct30.073744.10089@leland.Stanford.EDU> goldman@leland.Stanford.EDU (Oliver Isaac Goldman) writes:
  21. >I belive that it is even worse; printer drivers can *only* print graphics,i.e.
  22. >there are no support for down loadable fonts in the current specification for
  23. >printer drivers (right!?).  
  24. >
  25. >I don't know of a printer that do not have support for down loadable fonts
  26. >(even 9-pin printers have them, though only for fonts of some fixed size).
  27. >A program has to circumvent the printer device if it wants to down load a 
  28. >font, which means that the program has to know of the protocol of the 
  29. >particular printer. This is not a practical solution.
  30.  
  31. Its also out of the scope of the printer driver as it is intended in the 
  32. Amiga. A down loadable font is meant to be specific to a printer. 
  33. For using downloadable fonts, software shold be capable of asking the
  34. printer the availability and resolution it has, and then decide how the
  35. downloadable font must be. Even though it could have this infotmation from 
  36. the driver self, I guess it would be inpractical.
  37.  
  38. Another problem I see, is the following situation. Immagine a user with a 
  39. printer A that writes a document with a specific font. When the document is
  40. used by another user, who has a printer that cant download the font for 
  41. printer A, how is he supposed to print the document? Printer B should then
  42. use another font or refuse to print?
  43.  
  44. >> This is the point.
  45. >> Any application that does this must be rewritten to handle:
  46. >> 
  47. >>   the math to do the right conversion from 75dpi to 300dpi.
  48. >>   [this alone is quiet hard to do. You just cant double all
  49. >>    sizes and expect it to be right. Its even harder by the 
  50. >Is it that hard? Can you point out is the following discussion is wrong 
  51. >or lacks some details:
  52.  
  53. Nothing wrong, just I didnt point it out right.
  54.  
  55. >A font is accessed in units of ppm (pixels per em, i.e. number of ink dots 
  56. >in a perfect square that fits inside a character of the font). The unit
  57. >that is preferred is however points, which can be converted if the resolution
  58. >of the device is known. The reference point is the screen resolution, i.e. 
  59. >a font on screen has the same height in ppm as in pt on screen. 
  60.  
  61. Here we have to differentiate if we are spaking of CG fonts only or if 
  62. we speak speak of scalable font.
  63. CG fonts have their natural unit in em. This information is avaiable and
  64. can be used to determine the font size you need on screen. The font has
  65. few other information, the scaling engine can use the supplided informations
  66. to render the font you need. This information is dependent on the interface
  67. the system (in this case the diskfont.library) gives you.
  68.  
  69. Scalable fonts are font in bitmap tha can be 'scaled' by the diskfont.library
  70. to any point size. Their size is given in points. If you are lucky you can 
  71. also find out if it was intended to be for wide or narrow pixel, the aspect
  72. ratio and other data. (I dont have the documentation right now, but it 
  73. depends on the version of the font structure).
  74.  
  75. >Say that I 
  76. >have a 140x300 DPI printer (an arbitrary resolution), then I would request 
  77. >I 10pt font like:
  78. >
  79. >Point size = 10pt
  80. >Resolution = 140 x 300
  81. >Ppm size = pt / ScreenDPI * DPIY => 10 / 72 * 300 = 41.6666 (~42ppm)
  82. >
  83. >I would then set up a font request (a TTextAttr structure) with the ppm size 
  84. >42 and the device resolution 140x300.
  85.  
  86. Nope you only did the calculation in one direction. What the other size will 
  87. be depends on the aspect ratio of you displaying device, the font design for
  88. wide or tall pixel (scalable fonts), the aspect ratio the engine is sizing 
  89. the caracter at the moment (its not the aspect ratio of the displaying 
  90. device).
  91.  
  92. >This is straight forward, given that I will not need to apply special 
  93. >adjustment of the space between certain letter combinations (pair-kerning,
  94. >e.g. reducing the gap between A and O). That would require some (non-linear)
  95. >scaling, which has to be handled by a DTP program anyway. Special kerning 
  96. >information is needed for this, but that is not printer specific (it's needed
  97. >for the screen as well).
  98.  
  99. >>   the splitting of the page in more horrizontal strips.
  100. >>   the bigger memory requirements for this printing.
  101. >>   and so on...
  102. >[These problem could be reduced if there where support for down loading fonts
  103. >through the printer drivers (that would not work for all printer though, e.g.
  104. >some printers can only support fonts of fixed sizes.)]
  105.  
  106. see above
  107.  
  108. >I agree, though I don't think the bullet is really needed unless you want to
  109. >do pair-wise kerning (some fonts don't even contain kerning information), 
  110. >rotation etc.  The diskfont.library will give you the correct size and 
  111. >resolution for fonts as of OS 2.04. I guess programs are just not written
  112. >to take advantage of the new features.
  113.  
  114. The actual diskfont.library give you the ablity to size fonts, but
  115. there are cases you cant know if you have gotten what you asked for.
  116. With bullet you have sligtly complexer interface, but you can aks and 
  117. really get what you asked.
  118.  
  119. I guess this is getting more confusing at every post, isnt it?:-)
  120.   Matija
  121.  
  122. >     Michael Jansson      mij@IDA.LIU.SE, uunet!liuida!mij, mij@SELIUI51.BITNET
  123. -- 
  124. Best regards from Matija Milostinik           : matija@avalon.ifi.unizh.ch  
  125.                                               : matija@amiga.physik.unizh.ch
  126. Therefore, use local labels in the procedures as often as possible. 
  127. Save the environment!  Recycle!  ;-)                 (Bjoern Reese)
  128.