unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* longlines-show-hard-newlines - should not the default be t?
@ 2008-06-22  0:55 Lennart Borgman (gmail)
  2008-06-22  1:09 ` Chong Yidong
  2008-06-22  1:35 ` Miles Bader
  0 siblings, 2 replies; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22  0:55 UTC (permalink / raw)
  To: Emacs Devel

I think the default value should be t. I think longlines can be quite 
confusing otherwise.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  0:55 longlines-show-hard-newlines - should not the default be t? Lennart Borgman (gmail)
@ 2008-06-22  1:09 ` Chong Yidong
  2008-06-22  1:27   ` Lennart Borgman (gmail)
  2008-06-22  1:35 ` Miles Bader
  1 sibling, 1 reply; 17+ messages in thread
From: Chong Yidong @ 2008-06-22  1:09 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Emacs Devel

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

> I think the default value should be t. I think longlines can be quite
> confusing otherwise.

That runs into problems when the buffer is displayed in of different
widths.  This is one of the two main limitations of longlines mode (the
other being the font-lock problem discussed before).

I am taking a look at Kim Storm's window wrapping code.  Probably it's
better to offer that from the menu bar, instead of longlines mode.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  1:09 ` Chong Yidong
@ 2008-06-22  1:27   ` Lennart Borgman (gmail)
  2008-06-22  1:37     ` Chong Yidong
  2008-06-22  1:38     ` Chong Yidong
  0 siblings, 2 replies; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22  1:27 UTC (permalink / raw)
  To: Chong Yidong; +Cc: Emacs Devel

Chong Yidong wrote:
> "Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:
> 
>> I think the default value should be t. I think longlines can be quite
>> confusing otherwise.
> 
> That runs into problems when the buffer is displayed in of different
> widths.  This is one of the two main limitations of longlines mode (the
> other being the font-lock problem discussed before).

I am sorry, but I did not follow that discussion. What are the problems?

It looks to me like the display of hard new lines should be managed by 
font lock. Is there any problem with doing that?

> I am taking a look at Kim Storm's window wrapping code.  Probably it's
> better to offer that from the menu bar, instead of longlines mode.





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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  0:55 longlines-show-hard-newlines - should not the default be t? Lennart Borgman (gmail)
  2008-06-22  1:09 ` Chong Yidong
@ 2008-06-22  1:35 ` Miles Bader
  2008-06-22 10:02   ` Lennart Borgman (gmail)
  1 sibling, 1 reply; 17+ messages in thread
From: Miles Bader @ 2008-06-22  1:35 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Emacs Devel

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:
> I think the default value should be t. I think longlines can be quite
> confusing otherwise.

The current behavior is _exactly_ like the overwhelming majority of
windows/mac/gnome/etc text-entry displays:  they treat hard newlines as
paragraph boundaries, but do not visually differentiate them from
automatically wrapped lines.  [Though the difference is usually fairly
obvious because of whitespace]

There are certainly times when one wants to explicitly show hard
newlines, but it shouldn't be the default.

-Miles

-- 
Discriminate, v.i. To note the particulars in which one person or thing is,
if possible, more objectionable than another.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  1:27   ` Lennart Borgman (gmail)
@ 2008-06-22  1:37     ` Chong Yidong
  2008-06-22  1:38     ` Chong Yidong
  1 sibling, 0 replies; 17+ messages in thread
From: Chong Yidong @ 2008-06-22  1:37 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Emacs Devel

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

> It looks to me like the display of hard new lines should be managed by
> font lock. Is there any problem with doing that?

You mean to add a font-lock function that adds "\n" display properties?
Doable in principle, but AFAIK no advantages over Kim Storm's patch.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  1:27   ` Lennart Borgman (gmail)
  2008-06-22  1:37     ` Chong Yidong
@ 2008-06-22  1:38     ` Chong Yidong
  1 sibling, 0 replies; 17+ messages in thread
From: Chong Yidong @ 2008-06-22  1:38 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Emacs Devel

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

>>> I think the default value should be t. I think longlines can 
    be quite
>>> confusing otherwise.
>>
>> That runs into problems when the buffer is displayed in of 
   different
>> widths.  This is one of the two main limitations of longlines 
   mode (the
>> other being the font-lock problem discussed before).
>
> I am sorry, but I did not follow that discussion. What are the 
  problems?

