From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Jakub =?UTF-8?Q?Je=C4=8Dm=C3=ADnek?= Newsgroups: gmane.emacs.bugs Subject: bug#64205: Fix missing cell border when using orgtbl-to-table.el function Date: Wed, 21 Jun 2023 17:42:22 +0200 Message-ID: References: <87ttv0g7nk.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="000000000000ca140a05fea59d81" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="32507"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 64205@debbugs.gnu.org To: Robert Pluim Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Jun 21 18:23:22 2023 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 1qC0c5-0008IU-Qp for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 21 Jun 2023 18:23:21 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qC0bo-0002tF-Hh; Wed, 21 Jun 2023 12:23:04 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qC0bm-0002py-V1 for bug-gnu-emacs@gnu.org; Wed, 21 Jun 2023 12:23:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1qC0bm-0003nl-MO for bug-gnu-emacs@gnu.org; Wed, 21 Jun 2023 12:23:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qC0bm-0003M6-4Y for bug-gnu-emacs@gnu.org; Wed, 21 Jun 2023 12:23:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Jakub =?UTF-8?Q?Je=C4=8Dm=C3=ADnek?= Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 21 Jun 2023 16:23:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64205 X-GNU-PR-Package: emacs Original-Received: via spool by 64205-submit@debbugs.gnu.org id=B64205.168736453212788 (code B ref 64205); Wed, 21 Jun 2023 16:23:02 +0000 Original-Received: (at 64205) by debbugs.gnu.org; 21 Jun 2023 16:22:12 +0000 Original-Received: from localhost ([127.0.0.1]:34143 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qC0ax-0003KB-Uw for submit@debbugs.gnu.org; Wed, 21 Jun 2023 12:22:12 -0400 Original-Received: from mail-yb1-f173.google.com ([209.85.219.173]:45172) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qBzyh-00021A-Hu for 64205@debbugs.gnu.org; Wed, 21 Jun 2023 11:42:40 -0400 Original-Received: by mail-yb1-f173.google.com with SMTP id 3f1490d57ef6-bc379e4c1cbso6198527276.2 for <64205@debbugs.gnu.org>; Wed, 21 Jun 2023 08:42:39 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1687362154; x=1689954154; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=IUP2k4gzk23OBJ2TTp0cOl2M0ox/qHhKuTOnysylia4=; b=Cppq624MgmaV4THFoL1omeF0kJ0YmBF9vW21kQDJJavhvsV8WozYC03GTtKHfApSkT pq30z2cWFyVRwe4o8LWqIJCFvPlLcXwhf+wVHUNDp1T42xhWBdQAjZL0ORc4jUl7KgJ+ ZUbcPHLQRDW7Bnpw6QvQhVFwxujRbXguNx4e3/KVn3Zjx9Y0INZTH4XJYuqEgoFoW3Lo OUCL0k5oXZmBVGh0N57QoO2S0FkZuhVZ1q9Z1zd1TqngE5eYLNu6/mjK2HKm7OgLMBGO 94V5MXowsyItHnaGNSApNtFljcBVZ0FQL/CpDeE+fLmUxvvPWiHWQMwhmbyfV6BVKzm4 Upww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1687362154; x=1689954154; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=IUP2k4gzk23OBJ2TTp0cOl2M0ox/qHhKuTOnysylia4=; b=Coxy6yfaBBcp3qEOFrNFmezl3qdchy/HU/hpUwOIzpKOwFRo2hxx4iSyU2TBvYM37J 7RC51NoNC6QM2zTGkG6W/dveFakEZTDrsWJFu7sCBtS/qU6L40ShR5lu+XZGCHu+nZyJ h2f1IDn4WTWJRsJQRyJqj8+CVvwBeCERmn6i8+mg86KA9TfFSESz3MCtz6g3t90BBGoR rM1f4L4t1bLZpM4LO4eYAukrPry02Od0MSe8A3ywpx7mVSMRE2fAsuGwz/YLcLCNR2sq HNVfeZjSKEG+FI3EpyUn3sP/uJkdv2o6PfjhlclX+lDtAerH5MdxzS0wSgckqS+Qhs63 TJDg== X-Gm-Message-State: AC+VfDxTipsyyqJfOY8VfyoRjkCLyZVJS8hfZi53/zWhnVeVPkZTAky3 AEHcz5OmYGfXpo2cMs8DQ1oYUWtVSrmxVM8UrR4= X-Google-Smtp-Source: ACHHUZ6PuilnokwFNl7QiRgzJTm8Zp1BeQw1n1+mJN0Gb42i0K0scUJrMhqIkVsSJUbhvF55TN/QewtpC1Alk07eRYk= X-Received: by 2002:a5b:d02:0:b0:be6:74b1:b73f with SMTP id y2-20020a5b0d02000000b00be674b1b73fmr13554185ybp.18.1687362153855; Wed, 21 Jun 2023 08:42:33 -0700 (PDT) In-Reply-To: <87ttv0g7nk.fsf@gmail.com> X-Mailman-Approved-At: Wed, 21 Jun 2023 12:22:10 -0400 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-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:263842 Archived-At: --000000000000ca140a05fea59d81 Content-Type: multipart/alternative; boundary="000000000000ca140905fea59d7f" --000000000000ca140905fea59d7f Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable You're right. There are more of these mistakes in the `org-table' file, for example on line 1061, 1126 and 4666. Jakub st 21. 6. 2023 v 17:24 odes=C3=ADlatel Robert Pluim naps= al: > >>>>> On Wed, 21 Jun 2023 16:08:13 +0200, Jakub Je=C4=8Dm=C3=ADnek < > jecminek.k@gmail.com> said: > Jakub> diff --git a/lisp/org/org-table.el b/lisp/org/org-table.el > Jakub> index 42f234790c5..6810fd8dc5a 100644 > Jakub> --- a/lisp/org/org-table.el > Jakub> +++ b/lisp/org/org-table.el > Jakub> @@ -6132,9 +6132,13 @@ supported." > Jakub> (with-temp-buffer > Jakub> (insert (orgtbl-to-orgtbl table params)) > Jakub> (org-table-align) > Jakub> - (replace-regexp-in-string > Jakub> - "-|" "-+" > Jakub> - (replace-regexp-in-string "|-" "+-" (buffer-substring 1 > (buffer-size)))))) > Jakub> + (goto-char (point-min)) > Jakub> + (while (re-search-forward "-|" nil t) > Jakub> + (replace-match "-+")) > Jakub> + (goto-char (point-min)) > Jakub> + (while (re-search-forward "|-" nil t) > Jakub> + (replace-match "+-")) > Jakub> + (buffer-string))) > > You=CA=BCre replacing fixed strings, so you could use `search-forward' > instead of `re-search-forward'. > > Robert > -- > --000000000000ca140905fea59d7f Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
You're right. There are more of these mistakes in the = `org-table' file, for example on line 1061, 1126 and 4666.

