Re: [AUCTeX] beamer

2018-03-03 Thread giacomo . boffi
Arash Esbati  writes:

> I'm not sure if we have an issue with the manual of preview here, but
> IIRC, one must pass the environments option(s) explicitly to preview.sty
> if loaded in .tex file, `active' alone doesn't suffice.  This code
> produces the desired result:
>
> \documentclass{beamer}
>
> \usepackage[textmath,displaymath,sections,active]{preview}
> \PreviewEnvironment*{frame}

Ciao Arash,

the documentation of the latex side of preview has

*active* is the most essential option. If this option is not
  specified, the preview package will be inactive and the document
  will be typeset as if the preview package were not loaded, except
  that all declarations and environments defined by the package are
  still legal but have no effect. This allows defining previewing
  characteristics in your document, and only activating them by
  calling LaTeX as

 latex ’\PassOptionsToPackage{active}{preview}\input{filename}’

my understanding is that you manually specify "active" only in the
relatively rare case in which you want to extract. e.g., the formulas
from a document as a set of png files --- in all the other cases, in
which you want to normally process the .tex file and just want to modify
the behavior of preview, e.g., with respect to beamer's "frame"
environments, you DO NOT put "active" in the latex source, because it's
the job of preview the elisp package to correctly invoke latex.

I have to add that the behavior described in the manual is no more what
happens using preview.el these days.

Thank you for the interest in my post ፨ g


___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


Re: [AUCTeX] beamer

2018-03-03 Thread giacomo . boffi
Ciao Mosè,

thank you for the working solution

> (with-eval-after-load "preview"
 >   (add-to-list 'preview-default-preamble
 >"\\PreviewEnvironment*{frame}" t))

that you have posted. Preview's info manual suggests to customize the
"preview-default-preamble" variable but it's more or less equivalent,
isn't it?.

I didn't know of this elisp mechanism to influence the behaviour of
preview, the latex package.

Is it possible that the breakage of my "test2.tex" file, that used to
work perfectly, is connected to the emacs side of preview manipulating
the latex side?

Again, thank you for the code ፨ g


___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


[AUCTeX] beamer

2018-02-28 Thread giacomo . boffi
I have two files, test1.tex

\documentclass{beamer}
\begin{document}
\begin{frame}
  \[ a = \begin{bmatrix} 2 & 4 \\ 7 & 3 \end{bmatrix} \]
\end{frame}
\end{document}

and test2.tex (* note that here I load preview.sty and use one of the
commands here defined *)

\documentclass{beamer}
\usepackage{preview}
\PreviewEnvironment*{frame}
\begin{document}
\begin{frame}
  \[ a = \begin{bmatrix} 2 & 4 \\ 7 & 3 \end{bmatrix} \]
\end{frame}
\end{document}

When I hit C-c C-p C-d (preview-document) in the buffer of test1 I have
that the image representing the displayed equation is produced, but it
is not correctly placed --- it is placed instead at the end of the frame
source

When I hit C-c C-p C-d (preview-document) in the buffer of test2 I have
the following message in the minibuffer

error in process sentinel: LaTeX found no preview images

and a longish output from latex that I'm going to append at the end of
my post.

The first version (test1) is known to be buggy, the second one was
suggested by someone on the list to tell preview.sty how to fix the
problem with beamer frames and has worked for years.  I don't know
exactly when the problem started because I use beamer two months each
year...

Any help will be appreciated, thank you in advance ፨ g

Here follows the log of the preview compilation
v
Running `Preview-LaTeX' on `test' with ``pdflatex  -file-line-error  
--synctex=1 
"\nonstopmode\nofiles\PassOptionsToPackage{active,tightpage,auctex}{preview}\AtBeginDocument{\ifx\ifPreview\undefined\RequirePackage[displaymath,floats,graphics,textmath,sections,footnotes]{preview}[2004/11/05]\fi}"
 "\input" test.tex''
This is pdfTeX, Version 3.14159265-2.6-1.40.18 (TeX Live 2017/Debian) 
(preloaded format=pdflatex)
 restricted \write18 enabled.
entering extended mode
LaTeX2e <2017-04-15>
Babel <3.18> and hyphenation patterns for 56 language(s) loaded.

No auxiliary output files.

