From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Christoph Arenz Newsgroups: gmane.emacs.bugs Subject: bug#54800: 28.1; calc: Cursor positioned at weird position in calc stack Date: Mon, 11 Apr 2022 12:25:24 +0200 Message-ID: <4792caf2-0ef7-d768-6b0a-c87f38cde558@web.de> References: <4a0319d6-b533-b3d8-bf52-bb18d74757e1@web.de> <831qy6aewb.fsf@gnu.org> <3e3b4386-9720-60bb-1e54-fa7326191b7a@web.de> <83k0by8js0.fsf@gnu.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="6762"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.7.0 Cc: 54800@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Apr 11 12:26:50 2022 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1ndrFy-0001VQ-Df for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 11 Apr 2022 12:26:50 +0200 Original-Received: from localhost ([::1]:35862 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ndrFw-0005UI-KP for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 11 Apr 2022 06:26:48 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:57346) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ndrFE-0005OZ-2M for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2022 06:26:05 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:48718) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1ndrFB-0007LQ-Vc for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2022 06:26:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1ndrFB-0001OL-S6 for bug-gnu-emacs@gnu.org; Mon, 11 Apr 2022 06:26:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Christoph Arenz Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 11 Apr 2022 10:26:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 54800 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 54800-submit@debbugs.gnu.org id=B54800.16496727345306 (code B ref 54800); Mon, 11 Apr 2022 10:26:01 +0000 Original-Received: (at 54800) by debbugs.gnu.org; 11 Apr 2022 10:25:34 +0000 Original-Received: from localhost ([127.0.0.1]:42614 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ndrEk-0001NW-77 for submit@debbugs.gnu.org; Mon, 11 Apr 2022 06:25:34 -0400 Original-Received: from mout.web.de ([212.227.17.12]:34083) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ndrEh-0001NI-M6 for 54800@debbugs.gnu.org; Mon, 11 Apr 2022 06:25:32 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=web.de; s=dbaedf251592; t=1649672725; bh=e00s/VVmQB9PmmMItyrG/dch1+rqoZJu0Mf89BlWrSA=; h=X-UI-Sender-Class:Date:Subject:To:Cc:References:From:In-Reply-To; b=Jx3T0AQpglvPjWD7M9c9t8Yanvagou5Su06WmrZih4IEbWDQlhfX4RUlxdumLGq31 igc14gPNO7SZxqBBBij8skob0orkTPbs3l4DxR1Hikfpv3GcBcN09HtoW9Q5bgzEOG lLtnON6B2ODxRyNIbnqYLpjphWjnrPawfFR0HEvs= X-UI-Sender-Class: c548c8c5-30a9-4db5-a2e7-cb6cb037b8f9 Original-Received: from [192.168.188.20] ([5.83.186.215]) by smtp.web.de (mrweb105 [213.165.67.124]) with ESMTPSA (Nemesis) id 1MyNwk-1nsOTZ1Rxk-00yiic; Mon, 11 Apr 2022 12:25:25 +0200 Content-Language: en-US In-Reply-To: <83k0by8js0.fsf@gnu.org> X-Provags-ID: V03:K1:xDySZ9dNFPu/mDeb3Ln0dkhSMQPecNv4f+sFqiuzW8pyKIhlG2y 2DYWn8fWJhBM47hWfYxnq2j981vVW91voCzGJesqORiCth4I6oFD97zYbhqv34MBV/0NW9r xvTmKiJpTMSHFP1uWcZw9lWhuj8lwKx/wBS1mGLJr2XwbO7VPxoeZaWob6HNONxkO6bTAvc 615KDfMpcFdGDrr474Ktw== X-UI-Out-Filterresults: notjunk:1;V03:K0:pEng3eu6aTs=:0cGPRwOaazcVbjcFcZfCjM IWy8XFeBB0MDWlCtSNiIK06Qvii4gfRkZF8Q3ec9G1ZZxeBC4yiOtsAmfbEvG2DWTr6ZsOSNi XHPTkMKk4Ft+gwuxTElmPGEM7IDF97Ra4Fd/Ojpg2HI2sQiMc2vtr7gRiRzTaDt17TmaQ4xbO DkJ6LSHrUorXY4a4HQAfPtmD+H/Vo6NKxdB15eyvHpOuG+Q/nu4SBsEbDZGDDZy9NsbpH/Km+ P0IeK6oy3w45/gu4mMYmAZTa40JUyY2Dvc+69X6fFjaKKjVX7S3ka83k4n2zT2aHU9DOMVOhJ trYj8PQ60Lh+F3GeapfY8SrBk5/DWFin+lBJLakPStMKPUbSeq7YW5jCbDeS48wsT5jUd7kuu G6yEVWp+jXt1VL8frSy0RAi6zPiheP398SMofU8CAhOHhNR9td9EDth7RzIn2H/231DFS4aoJ Wg5KlDJyjx4LVUzK8Kanf3B2/YOAL8n1MmBqzhYsS0H0LXQLIDkG4WFInrDEPvACGcMXyrSC/ Dn2CFcgKWEbwBd37veKIbZneRWfKuLzGC83JY3fZT5L6LaYjBZnkibhZGu7q6Aj6eOeegAAwO +Q0dY5VcSnSxENG9HCF/DHQVw6Wnwyb35EOmtXFKfxHBOQ2NGkqxVvrIJ2+uBRp7M4Q/J+9Y0 15YsSZjpd38p35i8TjoxFq4hpiqquldsFLjnHWkrZdVdODGmiuYqUUVqtSyc35jybUl90xeAd J+nntsPuF/M5SYKB0pgxrgft5mfslsgOcidupFGoEjiLUPfeymG0KHF0BgfbqyHS1uHnBwCj X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:229705 Archived-At: On 09.04.22 15:32, Eli Zaretskii wrote: >> Date: Sat, 9 Apr 2022 14:31:06 +0200 >> Cc: 54800@debbugs.gnu.org >> From: Christoph Arenz >> >>> I think the bug is actually off-by-one error, because the >>> vertical-motion call doesn't take the header-line into account. So I >>> suggest the following patch instead, please see if it solves the >>> problem: >> Your patch solves the problem and shows maximum content of the stack >> in the window. > Thanks, I installed the fix on the emacs-28 branch. > I noticed that while the patch fixes the problem in most cases, depending on the height of the calc stack window, there can be the case that the cursor is not positioned on the top-of-stack symbol `.' but one line above, at the beginning of the line with the first stack entry. This can be changed by using the number 4 instead of 3 in the patch. Not sure if this is the best fix. (vertical-motion (- 4 (window-height win)))