* Re: Enriched mode: avoid removing my manual indents
[not found] ` <mailman.475.1369680957.22516.help-gnu-emacs@gnu.org>
@ 2013-05-28 11:50 ` Alexandre Oberlin
2013-06-04 11:52 ` Alexandre Oberlin
` (3 subsequent siblings)
4 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oberlin @ 2013-05-28 11:50 UTC (permalink / raw)
To: help-gnu-emacs
Thanks Stefan for the info.
I just sent a bug report as suggested.
Alexandre
On Mon, 27 May 2013 20:55:37 +0200, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
>> Thanks Drew for your reply. Maybe this behavior is not a bug but it is
>> certainly confusing to me.
>
> `enriched-mode' was the beginning of something that never materialized,
> so it's no wonder it doesn't work exactly like you want.
>
> It's not used very much as far as I know. But I think Drew's point is
> right, in that it would make sense to split enriched-mode into
> sub-elements, such that the "save faces" part could be used separately.
>
>
> Stefan
>
>
--
Alexandre Oberlin
http://www.migo.info
^ permalink raw reply [flat|nested] 10+ messages in thread
* Re: Enriched mode: avoid removing my manual indents
[not found] ` <mailman.475.1369680957.22516.help-gnu-emacs@gnu.org>
2013-05-28 11:50 ` Alexandre Oberlin
@ 2013-06-04 11:52 ` Alexandre Oberlin
2014-02-15 17:30 ` [SOLVED] " Alexandre Oberlin
` (2 subsequent siblings)
4 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oberlin @ 2013-06-04 11:52 UTC (permalink / raw)
To: help-gnu-emacs
Hi all,
BTW, there is AFAIK a true bug in enriched-mode, which I noticed long ago:
the accentuated characters are not recovered by "recover-this-file". I get
garbage and the old song;
> However, each of them encountered characters it couldn't encode:
> utf-8-unix cannot encode these: � � � � � � � � � � ...
(GNU Emacs 23.4.1)
It’s nice that this command can be undone!
I guess I should report a bug ASAP. I also must try in org-mode.
Alexandre
On Mon, 27 May 2013 20:55:37 +0200, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
>
> `enriched-mode' was the beginning of something that never materialized,
> so it's no wonder it doesn't work exactly like you want.
>
> It's not used very much as far as I know. But I think Drew's point is
> right, in that it would make sense to split enriched-mode into
> sub-elements, such that the "save faces" part could be used separately.
>
>
> Stefan
>
>
--
Alexandre Oberlin
http://www.migo.info
^ permalink raw reply [flat|nested] 10+ messages in thread
* [SOLVED] Re: Enriched mode: avoid removing my manual indents
[not found] ` <mailman.475.1369680957.22516.help-gnu-emacs@gnu.org>
2013-05-28 11:50 ` Alexandre Oberlin
2013-06-04 11:52 ` Alexandre Oberlin
@ 2014-02-15 17:30 ` Alexandre Oberlin
2014-02-15 17:30 ` Alexandre Oberlin
2014-02-15 17:32 ` Alexandre Oberlin
4 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oberlin @ 2014-02-15 17:30 UTC (permalink / raw)
To: help-gnu-emacs
Hi all,
Old issue solved, just in case someone else uses enriched-mode, which I
personally find invaluable to highlight my notes with colours or styles.
Let’s recall the problem:
On Fri, 24 May 2013 14:42:12 +0200, Alexandre Oberlin
<email_through@migo.info> wrote:
> I use enriched mode extensively but if I start a new line say on column
> 8, then why does enriched mode think that is an error and put it back to
> beginning of line as soon as I type return ?
On Mon, 27 May 2013 20:55:37 +0200, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
> `enriched-mode' was the beginning of something that never materialized,
> so it's no wonder it doesn't work exactly like you want.
>
> It's not used very much as far as I know. But I think Drew's point is
> right, in that it would make sense to split enriched-mode into
> sub-elements, such that the "save faces" part could be used separately.
Actually the annoyance was bigger than what I wrote in this thread, since
you are virtually stuck to one indentation column once it is set. However,
getting rid of this was in fact dirty simple.
Here’s what I did, while inside a buffer in enriched-mode:
1. Hit CTRL + h, k
2. Hit RETURN
3. Read the fine help:
#############################################
RET (translated from <return>) runs the command
reindent-then-newline-and-indent, which is an interactive Lisp
function in `simple.el'.
It is bound to RET.
(reindent-then-newline-and-indent)
Reindent current line, insert newline, then indent the new line.
Indentation of both lines is done according to the current major mode,
which means calling the current value of `indent-line-function'.
In programming language modes, this is the same as TAB.
In some text modes, where TAB inserts a tab, this indents to the
column specified by the function `current-left-margin'.
[back]
#############################################
Of course there are several solutions once you know the above.
A quick and dirty one is to overwrite the reindent-then-newline-and-indent
function’s definition by putting the following in your .emacs file:
(defun reindent-then-newline-and-indent ()
"No thanks"
(interactive "*")
(newline)
(indent-according-to-mode))
Modifying /usr/share/emacs/23.4/lisp/textmodes/enriched.el might be a
better solution, but it would take more time.
I wish I had this flexibility in a few other software programs...
Hope it helps,
Alexandre
^ permalink raw reply [flat|nested] 10+ messages in thread
* [SOLVED] Re: Enriched mode: avoid removing my manual indents
[not found] ` <mailman.475.1369680957.22516.help-gnu-emacs@gnu.org>
` (2 preceding siblings ...)
2014-02-15 17:30 ` [SOLVED] " Alexandre Oberlin
@ 2014-02-15 17:30 ` Alexandre Oberlin
2014-02-15 17:32 ` Alexandre Oberlin
4 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oberlin @ 2014-02-15 17:30 UTC (permalink / raw)
To: help-gnu-emacs
Hi all,
Old issue solved, just in case someone else uses enriched-mode, which I
personally find invaluable to highlight my notes with colours or styles.
Let’s recall the problem:
On Fri, 24 May 2013 14:42:12 +0200, Alexandre Oberlin
<email_through@migo.info> wrote:
> I use enriched mode extensively but if I start a new line say on column
> 8, then why does enriched mode think that is an error and put it back to
> beginning of line as soon as I type return ?
On Mon, 27 May 2013 20:55:37 +0200, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
> `enriched-mode' was the beginning of something that never materialized,
> so it's no wonder it doesn't work exactly like you want.
>
> It's not used very much as far as I know. But I think Drew's point is
> right, in that it would make sense to split enriched-mode into
> sub-elements, such that the "save faces" part could be used separately.
Actually the annoyance was bigger than what I wrote in this thread, since
you are virtually stuck to one indentation column once it is set. However,
getting rid of this was in fact dirty simple.
Here’s what I did, while inside a buffer in enriched-mode:
1. Hit CTRL + h, k
2. Hit RETURN
3. Read the fine help:
#############################################
RET (translated from <return>) runs the command
reindent-then-newline-and-indent, which is an interactive Lisp
function in `simple.el'.
It is bound to RET.
(reindent-then-newline-and-indent)
Reindent current line, insert newline, then indent the new line.
Indentation of both lines is done according to the current major mode,
which means calling the current value of `indent-line-function'.
In programming language modes, this is the same as TAB.
In some text modes, where TAB inserts a tab, this indents to the
column specified by the function `current-left-margin'.
[back]
#############################################
Of course there are several solutions once you know the above.
A quick and dirty one is to overwrite the reindent-then-newline-and-indent
function’s definition by putting the following in your .emacs file:
(defun reindent-then-newline-and-indent ()
"No thanks"
(interactive "*")
(newline)
(indent-according-to-mode))
Modifying /usr/share/emacs/23.4/lisp/textmodes/enriched.el might be a
better solution, but it would take more time.
I wish I had this flexibility in a few other software programs...
Hope it helps,
Alexandre
^ permalink raw reply [flat|nested] 10+ messages in thread
* [SOLVED] Re: Enriched mode: avoid removing my manual indents
[not found] ` <mailman.475.1369680957.22516.help-gnu-emacs@gnu.org>
` (3 preceding siblings ...)
2014-02-15 17:30 ` Alexandre Oberlin
@ 2014-02-15 17:32 ` Alexandre Oberlin
4 siblings, 0 replies; 10+ messages in thread
From: Alexandre Oberlin @ 2014-02-15 17:32 UTC (permalink / raw)
To: help-gnu-emacs
Hi all,
Old issue solved, just in case someone else uses enriched-mode, which I
personally find invaluable to highlight my notes with colours or styles.
Let’s recall the problem:
On Fri, 24 May 2013 14:42:12 +0200, Alexandre Oberlin
<email_through@migo.info> wrote:
> I use enriched mode extensively but if I start a new line say on column
> 8, then why does enriched mode think that is an error and put it back to
> beginning of line as soon as I type return ?
On Mon, 27 May 2013 20:55:37 +0200, Stefan Monnier
<monnier@iro.umontreal.ca> wrote:
> `enriched-mode' was the beginning of something that never materialized,
> so it's no wonder it doesn't work exactly like you want.
>
> It's not used very much as far as I know. But I think Drew's point is
> right, in that it would make sense to split enriched-mode into
> sub-elements, such that the "save faces" part could be used separately.
Actually the annoyance was bigger than what I wrote in this thread, since
you are virtually stuck to one indentation column once it is set. However,
getting rid of this was in fact dirty simple.
Here’s what I did, while inside a buffer in enriched-mode:
1. Hit CTRL + h, k
2. Hit RETURN
3. Read the fine help:
#############################################
RET (translated from <return>) runs the command
reindent-then-newline-and-indent, which is an interactive Lisp
function in `simple.el'.
It is bound to RET.
(reindent-then-newline-and-indent)
Reindent current line, insert newline, then indent the new line.
Indentation of both lines is done according to the current major mode,
which means calling the current value of `indent-line-function'.
In programming language modes, this is the same as TAB.
In some text modes, where TAB inserts a tab, this indents to the
column specified by the function `current-left-margin'.
[back]
#############################################
Of course there are several solutions once you know the above.
A quick and dirty one is to overwrite the reindent-then-newline-and-indent
function’s definition by putting the following in your .emacs file:
(defun reindent-then-newline-and-indent ()
"No thanks"
(interactive "*")
(newline)
(indent-according-to-mode))
Modifying /usr/share/emacs/23.4/lisp/textmodes/enriched.el might be a
better solution, but it would take more time.
I wish I had this flexibility in a few other software programs...
Hope it helps,
Alexandre
^ permalink raw reply [flat|nested] 10+ messages in thread