Sorry, I was confused.  I thought you meant
longlines-wrap-follows-window-size.  But yeah, regarding
longlines-show-hard-newlines: what Miles said.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22  1:35 ` Miles Bader
@ 2008-06-22 10:02   ` Lennart Borgman (gmail)
  2008-06-22 12:11     ` Stefan Monnier
  0 siblings, 1 reply; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22 10:02 UTC (permalink / raw)
  To: Miles Bader; +Cc: Emacs Devel

Miles Bader wrote:
> "Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:
>> I think the default value should be t. I think longlines can be quite
>> confusing otherwise.
> 
> The current behavior is _exactly_ like the overwhelming majority of
> windows/mac/gnome/etc text-entry displays:  they treat hard newlines as
> paragraph boundaries, but do not visually differentiate them from
> automatically wrapped lines.  [Though the difference is usually fairly
> obvious because of whitespace]

That is not nice, you are stealing my usual arguments ;-)

I often get frustrated by the fact that hard newlines are not displayed 
in other applications. For example trying to cowrite something with 
someone unaware of this may be a lot of extra work.

This has been addressed in word processors, but admittedly they do not 
show hard new lines by default. I guess however that this is because 
they normally have less technical aware users.

> There are certainly times when one wants to explicitly show hard
> newlines, but it shouldn't be the default.

One reason to show hard newlines as default is that Emacs displays the 
buffer different when longlines-mode is on. It is then an analogy to the 
fringes shown for wrapped lines.

> -Miles
> 




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 10:02   ` Lennart Borgman (gmail)
@ 2008-06-22 12:11     ` Stefan Monnier
  2008-06-22 12:28       ` Lennart Borgman (gmail)
  0 siblings, 1 reply; 17+ messages in thread
From: Stefan Monnier @ 2008-06-22 12:11 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Emacs Devel, Miles Bader

> I often get frustrated by the fact that hard newlines are not displayed in
> other applications. For example trying to cowrite something with someone
> unaware of this may be a lot of extra work.

Yes, it's a pain in the association list.

When using the display-wrapping code, we have some info in the fringes,
but to b honest, I'm not very satisfied with them either: they work
great when some lines are wrapped, but they're not so hot when most
lines are wrapped.

