all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* LaTeX-editing TEXTAREAs using w3m?
@ 2008-09-29 11:56 Nicolas Neuss
  2008-09-29 12:00 ` Nicolas Neuss
                   ` (7 more replies)
  0 siblings, 8 replies; 12+ messages in thread
From: Nicolas Neuss @ 2008-09-29 11:56 UTC (permalink / raw
  To: help-gnu-emacs

Hello,

I have a web server which renders small LaTeX snippets as PDF or HTML/GIF.
The LaTeX snippets can be edited via a browser as HTML-textarea fields.
However, using standard browsers I miss the LaTeX-editing features I have
available when editing LaTeX code with Emacs.

One possible remedy would be to use w3m and switch on LaTeX mode when
editing textareas.  I have tried this, and the straightforward way did not
work (that is, the w3m information did get lost when I did M-x latex-mode).
Does anyone know if such a feature is easily possible?

Thank you very much,

Nicolas


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
@ 2008-09-29 12:00 ` Nicolas Neuss
  2008-09-29 13:43 ` Paul R
                   ` (6 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Nicolas Neuss @ 2008-09-29 12:00 UTC (permalink / raw
  To: help-gnu-emacs

Nicolas Neuss <lastname@math.uni-karlsruhe.de> writes:

> However, using standard browsers I miss the LaTeX-editing features I have
> available when editing LaTeX code with Emacs.
>
> One possible remedy would be to use w3m and switch on LaTeX mode when

To be more precise "the Emacs interface to w3m" (or whatever other Emacs
browser might be available).

> editing textareas.  I have tried this, and the straightforward way did
> not work (that is, the w3m information did get lost when I did M-x
> latex-mode).  Does anyone know if such a feature is easily possible?
>
> Thank you very much,
>
> Nicolas


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
  2008-09-29 12:00 ` Nicolas Neuss
@ 2008-09-29 13:43 ` Paul R
       [not found] ` <mailman.20151.1222695852.18990.help-gnu-emacs@gnu.org>
                   ` (5 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Paul R @ 2008-09-29 13:43 UTC (permalink / raw
  To: Nicolas Neuss; +Cc: help-gnu-emacs

On Mon, 29 Sep 2008 13:56:15 +0200, Nicolas Neuss <lastname@math.uni-karlsruhe.de> said:

Nicolas> One possible remedy would be to use w3m and switch on LaTeX
Nicolas> mode when editing textareas. I have tried this, and the
Nicolas> straightforward way did not work (that is, the w3m
Nicolas> information did get lost when I did M-x latex-mode). Does
Nicolas> anyone know if such a feature is easily possible?

I guess you'll have to edit your LaTeX code in a temporary LaTeX-mode
buffer then paste it back to your browser text box.

-- 
  Paul




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
       [not found] ` <mailman.20151.1222695852.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 14:27   ` Andreas Politz
  0 siblings, 0 replies; 12+ messages in thread
From: Andreas Politz @ 2008-09-29 14:27 UTC (permalink / raw
  To: help-gnu-emacs

Paul R wrote:
> On Mon, 29 Sep 2008 13:56:15 +0200, Nicolas Neuss <lastname@math.uni-karlsruhe.de> said:
> 
> Nicolas> One possible remedy would be to use w3m and switch on LaTeX
> Nicolas> mode when editing textareas. I have tried this, and the
> Nicolas> straightforward way did not work (that is, the w3m
> Nicolas> information did get lost when I did M-x latex-mode). Does
> Nicolas> anyone know if such a feature is easily possible?
> 
> I guess you'll have to edit your LaTeX code in a temporary LaTeX-mode
> buffer then paste it back to your browser text box.
> 


Or try the indirect buffer feature. Something like this :

(defun edit-latex (start end)
   (interactive "r")
   (switch-to-buffer
    (make-indirect-buffer (current-buffer) "*edit-latex*" t))
   (narrow-to-region start end)
   (toggle-read-only -1)
   (latex-mode))

-ap


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
                   ` (2 preceding siblings ...)
       [not found] ` <mailman.20151.1222695852.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 15:09 ` Drew Adams
       [not found] ` <mailman.20157.1222700981.18990.help-gnu-emacs@gnu.org>
                   ` (3 subsequent siblings)
  7 siblings, 0 replies; 12+ messages in thread
From: Drew Adams @ 2008-09-29 15:09 UTC (permalink / raw
  To: 'Nicolas Neuss', help-gnu-emacs

> I have a web server which renders small LaTeX snippets as PDF 
> or HTML/GIF. The LaTeX snippets can be edited via a browser as 
> HTML-textarea fields. However, using standard browsers I miss
> the LaTeX-editing features I have
> available when editing LaTeX code with Emacs.
> 
> One possible remedy would be to use w3m and switch on LaTeX mode when
> editing textareas.  I have tried this, and the 
> straightforward way did not
> work (that is, the w3m information did get lost when I did 
> M-x latex-mode).
> Does anyone know if such a feature is easily possible?

This is probably no help, but isn't there a way to open an editor (e.g. the
value of $EDITOR) from a Web browser for such a text area? If there is, then you
should be able to use emacsclient (or gnuclient) to do that editing with Emacs.

That's one of the things emacsclient is for: to let you open Emacs from some
other app. Dunno if Web browsers let you do that easily, though.





^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
       [not found] ` <mailman.20157.1222700981.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 16:07   ` Richard Riley
  2008-09-29 18:22     ` Drew Adams
       [not found]     ` <mailman.20173.1222712592.18990.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 12+ messages in thread
From: Richard Riley @ 2008-09-29 16:07 UTC (permalink / raw
  To: help-gnu-emacs

"Drew Adams" <drew.adams@oracle.com> writes:

>> I have a web server which renders small LaTeX snippets as PDF 
>> or HTML/GIF. The LaTeX snippets can be edited via a browser as 
>> HTML-textarea fields. However, using standard browsers I miss
>> the LaTeX-editing features I have
>> available when editing LaTeX code with Emacs.
>> 
>> One possible remedy would be to use w3m and switch on LaTeX mode when
>> editing textareas.  I have tried this, and the 
>> straightforward way did not
>> work (that is, the w3m information did get lost when I did 
>> M-x latex-mode).
>> Does anyone know if such a feature is easily possible?
>
> This is probably no help, but isn't there a way to open an editor (e.g. the
> value of $EDITOR) from a Web browser for such a text area? If there is, then you
> should be able to use emacsclient (or gnuclient) to do that editing with Emacs.
>
> That's one of the things emacsclient is for: to let you open Emacs from some
> other app. Dunno if Web browsers let you do that easily, though.

Firefox does.

Look into using : https://addons.mozilla.org/en-US/firefox/addon/4125


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
                   ` (4 preceding siblings ...)
       [not found] ` <mailman.20157.1222700981.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 16:16 ` Bastien
  2008-09-29 16:36 ` Raj Shekhar
       [not found] ` <mailman.20162.1222705005.18990.help-gnu-emacs@gnu.org>
  7 siblings, 0 replies; 12+ messages in thread
From: Bastien @ 2008-09-29 16:16 UTC (permalink / raw
  To: help-gnu-emacs

Nicolas Neuss <lastname@math.uni-karlsruhe.de> writes:

> One possible remedy would be to use w3m and switch on LaTeX mode when
> editing textareas.  I have tried this, and the straightforward way did not
> work (that is, the w3m information did get lost when I did M-x latex-mode).
> Does anyone know if such a feature is easily possible?

(setq w3m-form-textarea-edit-mode 'latex-mode)

-- 
Bastien




^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
                   ` (5 preceding siblings ...)
  2008-09-29 16:16 ` Bastien
@ 2008-09-29 16:36 ` Raj Shekhar
       [not found] ` <mailman.20162.1222705005.18990.help-gnu-emacs@gnu.org>
  7 siblings, 0 replies; 12+ messages in thread
From: Raj Shekhar @ 2008-09-29 16:36 UTC (permalink / raw
  To: help-gnu-emacs

In infinite wisdom Nicolas Neuss <lastname@math.uni-karlsruhe.de> spoke thus:

> I have a web server which renders small LaTeX snippets as PDF or HTML/GIF.
> The LaTeX snippets can be edited via a browser as HTML-textarea fields.
> However, using standard browsers I miss the LaTeX-editing features I have
> available when editing LaTeX code with Emacs.

If you use Firefox, check out the mozex extension
<http://mozex.mozdev.org/development.html> It allows you to open
textarea in emacs.  Install and check out its preferences to set your
editor.

-- 
raj shekhar
facts: http://rajshekhar.net
opinions: http://rajshekhar.net/blog
I've never made anyone's life easier and you know it!



^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
       [not found] ` <mailman.20162.1222705005.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 17:25   ` Nicolas Neuss
  0 siblings, 0 replies; 12+ messages in thread
From: Nicolas Neuss @ 2008-09-29 17:25 UTC (permalink / raw
  To: help-gnu-emacs

Bastien <bastienguerry@googlemail.com> writes:

> (setq w3m-form-textarea-edit-mode 'latex-mode)

Wow!  I guess this is the easiest way, although the other suggestions are
interesting as well!

Thank you all for the very useful feedback,

Nicolas


^ permalink raw reply	[flat|nested] 12+ messages in thread

* RE: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 16:07   ` Richard Riley
@ 2008-09-29 18:22     ` Drew Adams
       [not found]     ` <mailman.20173.1222712592.18990.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 12+ messages in thread
From: Drew Adams @ 2008-09-29 18:22 UTC (permalink / raw
  To: 'Richard Riley', help-gnu-emacs

> > This is probably no help, but isn't there a way to open an 
> > editor (e.g. the value of $EDITOR) from a Web browser for such
> > a text area? If there is, then you should be able to use
> > emacsclient (or gnuclient) to do that editing with Emacs.
> >
> > That's one of the things emacsclient is for: to let you 
> > open Emacs from some other app. Dunno if Web browsers let you
> > do that easily, though.
> 
> Firefox does.
> Look into using : https://addons.mozilla.org/en-US/firefox/addon/4125

Yes, thanks for the link; works fine. Makes Firefox pop up an Emacs window (via
emacsclient) whenever you use an HTML text area. Just use `C-x #' to send the
edited text back to the browser.





^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
       [not found]     ` <mailman.20173.1222712592.18990.help-gnu-emacs@gnu.org>
@ 2008-09-29 18:37       ` Richard Riley
  2008-10-02 13:24         ` Christian Herenz
  0 siblings, 1 reply; 12+ messages in thread
From: Richard Riley @ 2008-09-29 18:37 UTC (permalink / raw
  To: help-gnu-emacs

"Drew Adams" <drew.adams@oracle.com> writes:

>> > This is probably no help, but isn't there a way to open an 
>> > editor (e.g. the value of $EDITOR) from a Web browser for such
>> > a text area? If there is, then you should be able to use
>> > emacsclient (or gnuclient) to do that editing with Emacs.
>> >
>> > That's one of the things emacsclient is for: to let you 
>> > open Emacs from some other app. Dunno if Web browsers let you
>> > do that easily, though.
>> 
>> Firefox does.
>> Look into using : https://addons.mozilla.org/en-US/firefox/addon/4125
>
> Yes, thanks for the link; works fine. Makes Firefox pop up an Emacs window (via
> emacsclient) whenever you use an HTML text area. Just use `C-x #' to send the
> edited text back to the browser.

Linux users (X) might be interested in this little script which I call
from the extension above:

,----
| wmctrl -a emacs
| source ~/bin/emacs.bash
| edit $1
`----

wmctrl brings emacs to the foreground and the emacs.bash is a copy of
the bash script which defines edit() to use emacs client or start emacs
as appropriate. Edit as appropriate.

Caveat : When using with gmail for example set gmail up to use "basic
html" or it wont work.


 


^ permalink raw reply	[flat|nested] 12+ messages in thread

* Re: LaTeX-editing TEXTAREAs using w3m?
  2008-09-29 18:37       ` Richard Riley
@ 2008-10-02 13:24         ` Christian Herenz
  0 siblings, 0 replies; 12+ messages in thread
From: Christian Herenz @ 2008-10-02 13:24 UTC (permalink / raw
  To: help-gnu-emacs

Richard Riley schrieb:

> ,----
> | wmctrl -a emacs
> | source ~/bin/emacs.bash
> | edit $1
> `----
> 
> wmctrl brings emacs to the foreground and the emacs.bash is a copy of
> the bash script which defines edit() to use emacs client or start emacs
> as appropriate. Edit as appropriate.
> 

But wmctrl is not installed as default, at least on this machine here?

Greets,
Christian


^ permalink raw reply	[flat|nested] 12+ messages in thread

end of thread, other threads:[~2008-10-02 13:24 UTC | newest]

Thread overview: 12+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-09-29 11:56 LaTeX-editing TEXTAREAs using w3m? Nicolas Neuss
2008-09-29 12:00 ` Nicolas Neuss
2008-09-29 13:43 ` Paul R
     [not found] ` <mailman.20151.1222695852.18990.help-gnu-emacs@gnu.org>
2008-09-29 14:27   ` Andreas Politz
2008-09-29 15:09 ` Drew Adams
     [not found] ` <mailman.20157.1222700981.18990.help-gnu-emacs@gnu.org>
2008-09-29 16:07   ` Richard Riley
2008-09-29 18:22     ` Drew Adams
     [not found]     ` <mailman.20173.1222712592.18990.help-gnu-emacs@gnu.org>
2008-09-29 18:37       ` Richard Riley
2008-10-02 13:24         ` Christian Herenz
2008-09-29 16:16 ` Bastien
2008-09-29 16:36 ` Raj Shekhar
     [not found] ` <mailman.20162.1222705005.18990.help-gnu-emacs@gnu.org>
2008-09-29 17:25   ` Nicolas Neuss

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.