Gmail Calendar Documents Reader Web more »
Recently Visited Groups | Help | Sign in
Google Groups Home
Possible bug in Mac Distiller's charpath?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  16 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
jdaw1  
View profile  
 More options Feb 16 2008, 6:17 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Sat, 16 Feb 2008 15:17:52 -0800 (PST)
Local: Sat, Feb 16 2008 6:17 pm
Subject: Possible bug in Mac Distiller's charpath?
Please consider the following code, also available at
www.jdawiseman.com/papers/bugs/20080216_charpath.ps
%!

% Julian D. A. Wiseman, 16th February 2008, www.jdawiseman.com

/FontSize 100 def
/Times-Roman FontSize selectfont
0 setgray  0.24 setlinewidth  1 setlinecap  1 setlinejoin  [] 0
setdash

72 72 FontSize 6 mul add moveto
(0) true charpath
(2) true charpath
stroke

72 72 FontSize 4.5 mul add moveto
FontSize 2 div FontSize rlineto  FontSize 2 div FontSize neg rlineto
stroke

72 72 FontSize 3 mul add moveto
(0) true charpath
FontSize 2 div FontSize rlineto  FontSize 2 div FontSize neg rlineto
(2) true charpath
stroke

showpage

GhostScript correctly outputs www.jdawiseman.com/papers/bugs/20080216_charpath_Ghostscript.pdf

But Mac Distiller (Professional, 8.1.0, 10/23/06) outputs
www.jdawiseman.com/papers/bugs/20080216_charpath_MacDistiller.pdf
which is missing the lines drawn by the two linetos (though not the
positioning affect). Mac Preview is very similar to the Distiller:
www.jdawiseman.com/papers/bugs/20080216_charpath_Preview.pdf