In that case, I'd much prefer that instead of adding the curly arrows in
the fringe on 90% of the lines, we add a paragraph-icon in the fringe of
the few lines that do not wrap.


        Stefan




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 12:11     ` Stefan Monnier
@ 2008-06-22 12:28       ` Lennart Borgman (gmail)
  2008-06-22 18:08         ` Stephen J. Turnbull
  0 siblings, 1 reply; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22 12:28 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Emacs Devel, Miles Bader

Stefan Monnier wrote:
> When using the display-wrapping code, we have some info in the fringes,
> but to b honest, I'm not very satisfied with them either: they work
> great when some lines are wrapped, but they're not so hot when most
> lines are wrapped.
> 
> In that case, I'd much prefer that instead of adding the curly arrows in
> the fringe on 90% of the lines, we add a paragraph-icon in the fringe of
> the few lines that do not wrap.


But will it not be much harder to see to which line the fringe belongs?




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:08         ` Stephen J. Turnbull
@ 2008-06-22 18:03           ` Lennart Borgman (gmail)
  2008-06-22 18:26             ` David Kastrup
  2008-06-22 21:29           ` Drew Adams
  1 sibling, 1 reply; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22 18:03 UTC (permalink / raw)
  To: Stephen J. Turnbull; +Cc: Miles Bader, Stefan Monnier, Emacs Devel

Stephen J. Turnbull wrote:
> Lennart Borgman (gmail) writes:
> 
>  > Stefan Monnier wrote:
> 
>  > > add a paragraph-icon in the fringe of the few lines that do not wrap.
>  > 
>  > But will it not be much harder to see to which line the fringe belongs?
> 
> That's why when God created Fringes, Right *and* Left did He create
> them.  Put it in the left fringe (except in Hebrew and Arabic, of
> course!)

Yes! But creation is not finished and that is why he gave us the ability 
to choose, create. And actually I think using the left fringe for this 
would be a mistake. I think most human beeings expect to find line feeds 
to the right. Even though that is a human mistake it would be another 
not to take this into account.

And the right fringes are too far away to be realistic.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 12:28       ` Lennart Borgman (gmail)
@ 2008-06-22 18:08         ` Stephen J. Turnbull
  2008-06-22 18:03           ` Lennart Borgman (gmail)
  2008-06-22 21:29           ` Drew Adams
  0 siblings, 2 replies; 17+ messages in thread
From: Stephen J. Turnbull @ 2008-06-22 18:08 UTC (permalink / raw)
  To: Lennart Borgman (gmail); +Cc: Miles Bader, Stefan Monnier, Emacs Devel

Lennart Borgman (gmail) writes:

 > Stefan Monnier wrote:

 > > add a paragraph-icon in the fringe of the few lines that do not wrap.
 > 
 > But will it not be much harder to see to which line the fringe belongs?

That's why when God created Fringes, Right *and* Left did He create
them.  Put it in the left fringe (except in Hebrew and Arabic, of
course!)





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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:03           ` Lennart Borgman (gmail)
@ 2008-06-22 18:26             ` David Kastrup
  2008-06-22 18:32               ` Lennart Borgman (gmail)
  2008-06-22 21:37               ` Stefan Monnier
  0 siblings, 2 replies; 17+ messages in thread
From: David Kastrup @ 2008-06-22 18:26 UTC (permalink / raw)
  To: Lennart Borgman (gmail)
  Cc: Stephen J. Turnbull, Emacs Devel, Stefan Monnier, Miles Bader

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

> Stephen J. Turnbull wrote:
>> Lennart Borgman (gmail) writes:
>>
>>  > Stefan Monnier wrote:
>>
>>  > > add a paragraph-icon in the fringe of the few lines that do not wrap.
>>  >  > But will it not be much harder to see to which line the fringe
>> belongs?
>>
>> That's why when God created Fringes, Right *and* Left did He create
>> them.  Put it in the left fringe (except in Hebrew and Arabic, of
>> course!)
>
> Yes! But creation is not finished and that is why he gave us the
> ability to choose, create. And actually I think using the left fringe
> for this would be a mistake. I think most human beeings expect to find
> line feeds to the right. Even though that is a human mistake it would
> be another not to take this into account.

We already made the default scroll bar placement to the left because
texts and text work tends to be left-justified.  Yes, it is contrary to
the normal expectations, but as long as it has a noticeable benefit,
that has not kept us from improving Emacs.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:26             ` David Kastrup
@ 2008-06-22 18:32               ` Lennart Borgman (gmail)
  2008-06-22 18:37                 ` David Kastrup
  2008-06-22 21:37               ` Stefan Monnier
  1 sibling, 1 reply; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22 18:32 UTC (permalink / raw)
  To: David Kastrup
  Cc: Stephen J. Turnbull, Emacs Devel, Stefan Monnier, Miles Bader

David Kastrup wrote:
> "Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:
> 
>> Stephen J. Turnbull wrote:
>>> Lennart Borgman (gmail) writes:
>>>
>>>  > Stefan Monnier wrote:
>>>
>>>  > > add a paragraph-icon in the fringe of the few lines that do not wrap.
>>>  >  > But will it not be much harder to see to which line the fringe
>>> belongs?
>>>
>>> That's why when God created Fringes, Right *and* Left did He create
>>> them.  Put it in the left fringe (except in Hebrew and Arabic, of
>>> course!)
>> Yes! But creation is not finished and that is why he gave us the
>> ability to choose, create. And actually I think using the left fringe
>> for this would be a mistake. I think most human beeings expect to find
>> line feeds to the right. Even though that is a human mistake it would
>> be another not to take this into account.
> 
> We already made the default scroll bar placement to the left because
> texts and text work tends to be left-justified.

Not on w32 I think.

> Yes, it is contrary to
> the normal expectations, but as long as it has a noticeable benefit,
> that has not kept us from improving Emacs.

But this would also deviate from for example how OpenOffice shows 
similar things.

Though I can't make up my mind. More trying to collect the arguments.




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:32               ` Lennart Borgman (gmail)
@ 2008-06-22 18:37                 ` David Kastrup
  0 siblings, 0 replies; 17+ messages in thread
From: David Kastrup @ 2008-06-22 18:37 UTC (permalink / raw)
  To: Lennart Borgman (gmail)
  Cc: Stephen J. Turnbull, Emacs Devel, Stefan Monnier, Miles Bader

"Lennart Borgman (gmail)" <lennart.borgman@gmail.com> writes:

> David Kastrup wrote:
>
>> We already made the default scroll bar placement to the left because
>> texts and text work tends to be left-justified.
>
> Not on w32 I think.

I would not know.

>> Yes, it is contrary to the normal expectations, but as long as it has
>> a noticeable benefit, that has not kept us from improving Emacs.
>
> But this would also deviate from for example how OpenOffice shows
> similar things.
>
> Though I can't make up my mind. More trying to collect the arguments.

A wrap mark is fine at the right margin: there will be text close to it
(as long as the words are not all too long).  A hard LF mark, in
contrast, seems better to the left if one want to make the visual
connection.

That's how it appears to me.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




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

* RE: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:08         ` Stephen J. Turnbull
  2008-06-22 18:03           ` Lennart Borgman (gmail)
@ 2008-06-22 21:29           ` Drew Adams
  1 sibling, 0 replies; 17+ messages in thread
