1 Aug 2010 17:20

### Re: Question on Preview

* Ing. Dieter Jurzitza (2010-07-31) writes:

> I installed auctex 11.86 and I stumble over issues when using preview. When
> saying "Preview -> Document" I get a "one-way-road"- sign and the error
> messages are listed below (sorry, somewhat lengthy ...)
>
> The document is a latex document, it looks as follows:
>
> \documentclass[12pt]{article}
> \begin{document}
> $$> f_{Res}=\frac{1}{2\pi\sqrt{m_{M}F_{M}}}=\frac{\omega_{0}}{2\pi} >$$
> \end{document}

Hm, this is working fine here.

> The output after activating preview latex see below. Obviously ghostscript
> stumbles across some issue - but I do not understand which one.
[...]
> Running Preview-PDF2DSC' with pdf2dsc test.pdf
> test.prv/tmp23068TMR/preview.dsc''
> Error: /undefinedfilename in --file--

The error looks like it cannot find test.pdf.  At least I get something
similar when I execute pdf2dsc foo.pdf' on the command line if foo.pdf
is not available.  Does pdf2dsc work if you call it manually on an
existing PDF file?

--

--


1 Aug 2010 17:07

### Re: psTricks and emacs

* chrt <at> jpbronner-schule.de (2010-07-31) writes:

> My problem: I want to use psTricks and know from TexnicCenter, that it is
> easy to get a pdf-file using ps2pdf.
>
> Best is a "Outputprofile", with four steps:
>
> latex %1
> dvips -o %1-pics.ps %1.dvi

AUCTeX will do call dvips and launch a Postscript viewer (in case
Windows is aware of one) once you do C-c C-c View <RET>'.  You could
define your own view command to convert the Postscript file to PDF as
well.  See (info "(auctex)Starting Viewers") for a description of the
customization options.

> ps2pdf12 %1-pics.ps
> pdflatex %1.tex ,

Why the pdflatex call?

> This way you get your pdf-Document with one mouse-click.

Unless you need multiple LaTeX runs, a BibTeX run, or the like ...

> As you can see: I've tried to manage this with a batch-file and it works
> with a constant Filename (like "maindoc.tex"), but I don't know how to give
> the name of the actual buffer/file to %1.

A function call to give you the name of the master file without an


1 Aug 2010 22:23

### Re: Question on Preview

Please keep the mailing list copied!

* Ing. Dieter Jurzitza (2010-08-01) writes:

> I tried pdf2dsc with some existing pdf-file and it terminates without "noise".
> The return value is zero.
>
> The file pdf2dsc stems from ghostscript 8.70. I tried the compilation of the
> code snipped I have been sending with my first email, so the pdf-file consists
> of a single equation.

The Ghostscript installation I have here is 8.71.  But I am not sure if
the Ghostscript version is related to the problem.

The next thing I'd try is to use Emacs, AUCTeX and preview-latex without
customizations and see if this changes anything.  You could do this by
starting Emacs like this:

emacs -Q -l auctex -l preview-latex

--

--
Ralf

2 Aug 2010 20:37

### Re: Question on Preview

Dear Ralf,
sorry, you answered twice, I replied to your PM, my fault. However, I have
been fiddling around with this issue, but even trying your suggestion did not
change anything. Probably an issue with ghostscript?

The file "prv_test.fmt" has a size of 3390695 Byte, what sounds huge compared
to the contents of the "regular" tex-file - but I cannot judge what should be
considered "normal" in this regard.

If I should provide any additional information - please let me know.
In any case, many thanks for your ongoing efforts so far!
Take care

Dieter Jurzitza

By the way, the system I am working on is openSUSE 11.3 "out of the box"

*****
> Am Sonntag, 1. August 2010, 22:23:39 schrieb Ralf Angeli:
> starting Emacs like this:
>
> emacs -Q -l auctex -l preview-latex

--

--
-----------------------------------------------------------

|
\
/\_/\           |
| ~x~ |/-----\   /


2 Aug 2010 21:35

### Re: Question on Preview

* Ing. Dieter Jurzitza (2010-08-02) writes:

> sorry, you answered twice, I replied to your PM, my fault.

