emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* [PATCH] Ensure org-table-header displays without cursor inside table
@ 2024-04-05 14:20 Lei Zhe
  2024-04-05 18:39 ` Ihor Radchenko
  0 siblings, 1 reply; 7+ messages in thread
From: Lei Zhe @ 2024-04-05 14:20 UTC (permalink / raw)
  To: emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 311 bytes --]

Hi org-mode community,

The patch ensures the header of an org-table displays without the cursor
inside the table when org-table-header-line-mode is enabled.

BTW, this is my first patch for org-mode, so please correct me if there
are any issues with it.
Also, I've done the paperwork before.

Regards,
Zhe Lei

[-- Attachment #1.2: Type: text/html, Size: 456 bytes --]

[-- Attachment #2: 0001-Ensure-org-table-header-displays-without-cursor-insi.patch --]
[-- Type: application/octet-stream, Size: 905 bytes --]

From 78a41e6d8367b8e70ca6a9b81ba20c0a86e01ce1 Mon Sep 17 00:00:00 2001
From: llcc <lzhes43@gmail.com>
Date: Fri, 5 Apr 2024 22:07:12 +0800
Subject: [PATCH] Ensure org-table-header displays without cursor inside table

---
 lisp/org-table.el | 1 +
 1 file changed, 1 insertion(+)

diff --git a/lisp/org-table.el b/lisp/org-table.el
index bd8d59f45..5475b6d42 100644
--- a/lisp/org-table.el
+++ b/lisp/org-table.el
@@ -494,6 +494,7 @@ This may be useful when columns have been shrunk."
           (redisplay)
           (let* ((ws (window-start))
                  (beg (save-excursion
+                        (goto-char ws)
                         (goto-char (org-table-begin))
                         (while (or (org-at-table-hline-p)
                                    (looking-at-p ".*|\\s-+<[rcl]?\\([0-9]+\\)?>"))

base-commit: e9c288dfaccc2960e5b6889e6aabea700ad4e05a
-- 
2.39.3 (Apple Git-146)


^ permalink raw reply related	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2024-04-12 23:55 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-04-05 14:20 [PATCH] Ensure org-table-header displays without cursor inside table Lei Zhe
2024-04-05 18:39 ` Ihor Radchenko
     [not found]   ` <CALjq+LYwpu+Chej9ZbDV=qYGKhnTvBBeTgVvw3QV7dm-WB0WTQ@mail.gmail.com>
2024-04-06  0:29     ` Fwd: " Lei Zhe
2024-04-06 12:36     ` Ihor Radchenko
2024-04-12  9:23       ` Bastien Guerry
2024-04-12 18:05         ` Ihor Radchenko
2024-04-12 23:53           ` Lei Zhe

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).