From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Boruch Baum Newsgroups: gmane.emacs.bugs Subject: bug#18183: 24.3; table-fixed-width-mode fails with kill/yank Date: Mon, 7 Dec 2020 13:21:56 -0500 Message-ID: <20201207182156.q2wzdjjbiyt63kh5@E15-2016.optimum.net> References: <53DE7C34.6030304@gmx.com> <87y2idizbd.fsf@gnus.org> <20201206090648.n23pfcopzkalkwqb@E15-2016.optimum.net> <877dpvc8hm.fsf@gnus.org> <20201206182023.jabgkssgn2g4okjt@E15-2016.optimum.net> <871rg1k9hr.fsf@gnus.org> <87wnxtiubi.fsf@gnus.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="16059"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: NeoMutt/20180716 Cc: 18183@debbugs.gnu.org To: Lars Ingebrigtsen Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Mon Dec 07 19:24:23 2020 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 1kmLBN-00043N-4M for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 07 Dec 2020 19:24:21 +0100 Original-Received: from localhost ([::1]:35018 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kmLBL-0007Tw-Ke for geb-bug-gnu-emacs@m.gmane-mx.org; Mon, 07 Dec 2020 13:24:19 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:35182) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kmLA6-0007S7-AL for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2020 13:23:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:43941) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kmLA6-0008KI-1u for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2020 13:23:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kmLA5-0004P2-TX for bug-gnu-emacs@gnu.org; Mon, 07 Dec 2020 13:23:01 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Boruch Baum Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 07 Dec 2020 18:23:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 18183 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: moreinfo Original-Received: via spool by 18183-submit@debbugs.gnu.org id=B18183.160736532716858 (code B ref 18183); Mon, 07 Dec 2020 18:23:01 +0000 Original-Received: (at 18183) by debbugs.gnu.org; 7 Dec 2020 18:22:07 +0000 Original-Received: from localhost ([127.0.0.1]:55487 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kmL9D-0004Np-97 for submit@debbugs.gnu.org; Mon, 07 Dec 2020 13:22:07 -0500 Original-Received: from mout.gmx.net ([212.227.17.22]:37083) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kmL9B-0004NH-Cw for 18183@debbugs.gnu.org; Mon, 07 Dec 2020 13:22:06 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1607365319; bh=LpOmdVDGBgeXNJ14UCPwX8PVnSw8/3KTUZWFpd3vAK8=; h=X-UI-Sender-Class:Date:From:To:Cc:Subject:References:In-Reply-To; b=Yoo49PjNpBhlYn7rRLUCLslXb0grRKSyPFt8Pm+qwudvAhwOCpqIAVVPoBmJFW+du FZTygkiAsZHoQlqnpu8AYVRNW1r72c6SJVG2MZBQVrtKpbI2AAoRv8LTMom+cxP1FP 7SPYDGAe/jSKG3AqD2+eI7ceEUD0Jl2MOd77gDps= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Original-Received: from E15-2016.optimum.net ([70.19.86.82]) by mail.gmx.com (mrgmx104 [212.227.17.174]) with ESMTPSA (Nemesis) id 1MY6Cb-1keoEE0KHF-00YQsR; Mon, 07 Dec 2020 19:21:59 +0100 Content-Disposition: inline In-Reply-To: <87wnxtiubi.fsf@gnus.org> X-Provags-ID: V03:K1:M/toHEK+KM+OKExxFkwK6obmTMkxRTr2rr+AUAYiGYcI04sD7HF Urj+dldWO/9Z1zpGiCvb6Ms9/WvcmQwS+RYDo+C9VHO3bTX7wkXMYTshg4GdzY0oQ1Onwfn n2M2u07+/eigB7mgaoQsufTe+0eh3YJwjmhqjBVn6wYJBjfVkaD+vHpwbvuRGWWAKMHliRv dxmmXTrUifDHsgP7mSC3A== X-UI-Out-Filterresults: notjunk:1;V03:K0:+0RXlAn/Vx8=:6QZimoZysaollXIUizMHHX 8p3Y7KbCMUj2lx3eeC2SNPoid7tRP6Y1yOj7/t5EgQwASzbpqT3woPi+t9e4KUXe2GVmLVg/Z Lt36IL3uxk6G3CJXuu4rEq0YTUj/EDeNR1UF0V+WNJc9y4Pu7/utfemijl5AqK0D0qZ2xCg8J ejjfpsm3R1OU8eiEdkf3Px8GzJG1zU+mrg2nzmy+UbkHfy8ezhnLiNkOCpHFi9ltvjc39rkCS ot5zeeGDVaRf2sA0FoLsUvFzMZGY5iFZIJXQ5iURG46OYaKqbZ4awNw9VoAya/4lI7EMPWcon Hv0LXTZxlAbt3x7XeXVEEO8i5GpJ84ze9exhMx2y7CeSqz3PKPGJKjRKARMhildeqlRNe4Ph5 82/ST3rybF84p26S7KOcPw8eb6LrY5wHYfvUCkrVdErwWL4RUOSoqIEavTeCIgREZtR/JFyF8 T2RuqL6SQVwVpNGArhxwz27Qb2cqxgoO0rQ3aUJiQEhoM0G2q05vD3LhmqHPFxxgW+tpUZkgZ aTCJcCglkFGhiDH5X27UdN4A6o6uae4i8yHZEt9Uknzvg1BP2/ta5Jo7Js//Indz1OL5e7R4B wpqfFH+Py92lymseLABgvB9RJz6Tr8+saqmEeTBxY05AKj88FrI8EDfSjrQVGiqx68673CEtI Er9LXON72DRgFtXeQXjZ/oqOLPP5dlI8X9vblsVy2FPKrhz0aGLMUqxQ2ncEPhu1Rd/X3QtSx VFTP3auZBpWr/lJekvA5DDcEFxdquA7hiMmA5KurS9IQtLhO8eE+RoxAmCUd8W7BjTm7+guT 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:195279 Archived-At: I think I have a fix, centered around adding two lines to function table--update-cell. In the snippet below, the new lines are marked with an arrow ; <-------- (defun table--update-cell (&optional now) "Update the table cell contents. When the optional parameter NOW is nil it only sets up the update timer. If it is non-nil the function copies the contents of the cell cache buffer into the designated cell in the table buffer." (if (null table-update-timer) nil (table--cancel-timer table-update-timer) (setq table-update-timer nil)) (if (or (not now) (and (boundp 'quail-converting) quail-converting) ;; defer operation while current quail work is n= ot finished. (and (boundp 'quail-translating) quail-translating)) (setq table-update-timer (table--set-timer table-time-before-update (function table--update-cell) 'now)) (save-current-buffer (set-buffer table-cell-buffer) (let ((cache-buffer (get-buffer-create table-cache-buffer-name)) (org-coord (table--get-coordinate)) (fixed table-fixed-width-mode) ; <-------- (in-cell (equal (table--cell-to-coord (table--probe-cell)) (cons table-cell-info-lu-coordinate table-cell-info-rb-coordinate))= ) rectangle) (set-buffer cache-buffer) (setq-local table-fixed-width-mode fixed) ; <--------- (setq rectangle (extract-rectangle 1 (table--goto-coordinate (cons table-cell-info-width (1- table-cell= -info-height))))) (set-buffer table-cell-buffer) (delete-rectangle (table--goto-coordinate table-cell-info-lu-coordinate) (table--goto-coordinate table-cell-info-rb-coordinate)) (table--goto-coordinate table-cell-info-lu-coordinate) (table--insert-rectangle rectangle) (let* ((cell (table--probe-cell))) ; must probe again in case of wide cha= racters (table--put-cell-property cell) (table--put-cell-justify-property cell table-cell-info-justify) (table--put-cell-valign-property cell table-cell-info-valign)) (table--goto-coordinate (if in-cell (table--transcoord-cache-to-table table-cell-cache-point-coordinate) org-coord)))) ;; simulate undo behavior under overwrite-mode (if (and overwrite-mode (not (eq buffer-undo-list t))) (setq buffer-undo-list (cons nil buffer-undo-list))))) =2D- hkp://keys.gnupg.net CA45 09B5 5351 7C11 A9D1 7286 0036 9E45 1595 8BC0