Gnus development mailing list
 help / color / mirror / Atom feed
* Writing enriched text
@ 1999-04-20 20:55 François Pinard
  1999-04-20 21:26 ` Colin Rafferty
  1999-04-21  7:26 ` Writing enriched text Kai.Grossjohann
  0 siblings, 2 replies; 47+ messages in thread
From: François Pinard @ 1999-04-20 20:55 UTC (permalink / raw)


Hi, people.

This is an old wish of mine, maybe some of you has a ready solution for me?
What is the easiest way to write an text/enriched message, using Gnus?
Please take me by the hand and explain me how to proceed! :-)

-- 
François Pinard                            mailto:pinard@iro.umontreal.ca
Join the free Translation Project!    http://www.iro.umontreal.ca/~pinard



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

* Re: Writing enriched text
  1999-04-20 20:55 Writing enriched text François Pinard
@ 1999-04-20 21:26 ` Colin Rafferty
  1999-04-20 21:43   ` Hrvoje Niksic
                     ` (4 more replies)
  1999-04-21  7:26 ` Writing enriched text Kai.Grossjohann
  1 sibling, 5 replies; 47+ messages in thread
From: Colin Rafferty @ 1999-04-20 21:26 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 103 bytes --]

François Pinard writes:

> What is the easiest way to write an text/enriched message, using Gnus?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/enriched, Size: 246 bytes --]

I'm note sure <bold>how</bold> to do it easily.  I
<italic>think</italic> that it would be similar to writing html by
hand, which is
<x-bg-color><param>DarkSlateGray</param><x-color><param>violet</param>hard</x-color></x-bg-color>, 
but doable.


[-- Attachment #3: Type: text/plain, Size: 174 bytes --]


> Please take me by the hand and explain me how to proceed! :-)

Maybe take a look at etc/enriched.doc without letting it get parsed.
Then do some cut and paste.

-- 
Colin

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

* Re: Writing enriched text
  1999-04-20 21:26 ` Colin Rafferty
@ 1999-04-20 21:43   ` Hrvoje Niksic
  1999-04-20 21:44   ` François Pinard
                     ` (3 subsequent siblings)
  4 siblings, 0 replies; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-20 21:43 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> writes:

> François Pinard writes:
> 
> > What is the easiest way to write an text/enriched message, using Gnus?
> 
> I'm note sure how to do it easily.  I think that it would be similar
> to writing html by hand, which is hard, but doable.

I'm almost positive that enriched mode has facilities for converting
text properties (e.g. those created by facemenu.el) to enriched.  Gnus
could even use it automatically if it detects text properties of that
kind in the message.


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

* Re: Writing enriched text
  1999-04-20 21:26 ` Colin Rafferty
  1999-04-20 21:43   ` Hrvoje Niksic
@ 1999-04-20 21:44   ` François Pinard
  1999-04-21 13:49     ` Colin Rafferty
  1999-04-20 21:52   ` David Hedbor
                     ` (2 subsequent siblings)
  4 siblings, 1 reply; 47+ messages in thread
From: François Pinard @ 1999-04-20 21:44 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> écrit:

> François Pinard writes:

> > What is the easiest way to write an text/enriched message, using Gnus?

> I'm note sure how to do it easily.  I think that it would be similar
> to writing html by hand, which is hard, but doable.

