[ps] Mozilla generate invalid font when enable true type printing

RESOLVED FIXED

Status

()

Core
Printing: Output
RESOLVED FIXED
14 years ago
14 years ago

People

(Reporter: Pete Zha, Assigned: Pete Zha)

Tracking

Trunk
x86
Linux
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(2 attachments)

(Assignee)

Description

14 years ago
If the user defined font's size is smaller than 2000 bytes, some printer will
determine it is an invalid font and ignore the whole page. I will attach an
example postscript.
The printer I'm using is Xerox DocuPrint N32. I enable the ps error out put of
this printer and get the error: invalid font
(Assignee)

Comment 1

14 years ago
Created attachment 154438 [details]
sample postscript file
(Assignee)

Comment 2

14 years ago
Created attachment 154439 [details] [diff] [review]
patch

The idea is make sure the size of the user defined font is always bigger than
2000 bytes.
(Assignee)

Updated

14 years ago
Attachment #154439 - Flags: superreview?(roc)
Attachment #154439 - Flags: review?(tor)

Comment 3

14 years ago
Comment on attachment 154439 [details] [diff] [review]
patch

I would recommend a longer comment, maybe something like this:

// Add a small set of characters to the subset of the user
// defined font to produce to make sure the font ends up 
// being larger than 2000 bytes, a threshold under which 
// some printers will consider the font invalid.  (bug 253219)
Attachment #154439 - Flags: review?(tor) → review+

Updated

14 years ago
Summary: Mozilla generate invalid font when enable true type printing → [ps] Mozilla generate invalid font when enable true type printing
Is there a way to guarantee that this produces a font of more than 2000 bytes?
(Assignee)

Comment 5

14 years ago
(In reply to comment #4)
> Is there a way to guarantee that this produces a font of more than 2000 bytes?
I don't have a good idea to do it. So, this solution should be a work arround. I
think most of the font should have glyph data more than 2000 bytes if we add 0-9
to it. Anyway, we could add more chars like a-z to it to make sure the font size.
Comment on attachment 154439 [details] [diff] [review]
patch

This is horrible, but I can't think of a particularly better way to do it
Attachment #154439 - Flags: superreview?(roc) → superreview+
(Assignee)

Comment 7

14 years ago
checked in with tor's comments
Status: NEW → RESOLVED
Last Resolved: 14 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.