From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Alex Newsgroups: gmane.emacs.devel Subject: Re: Native display of line numbers, improved Date: Sun, 25 Jun 2017 21:43:37 -0600 Message-ID: <87a84vl8gm.fsf@lylat> References: <83tw35thxw.fsf@gnu.org> <87efu7lsj0.fsf@lylat> <83r2y7sc9q.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: blaine.gmane.org 1498448673 669 195.159.176.226 (26 Jun 2017 03:44:33 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 26 Jun 2017 03:44:33 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.0.50 (gnu/linux) Cc: emacs-devel@gnu.org To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Mon Jun 26 05:44:26 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 1dPKws-0008Ff-A3 for ged-emacs-devel@m.gmane.org; Mon, 26 Jun 2017 05:44:26 +0200 Original-Received: from localhost ([::1]:44561 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dPKwx-000065-Ey for ged-emacs-devel@m.gmane.org; Sun, 25 Jun 2017 23:44:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:53886) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dPKwr-00005y-9h for emacs-devel@gnu.org; Sun, 25 Jun 2017 23:44:26 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dPKwm-0004oY-Dc for emacs-devel@gnu.org; Sun, 25 Jun 2017 23:44:25 -0400 Original-Received: from mail-it0-x231.google.com ([2607:f8b0:4001:c0b::231]:35812) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dPKwm-0004oS-9O; Sun, 25 Jun 2017 23:44:20 -0400 Original-Received: by mail-it0-x231.google.com with SMTP id v202so14272663itb.0; Sun, 25 Jun 2017 20:44:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=Lf0rf1jJw5Lt63kHC1G1CHzEIu+uOg1pT81DLeKBZKk=; b=Y9qcf93f1Oqvjj3ce7oALna9cXdIak/4kROKDVDt7ECDwpfqm/Tf4LMAW93102s3Sj yM6hc2RDPwYaiYucpsTl976TTM3YjtmTcCCWW5c7UCDeHDQBW6dJQ1AqFl8PbH4szhxT TzEGx1BMnnFwbEKkoC1OE8MkaxMyIZB6CNUK9ihC4IQmjkslOVURltOgFTtIkx8dFGt7 w0Fr+gSfFHih8HYXdWfx9p/18KK52HMsH5Q8MBc9Ayr19+LZ5tEBMJmsc3r0izEWuLdF IZIlU5shMwAm62pp3mLturqx/t23pFHmjZf83Eg4cQHE29zDyz+F41Bb+8W9qFV9xZSW VlsA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=Lf0rf1jJw5Lt63kHC1G1CHzEIu+uOg1pT81DLeKBZKk=; b=o6Z7KNZ7LnefW5gRxrzQohPTS8G1J47AnC63qmvrMudchNorQs//Z8ss5xVZYlZbwZ F8OW+DBcWE9vfcaapbZ/3UzC+oiFzeT3cZzgWwgrct/cqkjXGB5rV7hYqpukZRuwRM08 p1n1GoT63bvZvhjYKMiUUWRCgahYMl+kNHF9XkZIPJVK3E6HfKUSAM+aaQ8cFq5ugvcw VyKxjADEd655v9T+MZJVKCLYEo4PG6jUkBInZPa7S0JJGjeKJduYDn9/m5yjE5nOCDv9 3opUbf5pVwgnGAJw5TZNXH5OcMB6Z1qV3TE/be1MvqH56VXxYtrn91y1XaWzc+pc0frP ngWg== X-Gm-Message-State: AKS2vOyDBZef1YXxcQpC06kWBMT55X+2YE/3BBSXvWlbz+2LsGJr9lTk ntL5UljmUQ0Q2Rox X-Received: by 10.36.239.133 with SMTP id i127mr20431108ith.57.1498448658059; Sun, 25 Jun 2017 20:44:18 -0700 (PDT) Original-Received: from lylat (S010664777d9cebe3.ss.shawcable.net. [70.64.85.59]) by smtp.gmail.com with ESMTPSA id e14sm6836001itc.30.2017.06.25.20.44.16 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 25 Jun 2017 20:44:17 -0700 (PDT) In-Reply-To: <83r2y7sc9q.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 26 Jun 2017 05:39:29 +0300") X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2607:f8b0:4001:c0b::231 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:215988 Archived-At: Eli Zaretskii writes: >> From: Alex >> Cc: emacs-devel@gnu.org >> Date: Sun, 25 Jun 2017 14:30:11 -0600 >> >> 1. An option to never dynamically shrink 'display-line-number-width' >> while still dynamically growing. I dislike having column 0 constantly >> changing, so an option to only grow the width dynamically like in >> (n)linum would be very appreciated. > > How is growing different from shrinking? Just wondering. Growing is necessary in the case where the width of the new line(s) exceeds the current 'display-line-number-width'. Of course that can be worked around by setting 'display-line-number-width' to a sufficiently large number, but I would like it to be no larger than what it needs to be for the current text in the buffer. Shrinking on the other hand is never necessary. >> 2. Building off of the above, it would be nice if there was an option to >> calculate the minimum line number width of a buffer when visiting it, >> like in linum. > > What is the definition of "the minimum line number width of a buffer"? Sorry for being vague. What I meant was "the number of digits to display the last line in the buffer". For example, if the file has 10000 lines, then when visiting it 'display-line-number-width' should be immediately set to 5.