Emacs already gives me tools for editing an enriched buffer (as per
`enriched.doc' which you mentioned).  So, I was at least intending to use
this; it should be easier than directly writing HTML.  Sending enriched
messages would be a good opportunity for me to acquire more familiarity
with the tools.

> > Please take me by the hand and explain me how to proceed! :-)

> Maybe take a look at etc/enriched.doc without letting it get parsed.
> Then do some cut and paste.

OK, granted, but which type of glue should I use?  More specifically, how
do I take care of the MML thing?  I never did anything more sophisticated
than using `C-c C-a'.  How did you do it on your side for the message you
sent, Colin?  What did you write exactly?

-- 
François Pinard                            mailto:pinard@iro.umontreal.ca
Join the free Translation Project!    http://www.iro.umontreal.ca/~pinard



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

* Re: Writing enriched text
  1999-04-20 21:26 ` Colin Rafferty
  1999-04-20 21:43   ` Hrvoje Niksic
  1999-04-20 21:44   ` François Pinard
@ 1999-04-20 21:52   ` David Hedbor
  1999-04-20 22:42     ` Hrvoje Niksic
  1999-04-21  0:04   ` enriched bug (was Re: Writing enriched text) Stainless Steel Rat
  1999-04-22  7:52   ` Can't read this! " Jaap-Henk Hoepman
  4 siblings, 1 reply; 47+ messages in thread
From: David Hedbor @ 1999-04-20 21:52 UTC (permalink / raw)



Hmm. I had to load facemenu explicitly to display your message (or
it stopped on a facemenu function not being found). 

-- 
[ Below is a random fortune, which is unrelated to the above message. ]
travel, n.:
	Something that makes you feel like you're getting somewhere.



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

* Re: Writing enriched text
  1999-04-20 21:52   ` David Hedbor
@ 1999-04-20 22:42     ` Hrvoje Niksic
  1999-04-20 23:08       ` Bruce Stephens
  0 siblings, 1 reply; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-20 22:42 UTC (permalink / raw)


David Hedbor <david@hedbor.org> writes:

> Hmm. I had to load facemenu explicitly to display your message (or
> it stopped on a facemenu function not being found).

This means that facemenu is not getting correctly autoloaded in your
XEmacs.  It works right for me in XEmacs 21.2.


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

* Re: Writing enriched text
  1999-04-20 22:42     ` Hrvoje Niksic
@ 1999-04-20 23:08       ` Bruce Stephens
  1999-04-20 23:20         ` David Hedbor
  0 siblings, 1 reply; 47+ messages in thread
From: Bruce Stephens @ 1999-04-20 23:08 UTC (permalink / raw)


Hrvoje Niksic <hniksic@srce.hr> writes:

> David Hedbor <david@hedbor.org> writes:
> 
> > Hmm. I had to load facemenu explicitly to display your message (or
> > it stopped on a facemenu function not being found).
> 
> This means that facemenu is not getting correctly autoloaded in your
> XEmacs.  It works right for me in XEmacs 21.2.

Hmm, worked all right for me in XEmacs 20.4.  Ah, in .emacs, I have:

        (autoload 'facemenu-get-face "facemenu")


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

* Re: Writing enriched text
  1999-04-20 23:08       ` Bruce Stephens
@ 1999-04-20 23:20         ` David Hedbor
  0 siblings, 0 replies; 47+ messages in thread
From: David Hedbor @ 1999-04-20 23:20 UTC (permalink / raw)


Bruce Stephens <bruce@cenderis.demon.co.uk> writes:

> Hrvoje Niksic <hniksic@srce.hr> writes:
> 
> > David Hedbor <david@hedbor.org> writes:
> > 
> > > Hmm. I had to load facemenu explicitly to display your message (or
> > > it stopped on a facemenu function not being found).
> > 
> > This means that facemenu is not getting correctly autoloaded in your
> > XEmacs.  It works right for me in XEmacs 21.2.
> 
> Hmm, worked all right for me in XEmacs 20.4.  Ah, in .emacs, I have:
> 
>         (autoload 'facemenu-get-face "facemenu")

That is the function that wasn't found, indeed. I added a (require
'facemenu) to .gnus.el instead.

-- 
[ Below is a random fortune, which is unrelated to the above message. ]
Help!  I'm trapped in a Chinese computer factory!



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

* enriched bug (was Re: Writing enriched text)
  1999-04-20 21:26 ` Colin Rafferty
                     ` (2 preceding siblings ...)
  1999-04-20 21:52   ` David Hedbor
@ 1999-04-21  0:04   ` Stainless Steel Rat
  1999-04-21  0:08     ` Hrvoje Niksic
  1999-04-22  7:52   ` Can't read this! " Jaap-Henk Hoepman
  4 siblings, 1 reply; 47+ messages in thread
From: Stainless Steel Rat @ 1999-04-21  0:04 UTC (permalink / raw)


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

When I try to read Colin's message I get this backtrace (trimmed
extensively):

Signaling: (void-function facemenu-get-face)
  facemenu-get-face(fg:violet)
  enriched-decode-foreground(104 108 "violet")
  apply(enriched-decode-foreground 104 108 "violet")

This is with Pterodactyl Gnus 0.83, XEmacs 20.4 compiled with every --with
option that can be set 'no' set 'no'.
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v0.9.5 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE3HRYFgl+vIlSVSNkRAsEWAKDx8IJSlmzwY53pnOlNZd4/1AuHowCg8EtO
CQYLuXnQEH0ar4uh3tl9KCo=
=qjq/
-----END PGP SIGNATURE-----

-- 
Rat <ratinox@peorth.gweep.net>    \ Warning: pregnant women, the elderly, and
Minion of Nathan - Nathan says Hi! \ children under 10 should avoid prolonged
PGP Key: at a key server near you!  \ exposure to Happy Fun Ball.


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

* Re: enriched bug (was Re: Writing enriched text)
  1999-04-21  0:04   ` enriched bug (was Re: Writing enriched text) Stainless Steel Rat
@ 1999-04-21  0:08     ` Hrvoje Niksic
  0 siblings, 0 replies; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-21  0:08 UTC (permalink / raw)


Stainless Steel Rat <ratinox@peorth.gweep.net> writes:

> When I try to read Colin's message I get this backtrace (trimmed
> extensively):
> 
> Signaling: (void-function facemenu-get-face)
>   facemenu-get-face(fg:violet)
>   enriched-decode-foreground(104 108 "violet")
>   apply(enriched-decode-foreground 104 108 "violet")
> 
> This is with Pterodactyl Gnus 0.83, XEmacs 20.4 compiled with every
> --with option that can be set 'no' set 'no'.

It's a bug in XEmacs 20.4.  To work around it, you need to add
something like:

    (autoload 'facemenu-get-face "facemenu")

to your .emacs.


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

* Re: Writing enriched text
  1999-04-20 20:55 Writing enriched text François Pinard
  1999-04-20 21:26 ` Colin Rafferty
@ 1999-04-21  7:26 ` Kai.Grossjohann
  1999-04-21 12:48   ` William M. Perry
  1999-04-24 15:17   ` François Pinard
  1 sibling, 2 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-21  7:26 UTC (permalink / raw)


François Pinard <pinard@iro.umontreal.ca> writes:

  > This is an old wish of mine, maybe some of you has a ready
  > solution for me?  What is the easiest way to write an
  > text/enriched message, using Gnus?  Please take me by the hand and
  > explain me how to proceed! :-)

Never thought about it.  Maybe M-x make-indirect-buffer RET is part of
the solution?  (After narrowing the message buffer to the body.)

Hm.  That wouldn't work.  Hm.  Enriched-mode adds a Content-type
header to the start of the text, which would then appear in the actual
text in the message.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
  1999-04-21  7:26 ` Writing enriched text Kai.Grossjohann
@ 1999-04-21 12:48   ` William M. Perry
  1999-04-21 13:43     ` Laura Conrad
                       ` (2 more replies)
  1999-04-24 15:17   ` François Pinard
  1 sibling, 3 replies; 47+ messages in thread
From: William M. Perry @ 1999-04-21 12:48 UTC (permalink / raw)
  Cc: ding

Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> François Pinard <pinard@iro.umontreal.ca> writes:
> 
>   > This is an old wish of mine, maybe some of you has a ready
>   > solution for me?  What is the easiest way to write an
>   > text/enriched message, using Gnus?  Please take me by the hand and
>   > explain me how to proceed! :-)
> 
> Never thought about it.  Maybe M-x make-indirect-buffer RET is part of
> the solution?  (After narrowing the message buffer to the body.)
> 
> Hm.  That wouldn't work.  Hm.  Enriched-mode adds a Content-type
> header to the start of the text, which would then appear in the actual
> text in the message.

What we really need is an html and/or enriched-text minor mode.  Or just
have message-mode smart enough to use 'htmlify.el' if it detects text
properties other than MML ones after mail-header-separator.

You would of course want this configurable, similar to how netscape lets
you do it:

1. Always send only HTML email
2. Never send HTML email
3. Always send HTML with text/plain alternative
4. Ask the user

-Bill P.


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

* Re: Writing enriched text
  1999-04-21 12:48   ` William M. Perry
@ 1999-04-21 13:43     ` Laura Conrad
  1999-04-21 13:45     ` Kai.Grossjohann
       [not found]     ` <knn202ks3v.fsf@concord.com>
  2 siblings, 0 replies; 47+ messages in thread
From: Laura Conrad @ 1999-04-21 13:43 UTC (permalink / raw)


wmperry@aventail.com (William M. Perry) writes:

> You would of course want this configurable, similar to how netscape lets
> you do it:
> 
> 1. Always send only HTML email
> 2. Never send HTML email
> 3. Always send HTML with text/plain alternative
> 4. Ask the user

But, unlike netscape, we would NOT make 3 the default.  

I assume we would also set up some configuration variable so that
users could vary this by group or to-address or whatever.