In my sent mail folder there is only one reply to you with the mailing
list copied.  Perhaps the mailing list software sent a copy to your
account as well.  IIRC there is an option to disable this if your mail

> However, I have
> been fiddling around with this issue, but even trying your suggestion did not
> change anything. Probably an issue with ghostscript?

As mentioned before, it looks like test.pdf is not found by Ghostscript.
But without being able to reproduce the problem I cannot fathom why.

--

--
Ralf

3 Aug 2010 18:28

### user-keyword-class

Hello auctex mail list,

I'm using auctex 11.85 on aquamacs 1.9 and I have recently tried to
make my own keyword
classes for highlighting latex syntax such as \citet{}, \citep{} and
\citealp{}. I have used the semi-graphical interface to add a
"keyword with specs" as an "command with arguments" ordering a
foreground color change. This has resulted in that the keyword (e.g.
\citet) is highlighted in purple while the argument(s) "[...]{...}"
remain text black and not colored as I ordered.

Do anyone know why this happens and how to get the correct syntax
highlighting on user added keyword ?

Best regards,
P. Eriksson

3 Aug 2010 20:22

### Re: user-keyword-class

* Per Eriksson (2010-08-03) writes:

> I'm using auctex 11.85 on aquamacs 1.9 and I have recently tried to
> make my own keyword classes for highlighting latex syntax such as
> \citet{}, \citep{} and \citealp{}.

and AUCTeX is configured to parse the contents of files, then the macros
you mentioned above should be highlighted by default.

> I have used the semi-graphical interface to add a
> "keyword with specs" as an "command with arguments" ordering a
> foreground color change. This has resulted in that the keyword (e.g.
> \citet) is highlighted in purple while the argument(s) "[...]{...}"
> remain text black and not colored as I ordered.
>
> Do anyone know why this happens and how to get the correct syntax
> highlighting on user added keyword ?

What is the exact value of font-latex-user-keyword-classes' now?

--

--
Ralf

3 Aug 2010 21:53

### Re: user-keyword-class

Please keep the mailing list copied!

* Per Eriksson (2010-08-03) writes:

> I load the natbib package in my main tex file, but I input separate
> files for chapters. As you say the specific macros gets correctly
> highlighted in the main file whereas they are unaffected in other
> files where natbib is not explicitly loaded.

That should still work.  At least if AUCTeX is able to find the master
file.  This should be given as a file variable, e.g. like this:

%%% Local Variables:
%%% mode: latex
%%% TeX-master: "master"
%%% End:

> The value of font-latex-user-keyword-classes is currently:
>
> (("testkey"
>    (("citet" ""))
>    (:foreground "DarkCyan")
>    command))

The entry for \citet is lacking a format specifier.

--

--
Ralf

4 Aug 2010 11:00

### Automatically run LaTeX/BibTeX as required

Hi,

I'm new to this list, so I don't know whether this has been asked
before.

Given that AucTeX already reports that you might want to run BibTeX or
LaTeX again to fix references/citations/etc, would it be possible to
create a separate command that tries to do all this automatically?

I'm currently working on a document where references to equations have
a tendency to switch pages, causing me to often have to rerun LaTeX.
Unfortunately my elisp knowledge is far too small to implement this
myself.

Best,
Jaap Eldering

4 Aug 2010 12:29

### Re: Automatically run LaTeX/BibTeX as required

On 4 August 2010 18:30, Jaap Eldering wrote:
Given that AucTeX already reports that you might want to run BibTeX or
LaTeX again to fix references/citations/etc, would it be possible to
create a separate command that tries to do all this automatically?

Hi Jaap,

I think you're looking for "texify" which will do the required runs of LaTeX and BibTeX to get references and cross-references right.

I've included the following in my .emacs file, which makes the texify command available. You can then press C-c C-c in your latex file and select either Texify (to get a dvi file) or TexifyPDF (to get a pdf file).

Hope this helps.

Cheers,

Andreas

(lambda ()
'("Texify" "texify -b %t" TeX-run-command t (latex-mode) :help "Texify document to dvi (resolves all cross-references, etc.)") t)
_______________________________________________