emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Display-based word wrapping


From: David Kastrup
Subject: Re: Display-based word wrapping
Date: Sun, 22 Jun 2008 22:12:42 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.60 (gnu/linux)

Chong Yidong <address@hidden> writes:

> I have been studying Kim Storm's display-based word wrapping code.  I
> believe it's pretty safe, and suitable for inclusion into the Emacs 23
> release (probably turned off by default).
>
> The original patch included a `wrap-column' variable, but I'd like to
> modify this to use `truncate-lines' instead, as shown below.  This would
> mean that word wrap always uses the right window edge as a wrap column.
> Any objections?
>
>
>
> truncate-lines is a variable defined in `C source code'.
>
> Documentation:
> Whether lines longer than the window width are truncated.
> If the value is nil or `word-wrap', long lines are displayed using
> continuation lines.  If nil, the wrapping occurs at the right window
> edge.  If `word-wrap', it occurs at the rightmost space or tab
> character, if possible.

How about not using word-wrap, but rather integers?  A positive integer
indicates the column before the wrap should occur, with negative
integers counting from the right margin?  That makes it possible to
specify a fixed wrap position if really wanted.  Also the
truncate-partial-window-width override should have the same meaning and
take precedence if non-nil.

I am not sure this flexibility is needed, though.

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




reply via email to

[Prev in Thread] Current Thread [Next in Thread]