-- 
Laura (mailto:lconrad@world.std.com , http://www.world.std.com/~lconrad/ )
(617) 661-8097	 
233 Broadway, Cambridge, MA 02139


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

* Re: Writing enriched text
  1999-04-21 12:48   ` William M. Perry
  1999-04-21 13:43     ` Laura Conrad
@ 1999-04-21 13:45     ` Kai.Grossjohann
  1999-04-21 15:03       ` Alan Shutko
  1999-04-21 19:08       ` Lars Magne Ingebrigtsen
       [not found]     ` <knn202ks3v.fsf@concord.com>
  2 siblings, 2 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-21 13:45 UTC (permalink / raw)


wmperry@aventail.com (William M. Perry) writes:

  > What we really need is an html and/or enriched-text minor mode.

Is this sufficient?  Suppose people are composing multipart messages
where several parts should be edited using such special modes.  RMS
wants Emacs to go more into the WYSYWYG direction, so we can expect
stuff like this to happen more often.

So, what we need is a way to edit a buffer using some special mode.
When editing in that mode is finished, the internal representation
needs to be transformed to the storage form (format-alist?) which
would then be included in the message.

Or, we need a way to dissect a buffer into areas each of which is
edited in a different mode.  OLE, anyone?

Am I misunderstanding something?  I'm not saying all of this should
work right now, but the basic machinery could be there to be used with
enriched-mode now (and maybe htmlify) and other stuff could be plugged
in later.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
  1999-04-20 21:44   ` François Pinard
@ 1999-04-21 13:49     ` Colin Rafferty
  1999-04-21 14:09       ` Kai.Grossjohann
  0 siblings, 1 reply; 47+ messages in thread
From: Colin Rafferty @ 1999-04-21 13:49 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 423 bytes --]

François Pinard writes:
> Colin Rafferty <craffert@ms.com> écrit:
>> François Pinard writes:

>> > What is the easiest way to write an text/enriched message, using Gnus?

>> I'm note sure how to do it easily.  I think that it would be similar
>> to writing html by hand, which is hard, but doable.

> Emacs already gives me tools for editing an enriched buffer (as per
> `enriched.doc' which you mentioned).  


[-- Attachment #2.1: Type: text/plain, Size: 97 bytes --]

Where are these tools?  I can only see how to display something.
Where is `enriched-edit-mode'?


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2.2: Type: text/enriched, Size: 112 bytes --]

Where are these tools?  I can only see how to display something.
Where is <italic>enriched-edit-mode</italic>?


[-- Attachment #3: Type: text/plain, Size: 695 bytes --]


>> > Please take me by the hand and explain me how to proceed! :-)

>> Maybe take a look at etc/enriched.doc without letting it get parsed.
>> Then do some cut and paste.

> I never did anything more sophisticated than using `C-c C-a'.  How
> did you do it on your side for the message you sent, Colin?  

The `part' tag I created by guess-work, and the contents I created
by looking at etc/enriched.doc in an xterm (since XEmacs automatically 
converts it (how do I look at the encoded enriched.doc in XEmacs?)).

> What did you write exactly?

Fortunately, I never delete buffers.  I just went to that old message
buffer, and hit `C-x u'.

Here is exactly what I had before I hit `C-c C-c':


[-- Attachment #4: Document just before hitting C-c C-c --]
[-- Type: text/plain, Size: 769 bytes --]

To: GNUS Mailing List <ding@gnus.org>
Subject: Re: Writing enriched text
Mail-Copies-To: never
X-Attribution: >
References: <oqlnfnqaf2.fsf@titan.progiciels-bpi.ca>
.
François Pinard writes:

> What is the easiest way to write an text/enriched message, using Gnus?

<#part type=text/enriched disposition=inline>

I'm note sure <bold>how</bold> to do it easily.  I
<italic>think</italic> that it would be similar to writing html by
hand, which is
<x-bg-color><param>DarkSlateGray</param><x-color><param>violet</param>hard</x-color></x-bg-color>, 
but doable.

<#/part>

> Please take me by the hand and explain me how to proceed! :-)

Maybe take a look at etc/enriched.doc without letting it get parsed.
Then do some cut and paste.

-- 
Colin

[-- Attachment #5: Type: text/plain, Size: 11 bytes --]


-- 
Colin

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

* Re: Writing enriched text
  1999-04-21 13:49     ` Colin Rafferty
@ 1999-04-21 14:09       ` Kai.Grossjohann
  1999-04-21 14:43         ` Colin Rafferty
  0 siblings, 1 reply; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-21 14:09 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> writes:

  > François Pinard writes:
  > 
  > > Emacs already gives me tools for editing an enriched buffer (as per
  > > `enriched.doc' which you mentioned).  
  > 
  > Where are these tools?  I can only see how to display something.
  > Where is `enriched-edit-mode'?

You type C-x C-f /tmp/foo RET.  You then type M-x enriched-mode RET.
You then change text properties by marking a region then using
C-down-mouse-2 (the `Text Properties' menu, M-g is an alternative) to
make words bold, say.  You then say C-x C-s.

The resulting file /tmp/foo will contain text/enriched tags.

The editing support is C-down-mouse-2.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
       [not found]     ` <knn202ks3v.fsf@concord.com>
@ 1999-04-21 14:22       ` William M. Perry
  0 siblings, 0 replies; 47+ messages in thread
From: William M. Perry @ 1999-04-21 14:22 UTC (permalink / raw)
  Cc: ding

Laura Conrad <lconrad@concord.com> writes:

> wmperry@aventail.com (William M. Perry) writes:
> 
> > You would of course want this configurable, similar to how netscape lets
> > you do it:
> > 
> > 1. Always send only HTML email
> > 2. Never send HTML email
> > 3. Always send HTML with text/plain alternative
> > 4. Ask the user
> 
> But, unlike netscape, we would NOT make 3 the default.  
> 
> I assume we would also set up some configuration variable so that
> users could vary this by group or to-address or whatever.

Could be done via a posting-style type variable, or a group property.  You
could have something like 

(defcustom message-html-posting-style 'ask
  "*Controls how and when to post HTML email."
  :group 'message
  :type '(choice (const :tag "Ask when necessary" ask)
                 (const :tag "Always send only HTML" html)
                 (const :tag "Always send HTML and plain text" both)
                 (const :tag "Never send HTML" never)
                 (sexp  :tag "Custom function" nil)))

-Bill P.


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

* Re: Writing enriched text
  1999-04-21 14:09       ` Kai.Grossjohann
@ 1999-04-21 14:43         ` Colin Rafferty
  1999-04-22 15:04           ` Kai.Grossjohann
                             ` (2 more replies)
  0 siblings, 3 replies; 47+ messages in thread
From: Colin Rafferty @ 1999-04-21 14:43 UTC (permalink / raw)


Kai Grossjohann writes:
> Colin Rafferty <craffert@ms.com> writes:
>> François Pinard writes:
>> 
>> > Emacs already gives me tools for editing an enriched buffer (as per
>> > `enriched.doc' which you mentioned).  
>> 
>> Where are these tools?  I can only see how to display something.
>> Where is `enriched-edit-mode'?

> You type C-x C-f /tmp/foo RET.  You then type M-x enriched-mode RET.
> You then change text properties by marking a region then using
> C-down-mouse-2 (the `Text Properties' menu, M-g is an alternative) to
> make words bold, say.  You then say C-x C-s.

I see the light.  This is an Emacs thing.  Or at least, Emacs
bindings.

The enriched-mode things works, but it is a pain in the ass doing all
the text-properties by hand.

-- 
Colin


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

* Re: Writing enriched text
  1999-04-21 13:45     ` Kai.Grossjohann
@ 1999-04-21 15:03       ` Alan Shutko
  1999-04-21 17:29         ` Oscar Figueiredo
  1999-04-21 19:08       ` Lars Magne Ingebrigtsen
  1 sibling, 1 reply; 47+ messages in thread
From: Alan Shutko @ 1999-04-21 15:03 UTC (permalink / raw)
  Cc: ding

Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> Or, we need a way to dissect a buffer into areas each of which is
> edited in a different mode.  OLE, anyone?


We _definately_ need this.  This would make help writing javascript in
html, yacc, lex, web, and tons of other places.  If you figure out how
to do this....

-- 
Alan Shutko <ats@acm.org> - By consent of the corrupted
You will wish you hadn't.


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

* Re: Writing enriched text
  1999-04-21 15:03       ` Alan Shutko
@ 1999-04-21 17:29         ` Oscar Figueiredo
  1999-04-21 17:51           ` William M. Perry
  1999-04-22 15:01           ` Kai.Grossjohann
  0 siblings, 2 replies; 47+ messages in thread
From: Oscar Figueiredo @ 1999-04-21 17:29 UTC (permalink / raw)


>>>>> "Alan" == Alan Shutko <ats@acm.org> writes:

  Alan> Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
  >> Or, we need a way to dissect a buffer into areas each of which is
  >> edited in a different mode.  OLE, anyone?

  Alan> We _definately_ need this.  This would make help writing javascript in
  Alan> html, yacc, lex, web, and tons of other places.  If you figure out how
  Alan> to do this....

This has been more or less done already though not exactly as you would expect:
look for "indirect buffers" in Emacs 20.something and XEmacs 21.2

>From the XEmacs 21.2 NEWS file:

** You can now create "indirect buffers", like in GNU Emacs.  An
indirect buffer shares its text with another buffer ("base buffer"),
but has its own major mode, local variables, extents, and narrowing.
An indirect buffer has a name of its own, distinct from those of the
base buffer and all other buffers.  An indirect buffer cannot itself
be visiting a file (though its base buffer can be).  The base buffer
cannot itself be indirect.

Use (make-indirect-buffer BASE-BUFFER NAME) to make an indirect buffer
named NAME whose base is BASE-BUFFER.  If BASE-BUFFER is an indirect
buffer, its base buffer is used as the base for the new buffer.

You can make an indirect buffer current, or switch to it in a window,
just as you would a non-indirect buffer.

The function `buffer-base-buffer', given an indirect buffer, returns
its base buffer.  It returns nil when given an ordinary buffer (not
indirect).  `buffer-indirect-children' returns a list of the indirect
children of a base buffer.

Oscar


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

* Re: Writing enriched text
  1999-04-21 17:29         ` Oscar Figueiredo
@ 1999-04-21 17:51           ` William M. Perry
  1999-04-22 15:01           ` Kai.Grossjohann
  1 sibling, 0 replies; 47+ messages in thread
From: William M. Perry @ 1999-04-21 17:51 UTC (permalink / raw)
  Cc: ding

Oscar Figueiredo <Oscar.Figueiredo@di.epfl.ch> writes:

> >>>>> "Alan" == Alan Shutko <ats@acm.org> writes:
> 
>   Alan> Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
>   >> Or, we need a way to dissect a buffer into areas each of which is
>   >> edited in a different mode.  OLE, anyone?
> 
>   Alan> We _definately_ need this.  This would make help writing javascript in
>   Alan> html, yacc, lex, web, and tons of other places.  If you figure out how
>   Alan> to do this....
> 
> This has been more or less done already though not exactly as you would
> expect: look for "indirect buffers" in Emacs 20.something and XEmacs 21.2

What would be ideal is if you could change the syntax table and keymaps in
an extent/text property region.  I know you can do this for keymaps, but I
don't think you can durrently to it for syntax tables.

Then instead of an indirect _buffer_, you would have a region of the buffer
that would in effect be in 'sgml-mode' or 'enriched-mode'.  But you would
still really want the bindings of 'message-mode' to be in effect, so this
points to using minor modes instead of mixing major ones... hmmmm :(

We just need really studly minor mode versions of sgml-mode and
enriched-mode that integrate really well with mail-mode or message-mode.

-Bill P.


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

* Re: Writing enriched text
  1999-04-21 13:45     ` Kai.Grossjohann
  1999-04-21 15:03       ` Alan Shutko
@ 1999-04-21 19:08       ` Lars Magne Ingebrigtsen
  1999-04-21 21:41         ` Hrvoje Niksic
  1 sibling, 1 reply; 47+ messages in thread
From: Lars Magne Ingebrigtsen @ 1999-04-21 19:08 UTC (permalink / raw)


Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> Or, we need a way to dissect a buffer into areas each of which is
> edited in a different mode.  OLE, anyone?

Yes, I think that would be useful.  HTML/JavaScript, for instance, or
text mode when editing doc strings in Elisp files, etc.

But the major modes are really, really, really buffer-based, and I
think that adding such a capability would be a major deal.  Minor
modes are easier to switch on/off when wandering around in the buffer, 
but re-implementing all major modes as minor modes would also be a
huge amount of work.

But if it could be done, it would be neat.

-- 
(domestic pets only, the antidote for overdose, milk.)
  larsi@gnus.org * Lars Magne Ingebrigtsen


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

* Re: Writing enriched text
  1999-04-21 19:08       ` Lars Magne Ingebrigtsen
@ 1999-04-21 21:41         ` Hrvoje Niksic
  1999-04-22  7:24           ` Colin Marquardt
                             ` (3 more replies)
  0 siblings, 4 replies; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-21 21:41 UTC (permalink / raw)


Lars Magne Ingebrigtsen <larsi@gnus.org> writes:

> But the major modes are really, really, really buffer-based, and I
> think that adding such a capability would be a major deal.

But couldn't mml setup a command that puts the user to a temporary
buffer, and have C-c C-c exit out of it with the proper conversions?
This sounds easy to implement and easy to use.

If you are feeling maximally gung, you can even implement it using
indirect buffers.


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

* Re: Writing enriched text
  1999-04-21 21:41         ` Hrvoje Niksic
@ 1999-04-22  7:24           ` Colin Marquardt
  1999-04-22  8:41             ` Hrvoje Niksic
  1999-04-22 15:37           ` Jan Vroonhof
                             ` (2 subsequent siblings)
  3 siblings, 1 reply; 47+ messages in thread
From: Colin Marquardt @ 1999-04-22  7:24 UTC (permalink / raw)


* Hrvoje Niksic <hniksic@srce.hr> writes:

> Lars Magne Ingebrigtsen <larsi@gnus.org> writes:
>> But the major modes are really, really, really buffer-based, and I
>> think that adding such a capability would be a major deal.

> But couldn't mml setup a command that puts the user to a temporary
> buffer, and have C-c C-c exit out of it with the proper conversions?
> This sounds easy to implement and easy to use.

> If you are feeling maximally gung, you can even implement it using
> indirect buffers.

What about:

 ;;; mmm.el --- Multiple Major Modes for XEmacs
 [...]
 ;;; Commentary:
 
 ;; This file implements a XEmacs lisp extension that allows multiple
 ;; major modes to co-exist in a single buffer. It's a workable, yet
 ;; imperfect, solution that basically supports key bindings and
 ;; font-lock in those regions with a secondary major mode. To
 ;; activate one secondary major mode, simply add a hook to the
 ;; primary major mode's hook.  For details, see defun
 ;; `mmm-activator'.

I remember seeing you comment positively on this, but haven't used it 
myself.

The example "secondary major mode" Gongquan Chen is providing is
 
 ;;; mmm-html.el --- Enabling CSS/Javascript/VBScript modes in HTML mode

Cheers,
  Colin

-- 
Colin Marquardt <colin.marquardt@gmx.de>


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

* Can't read this! (was Re: Writing enriched text)
  1999-04-20 21:26 ` Colin Rafferty
                     ` (3 preceding siblings ...)
  1999-04-21  0:04   ` enriched bug (was Re: Writing enriched text) Stainless Steel Rat
@ 1999-04-22  7:52   ` Jaap-Henk Hoepman
  1999-04-22  9:09     ` Lee Willis
  4 siblings, 1 reply; 47+ messages in thread
From: Jaap-Henk Hoepman @ 1999-04-22  7:52 UTC (permalink / raw)


On 20 Apr 1999 17:26:57 -0400 Colin Rafferty <craffert@ms.com> writes:
> François Pinard writes:
> 
> > What is the easiest way to write an text/enriched message, using Gnus?
> 

Trying to read Colin's message gives the following error (using pgnus 0.80)

  Loading enriched...
  Loading enriched...done
  Enriched: decoding document...
  Symbol's function definition is void: facemenu-get-face

And trying to include it in this followup does not include anything....

What gives,

Jaap-Henk

-- 
Jaap-Henk Hoepman             | Come sail your ships around me
Dept. of Computer Science     | And burn these bridges down
University of Twente          |       Nick Cave - "Ship Song"
Email: hoepman@cs.utwente.nl === WWW: www.cs.utwente.nl/~hoepman
Phone: +31 53 4893795 === Secr: +31 53 4893770 === Fax: +31 53 4894590
PGP ID: 0xF52E26DD  Fingerprint: 1AED DDEB C7F1 DBB3  0556 4732 4217 ABEF


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

* Re: Writing enriched text
  1999-04-22  7:24           ` Colin Marquardt
@ 1999-04-22  8:41             ` Hrvoje Niksic
  0 siblings, 0 replies; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-22  8:41 UTC (permalink / raw)


Colin Marquardt <colin.marquardt@gmx.de> writes:

> > If you are feeling maximally gung, you can even implement it using
> > indirect buffers.
> 
> What about:
> 
>  ;;; mmm.el --- Multiple Major Modes for XEmacs
[...]

Well, it's a cool hack, but I don't think you can quite use it for
"serious" major modes.


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

* Re: Can't read this! (was Re: Writing enriched text)
  1999-04-22  7:52   ` Can't read this! " Jaap-Henk Hoepman
@ 1999-04-22  9:09     ` Lee Willis
  1999-04-23 14:50       ` Justin Sheehy
  0 siblings, 1 reply; 47+ messages in thread
From: Lee Willis @ 1999-04-22  9:09 UTC (permalink / raw)


Jaap-Henk Hoepman <hoepman@cs.utwente.nl> writes:

> Trying to read Colin's message gives the following error (using pgnus 0.80)
> 
>   Loading enriched...
>   Loading enriched...done
>   Enriched: decoding document...
>   Symbol's function definition is void: facemenu-get-face
> 
> And trying to include it in this followup does not include anything....
> What gives,

It's a bug in Xemacs 20.4 apparently. I can't remember the work-around
but it has been posted to this list recently so you may like to check
the archives. I think it involves simply putting a require in your
.gnus.el but I can't remember what exactly you have to require :)

HTH
Lee.
-- 
I was doing object-oriented assembly at 1 year old ...  
For some reason my mom insists on calling it "Playing with blocks"


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

* Re: Writing enriched text
  1999-04-21 17:29         ` Oscar Figueiredo
  1999-04-21 17:51           ` William M. Perry
@ 1999-04-22 15:01           ` Kai.Grossjohann
  1999-04-23 20:39             ` François Pinard
  1999-04-25 18:17             ` Hrvoje Niksic
  1 sibling, 2 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-22 15:01 UTC (permalink / raw)


Oscar Figueiredo <Oscar.Figueiredo@di.epfl.ch> writes:

  > This has been more or less done already though not exactly as you
  > would expect: look for "indirect buffers" in Emacs 20.something
  > and XEmacs 21.2 [...]

I know about this, but I think it is not complete: what's missing is a
way to transform an enriched-mode buffer from the internal
representation to the text/enriched representation (i.e. replacing
face attributes with tags).  And vice versa, of course.

So, we would need a command which takes the contents of a <part>,
grinds it through the format-alist mechanism (or a similar one) and
presents the result in a new buffer.  The user may then edit and hit
C-c C-c, whereupon the format-list mechnism (or a similar one) takes
over again and the result is put between the <part>...</part> tags.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
  1999-04-21 14:43         ` Colin Rafferty
@ 1999-04-22 15:04           ` Kai.Grossjohann
  1999-04-22 15:24             ` Colin Rafferty
  1999-04-23 12:56             ` Hrvoje Niksic
  1999-04-22 15:55           ` Jan Vroonhof
       [not found]           ` <vaf676o7l3p.fsf@ramses.cs.uni-dortmund.de <byd80whcpl.fsf@bolzano.math.ethz.ch>
  2 siblings, 2 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-22 15:04 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> writes:

  > The enriched-mode things works, but it is a pain in the ass doing all
  > the text-properties by hand.

Oh, the wonders of `direct manipulation'...  But seriously, how should
Emacs know which words should be italic?

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
  1999-04-22 15:04           ` Kai.Grossjohann
@ 1999-04-22 15:24             ` Colin Rafferty
  1999-04-22 16:01               ` Kai.Grossjohann
  1999-04-23 12:56             ` Hrvoje Niksic
  1 sibling, 1 reply; 47+ messages in thread
From: Colin Rafferty @ 1999-04-22 15:24 UTC (permalink / raw)


[-- Attachment #1: Type: text/plain, Size: 291 bytes --]

Kai Grossjohann writes:
> Colin Rafferty <craffert@ms.com> writes:

>> The enriched-mode things works, but it is a pain in the ass doing all
>> the text-properties by hand.

> Oh, the wonders of `direct manipulation'...  But seriously, how should
> Emacs know which words should be italic?


[-- Attachment #2.1: Type: text/plain, Size: 265 bytes --]

My problem is that XEmacs doesn't have the menus to change the text
properties the way that FSF Emacs does.

In enriched-mode, an emacs just knows what is italicized and what is
not.  In the text/enriched, it looks like this: <italic>this is italic
text</italic>.


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2.2: Type: text/enriched, Size: 280 bytes --]

My problem is that XEmacs doesn't have the menus to change the text
properties the way that FSF Emacs does.


In enriched-mode, an emacs just knows what is italicized and what is
not.  In the text/enriched, it looks this: <<italic><italic>this is
italic text</italic><</italic>.


[-- Attachment #3: Type: text/plain, Size: 11 bytes --]


-- 
Colin

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

* Re: Writing enriched text
  1999-04-21 21:41         ` Hrvoje Niksic
  1999-04-22  7:24           ` Colin Marquardt
@ 1999-04-22 15:37           ` Jan Vroonhof
       [not found]           ` <k8z <byiuaohdim.fsf@bolzano.math.ethz.ch>
  1999-04-23 20:44           ` François Pinard
  3 siblings, 0 replies; 47+ messages in thread
From: Jan Vroonhof @ 1999-04-22 15:37 UTC (permalink / raw)


Colin Marquardt <colin.marquardt@gmx.de> writes:

>  ;;; mmm.el --- Multiple Major Modes for XEmacs
>  [...]
>  ;;; Commentary:

Do you have an URL for this?

Jan


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

* Re: Writing enriched text
  1999-04-21 14:43         ` Colin Rafferty
  1999-04-22 15:04           ` Kai.Grossjohann
@ 1999-04-22 15:55           ` Jan Vroonhof
       [not found]           ` <vaf676o7l3p.fsf@ramses.cs.uni-dortmund.de <byd80whcpl.fsf@bolzano.math.ethz.ch>
  2 siblings, 0 replies; 47+ messages in thread
From: Jan Vroonhof @ 1999-04-22 15:55 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> writes:

> 
> My problem is that XEmacs doesn't have the menus to change the text
> properties the way that FSF Emacs does.

It does. The autoloading seems to be a bit broken though.

(require 'facemenu)
(facemenu-update)

should give you an Edit->Text Properties menu

Jan


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

* Re: Writing enriched text
  1999-04-22 15:24             ` Colin Rafferty
@ 1999-04-22 16:01               ` Kai.Grossjohann
  0 siblings, 0 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-22 16:01 UTC (permalink / raw)


Colin Rafferty <craffert@ms.com> writes:

  > My problem is that XEmacs doesn't have the menus to change the text
  > properties the way that FSF Emacs does.

Oh, I see.  I don't use XEmacs, so I didn't know about this problem.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
       [not found]           ` <vaf676o7l3p.fsf@ramses.cs.uni-dortmund.de <byd80whcpl.fsf@bolzano.math.ethz.ch>
@ 1999-04-22 16:54             ` Colin Rafferty
  0 siblings, 0 replies; 47+ messages in thread
From: Colin Rafferty @ 1999-04-22 16:54 UTC (permalink / raw)


Jan Vroonhof writes:
> Colin Rafferty <craffert@ms.com> writes:

>> My problem is that XEmacs doesn't have the menus to change the text
>> properties the way that FSF Emacs does.

> It does. The autoloading seems to be a bit broken though.

> (require 'facemenu)
> (facemenu-update)

> should give you an Edit->Text Properties menu

Perfect.  Thanks.

-- 
Colin


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

* Re: Writing enriched text
       [not found]           ` <k8z <byiuaohdim.fsf@bolzano.math.ethz.ch>
@ 1999-04-23  7:42             ` Colin Marquardt
  0 siblings, 0 replies; 47+ messages in thread
From: Colin Marquardt @ 1999-04-23  7:42 UTC (permalink / raw)


* Jan Vroonhof <vroonhof@math.ethz.ch> writes:

> Colin Marquardt <colin.marquardt@gmx.de> writes:
>> ;;; mmm.el --- Multiple Major Modes for XEmacs
>> [...]
>> ;;; Commentary:

> Do you have an URL for this?

Yes, it's

 http://members.tripod.com/gchen2/xemacs/

Cheers,
 Colin

-- 
Colin Marquardt <colin.marquardt@gmx.de>


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

* Re: Writing enriched text
  1999-04-22 15:04           ` Kai.Grossjohann
  1999-04-22 15:24             ` Colin Rafferty
@ 1999-04-23 12:56             ` Hrvoje Niksic
  1999-04-23 13:25               ` Kai.Grossjohann
  1 sibling, 1 reply; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-23 12:56 UTC (permalink / raw)


Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> Colin Rafferty <craffert@ms.com> writes:
> 
>   > The enriched-mode things works, but it is a pain in the ass doing all
>   > the text-properties by hand.
> 
> Oh, the wonders of `direct manipulation'...  But seriously, how
> should Emacs know which words should be italic?

By examining text properties.


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

* Re: Writing enriched text
  1999-04-23 12:56             ` Hrvoje Niksic
@ 1999-04-23 13:25               ` Kai.Grossjohann
  1999-04-23 13:37                 ` Hrvoje Niksic
  0 siblings, 1 reply; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-23 13:25 UTC (permalink / raw)


Hrvoje Niksic <hniksic@srce.hr> writes:

  > Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
  > 
  > > Colin Rafferty <craffert@ms.com> writes:
  > > 
  > >   > The enriched-mode things works, but it is a pain in the ass doing all
  > >   > the text-properties by hand.
  > > 
  > > Oh, the wonders of `direct manipulation'...  But seriously, how
  > > should Emacs know which words should be italic?
  > 
  > By examining text properties.

And how do the text properties get there?  -- By hand.

Infloop :-)

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

* Re: Writing enriched text
  1999-04-23 13:25               ` Kai.Grossjohann
@ 1999-04-23 13:37                 ` Hrvoje Niksic
  1999-04-23 14:58                   ` William M. Perry
  0 siblings, 1 reply; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-23 13:37 UTC (permalink / raw)


Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> Hrvoje Niksic <hniksic@srce.hr> writes:
> 
>   > Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
>   > 
>   > > Colin Rafferty <craffert@ms.com> writes:
>   > > 
>   > >   > The enriched-mode things works, but it is a pain in the
>   > >   > ass doing all the text-properties by hand.
>   > > 
>   > > Oh, the wonders of `direct manipulation'...  But seriously, how
>   > > should Emacs know which words should be italic?
>   > 
>   > By examining text properties.
> 
> And how do the text properties get there?  -- By hand.

"By ``text properties'' menu entry."  Or by whatever interface someone
cares to implement.


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

* Re: Can't read this! (was Re: Writing enriched text)
  1999-04-22  9:09     ` Lee Willis
@ 1999-04-23 14:50       ` Justin Sheehy
  0 siblings, 0 replies; 47+ messages in thread
From: Justin Sheehy @ 1999-04-23 14:50 UTC (permalink / raw)


Lee Willis <lee@gbdirect.co.uk> writes:

> Jaap-Henk Hoepman <hoepman@cs.utwente.nl> writes:

> >   Symbol's function definition is void: facemenu-get-face

> It's a bug in Xemacs 20.4 apparently. I can't remember the work-around

This is probably what you are looking for:

(autoload 'facemenu-get-face "facemenu")

Just put that in your ~/.emacs and this bug shouldn't bite you again.

-- 
Justin Sheehy

In a cloud bones of steel.
  




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

* Re: Writing enriched text
  1999-04-23 13:37                 ` Hrvoje Niksic
@ 1999-04-23 14:58                   ` William M. Perry
  1999-04-23 15:45                     ` Per Abrahamsen
  0 siblings, 1 reply; 47+ messages in thread
From: William M. Perry @ 1999-04-23 14:58 UTC (permalink / raw)
  Cc: ding

Hrvoje Niksic <hniksic@srce.hr> writes:

> Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
> 
> > Hrvoje Niksic <hniksic@srce.hr> writes:
> > 
> >   > Kai.Grossjohann@CS.Uni-Dortmund.DE writes:
> >   > 
> >   > > Colin Rafferty <craffert@ms.com> writes:
> >   > > 
> >   > >   > The enriched-mode things works, but it is a pain in the
> >   > >   > ass doing all the text-properties by hand.
> >   > > 
> >   > > Oh, the wonders of `direct manipulation'...  But seriously, how
> >   > > should Emacs know which words should be italic?
> >   > 
> >   > By examining text properties.
> > 
> > And how do the text properties get there?  -- By hand.
> 
> "By ``text properties'' menu entry."  Or by whatever interface someone
> cares to implement.

M-x message-prettification-minor-mode

It could add some keybinding to do the fun things like bold, italic, etc.

You could even make it smart enough that if the user has used _only_ things 
that can be represented as *bold* or /italic/, it would send them out like
that, otherwise it could drop it into HTML or richtext.

-Bill P.


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

* Re: Writing enriched text
  1999-04-23 14:58                   ` William M. Perry
@ 1999-04-23 15:45                     ` Per Abrahamsen
  0 siblings, 0 replies; 47+ messages in thread
From: Per Abrahamsen @ 1999-04-23 15:45 UTC (permalink / raw)


wmperry@aventail.com (William M. Perry) writes:

> M-x message-prettification-minor-mode
> 
> It could add some keybinding to do the fun things like bold, italic, etc.

But the keybindings are already there, in the Edit->Text Properties
menu or the M-g prefix.  In fact, `M-g u' and `M-g b' will already
make the text _\bu_\bn_\bd_\be_\br_\bl_\bi_\bn_\be or b\bbo\bol\bld\bd, even in a clumsy way.

> You could even make it smart enough that if the user has used _only_ things 
> that can be represented as *bold* or /italic/, it would send them out like
> that, otherwise it could drop it into HTML or richtext.

I think the best thing to do would be to make message-mode smart about
understanding text properties, combined with a `format preference'.

(defcustom message-rich-text-preferences
   '("text/plain"
     "text/plain + _\bb_\ba_\bc_\bk_\bs_\bp_\ba_\bc_\be hack."
     "text/plain + /format/ *conventions*"
     "text/enriched"
     "text/html")
   "Use the first format in the list supporting text properties in buffer.")




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

* Re: Writing enriched text
  1999-04-22 15:01           ` Kai.Grossjohann
@ 1999-04-23 20:39             ` François Pinard
  1999-04-25 18:17             ` Hrvoje Niksic
  1 sibling, 0 replies; 47+ messages in thread
From: François Pinard @ 1999-04-23 20:39 UTC (permalink / raw)
  Cc: ding

Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> [...] what's missing is a way to transform an enriched-mode buffer
> from the internal representation to the text/enriched representation
> (i.e. replacing face attributes with tags).  And vice versa, of course.

These are already available.  See functions `format-decode-region' and
`format-encode-region'.

> So, we would need a command which takes the contents of a <part>,
> grinds it through the format-alist mechanism (or a similar one) and
> presents the result in a new buffer.  The user may then edit and hit
> C-c C-c, whereupon the format-list mechnism (or a similar one) takes
> over again and the result is put between the <part>...</part> tags.

This is the kind of thing I was hoping to find from my initial request.
Maybe we have all the necessary building blocks by now.  We only miss the
initiative of someone to add the glue cleverly.

We are not far from having the capability of composing text/enriched quite
easily right under Gnus.

-- 
François Pinard                            mailto:pinard@iro.umontreal.ca
Join the free Translation Project!    http://www.iro.umontreal.ca/~pinard


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

* Re: Writing enriched text
  1999-04-21 21:41         ` Hrvoje Niksic
                             ` (2 preceding siblings ...)
       [not found]           ` <k8z <byiuaohdim.fsf@bolzano.math.ethz.ch>
@ 1999-04-23 20:44           ` François Pinard
  1999-04-25 18:14             ` Hrvoje Niksic
  3 siblings, 1 reply; 47+ messages in thread
From: François Pinard @ 1999-04-23 20:44 UTC (permalink / raw)
  Cc: ding

[-- Attachment #1: Type: text/plain, Size: 286 bytes --]

Hrvoje Niksic <hniksic@srce.hr> writes:

> If you are feeling maximally gung, you can even implement it using
> indirect buffers.

I do not know what `gung' means (would someone tell me? :-), but if indirect
buffers allow me to directly and easily edit text/enriched between the
proper 

[-- Attachment #2: Type: text/plain, Size: 209 bytes --]

and </#part> in enriched mode, then `gung' I should be!

-- 
François Pinard                            mailto:pinard@iro.umontreal.ca
Join the free Translation Project!    http://www.iro.umontreal.ca/~pinard

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

* Re: Writing enriched text
  1999-04-21  7:26 ` Writing enriched text Kai.Grossjohann
  1999-04-21 12:48   ` William M. Perry
@ 1999-04-24 15:17   ` François Pinard
  1 sibling, 0 replies; 47+ messages in thread
From: François Pinard @ 1999-04-24 15:17 UTC (permalink / raw)
  Cc: ding

Kai.Grossjohann@CS.Uni-Dortmund.DE écrit:

>   > What is the easiest way to write an text/enriched message, using Gnus?

> Never thought about it.  Maybe M-x make-indirect-buffer RET is part of
> the solution?  (After narrowing the message buffer to the body.)

In fact, _before_ narrowing the message buffer.

> Hm.  That wouldn't work.  Hm.  Enriched-mode adds a Content-type header
> to the start of the text, which would then appear in the actual text in
> the message.

It could work.  We would just have to clean up the thing before the message
goes out.

-- 
François Pinard                            mailto:pinard@iro.umontreal.ca
Join the free Translation Project!    http://www.iro.umontreal.ca/~pinard



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

* Re: Writing enriched text
  1999-04-23 20:44           ` François Pinard
@ 1999-04-25 18:14             ` Hrvoje Niksic
  0 siblings, 0 replies; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-25 18:14 UTC (permalink / raw)


François Pinard <pinard@IRO.UMontreal.CA> writes:

> Hrvoje Niksic <hniksic@srce.hr> writes:
> 
> > If you are feeling maximally gung, you can even implement it using
> > indirect buffers.
> 
> I do not know what `gung' means (would someone tell me? :-), but if
> indirect buffers allow me to directly and easily edit text/enriched
> between the proper and </#part> in enriched mode, then `gung' I
> should be!

Indirect buffers are a feature that is still relatively new in Emacs
-- I haven't seen code seriously using it -- that allows you to have
several different buffers share the same buffer text.  This means that 
you can create an "indirect buffer" out of the message buffer, narrow
it to the <part>...</part>, and put it in enriched mode.


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

* Re: Writing enriched text
  1999-04-22 15:01           ` Kai.Grossjohann
  1999-04-23 20:39             ` François Pinard
@ 1999-04-25 18:17             ` Hrvoje Niksic
  1999-04-25 21:34               ` Kai.Grossjohann
  1 sibling, 1 reply; 47+ messages in thread
From: Hrvoje Niksic @ 1999-04-25 18:17 UTC (permalink / raw)


Kai.Grossjohann@CS.Uni-Dortmund.DE writes:

> I know about this, but I think it is not complete: what's missing is a
> way to transform an enriched-mode buffer from the internal
> representation to the text/enriched representation (i.e. replacing
> face attributes with tags).  And vice versa, of course.

How can you say that?  Have you even looked at `enriched.el'?  The
functions `enriched-encode' and `enriched-decode' happen to do exactly
what you describe.



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

* Re: Writing enriched text
  1999-04-25 18:17             ` Hrvoje Niksic
@ 1999-04-25 21:34               ` Kai.Grossjohann
  0 siblings, 0 replies; 47+ messages in thread
From: Kai.Grossjohann @ 1999-04-25 21:34 UTC (permalink / raw)


Hrvoje Niksic <hniksic@srce.hr> writes:

  > How can you say that?

Sorry, I must've had a bad day.

kai
-- 
Abort this operation?   [Abort]  [Cancel]


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

end of thread, other threads:[~1999-04-25 21:34 UTC | newest]

Thread overview: 47+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1999-04-20 20:55 Writing enriched text François Pinard
1999-04-20 21:26 ` Colin Rafferty
1999-04-20 21:43   ` Hrvoje Niksic
1999-04-20 21:44   ` François Pinard
1999-04-21 13:49     ` Colin Rafferty
1999-04-21 14:09       ` Kai.Grossjohann
1999-04-21 14:43         ` Colin Rafferty
1999-04-22 15:04           ` Kai.Grossjohann
1999-04-22 15:24             ` Colin Rafferty
1999-04-22 16:01               ` Kai.Grossjohann
1999-04-23 12:56             ` Hrvoje Niksic
1999-04-23 13:25               ` Kai.Grossjohann
1999-04-23 13:37                 ` Hrvoje Niksic
1999-04-23 14:58                   ` William M. Perry
1999-04-23 15:45                     ` Per Abrahamsen
1999-04-22 15:55           ` Jan Vroonhof
     [not found]           ` <vaf676o7l3p.fsf@ramses.cs.uni-dortmund.de <byd80whcpl.fsf@bolzano.math.ethz.ch>
1999-04-22 16:54             ` Colin Rafferty
1999-04-20 21:52   ` David Hedbor
1999-04-20 22:42     ` Hrvoje Niksic
1999-04-20 23:08       ` Bruce Stephens
1999-04-20 23:20         ` David Hedbor
1999-04-21  0:04   ` enriched bug (was Re: Writing enriched text) Stainless Steel Rat
1999-04-21  0:08     ` Hrvoje Niksic
1999-04-22  7:52   ` Can't read this! " Jaap-Henk Hoepman
1999-04-22  9:09     ` Lee Willis
1999-04-23 14:50       ` Justin Sheehy
1999-04-21  7:26 ` Writing enriched text Kai.Grossjohann
1999-04-21 12:48   ` William M. Perry
1999-04-21 13:43     ` Laura Conrad
1999-04-21 13:45     ` Kai.Grossjohann
1999-04-21 15:03       ` Alan Shutko
1999-04-21 17:29         ` Oscar Figueiredo
1999-04-21 17:51           ` William M. Perry
1999-04-22 15:01           ` Kai.Grossjohann
1999-04-23 20:39             ` François Pinard
1999-04-25 18:17             ` Hrvoje Niksic
1999-04-25 21:34               ` Kai.Grossjohann
1999-04-21 19:08       ` Lars Magne Ingebrigtsen
1999-04-21 21:41         ` Hrvoje Niksic
1999-04-22  7:24           ` Colin Marquardt
1999-04-22  8:41             ` Hrvoje Niksic
1999-04-22 15:37           ` Jan Vroonhof
     [not found]           ` <k8z <byiuaohdim.fsf@bolzano.math.ethz.ch>
1999-04-23  7:42             ` Colin Marquardt
1999-04-23 20:44           ` François Pinard
1999-04-25 18:14             ` Hrvoje Niksic
     [not found]     ` <knn202ks3v.fsf@concord.com>
1999-04-21 14:22       ` William M. Perry
1999-04-24 15:17   ` François Pinard

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).