mailing-list for TeXmacs Users

Text archives Help


Re: [TeXmacs] TeX export problem


Chronological Thread 
  • From: Peter Rapčan <address@hidden>
  • To: address@hidden
  • Subject: Re: [TeXmacs] TeX export problem
  • Date: Fri, 10 Sep 2010 10:50:51 +0200

Hi Max,

Thanks for your help. I remember tex export worked for me before, but it may be that at that time I had the definitions in the main .tm file. Anyway, that way the export works now, thanks. 

On a related subject:  When inserting a bibliography, using a relative path for the .bib file does not work. This is not convenient when collaborating with others, since their absolute paths are seldom the same.

Peter.


On Sep 10, 2010, at 10:10 AM, Gubinelli Massimiliano wrote:

Hi all,

From: Peter Rapčan <address@hidden>
Date: September 9, 2010 4:19:50 PM GMT+02:00
Subject: [TeXmacs] TeX export problem
Reply-To: address@hidden

Hi,

I have the following problem. I defined macros for Dirac notation, which work fine in texmacs. After exporting to latex, the macro definitions are present, e.g. a \ket is defined, in the latex file but the latex file does not contain the calls to the macros themselves, nor the parameters (there is an empty space instead). I attach a .tm file, macro definitions and the generated tex file. Any help is appreciated.

Cheers,


Actually after some more digging, it seems to be a problem which does not depend on latex conversion routines,
The following simplified document
---------------------------------------------------------
<TeXmacs|1.0.7.6>

<style|article>

<\body>
  <\hide-preamble>
    <include|./texmacs_macros/macro_definitions.tm>

    \;
  </hide-preamble>

  The ket <ket|\<psi\>> will not export to tex.
</body>
---------------------------------------------------------

produce the following call to the texmacs->latex scheme routine in TeXmacs/progs/convert/latex/tmtex.scm


texmacs->latex [((last? . #f) (texmacs->latex:use-macros . on) (texmacs->latex:use-catcodes . off) (texmacs->latex:indirect-bib . off) (texmacs->latex:expand-user-macros . off) (texmacs->latex:expand-macros . on) (texmacs->latex:replace-style . on))], (document (TeXmacs 1.0.7.6) (style (tuple article)) (body (document (hide-preamble (document (with info-flag paper preamble true (document (concat (assign bra (quote (macro x (with mode math (concat (left langle) (arg x) (right |)))))) (assign ket (quote (macro x (with mode math (concat (left |) (arg x) (right rangle)))))) (assign braket (quote (macro x y (with mode math (concat (left langle) (arg x) (mid |) (arg y) (right rangle)))))) (assign braket-element (quote (macro x A y (with mode math (concat (left langle) (arg x) (mid |) (arg A) (mid |) (arg y) (right rangle)))))) (assign ketbra (quote (macro x y (with mode math (concat (left |) (arg x) (mid rangle) (mid langle) (arg y) (right |))))))) )) )) (concat The ket  (error compound ket)  will not export to tex.))) (initial (collection (associate info-flag short) (associate language english) (associate page-even 1.8cm) (associate page-medium paper) (associate page-odd 1.8cm) (associate page-right 1.8cm) (associate page-screen-margin false) (associate page-show-hf true) (associate page-type letter) (associate preamble false) (associate sfactor 6))))

texmacs->latex [((last? . #f) (texmacs->latex:use-macros . on) (texmacs->latex:use-catcodes . off) (texmacs->latex:indirect-bib . off) (texmacs->latex:expand-user-macros . off) (texmacs->latex:expand-macros . on) (texmacs->latex:replace-style . on))], (!file (document (hide-preamble (document (with info-flag paper preamble true (document (concat (assign bra (quote (macro x (with mode math (concat (left langle) (arg x) (right |)))))) (assign ket (quote (macro x (with mode math (concat (left |) (arg x) (right rangle)))))) (assign braket (quote (macro x y (with mode math (concat (left langle) (arg x) (mid |) (arg y) (right rangle)))))) (assign braket-element (quote (macro x A y (with mode math (concat (left langle) (arg x) (mid |) (arg A) (mid |) (arg y) (right rangle)))))) (assign ketbra (quote (macro x y (with mode math (concat (left |) (arg x) (mid rangle) (mid langle) (arg y) (right |))))))) )) )) (concat The ket  (error compound ket)  will not export to tex.)) (article) english (collection (associate info-flag short) (associate language english) (associate page-even 1.8cm) (associate page-medium paper) (associate page-odd 1.8cm) (associate page-right 1.8cm) (associate page-screen-margin false) (associate page-show-hf true) (associate page-type letter) (associate preamble false) (associate sfactor 6)) /Users/mgubi/t/clean32/TeXmacs)

as you can see here the portion related to the typesetted text is

 (concat The ket  (error compound ket)  will not export to tex.)

where the macro call has been replaced by error, so the converter routine simply discard the information.

There should be some problem when converting the tree to a scheme _expression_.

Joris?

max






Archive powered by MHonArc 2.6.19.

Top of page