Jakub

st 21. 6. 2023 v=C2=A017:24 odes=C3=ADlatel Robert Pluim = <rpluim@gmail.com> napsal:
>>>>> On Wed, 21 Jun 2023 16:08:13 += 0200, Jakub Je=C4=8Dm=C3=ADnek <jecminek.k@gmail.com> said:
=C2=A0 =C2=A0 Jakub> diff --git a/lisp/org/org-table.el b/lisp/org/org-t= able.el
=C2=A0 =C2=A0 Jakub> index 42f234790c5..6810fd8dc5a 100644
=C2=A0 =C2=A0 Jakub> --- a/lisp/org/org-table.el
=C2=A0 =C2=A0 Jakub> +++ b/lisp/org/org-table.el
=C2=A0 =C2=A0 Jakub> @@ -6132,9 +6132,13 @@ supported."
=C2=A0 =C2=A0 Jakub>=C2=A0 =C2=A0 (with-temp-buffer
=C2=A0 =C2=A0 Jakub>=C2=A0 =C2=A0 =C2=A0 (insert (orgtbl-to-orgtbl table= params))
=C2=A0 =C2=A0 Jakub>=C2=A0 =C2=A0 =C2=A0 (org-table-align)
=C2=A0 =C2=A0 Jakub> -=C2=A0 =C2=A0 (replace-regexp-in-string
=C2=A0 =C2=A0 Jakub> -=C2=A0 =C2=A0 =C2=A0"-|" "-+"<= br> =C2=A0 =C2=A0 Jakub> -=C2=A0 =C2=A0 =C2=A0(replace-regexp-in-string &quo= t;|-" "+-" (buffer-substring 1 (buffer-size))))))
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 (goto-char (point-min))
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 (while (re-search-forward "-|&q= uot; nil t)
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 =C2=A0 (replace-match "-+"= ))
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 (goto-char (point-min))
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 (while (re-search-forward "|-&q= uot; nil t)
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 =C2=A0 (replace-match "+-"= ))
=C2=A0 =C2=A0 Jakub> +=C2=A0 =C2=A0 (buffer-string)))

You=CA=BCre replacing fixed strings, so you could use `search-forward'<= br> instead of `re-search-forward'.

Robert
--
--000000000000ca140905fea59d7f-- --000000000000ca140a05fea59d81 Content-Type: application/octet-stream; name="0001-Fix-orgtbl-to-table.el-function-to-include-last-cell.patch" Content-Disposition: attachment; filename="0001-Fix-orgtbl-to-table.el-function-to-include-last-cell.patch" Content-Transfer-Encoding: base64 Content-ID: X-Attachment-Id: f_lj5vu69k0 RnJvbSA2MTAyNDk1NGU3NWM0ZTcxZWQ0OGMwNTY2ZTAyZmI2ZTY3YjNlNjg4IE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiA9P1VURi04P3E/SmFrdWI9MjBKZT1DND04RG09QzM9QURuZWs/ PSA8amVjbWluZWsua0BnbWFpbC5jb20+CkRhdGU6IFdlZCwgMjEgSnVuIDIwMjMgMTU6NTA6MzEg KzAyMDAKU3ViamVjdDogW1BBVENIXSBGaXggb3JndGJsLXRvLXRhYmxlLmVsIGZ1bmN0aW9uIHRv IGluY2x1ZGUgbGFzdCBjZWxsIGJvcmRlcgoKKiBsaXNwL29yZy9vcmctdGFibGUuZWwgKG9yZ3Ri bC10by10YWJsZS5lbCk6IFBlcmZvcm0gY2hhcmFjdGVyCnJlcGxhY2VtZW50IGluIHRoZSB0ZW1w IGJ1ZmZlciBhbmQgZml4IG1pc3NpbmcgY2VsbCBib3JkZXIuIChCdWcgIzY0MjA1KQotLS0KIGxp c3Avb3JnL29yZy10YWJsZS5lbCB8IDEwICsrKysrKystLS0KIDEgZmlsZSBjaGFuZ2VkLCA3IGlu c2VydGlvbnMoKyksIDMgZGVsZXRpb25zKC0pCgpkaWZmIC0tZ2l0I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