From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Ivan Kanis Newsgroups: gmane.emacs.devel Subject: Re: fill length of visual line mode Date: Fri, 03 Oct 2014 22:39:17 +0200 Message-ID: <87vbo0ga6i.fsf_-_@kanis.fr> References: <87oatu6hfn.fsf@kanis.fr> <87oatu6hfn.fsf@kanis.fr> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1412368787 11852 80.91.229.3 (3 Oct 2014 20:39:47 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 3 Oct 2014 20:39:47 +0000 (UTC) Cc: Eli Zaretskii , Emacs Development List To: Glenn Morris Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Fri Oct 03 22:39:41 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Xa9db-0005sN-Mg for ged-emacs-devel@m.gmane.org; Fri, 03 Oct 2014 22:39:39 +0200 Original-Received: from localhost ([::1]:41182 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xa9db-0007so-Bm for ged-emacs-devel@m.gmane.org; Fri, 03 Oct 2014 16:39:39 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:54895) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xa9dS-0007rq-T7 for emacs-devel@gnu.org; Fri, 03 Oct 2014 16:39:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xa9dN-0003lh-4H for emacs-devel@gnu.org; Fri, 03 Oct 2014 16:39:30 -0400 Original-Received: from kanis.fr ([46.19.35.252]:45852 helo=srv2.kanis.fr) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xa9dM-0003lX-UE; Fri, 03 Oct 2014 16:39:25 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=kanis.fr; s=alpha; h=Content-Transfer-Encoding:Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:References:Subject:Cc:To:From; bh=Uhww3yBnZgMQbCCxRSARu6B7xflRTM9kHo8QweoAr9A=; b=iNTE6ZSTOBKCvMn9aU5xC8hgwEUQByuxmjlZxFnlFR/8eBMfJFRIyjnvaBn7IX/eIUhlDTaysgQ+BZjgmgPDmQmLB1ZnfVR3V/PNzKRpPRMGgE/KP7bya3rQPI5tNrJT; Original-Received: from smtp.comencini.fr ([164.138.25.8]) by smtp.comencini.fr with esmtpsa (TLS1.1:DHE_RSA_AES_128_CBC_SHA1:128) (Exim 4.80.1) (envelope-from ) id 1Xa9dF-00083e-Km; Fri, 03 Oct 2014 22:39:18 +0200 Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAAAXNSR0IArs4c6QAAAB5QTFRF IBkXUxMTOCwoTC4qcUY8iFxQmmper31txpaJ/v/8aKZ1oAAAAcVJREFUOMt100tu2zAQAFDCXnUZ oAcIqG68LZULVLQBbwuSiffm6AIRRyeotAySJoVu2+FPpJWWC3/4NKOZocSW/yxWfnJ2+Bdwzhj7 8gleWVy7DXC2rkMNr2V/zRbghXIwthf3VbIA9Ffc71vZCSFyCEsBggtNS8ludwvfmhYA0Vn9o4DP zMWxR7+cPWzAYFzwM0ModtdmcDbDS6i/hT7L+RZof5yCXGrYe5jn2YO6BYMjgY+51tCIAqHgBLwR pwLnGuRjAKyBJkuN4yd4U92uCY1vUr2D/c5b8DuxyQwfOHUeaLqDJhnkkuGXbB56h2C1IVBdgncc bBi6feroa9B6jUDojnQPQKupbyXyeeCE1oT7Oqrt+SnfY3mkiyGA/3AmD3H5g32CcBx6hY8pRkwJ 9PpcjRGobUfprFnhAa1vepwcgMOhwG+pdSgKHFU9HAvoAH6XUl7lDUCCq5Qb6GMbVm3Aj++qDYCt wdBc/YHgOFCmS3mjDMRcSE2qY4E3Q3PVIQRQmeodNH4QEbRUFZzW+VotzwX4yTcRTySOML1qjcE5 hTirVqDHkMAP0PjAywp3d18JZtqzvr9zDYD+GaSKtE6Zlr/DLPNFmOcvBAAAAABJRU5ErkJggg== X-Hashcash: 1:20:141003:emacs-devel@gnu.org::Diu/FvjU6QO8NBqf:0000000000000000000000000000000000000000003YD/ X-Hashcash: 1:20:141003:eliz@gnu.org::3+2cLnvWfYkZuQZv:000001amw X-Hashcash: 1:20:141003:rgm@gnu.org::KTNEeJcCL2WVH982:0000004ENn In-Reply-To: (Glenn Morris's message of "Thu, 02 Oct 2014 11:50:10 -0400, Thu, 02 Oct 2014 18:16:48 +0300") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.93 (gnu/linux) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.4.x-2.6.x [generic] X-Received-From: 46.19.35.252 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:174954 Archived-At: October, 02 at 18:16 Eli wrote: >> From: Ivan Kanis >> Date: Thu, 02 Oct 2014 09:48:12 +0200 >>=20 >> I just enabled visual line mode today. I have started using it to >> display gnus article. I noticed that the fill happens at the width of >> the Emacs window. I set fill-column to 70 and I was expecting it to wrap >> there. > > That's not how word-wrap was designed and implemented. It works more > like Web browsers, i.e. it wraps at the window edge. It's too long for me at work where I use a tiling window manager and wide screen. >> There is a hack [1] by James Wright to make it work by expanding the >> right margin of the buffer's window. >>=20 >> I don't feel it should be so complicated to customize this behavior. >>=20 >> Would it be OK to code wrap at fill-column? > > Not sure what you mean by your question. Are you asking whether > patches to implement the wrap at fill-column will be accepted? If so, > I'm quite sure the answer is YES. It is what I meant. October, 02 at 11:50 Glenn wrote: > The code you quote seems mostly OK, but I don't know who wrote it, so > I can't just install it, for copyright reasons. >=20=20=20=20=20 > If someone can rewrite it and submit a patch, or if the original author > can submit the patch, I'd be happy to install the feature. It just boils down to setting the right margin. I have to hide the right fringe or it looks wrong. FWIW here is how I cobbled for gnus article. (defun ivan-gnus-hack-visual-line-length () "Set visual line length by expanding the right margin of the buffer=E2=80=99s window." (let ((window (selected-window))) (select-window (car (get-buffer-window-list gnus-article-buffer))) (set-window-margins nil 0 (- (window-width) 80)) (set-window-fringes (selected-window) 8 0) (visual-line-mode) (select-window window))) (add-hook 'gnus-article-prepare-hook 'ivan-gnus-hack-visual-line-length) It just feels hackish and wrong. The right thing I feel is to use fill-column. Ivan --=20 You must've hit the wrong any key. -- BOFH excuse #52