(./test.tex (/usr/share/texlive/texmf-dist/tex/latex/beamer/beamer.cls
Document Class: beamer 2018/02/20 v3.50 A class for typesetting presentations
(/usr/share/texlive/texmf-dist/tex/latex/beamer/beamerbasemodes.sty 
(/usr/share/texlive/texmf-dist/tex/latex/etoolbox/etoolbox.sty) 
(/usr/share/texlive/texmf-dist/tex/latex/beamer/beamerbasedecode.sty)) 
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ifpdf.sty) 
(/usr/share/texlive/texmf-dist/tex/latex/beamer/beamerbaseoptions.sty 
(/usr/share/texlive/texmf-dist/tex/latex/graphics/keyval.sty)) 
(/usr/share/texlive/texmf-dist/tex/latex/geometry/geometry.sty 
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ifvtex.sty) 
(/usr/share/texlive/texmf-dist/tex/generic/ifxetex/ifxetex.sty)) 
(/usr/share/texlive/texmf-dist/tex/latex/base/size11.clo) 
(/usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty 
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty 
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphics.sty 
(/usr/share/texlive/texmf-dist/tex/latex/graphics/trig.sty) 
(/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/graphics.cfg)
(/usr/share/texlive/texmf-dist/tex/latex/graphics-def/pdftex.def))) 
(/usr/share/texlive/texmf-dist/tex/latex/pgf/systemlayer/pgfsys.sty 
(/usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-lists.tex))
 (/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def 
(/usr/share/texlive/texmf-dist/tex/latex/ms/everyshi.sty)) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex)) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeysfiltered.code.tex))
 (/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgf.cfg) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-pdftex.def
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-common-pdf.def)))
 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsyssoftpath.code.tex)
 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsysprotocol.code.tex))
 (/usr/share/texlive/texmf-dist/tex/latex/xcolor/xcolor.sty 
(/usr/share/texlive/texmf-dist/tex/latex/graphics-cfg/color.cfg)) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcore.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex) 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.code.tex 
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunctions.basic.code.tex)
 
(/usr/share

[AUCTeX] minor releases

2015-10-16 Thread giacomo boffi
Dear maintainers,

I cannot use melpa to update auctex+preview and I'm a bit worried,
11.88 is one year old and you had seven minor releases on melpa,
some of them correcting problematic issues.

I wonder if it wouldn't be possible to make available the minor
releases either as tar.gz or, at least, in terms of patches.

Thank you


___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


Re: [AUCTeX] preview vs beamer

2014-04-01 Thread giacomo . boffi
Tassilo Horn  writes:

> Ok, how about this:
>
> --8<---cut here---start->8---
> \RequirePackage[active,delayed]{preview}
> \documentclass{beamer}
>
> \begin{document}
> \begin{frame}
>   \(1+1+1\)
> \end{frame}
> \end{document}
> --8<---cut here---end--->8---

no

when using the beamer document class, to use preview-mode
you need to load preview.sty and do some stuff, just like in 

\usepackage{preview}
\PreviewEnvironment{...}
\PreviewEnvironment*{frame}

to prevent preview-mode to get confused by beamer's frames



following your instructions, i can produce a slide with the inline
equation '1+1+1' BUT trying to activate a preview, say with
C-c C-p C-d pdflatex is unable to generate the required png and no
preview of the equation is inserted in  the (x)emacs buffer

in other words, so far preview-mode is not usable in conjunction with
a beamer document
-- 
rispetto alle altre lingue romanze, l'italiano
è quello che ha subito le modifiche maggiori
 --- m-tomatis, in IHC


___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


Re: [AUCTeX] preview vs beamer

2014-03-26 Thread giacomo . boffi
David Kastrup  writes:

> \usepackage[delayed]{preview} would likely be simpler.  Don't have a
> working TeXlive2013 right now, so cannot test.

I tested your suggestion and I experienced the same error I reported
in my OP

Tassilo's one leads to pdflatex generating the png stuff rather than
typesetting the document...

thank you, ciao
g
  



___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


Re: [AUCTeX] preview vs beamer

2014-03-24 Thread giacomo . boffi
Tassilo Horn  writes:

> giacomo.bo...@gmail.com writes:
>
> Hi Giacomo,
>
>> while I can load preview.sty in a document formatted according to the
>> "article" class, when I try to load it in a document formatted
>> according to the "beamer" class something weird happens as soon as the
>> tex engine tries to produce a page
>>
>> | 
>> | ! Undefined control sequence.
>> | \@EveryShipout@Output ...EveryShipout@Org@Shipout 
>> |   \box \@cclv 
>> | l.5 \end{document}
>> |   
>> | ? 
>> to which I reply
>> |   q
>> | OK, entering \batchmode
>> | 
>> and a zero lenght pippo.pdf file is produced
>
> I can reproduce that but I don't know how to fix it. :-(

Ciao Tassilo, thank you for confirming the issue

i have to add that preview-mode, the elisp package, works inside a
XEmacs buffer with a beamer document, as long as i don't
\usepackage{preview} in my preamble... (OTOH, if i don't load
preview.sty, preview-mode makes a mess trying to render frames,etc)

as preview-mode works, there is a way to have pdflatex load
preview.sty w/o going south, isn't it?


___
auctex mailing list
auctex@gnu.org
https://lists.gnu.org/mailman/listinfo/auctex


[AUCTeX] preview vs beamer

2014-03-22 Thread giacomo . boffi
while I can load preview.sty in a document formatted according to
the "article" class, when I try to load it in a document formatted
according to the "beamer" class something weird happens as soon as
the tex engine tries to produce a page 

| 
| ! Undefined control sequence.
| \@EveryShipout@Output ...EveryShipout@Org@Shipout 
|   \box \@cclv 
| l.5 \end{document}
|   
| ? 
to which I reply
|   q
| OK, entering \batchmode
| 
and a zero lenght pippo.pdf file is produced

I tried to compile the beamer document with pdflatex, latex, lualatex
and xelatex to no avail

I attach a complete transcript of my terminal session

any help will be appreciated, thank you in advance
   g

ps, I see that beamer declares itself being a development version, but
i installed it using debian version of texlive...


| 10:21:48: cat pippo.tex
\documentclass{article}
\usepackage{preview}
\begin{document}
Pippo!
\end{document}
| 10:21:51: pdflatex pippo.tex
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian)
 restricted \write18 enabled.
