Re: rel-0-8-1; Default options are always used, even when package is loaded

[email protected] (Frank Küster) Wed, 23 Feb 2005 09:39:26 +0100
Newsgroups gmane.emacs.latex.preview.devel
Message-ID <87650j3c1t.fsf__22399.4529610083$1109155141$gmane$org@alhambra.kuesterei.ch>
David Kastrup <[email protected]> schrieb:

> [email protected] (Frank K=FCster) writes:
>
>> David Kastrup <[email protected]> schrieb:
>>
>>> Something like that?
>>
>> Yes, at least from what it is intended to signify. It's rather
>> small, and you have to look very closely to see what it is. Maybe it
>> can get some refinement. And why is it in grey? Why not some
>> "terrifying" colors?
>
> Hey, that was a joke.  Could not use that, anyway, since Edvard Munch
> has been dead only since 1944.

I had assumed that you or somebody created the image to be similar, not
a copy. But perhaps that would still be plagiarism; I never thought
about Urheberrechte and painted art. Maybe we can find some tortured
creature in a painting by Hieronymus Bosch ;-)

>>   Nothing at all in PDFLaTeX mode, not even a roadwork sign
>>   visible. C-c ` brings me a help buffer and point in _region_.tex
>>   with the exclamation mark sign and the following gs output:
>
> Again, a different problem.  Probably a file name change.

Which files need to be removed for debugging after such a change? Would
everything matching "./_region_.*" (recursively) be enough, or must
auto/_region_.el also be removed? Logfiles are okay to keep?

> "GNU Ghostscript", not "GPL Ghostscript".
>
[...]
> And the directory you are running it in has appropriate permissions
> for creating a _region_.prv directory?

Yes. I did the following:

# readlink -f `which gs`
/usr/bin/gs-gpl
frank@alhambra:~/latex/test/auctex$ rm -r auto/_region_.el _region_.*
frank@alhambra:~/latex/test/auctex$ emacs -q --no-site-file

M-x load-library RET tex-site RET
M-x load-library RET preview RET ;; unchanged version
C-x C-f preview-gs-mini.tex ;; brings me into LaTeX mode
C-c C-p C-b y ;; asks for preamble caching, then a roadwork sign is
              ;; shown, then the preview with the \alpha.
C-x C-c

frank@alhambra:~/latex/test/auctex$ rm -rf auto/_region_.el _region_.*
frank@alhambra:~/latex/test/auctex$ emacs -q --no-site-file &
M-x load-library RET tex-site RET
M-x load-library RET preview RET ;; unchanged version
C-x C-f preview-gs-mini.tex ;; brings me into LaTeX mode
C-c C-t C-p   ;; now in PDFLaTeX mode
C-c C-p C-b y ;; asks for preamble caching, then a roadwork sign is
              ;; shown, then the exclamation mark sign. gs error is:

gs -q -dSAFER -dDELAYSAFER -dNOPAUSE -DNOPLATFONTS -dPrinted -dTextAlphaBit=
s\=3D4 -dGraphicsAlphaBits\=3D4 -sDEVICE\=3Dpng16m -r123.035x122.862
GS>/.preview-BP currentpagedevice/BeginPage get dup null eq {pop{pop}bind}i=
f def <</BeginPage{currentpagedevice/PageSize get dup 0 get 1 ne exch 1 get=
 1 ne or{.preview-BP gsave 0.705882 0.933333 0.705882 setrgbcolor false set=
strokeadjust 3 setlinewidth clippath strokepath matrix setmatrix true {2 in=
dex{newpath}if round exch round exch moveto pop false}{round exch round exc=
h lineto}{curveto}{closepath}pathforall pop fill grestore }{pop}ifelse}bind=
/PageSize[1 1]>>setpagedevice/preview-do{[count 3 roll save]3 1 roll{setpag=
edevice}stopped{handleerror quit}if cvx systemdict/.runandhide known{.setsa=
fe(AFPL Ghostscript)product ne{<<>>setpagedevice}if{.runandhide}}if stopped=
{handleerror quit}if count 1 ne{quit}if aload pop restore<</OutputFile(/dev=
/null)>>setpagedevice}bind def (_region_.prv/tmp3974YwD/preview.dsc)(r)file=
 dup dup 0 setfileposition 425()/SubFileDecode filter cvx exec dup dup 425 =
setfileposition 50()/SubFileDecode filter cvx <</OutputFile(_region_.prv/tm=
p3974YwD/prev001.png)>>preview-do
Error: /invalidfileaccess in --.outputpage--
Operand stack:
   1   true
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostrin=
gval--   2   %stopped_push   --nostringval--   --nostringval--   %loop_cont=
inue   2   3   %oparray_pop   --nostringval--   --nostringval--   false   1=
   %stopped_push   .runexec2   --nostringval--   --nostringval--   --nostri=
ngval--   2   %stopped_push   --nostringval--   --nostringval--   false   1=
   %stopped_push   1148   --nostringval--   %end_runandhide   --nostringval=
--   --nostringval--   --nostringval--   0   8   %oparray_pop   --nostringv=
al--   --nostringval--   --nostringval--   --nostringval--
Dictionary stack:
   --dict:1055/1123(ro)(G)--   --dict:0/20(G)--   --dict:76/200(L)--   --di=
ct:100/127(ro)(G)--   --dict:230/230(ro)(G)--   --dict:19/24(L)--   --dict:=
4/6(L)--   --dict:22/31(L)--
Current allocation mode is local

Preview-GhostScript finished

This is what I see in the filesystem:

frank@alhambra:~/latex/test/auctex$ ls _region_.prv/
tmp3974YwD
frank@alhambra:~/latex/test/auctex$ touch _region_.prv/tmp3974YwD/prev001.p=
ng
frank@alhambra:~/latex/test/auctex$ ls _region_.prv/tmp3974YwD/
prev001.png  preview.dsc
frank@alhambra:~/latex/test/auctex$=20

When I change gs to point to gs-esp:

alhambra:~# readlink -f `which gs`
/usr/bin/gs-esp
alhambra:~# gs --version
7.07.1
alhambra:~#=20

And do the same, switching to PDFLaTeX mode, I get a nice
preview. Right-clicking on it and chosing "Copy MIME" gives: -=C4hem, I
have to fake this, because Gnus wants to include the no-longer-existent
file in the mail. "Teil" war originally "part"=20

,----
| <#Teil type=3D"image/png" disposition=3Dinline
| description=3D"$a$"
| filename=3D/home/frank/latex/test/auctex/_region_.prv/tmp4007w0D/prev001.=
png>
| <#/Teil>
`----