-- Please, am I doing something wrong?
-- Please, is there a workaround?
-- How can I nag Adobe to fix it? (The bug-submission page on Adobe
doesn't work!)


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
abeddie@hotmail.com  
View profile  
 More options Feb 18 2008, 5:28 pm
Newsgroups: comp.lang.postscript
From: "abed...@hotmail.com" <abed...@hotmail.com>
Date: Mon, 18 Feb 2008 14:28:54 -0800 (PST)
Local: Mon, Feb 18 2008 5:28 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
On Feb 16, 6:17 pm, jdaw1 <jdawise...@gmail.com> wrote:

Try a string false charpath. False is for stroking and true
is for filling or clipping.

Ed


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Feb 18 2008, 6:20 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Mon, 18 Feb 2008 15:20:38 -0800 (PST)
Local: Mon, Feb 18 2008 6:20 pm
Subject: Re: Possible bug in Mac Distiller's charpath?

> Try a string false charpath. False is for stroking and true
> is for filling or clipping.

Not quite.
-- The boolean is only relevant when the characters are for stroking.
Times-Roman is for filling.
-- If that were the problem, why would it affect the intervening
linetos but not the character paths themselves?
-- More convincingly, when tested, changing the boolean makes no
difference.

Also, the problem isn't caused by the 'hand drawn' path being open, as
adding  currentpoint closepath moveto  to the end of the rlineto lines
doesn't fix it either.

I'm stuck on this odd problem. Please could someone tell what happens
with PC distiller?


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Feb 25 2008, 12:08 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Mon, 25 Feb 2008 09:08:31 -0800 (PST)
Local: Mon, Feb 25 2008 12:08 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
Bumping this as I'm sure that somebody will have a solution.

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
ken  
View profile  
 More options Feb 25 2008, 12:31 pm
Newsgroups: comp.lang.postscript
From: ken <k...@spamcop.net>
Date: Mon, 25 Feb 2008 17:31:42 -0000
Local: Mon, Feb 25 2008 12:31 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
In article <4a93619f-78c4-46a2-9e44-
b8e64b67c...@o77g2000hsf.googlegroups.com>, jdawise...@gmail.com says...

> Bumping this as I'm sure that somebody will have a solution.

Solution in what sense ? I agree that the result appears incorrect, and
is the same using Distiller 8 under Windows.

All the PostScript RIPs I have available to test with (Ghostscript, Jaws
and Harlequin) agree that the PDF produced is incorrect. Those which can
produce PDF output (Jaws and GS) produce 'correct' PDFs.

I don't have a copy of CPSI to test with, and the only person I know who
has one has quite an old copy. Amusingly, a version we already know has
a problem with charpath...

So it seems your only recourse is to use something other than Distiller,
or get Adobe to accept the bug (or explain why it isn't a bug ;-)

Can't help you with tha I'm afraid.

                Ken


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
sjprouty  
View profile  
 More options Feb 25 2008, 1:01 pm
Newsgroups: comp.lang.postscript
From: "sjprouty" <scott.pro...@solimarsystems.com>
Date: Mon, 25 Feb 2008 12:01:23 -0600
Local: Mon, Feb 25 2008 1:01 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
If you are just looking for a work around, here is a way to restructure the
code that seems to work:

72 72 FontSize 3 mul add moveto
(0) true charpath
currentpoint stroke moveto
FontSize 2 div FontSize rlineto  FontSize 2 div FontSize neg rlineto
currentpoint stroke moveto
(2) true charpath
stroke

Thanks
Scott Prouty

--
Message posted using http://www.talkaboutprogramming.com/group/comp.lang.postscript/
More information at http://www.talkaboutprogramming.com/faq.html


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
deedub...@gmail.com  
View profile  
 More options Feb 25 2008, 1:47 pm
Newsgroups: comp.lang.postscript
From: deedub...@gmail.com
Date: Mon, 25 Feb 2008 10:47:54 -0800 (PST)
Local: Mon, Feb 25 2008 1:47 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
Yes, you can stroke the path in three sections but that doesn't help
if there are line joining issues or you want to use the whole path for
clipping.

Note how adding clipping makes it REALLY different from Ghostscript:

%!PS-Bug
72 72 FontSize 3 mul add moveto
(0) true charpath
FontSize 2 div FontSize rlineto  FontSize 2 div FontSize neg rlineto
currentpoint moveto
(2) true charpath clip clippath initclip
stroke

showpage

I've seen this problem before and assumed it was related to "charpath
security" i.e. preventing the unauthorized extracting of copyrighted
font outlines. As such, a possible solution would be to use the
"superexec" operator with that magic number Adobe published in the
little black book to enable the use of "pathforall" on the character
outlines to extract all the lineto's and curveto's and then draw them
as a regular path (not a charpath).

-David W.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Feb 26 2008, 3:04 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Tue, 26 Feb 2008 12:04:48 -0800 (PST)
Local: Tues, Feb 26 2008 3:04 pm
Subject: Re: Possible bug in Mac Distiller's charpath?

> Yes, you can stroke the path in three sections but that doesn't help if ... you want to use the whole path for clipping.

Alas I do want to use it for clipping, so stroking in pieces doesn't
work.

> a possible solution would be to use the "superexec" operator with that magic number Adobe published in the little black book to enable the use of "pathforall" on the character outlines to extract all the lineto's and curveto's and then draw them as a regular path (not a charpath).

That might help. Thank you for the clue. An online search reveals code
using
    1183615869 internaldict /superexec get exec
The only documentation I can find, at www.tinaja.com/glib/pssecrets.pdf,
says:

> Here's how to activate superexec: First, you do a 1183615869 internaldict begin. From that point on, a {forall} superexec or a {get} superexec will often override and ignore any possible invalidaccess errors. This greatly expands your abilities to customize PostScript code and operations.

Please, is there fuller documentation anywhere? E.g., what does
"often" mean? This seems very useful.

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Feb 26 2008, 3:27 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Tue, 26 Feb 2008 12:27:03 -0800 (PST)
Local: Tues, Feb 26 2008 3:27 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
superexec is also mention in www.tinaja.com/glib/atg2.pdf (a set of
reprints  of Computer Shopper series from November 1987 to December
1989!).


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Feb 26 2008, 10:09 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Tue, 26 Feb 2008 19:09:37 -0800 (PST)
Local: Tues, Feb 26 2008 10:09 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
http://pages.cs.wisc.edu/~ghost/doc/cvs/History3.htm#V3.41_Interpreter
(a history of Ghostscript versions 3.n) says at the end of the section
entitled "30.7 Interpreter":

> Adds superexec, an undocumented operator that is equivalent to exec but

suppresses all invalidaccess checks.  NOT COMPLETED YET; currently
superexec
is equivalent to exec.  (zcontrol.c)

Which suggests that it doesn't work in GhostScript.

PS: I'm adding these links to this thread so that my code can contain
a single reference leading to everything.
% groups.google.com/group/comp.lang.postscript/browse_thread/thread/
8599a22cfa270e5f/


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
deedub...@gmail.com  
View profile  
 More options Feb 28 2008, 10:57 pm
Newsgroups: comp.lang.postscript
From: deedub...@gmail.com
Date: Thu, 28 Feb 2008 19:57:27 -0800 (PST)
Local: Thurs, Feb 28 2008 10:57 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
On Feb 26, 7:09 pm, jdaw1 <jdawise...@gmail.com> wrote:

You know what, now it seems that superexec isn't necessary.
Maybe that restriction was removed a long time ago and I'm just
showing my age?

Note the line I have added between the 'charpath' and the 'stroke'
below:

%!PS-Bug
/FontSize 100 def
/Times-Bold FontSize selectfont

72 72 FontSize 3 mul add moveto
(0) true charpath
FontSize 2 div FontSize rlineto  FontSize 2 div FontSize neg rlineto
currentpoint moveto
(2) true charpath

mark{/moveto load}{/lineto load}{/curveto load}{/closepath load}
pathforall ] newpath cvx exec

stroke

showpage

-----------------------
One more word of warning: if Distiller attempts to do font
substitution and you get the message "Font cannot be embedded", then
it doesn't work. At least, that happened to me. When I used Times-Bold
as you did, I got the substitution message and bad outlines. When I
used TimesNewRomanPS-BoldMT (which is available on my Windows system)
then it works. Also, if it's a really unknown font name, like
CrazyTimes-Wacko, then Distiller just uses Courier and it works
(albeit with Courier outlines).

-David W.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Mar 16 2008, 11:00 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Sun, 16 Mar 2008 20:00:41 -0700 (PDT)
Local: Sun, Mar 16 2008 11:00 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
It seems to me that the

mark{/moveto load}{/lineto load}{/curveto load}{/closepath load}
pathforall ] newpath cvx exec

