From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.devel Subject: Re: Native display of line numbers Date: Mon, 19 Jun 2017 10:04:18 +0200 Message-ID: <59478582.30803@gmx.at> References: <83lgoqzm0v.fsf@gnu.org> <59463D74.4040300@gmx.at> <83vantxsja.fsf@gnu.org> <838tkoya31.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1497859579 19217 195.159.176.226 (19 Jun 2017 08:06:19 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 19 Jun 2017 08:06:19 +0000 (UTC) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 19 10:06:12 2017 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1dMrhM-0004fR-9t for ged-emacs-devel@m.gmane.org; Mon, 19 Jun 2017 10:06:12 +0200 Original-Received: from localhost ([::1]:41059 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dMrhR-000511-B9 for ged-emacs-devel@m.gmane.org; Mon, 19 Jun 2017 04:06:17 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:33120) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dMrfq-0004Fc-TE for emacs-devel@gnu.org; Mon, 19 Jun 2017 04:04:42 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dMrfk-0000oC-Kt for emacs-devel@gnu.org; Mon, 19 Jun 2017 04:04:37 -0400 Original-Received: from mout.gmx.net ([212.227.17.22]:57171) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dMrff-0000lv-P6; Mon, 19 Jun 2017 04:04:28 -0400 Original-Received: from [192.168.1.100] ([46.125.250.86]) by mail.gmx.com (mrgmx103 [212.227.17.168]) with ESMTPSA (Nemesis) id 0MgbvP-1d7p8A1Nzz-00Nx6X; Mon, 19 Jun 2017 10:04:25 +0200 In-Reply-To: <838tkoya31.fsf@gnu.org> X-Provags-ID: V03:K0:QeyDxyfs2c/6DNjIUgFLHErC8oF9zrZq+LT8YRm12GXaeW680Xv Csl2MaDtSsuijOeAEdB1nb1ZMfD7FzqdZ2Bq8cDR341uVP7T9ujNxkLQr9M/kPNb6lZI3p2 4b+nrYzWxnwn+ofPEcuxB4+lqk5Deqs/TaeYhMSKSPTasjy0L0UfwTpksI4zHPesXgenAYk uFU1ArRuVL1sb8tMWqu4g== X-UI-Out-Filterresults: notjunk:1;V01:K0:tEm0ocRrEFk=:EV96Z97EJJUtlzFUSbt45S 7XKcbV9Tsy28sZD8uO+dvqStBVMAUOd6wfhM+YdXJxtSn29paQc+x4744Mw2hCa6rSyrHMTEm u/KvOhXNR1Fo5Reqe7Yi+640yUv7H7dKmD69XxNLnorFT7swlYQg2EPlOr8gpl50BSxiJ6JzX 6vpUWGcfpI1lo7Lq+aQDY2J7MCHuvnReS4NRpK6yNQ0AjzKkkBTjZafy1wxptsfUK2naspijR C3d7pnDfWbr5SZ7CP/LhCmvPGZCooIutSuKhtfBrUG2YuxxO+5Qkl/yqmWE7LBjQUapATksMU HRg0ppgs91NAMG+BqQ1DuLIsbs5Qatj4hRW1sjvSA65vRSpxePgLBR2z9eAfdP0fWFnNTfvMQ N/I5tJh7Bjk6ulaoGDa/oG6f4DDdDVw1f3PDzVP/plQhrfQRdjOmiYa4J8tJGex96LDBe+CSN YuiUFeLBF+6gJP3usz5WZ7agds+8b6PxOrcV5U0NfPFhrJPFLgw3Cvfu6VeSxyihcsuoMHq+B dW0D9PjJMDWtnEFz6WeWbEBTGw0AaynQC+ydG3OsSS99DNO+/u6MARhk0Z456a0MS6mYOk4mF dp08XkjpJHDkVX+IoJxQ6FFdUrjDlCzv5oxMD7lYNJPwCrdte7znICHiADPinVu7RNApZOPAj T7HijTjR0MAo2J0T3xgiqf34ojZNg24aZGMaM/j1H2+tqhE4fbVStzAjkX5zqcZvHOOuX+MJ9 VMP4cgts4L0rL+wA5jHsleMBvlQNyvMuYtmJdmJailV3TIWF2SZPeqSnwOrxfqtpMev0vHKN X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 212.227.17.22 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.21 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" Xref: news.gmane.org gmane.emacs.devel:215772 Archived-At: > Btw, the stuff that really bothers me are all those low-level > functions that depends on window geometry for measuring the text-area > width. Line numbers take up some of that space, and it isn't clear to= > me what that breaks. Perhaps you could take a look at the relevant > functions? We may need to provide a primitive which returns the width= > taken by the line number display. If you intend to keep the current implementation, I see no need for such a primitive. The window code doesn't handle =E2=80=98line-prefix=E2=80=99= or =E2=80=98wrap-prefix=E2=80=99 specially either. Things will get problema= tic as soon as you want to display line numbers outside the fringes or margins. But IIUC you currently don't have any intentions to do that. If someone wants the mouse to do something special on line numbers, then coordinates_in_window would have to be amended appropriately. Whether we want to consult the current glyph matrix in that case or keep a LorR bool + a line_number_display_width integer in the window structure is a minor issue IMHO. Maybe a boolean to turn off line numbers for a specific window only would be useful. This can be easily added later. martin