**********************************************************

Now trying your proposed solution with "GNU Ghostscript".=20

alhambra:~# readlink -f `which gs`
/usr/bin/gs-gpl
alhambra:~# gs --version
8.01

frank@alhambra:~/latex/test/auctex$ rm -rf auto/_region_.el _region_.*
frank@alhambra:~/latex/test/auctex$ emacs -q --no-site-file &
M-x load-library RET tex-site RET
M-x load-library RET preview RET ;; unchanged version
C-x C-f preview-gs-mini.tex ;; brings me into LaTeX mode
C-c C-t C-p   ;; now in PDFLaTeX mode
C-c C-p C-b y ;; asks for preamble caching. The buffer does not change
              ;; at all, but the minibuffer says "Type `C-c C-l' to
              ;; display results of compilation"

There is now a _region_.pdf with only the alpha in it, and
_region_.prv/tmp4090D5D/preview.dsc with the following content:

%!PS-Adobe-3.0
%%CreationDate: (D:20050223092600)
%%DocumentMedia: y5.289x6.266 6.266 5.289 70 white ()
%%Pages: 1
%%EndComments
%%BeginProlog
/Page null def
/Page# 0 def
/PDFSave null def
/DSCPageCount 0 def
/DoPDFPage {dup /Page# exch store pdfgetpage pdfshowpage } def
GS_PDF_ProcSet begin
pdfdict begin
%%EndProlog
%%BeginSetup
(_region_.pdf) (r) file { DELAYSAFER { .setsafe } if } stopped pop
 pdfopen begin
%%EndSetup
%%Page: 1 1
%%PageMedia: y5.289x6.266
1 DoPDFPage
%%Trailer
currentdict pdfclose
end
end
end
%%EOF

When I do C-c `, point is in a buffer with _region_.tex which shows the
exclamation mark sign, and the gs backtrace is:

gs -q -dSAFER -dDELAYSAFER -dNOPAUSE -DNOPLATFONTS -dPrinted -dTextAlphaBit=
s\=3D4 -dGraphicsAlphaBits\=3D4 -sDEVICE\=3Dpng16m -r123.035x122.862
GS>/.preview-BP currentpagedevice/BeginPage get dup null eq {pop{pop}bind}i=
f def <</BeginPage{currentpagedevice/PageSize get dup 0 get 1 ne exch 1 get=
 1 ne or{.preview-BP gsave 0.705882 0.933333 0.705882 setrgbcolor false set=
strokeadjust 3 setlinewidth clippath strokepath matrix setmatrix true {2 in=
dex{newpath}if round exch round exch moveto pop false}{round exch round exc=
h lineto}{curveto}{closepath}pathforall pop fill grestore }{pop}ifelse}bind=
/PageSize[1 1]>>setpagedevice/preview-do{[count 3 roll save]3 1 roll{setpag=
edevice}stopped{handleerror quit}if cvx systemdict/.runandhide known{.setsa=
fe(GNU Ghostscript)product ne{<<>>setpagedevice}if{.runandhide}}if stopped{=
handleerror quit}if count 1 ne{quit}if aload pop restore<</OutputFile(/dev/=
null)>>setpagedevice}bind def (_region_.prv/tmp4090D5D/preview.dsc)(r)file =
dup dup 0 setfileposition 425()/SubFileDecode filter cvx exec dup dup 425 s=
etfileposition 50()/SubFileDecode filter cvx <</OutputFile(_region_.prv/tmp=
4090D5D/prev001.png)>>preview-do
Error: /invalidfileaccess in --.outputpage--
Operand stack:
   1   true
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostrin=
gval--   2   %stopped_push   --nostringval--   --nostringval--   %loop_cont=
inue   2   3   %oparray_pop   --nostringval--   --nostringval--   false   1=
   %stopped_push   .runexec2   --nostringval--   --nostringval--   --nostri=
ngval--   2   %stopped_push   --nostringval--   --nostringval--   false   1=
   %stopped_push   1148   --nostringval--   %end_runandhide   --nostringval=
--   --nostringval--   --nostringval--   0   8   %oparray_pop   --nostringv=
al--   --nostringval--   --nostringval--   --nostringval--
Dictionary stack:
   --dict:1055/1123(ro)(G)--   --dict:0/20(G)--   --dict:76/200(L)--   --di=
ct:100/127(ro)(G)--   --dict:230/230(ro)(G)--   --dict:19/24(L)--   --dict:=
4/6(L)--   --dict:22/31(L)--
Current allocation mode is local

Preview-GhostScript finished

************************************************************

To add to the confusion, here is what I get with gs-afpl. Again with the
unchanged preview.el from the installation in /usr/local, now Debian
package of preview-latex should be involved.

alhambra:~# readlink -f `which gs`
/usr/bin/gs-afpl
alhambra:~# gs --version
8.14
alhambra:~#=20

frank@alhambra:~/latex/test/auctex$ rm -rf auto/_region_.el _region_.*
frank@alhambra:~/latex/test/auctex$ emacs -q --no-site-file &

M-x load-library RET tex-site RET
M-x load-library RET preview RET ;; unchanged version
C-x C-f preview-gs-mini.tex ;; brings me into LaTeX mode
C-c C-t C-p   ;; now in PDFLaTeX mode
C-c C-p C-b y ;; asks for preamble caching, then shows the roadwork
              ;; sign, then the exclamation mark sign, and the gs error
              is:

gs -q -dSAFER -dDELAYSAFER -dNOPAUSE -DNOPLATFONTS -dPrinted -dTextAlphaBit=
s\=3D4 -dGraphicsAlphaBits\=3D4 -sDEVICE\=3Dpng16m -r123.035x122.862
GS>/.preview-BP currentpagedevice/BeginPage get dup null eq {pop{pop}bind}i=
f def <</BeginPage{currentpagedevice/PageSize get dup 0 get 1 ne exch 1 get=
 1 ne or{.preview-BP gsave 0.705882 0.933333 0.705882 setrgbcolor false set=
strokeadjust 3 setlinewidth clippath strokepath matrix setmatrix true {2 in=
dex{newpath}if round exch round exch moveto pop false}{round exch round exc=
h lineto}{curveto}{closepath}pathforall pop fill grestore }{pop}ifelse}bind=
/PageSize[1 1]>>setpagedevice/preview-do{[count 3 roll save]3 1 roll{setpag=
edevice}stopped{handleerror quit}if cvx systemdict/.runandhide known{.setsa=
fe(AFPL Ghostscript)product ne{<<>>setpagedevice}if{.runandhide}}if stopped=
{handleerror quit}if count 1 ne{quit}if aload pop restore<</OutputFile(/dev=
/null)>>setpagedevice}bind def (_region_.prv/tmp4145A-D/preview.dsc)(r)file=
 dup dup 0 setfileposition 425()/SubFileDecode filter cvx exec dup dup 425 =
setfileposition 50()/SubFileDecode filter cvx <</OutputFile(_region_.prv/tm=
p4145A-D/prev001.png)>>preview-do
AFPL Ghostscript 8.14: **** Could not open the file  .
Error: /invalidfileaccess in --.outputpage--
Operand stack:
   1   true
Execution stack:
   %interp_exit   .runexec2   --nostringval--   --nostringval--   --nostrin=
gval--   2   %stopped_push   --nostringval--   --nostringval--   %loop_cont=
inue   2   3   %oparray_pop   --nostringval--   --nostringval--   false   1=
   %stopped_push   .runexec2   --nostringval--   --nostringval--   --nostri=
ngval--   2   %stopped_push   --nostringval--   --nostringval--   false   1=
   %stopped_push   1148   --nostringval--   %end_runandhide   --nostringval=
--   --nostringval--   --nostringval--   0   8   %oparray_pop   --nostringv=
al--   --nostringval--
Dictionary stack:
   --dict:1120/1686(ro)(G)--   --dict:0/20(G)--   --dict:77/200(L)--   --di=
ct:104/127(ro)(G)--   --dict:238/347(ro)(G)--   --dict:19/24(L)--   --dict:=
4/6(L)--   --dict:23/31(L)--
Current allocation mode is local
Last OS error: 2

Preview-GhostScript finished

I'll switch back to gs-esp for now, although I think this should be
fixed in the newer gs versions in Debian.

TIA, Frank
--=20
Frank K=FCster
Inst. f. Biochemie der Univ. Z=FCrich
Debian Developer



-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click
_______________________________________________
preview-latex-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/preview-latex-bugs


-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click