From: Drew Adams @ 2008-06-22 21:29 UTC (permalink / raw)
  To: 'Stephen J. Turnbull', 'Lennart Borgman (gmail)'
  Cc: 'Emacs Devel', 'Stefan Monnier',
	'Miles Bader'

FWIW, both MS Word and Framemaker place the pilcro at the end of the paragraph,
as if it were a character in the text. There are often other such "text symbols"
(e.g. section sign), whose display you can toggle on/off together. 





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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 18:26             ` David Kastrup
  2008-06-22 18:32               ` Lennart Borgman (gmail)
@ 2008-06-22 21:37               ` Stefan Monnier
  2008-06-22 21:49                 ` Lennart Borgman (gmail)
  1 sibling, 1 reply; 17+ messages in thread
From: Stefan Monnier @ 2008-06-22 21:37 UTC (permalink / raw)
  To: David Kastrup
  Cc: Stephen J. Turnbull, Emacs Devel, Lennart Borgman (gmail),
	Miles Bader

> We already made the default scroll bar placement to the left because
> texts and text work tends to be left-justified.  Yes, it is contrary to
> the normal expectations, but as long as it has a noticeable benefit,
> that has not kept us from improving Emacs.

I think the default should be the same as is done for the normal
wrap-icon in the fringe: put it on both sides.  E.g. put an icon on the
left at the beginning of a (long) line, and an icon on the right at the
end of a (long) line.


        Stefan




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

* Re: longlines-show-hard-newlines - should not the default be t?
  2008-06-22 21:37               ` Stefan Monnier
@ 2008-06-22 21:49                 ` Lennart Borgman (gmail)
  0 siblings, 0 replies; 17+ messages in thread
From: Lennart Borgman (gmail) @ 2008-06-22 21:49 UTC (permalink / raw)
  To: Stefan Monnier; +Cc: Stephen J. Turnbull, Emacs Devel, Miles Bader

Stefan Monnier wrote:
>> We already made the default scroll bar placement to the left because
>> texts and text work tends to be left-justified.  Yes, it is contrary to
>> the normal expectations, but as long as it has a noticeable benefit,
>> that has not kept us from improving Emacs.
> 
> I think the default should be the same as is done for the normal
> wrap-icon in the fringe: put it on both sides.  E.g. put an icon on the
> left at the beginning of a (long) line, and an icon on the right at the
> end of a (long) line.


You mean at the left of the continuation of a long line?

If this is implemented as fringes, I guess there is still nothing that 
prevents the use of the current 'display property too?




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

end of thread, other threads:[~2008-06-22 21:49 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-06-22  0:55 longlines-show-hard-newlines - should not the default be t? Lennart Borgman (gmail)
2008-06-22  1:09 ` Chong Yidong
2008-06-22  1:27   ` Lennart Borgman (gmail)
2008-06-22  1:37     ` Chong Yidong
2008-06-22  1:38     ` Chong Yidong
2008-06-22  1:35 ` Miles Bader
2008-06-22 10:02   ` Lennart Borgman (gmail)
2008-06-22 12:11     ` Stefan Monnier
2008-06-22 12:28       ` Lennart Borgman (gmail)
2008-06-22 18:08         ` Stephen J. Turnbull
2008-06-22 18:03           ` Lennart Borgman (gmail)
2008-06-22 18:26             ` David Kastrup
2008-06-22 18:32               ` Lennart Borgman (gmail)
2008-06-22 18:37                 ` David Kastrup
2008-06-22 21:37               ` Stefan Monnier
2008-06-22 21:49                 ` Lennart Borgman (gmail)
2008-06-22 21:29           ` Drew Adams

Code repositories for project(s) associated with this public inbox

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

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 read-only IMAP folder(s) and NNTP newsgroup(s).