From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Carlos Pita Newsgroups: gmane.emacs.bugs Subject: bug#31717: Date: Tue, 5 Jun 2018 00:30:10 -0300 Message-ID: References: <87vaaym04z.fsf@carlos.i-did-not-set--mail-host-address--so-tickle-me> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" X-Trace: blaine.gmane.org 1528169358 31068 195.159.176.226 (5 Jun 2018 03:29:18 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 5 Jun 2018 03:29:18 +0000 (UTC) To: 31717@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jun 05 05:29:14 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1fQ2ei-0007uy-M4 for geb-bug-gnu-emacs@m.gmane.org; Tue, 05 Jun 2018 05:29:08 +0200 Original-Received: from localhost ([::1]:43103 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fQ2gp-0002bv-MY for geb-bug-gnu-emacs@m.gmane.org; Mon, 04 Jun 2018 23:31:19 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:45220) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fQ2gd-0002bc-F1 for bug-gnu-emacs@gnu.org; Mon, 04 Jun 2018 23:31:08 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fQ2gY-0007sY-JX for bug-gnu-emacs@gnu.org; Mon, 04 Jun 2018 23:31:07 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:54171) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fQ2gY-0007sI-EE for bug-gnu-emacs@gnu.org; Mon, 04 Jun 2018 23:31:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fQ2gY-0004uQ-2N for bug-gnu-emacs@gnu.org; Mon, 04 Jun 2018 23:31:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <87vaaym04z.fsf@carlos.i-did-not-set--mail-host-address--so-tickle-me> Resent-From: Carlos Pita Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 05 Jun 2018 03:31:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 31717 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 31717-submit@debbugs.gnu.org id=B31717.152816943918822 (code B ref 31717); Tue, 05 Jun 2018 03:31:02 +0000 Original-Received: (at 31717) by debbugs.gnu.org; 5 Jun 2018 03:30:39 +0000 Original-Received: from localhost ([127.0.0.1]:33835 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fQ2gA-0004tV-VB for submit@debbugs.gnu.org; Mon, 04 Jun 2018 23:30:39 -0400 Original-Received: from mail-io0-f176.google.com ([209.85.223.176]:36966) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fQ2g9-0004tC-7O for 31717@debbugs.gnu.org; Mon, 04 Jun 2018 23:30:37 -0400 Original-Received: by mail-io0-f176.google.com with SMTP id s26-v6so1563611ioj.4 for <31717@debbugs.gnu.org>; Mon, 04 Jun 2018 20:30:37 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=2fE/jNNfkDiTJK4c0/NLg8sJk6VmNCZQCBLUTnukv68=; b=uSPjpcQjG0xkJqesvFb1hhKERIl+L79NnTIN+hOe7huxRUOWOBl6dbMJATjGaQmsHE JfPwR1vrFYkMDGEfyxqfmaz+EV/W2O6MMVuJIdivfLRrN9FkHAFx4ngBcMDZgxLlfAMm 80Yk9yVDp8pjiPzIX5zun8fpHkfOECZVLE4BLGpRFxfVWoPe1yCKrCTL8o+InZ7UFhx0 0WT7Fkr4FPvwUCCLWAKmsmvDVqprl5DXlwgen7GjQhM/joLSddMYT+NDg0rPa1+QiH4M fmqewX9LlPfwQpkxCnygkj0tamayHvQpjEOELCi3QeA5GNtoHrtK1iav1xvjRFvpUIfm JXFQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=2fE/jNNfkDiTJK4c0/NLg8sJk6VmNCZQCBLUTnukv68=; b=dCkeVCUne/Dbp5jroydvq3Y7WJsSzAxbvjXJXju0iQ7QLINCQnfFzNDPMcSUC65Vn6 vjHTolLW9ptclIm1dqqzVlfIFnqoiJB8i8hwekkFnKjkNQm9eWV//Waba/cGr7ZGj7bd U8CiZTxRcgrMPNAIlnlbp0pnLHN0FhHLU7zA8T8fYlwZMCHJDbqV73tFg+TSrI5IeI+J 7kNz3FqRBK3e/g0MeQ6vRZ5AJ3okgh/IbiZh+u3+ZlHIVYVnpo8VG56p4gNHDnr42zZQ Ztrcl76K1N5sEGu7/q6GqNTrYljifakD7c/bx5qWMJ/+xi1+3pSyLmFUGJK0xsZfdAyq Rquw== X-Gm-Message-State: ALKqPwcGQO2ca6YnFbaC9B0qAWJHqJqkezR4nsMsQhM4NXO7afzF8eEq oJubWUI3M+e/vaA9qRkvwWTuyz4NtOkRQz6nIxg= X-Google-Smtp-Source: ADUXVKJD9VxPdfN/6DyppPlUYdWWLtvGJSDcYv7AMI72stg8q+4hLeKY1HMBptlf4pQJj0C1n2vKFhU04Sk0xPXNfaE= X-Received: by 2002:a6b:2b10:: with SMTP id r16-v6mr23261077ior.204.1528169431457; Mon, 04 Jun 2018 20:30:31 -0700 (PDT) Original-Received: by 2002:a02:a98e:0:0:0:0:0 with HTTP; Mon, 4 Jun 2018 20:30:10 -0700 (PDT) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:146991 Archived-At: A little more experimentation with different windows sizes made me realize that the <70 hard and fast rule doesn't exist. Now I see the threshold indeed depends on the window size. But it is still too conservative, leading to premature enlargement of the line number space. I suggest three optimizations in order of assumed (wild guessed) ascending difficulty: 1. For relative/visual modes never reserve extra space. 2. If the lines in the file are < N never reserve extra space for >= N. 3. Take also into account the remaining window lines (I assume this is not as easy as it sounds).