just recreates the path. Please, how is that useful? (Aside: to
facilitate text editor bracket matching, I'd commence it with a "["
rather than a "mark".)


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
deedub...@gmail.com  
View profile  
 More options Mar 17 2008, 9:27 pm
Newsgroups: comp.lang.postscript
From: deedub...@gmail.com
Date: Mon, 17 Mar 2008 18:27:30 -0700 (PDT)
Local: Mon, Mar 17 2008 9:27 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
On Mar 16, 8:00 pm, jdaw1 <jdawise...@gmail.com> wrote:

> It seems to me that the

> mark{/moveto load}{/lineto load}{/curveto load}{/closepath load}
> pathforall ] newpath cvx exec

> just recreates the path. Please, how is that useful? (Aside: to
> facilitate text editor bracket matching, I'd commence it with a "["
> rather than a "mark".)

Well, it is useful because it fixed the bug for me (Distiller 8.1.0 on
Windows). Did you try it?
If I comment out those two lines, the path does not draw completely.

Adobe attaches a nasty attribute of some kind to the internal path
data structure if it involves a character outline. Whatever this
attribute is, it causes a bug when you try to do certain things with
the path. So by regenerating the path using only moveto, lineto,
curveto and closepath, you create a new, clean path data structure
that the interpreter thinks does not involve character outlines
(because it was not built using 'charpath'), so it does not have the
nasty attribute, so it does not have the bug when you stroke it.

-David W.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Aandi Inston  
View profile  
 More options Mar 18 2008, 4:25 am
Newsgroups: comp.lang.postscript
From: qu...@dial.pipex.con (Aandi Inston)
Date: Tue, 18 Mar 2008 08:25:17 GMT
Local: Tues, Mar 18 2008 4:25 am
Subject: Re: Possible bug in Mac Distiller's charpath?

deedub...@gmail.com wrote:
>Adobe attaches a nasty attribute of some kind to the internal path
>data structure if it involves a character outline. Whatever this
>attribute is, it causes a bug ...

I think that's right. Ignoring the bug, I think it is trying to do
something desirable: to recognise sequences like

charpath fill
charpath stroke
charpath gsave fill grestore stroke

and, rather than leaving them as a collection of outlines, distilling
into filled and/or stroked references to a real font.
----------------------------------------
Aandi Inston  
Please support usenet! Post replies and follow-ups, don't e-mail them.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Mar 18 2008, 12:47 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Tue, 18 Mar 2008 09:47:21 -0700 (PDT)
Local: Tues, Mar 18 2008 12:47 pm
Subject: Re: Possible bug in Mac Distiller's charpath?
Very logical, thank you. I will experiment.

OOI, why use

[ {/moveto load} {/lineto load} {/curveto load} {/closepath load}
pathforall ] newpath cvx exec

rather than a simpler

[ {moveto} {lineto} {curveto} {closepath} pathforall ] newpath cvx
exec


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
jdaw1  
View profile  
 More options Mar 18 2008, 1:17 pm
Newsgroups: comp.lang.postscript
From: jdaw1 <jdawise...@gmail.com>
Date: Tue, 18 Mar 2008 10:17:19 -0700 (PDT)
Local: Tues, Mar 18 2008 1:17 pm
Subject: Re: Possible bug in Mac Distiller's charpath?

> [ {moveto} {lineto} {curveto} {closepath} pathforall ] newpath cvx
> exec

Please ignore that question: very foolish.

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2009 Google