entering extended mode
(./pippo.tex
LaTeX2e <2011/06/27>
Babel <3.9h> and hyphenation patterns for 4 languages loaded.
(/usr/share/texlive/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/share/texlive/texmf-dist/tex/latex/base/size10.clo))
(/usr/local/share/texmf/tex/latex/preview/preview.sty) (./pippo.aux) 
[1{/var/lib/texmf/fonts/map/pdftex/updmap/pdftex.map}] (./pippo.aux) )

Output written on pippo.pdf (1 page, 11165 bytes).
Transcript written on pippo.log.
| 10:21:53: perl -pi -e's/article/beamer/' pippo.tex
| 10:22:01: pdflatex pippo.tex
This is pdfTeX, Version 3.1415926-2.5-1.40.14 (TeX Live 2013/Debian)
 restricted \write18 enabled.
entering extended mode
(./pippo.tex
LaTeX2e <2011/06/27>
Babel <3.9h> and hyphenation patterns for 4 languages loaded.
(/usr/share/texmf/tex/latex/beamer/base/beamer.cls
(/usr/share/texmf/tex/latex/beamer/base/beamerbasercs.sty)
Document Class: beamer 2012/10/15 development version 3.24 A class
for typesetting presentations (rcs-revision 24853e6b98cf)
(/usr/share/texmf/tex/latex/beamer/base/beamerbasemodes.sty
(/usr/share/texmf/tex/latex/beamer/base/beamerbasedecode.sty))
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ifpdf.sty)
(/usr/share/texmf/tex/latex/beamer/base/beamerbaseoptions.sty
(/usr/share/texlive/texmf-dist/tex/latex/graphics/keyval.sty))
(/usr/share/texlive/texmf-dist/tex/latex/geometry/geometry.sty
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ifvtex.sty)
(/usr/share/texlive/texmf-dist/tex/generic/ifxetex/ifxetex.sty))
(/usr/share/texlive/texmf-dist/tex/latex/base/size11.clo)
(/usr/share/texlive/texmf-dist/tex/latex/pgf/basiclayer/pgfcore.sty
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphicx.sty
(/usr/share/texlive/texmf-dist/tex/latex/graphics/graphics.sty
(/usr/share/texlive/texmf-dist/tex/latex/graphics/trig.sty)
(/usr/share/texlive/texmf-dist/tex/latex/latexconfig/graphics.cfg)
(/usr/share/texlive/texmf-dist/tex/latex/pdftex-def/pdftex.def
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/infwarerr.sty)
(/usr/share/texlive/texmf-dist/tex/generic/oberdiek/ltxcmds.sty
(/usr/share/texlive/texmf-dist/tex/latex/pgf/systemlayer/pgfsys.sty
(/usr/share/texlive/texmf-dist/tex/latex/pgf/utilities/pgfrcs.sty
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-common-lists.tex))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfutil-latex.def
(/usr/share/texlive/texmf-dist/tex/latex/ms/everyshi.sty))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfrcs.code.tex))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys.code.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeys.code.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/utilities/pgfkeysfiltered.code.tex))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgf.cfg)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-pdftex.def
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsys-common-pdf.def)))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsyssoftpath.code.tex)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/systemlayer/pgfsysprotocol.code.tex))
 (/usr/share/texmf/tex/latex/xcolor/xcolor.sty
(/usr/share/texlive/texmf-dist/tex/latex/latexconfig/color.cfg))
(/usr/share/texlive/texmf-dist/tex/generic/pgf/basiclayer/pgfcore.code.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmath.code.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathcalc.code.tex
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathutil.code.tex)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathparser.code.tex)
(/usr/share/texlive/texmf-dist/tex/generic/pgf/math/pgfmathfunction