mailing-list for TeXmacs Users

Text archives Help


Re: export to pdf and html and latex


Chronological Thread 
  • From: Jeroen Wouters <address@hidden>
  • To: vincent douce <address@hidden>, texmacs-users <address@hidden>
  • Subject: Re: export to pdf and html and latex
  • Date: Sat, 20 Nov 2021 16:47:26 +0000

Hi Vincent,

Re a: the shortcut still works for me. Did you change anything to my-
init-texmacs.scm? Other erroneous commands could prevent my-init-
texmacs.scm from reaching the point where you define this shortcut.

If you can, start TeXmacs from the terminal and look for error
messages. You could also try temporarily removing everything else from
my-init-texmacs.scm (after backing it up!) and see if that helps.

Re b: the below is what I use for html.

Best wishes,
Jeroen

(define (propose-html-name)
(with name (propose-name-buffer)
(if (string-ends? name ".tm")
(string-append (string-drop-right name 3) ".html"))))

(define (export-to-proposed-html)
(let ((html-name (propose-html-name)))
(if (url-test? html-name "f")
(user-confirm "File already exists. Really overwrite?" #f
(lambda (answ)
(when answ ((buffer-exporter "html") html-name))))
((buffer-exporter "html") html-name))))

(kbd-map
("M-e h" (export-to-proposed-html)))

On Sat, 2021-11-20 at 16:52 +0100, vincent douce wrote:
> hi
> a) i dont understand why my [very very] useful cmd+E+P does nt work any
> longer (see end of the mail)
> b) also, i would find very useful to have [the same or another] short
> to export to html or tex
> i apologize for not knowing how to search the way to write such code
> something equivalent to "wrapped-print-to-file" but for html ,
> Vincent
>
>
> ---------------------------------------
>
> (define (propose-pdf-name)
>   (with name (propose-name-buffer)
>   (if (string-ends? name ".tm")
>     (string-append (string-drop-right name 3) ".pdf"))))
>
> (define (export-to-proposed-pdf)
>   (let ((pdf-name (propose-pdf-name)))
>       (wrapped-print-to-file pdf-name)))
>
> (kbd-map
>   ("M-e p" (export-to-proposed-pdf)))
>




Archive powered by MHonArc 2.6.19.

Top of page