aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJuanma Barranquero2003-06-05 20:07:16 +0000
committerJuanma Barranquero2003-06-05 20:07:16 +0000
commite99add213b5dec56a1eba522937a979e91245b49 (patch)
treef9755141509bf0c9b81ddcd5ad1dc9a4b32eb8c4
parent0f9c2d466cc667f2c0309f77c92d8ff9f3aae0ad (diff)
downloademacs-e99add213b5dec56a1eba522937a979e91245b49.tar.gz
emacs-e99add213b5dec56a1eba522937a979e91245b49.zip
(table-cell-horizontal-chars): Renamed from table-cell-horizontal-char. Now a
string value instead of a character. ?= is allowed for horizontal boundary as well as ?-. (table-command-remap-alist, table-command-list): Changed defconst to defvar because the value is modified. (table-insert, table-insert-row, table-insert-column, table-recognize) (table-recognize-region, table-widen-cell, table-span-cell) table-split-cell-vertically): Change due to table-cell-horizontal-chars. (table--cell-horizontal-char-p): New function. (table--generate-source-scan-lines, table-delete-row, table-delete-column) (table--spacify-frame, table--find-row-column, table--probe-cell-left-up) (table--probe-cell-right-bottom, table--probe-cell): Change due to table-cell-horizontal-chars. From David Abrahams <dave@boost-consulting.com>
-rw-r--r--lisp/ChangeLog19
-rw-r--r--lisp/textmodes/table.el99
2 files changed, 74 insertions, 44 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 3d9b5485c73..baa8a657d4d 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,22 @@
12003-06-05 Takaaki Ota <Takaaki.Ota@am.sony.com>
2
3 * textmodes/table.el (table-cell-horizontal-chars): Renamed from
4 table-cell-horizontal-char. Now a string value instead of a
5 character. ?= is allowed for horizontal boundary as well as ?-.
6 (table-command-remap-alist, table-command-list): Changed defconst to
7 defvar because the value is modified.
8 (table-insert, table-insert-row, table-insert-column)
9 (table-recognize, table-recognize-region, table-widen-cell)
10 (table-span-cell, table-split-cell-vertically): Change due to
11 table-cell-horizontal-chars.
12 (table--cell-horizontal-char-p): New function.
13 (table--generate-source-scan-lines, table-delete-row)
14 (table-delete-column, table--spacify-frame)
15 (table--find-row-column, table--probe-cell-left-up)
16 (table--probe-cell-right-bottom, table--probe-cell): Change due to
17 table-cell-horizontal-chars. From David Abrahams
18 <dave@boost-consulting.com>
19
12003-06-05 Juanma Barranquero <lektu@terra.es> 202003-06-05 Juanma Barranquero <lektu@terra.es>
2 21
3 * gud.el: Moved to progmodes. 22 * gud.el: Moved to progmodes.
diff --git a/lisp/textmodes/table.el b/lisp/textmodes/table.el
index db5b9a7c35d..2edf604ecbf 100644
--- a/lisp/textmodes/table.el
+++ b/lisp/textmodes/table.el
@@ -5,7 +5,7 @@
5;; Keywords: wp, convenience 5;; Keywords: wp, convenience
6;; Author: Takaaki Ota <Takaaki.Ota@am.sony.com> 6;; Author: Takaaki Ota <Takaaki.Ota@am.sony.com>
7;; Created: Sat Jul 08 2000 13:28:45 (PST) 7;; Created: Sat Jul 08 2000 13:28:45 (PST)
8;; Revised: mar feb 18 2003 10:03:18 (Romance Standard Time) 8;; Revised: jue jun 05 2003 22:00:02 (Hora de verano romance)
9 9
10;; This file is part of GNU Emacs. 10;; This file is part of GNU Emacs.
11 11
@@ -688,10 +688,10 @@ height."
688 :tag "Cell Face" 688 :tag "Cell Face"
689 :group 'table) 689 :group 'table)
690 690
691(defcustom table-cell-horizontal-char ?\- 691(defcustom table-cell-horizontal-chars "-="
692 "*Character that forms table cell's horizontal border line." 692 "*Characters that may be used for table cell's horizontal border line."
693 :tag "Cell Horizontal Boundary Character" 693 :tag "Cell Horizontal Boundary Characters"
694 :type 'character 694 :type 'string
695 :group 'table) 695 :group 'table)
696 696
697(defcustom table-cell-vertical-char ?\| 697(defcustom table-cell-vertical-char ?\|
@@ -986,7 +986,7 @@ This is always set to nil at the entry to `table-with-cache-buffer' before execu
986 ) 986 )
987 "Bindings for table cell commands.") 987 "Bindings for table cell commands.")
988 988
989(defconst table-command-remap-alist 989(defvar table-command-remap-alist
990 '((self-insert-command . *table--cell-self-insert-command) 990 '((self-insert-command . *table--cell-self-insert-command)
991 (completion-separator-self-insert-autofilling . *table--cell-self-insert-command) 991 (completion-separator-self-insert-autofilling . *table--cell-self-insert-command)
992 (completion-separator-self-insert-command . *table--cell-self-insert-command) 992 (completion-separator-self-insert-command . *table--cell-self-insert-command)
@@ -1004,7 +1004,7 @@ This is always set to nil at the entry to `table-with-cache-buffer' before execu
1004 (dabbrev-completion . *table--cell-dabbrev-completion)) 1004 (dabbrev-completion . *table--cell-dabbrev-completion))
1005 "List of cons cells consisting of (ORIGINAL-COMMAND . TABLE-VERSION-OF-THE-COMMAND).") 1005 "List of cons cells consisting of (ORIGINAL-COMMAND . TABLE-VERSION-OF-THE-COMMAND).")
1006 1006
1007(defconst table-command-list nil 1007(defvar table-command-list nil
1008 "List of commands that override original commands.") 1008 "List of commands that override original commands.")
1009;; construct the real contents of the `table-command-list' 1009;; construct the real contents of the `table-command-list'
1010(let ((remap-alist table-command-remap-alist)) 1010(let ((remap-alist table-command-remap-alist))
@@ -1658,7 +1658,7 @@ Inside a table cell has a special keymap.
1658 (setq cw cell-width) 1658 (setq cw cell-width)
1659 (setq i 0) 1659 (setq i 0)
1660 (while (< i columns) 1660 (while (< i columns)
1661 (insert (make-string (car cw) table-cell-horizontal-char) table-cell-intersection-char) 1661 (insert (make-string (car cw) (string-to-char table-cell-horizontal-chars)) table-cell-intersection-char)
1662 (if (cdr cw) (setq cw (cdr cw))) 1662 (if (cdr cw) (setq cw (cdr cw)))
1663 (setq i (1+ i))) 1663 (setq i (1+ i)))
1664 (setq border-str (buffer-substring (point-min) (point-max))) 1664 (setq border-str (buffer-substring (point-min) (point-max)))
@@ -1748,7 +1748,7 @@ are appended at the bottom of the table."
1748 (while (> i 0) 1748 (while (> i 0)
1749 (setq rect (cons 1749 (setq rect (cons
1750 (concat (if exclude-left "" (char-to-string table-cell-intersection-char)) 1750 (concat (if exclude-left "" (char-to-string table-cell-intersection-char))
1751 (make-string (- (cadr this) (caar this)) table-cell-horizontal-char) 1751 (make-string (- (cadr this) (caar this)) (string-to-char table-cell-horizontal-chars))
1752 (if exclude-right "" (char-to-string table-cell-intersection-char))) 1752 (if exclude-right "" (char-to-string table-cell-intersection-char)))
1753 rect)) 1753 rect))
1754 (let ((j cell-height)) 1754 (let ((j cell-height))
@@ -1801,7 +1801,7 @@ created column(s) are appended at the right of the table."
1801 (coord-list (table--cell-list-to-coord-list (table--vertical-cell-list t nil 'left))) 1801 (coord-list (table--cell-list-to-coord-list (table--vertical-cell-list t nil 'left)))
1802 (append-column (if coord-list nil (setq coord-list (table--find-row-column 'column)))) 1802 (append-column (if coord-list nil (setq coord-list (table--find-row-column 'column))))
1803 (cell-width (car (table--min-coord-list coord-list))) 1803 (cell-width (car (table--min-coord-list coord-list)))
1804 (border-str (table--multiply-string (concat (make-string cell-width table-cell-horizontal-char) 1804 (border-str (table--multiply-string (concat (make-string cell-width (string-to-char table-cell-horizontal-chars))
1805 (char-to-string table-cell-intersection-char)) n)) 1805 (char-to-string table-cell-intersection-char)) n))
1806 (cell-str (table--multiply-string (concat (table--cell-blank-str cell-width) 1806 (cell-str (table--multiply-string (concat (table--cell-blank-str cell-width)
1807 (let ((str (string table-cell-vertical-char))) 1807 (let ((str (string table-cell-vertical-char)))
@@ -1915,13 +1915,13 @@ all the table specific features."
1915 (if (>= arg 0) 1915 (if (>= arg 0)
1916 (save-excursion 1916 (save-excursion
1917 (goto-char (point-min)) 1917 (goto-char (point-min))
1918 (let* ((border (format "[%c%c%c]" 1918 (let* ((border (format "[%s%c%c]"
1919 table-cell-horizontal-char 1919 table-cell-horizontal-chars
1920 table-cell-vertical-char 1920 table-cell-vertical-char
1921 table-cell-intersection-char)) 1921 table-cell-intersection-char))
1922 (border3 (concat border border border)) 1922 (border3 (concat border border border))
1923 (non-border (format "^[^%c%c%c]*$" 1923 (non-border (format "^[^%s%c%c]*$"
1924 table-cell-horizontal-char 1924 table-cell-horizontal-chars
1925 table-cell-vertical-char 1925 table-cell-vertical-char
1926 table-cell-intersection-char))) 1926 table-cell-intersection-char)))
1927 ;; `table-recognize-region' is an expensive function so minimize 1927 ;; `table-recognize-region' is an expensive function so minimize
@@ -1964,12 +1964,12 @@ specific features."
1964 (table--remove-cell-properties beg end) 1964 (table--remove-cell-properties beg end)
1965 (save-excursion 1965 (save-excursion
1966 (goto-char beg) 1966 (goto-char beg)
1967 (let* ((border (format "[%c%c%c]" 1967 (let* ((border (format "[%s%c%c]"
1968 table-cell-horizontal-char 1968 table-cell-horizontal-chars
1969 table-cell-vertical-char 1969 table-cell-vertical-char
1970 table-cell-intersection-char)) 1970 table-cell-intersection-char))
1971 (non-border (format "[^%c%c%c]" 1971 (non-border (format "[^%s%c%c]"
1972 table-cell-horizontal-char 1972 table-cell-horizontal-chars
1973 table-cell-vertical-char 1973 table-cell-vertical-char
1974 table-cell-intersection-char)) 1974 table-cell-intersection-char))
1975 (inhibit-read-only t)) 1975 (inhibit-read-only t))
@@ -2318,18 +2318,21 @@ table's rectangle structure."
2318 (1+ (cdr (cdr this))) 2318 (1+ (cdr (cdr this)))
2319 (cdr (cdr this)))))) 2319 (cdr (cdr this))))))
2320 (tmp (extract-rectangle (1- beg) end)) 2320 (tmp (extract-rectangle (1- beg) end))
2321 (border (format "[%c%c]\\%c" 2321 (border (format "[%s%c]\\%c"
2322 table-cell-horizontal-char 2322 table-cell-horizontal-chars
2323 table-cell-intersection-char 2323 table-cell-intersection-char
2324 table-cell-intersection-char)) 2324 table-cell-intersection-char))
2325 (blank (table--cell-blank-str)) 2325 (blank (table--cell-blank-str))
2326 rectangle) 2326 rectangle)
2327 ;; create a single wide vertical bar of empty cell fragment 2327 ;; create a single wide vertical bar of empty cell fragment
2328 (while tmp 2328 (while tmp
2329 (setq rectangle (cons (if (string-match border (car tmp)) 2329; (message "tmp is %s" tmp)
2330 (string table-cell-horizontal-char) 2330 (setq rectangle (cons
2331 (if (string-match border (car tmp))
2332 (substring (car tmp) 0 1)
2331 blank) 2333 blank)
2332 rectangle)) 2334 rectangle))
2335; (message "rectangle is %s" rectangle)
2333 (setq tmp (cdr tmp))) 2336 (setq tmp (cdr tmp)))
2334 (setq rectangle (nreverse rectangle)) 2337 (setq rectangle (nreverse rectangle))
2335 ;; untabify the area right of the bar that is about to be inserted 2338 ;; untabify the area right of the bar that is about to be inserted
@@ -2656,7 +2659,7 @@ DIRECTION is one of symbols; right, left, above or below."
2656 (setq rectangle 2659 (setq rectangle
2657 (cons (if below-contp 2660 (cons (if below-contp
2658 (char-to-string table-cell-intersection-char) 2661 (char-to-string table-cell-intersection-char)
2659 (char-to-string table-cell-horizontal-char)) 2662 (substring table-cell-horizontal-chars 0 1))
2660 rectangle)) 2663 rectangle))
2661 (while (> n-element 0) 2664 (while (> n-element 0)
2662 (setq rectangle (cons (table--cell-blank-str 1) rectangle)) 2665 (setq rectangle (cons (table--cell-blank-str 1) rectangle))
@@ -2664,7 +2667,7 @@ DIRECTION is one of symbols; right, left, above or below."
2664 (setq rectangle 2667 (setq rectangle
2665 (cons (if above-contp 2668 (cons (if above-contp
2666 (char-to-string table-cell-intersection-char) 2669 (char-to-string table-cell-intersection-char)
2667 (char-to-string table-cell-horizontal-char)) 2670 (substring table-cell-horizontal-chars 0 1))
2668 rectangle)) 2671 rectangle))
2669 (delete-rectangle beg end) 2672 (delete-rectangle beg end)
2670 (goto-char beg) 2673 (goto-char beg)
@@ -2673,11 +2676,13 @@ DIRECTION is one of symbols; right, left, above or below."
2673 (insert (if (and (> (point) (point-min)) 2676 (insert (if (and (> (point) (point-min))
2674 (save-excursion 2677 (save-excursion
2675 (forward-char -1) 2678 (forward-char -1)
2676 (looking-at (regexp-quote (char-to-string table-cell-horizontal-char))))) 2679 (looking-at (regexp-opt-charset
2680 (string-to-list table-cell-horizontal-chars)))))
2677 table-cell-intersection-char 2681 table-cell-intersection-char
2678 table-cell-vertical-char) 2682 table-cell-vertical-char)
2679 (table--cell-blank-str (- end beg 2)) 2683 (table--cell-blank-str (- end beg 2))
2680 (if (looking-at (regexp-quote (char-to-string table-cell-horizontal-char))) 2684 (if (looking-at (regexp-opt-charset
2685 (string-to-list table-cell-horizontal-chars)))
2681 table-cell-intersection-char 2686 table-cell-intersection-char
2682 table-cell-vertical-char)))) 2687 table-cell-vertical-char))))
2683 ;; recognize the newly created spanned cell 2688 ;; recognize the newly created spanned cell
@@ -2711,7 +2716,7 @@ Creates a cell above and a cell below the current point location."
2711 (goto-char beg) 2716 (goto-char beg)
2712 (delete-region beg end) 2717 (delete-region beg end)
2713 (insert table-cell-intersection-char 2718 (insert table-cell-intersection-char
2714 (make-string table-cell-info-width table-cell-horizontal-char) 2719 (make-string table-cell-info-width (string-to-char table-cell-horizontal-chars))
2715 table-cell-intersection-char) 2720 table-cell-intersection-char)
2716 (table--goto-coordinate old-coordinate) 2721 (table--goto-coordinate old-coordinate)
2717 (forward-line 1) 2722 (forward-line 1)
@@ -3284,6 +3289,10 @@ CALS (DocBook DTD):
3284 ((eq language 'cals) 10))) 3289 ((eq language 'cals) 10)))
3285 (insert ?\n))))) 3290 (insert ?\n)))))
3286 3291
3292(defun table--cell-horizontal-char-p (c)
3293 "Test if character C is one of the horizontal characters"
3294 (memq c (string-to-list table-cell-horizontal-chars)))
3295
3287(defun table--generate-source-scan-lines (dest-buffer language origin-cell tail-cell col-list row-list) 3296(defun table--generate-source-scan-lines (dest-buffer language origin-cell tail-cell col-list row-list)
3288 "Scan the table line by line. 3297 "Scan the table line by line.
3289Currently this method is for LaTeX only." 3298Currently this method is for LaTeX only."
@@ -3303,18 +3312,18 @@ Currently this method is for LaTeX only."
3303 start i c) 3312 start i c)
3304 (if border-p 3313 (if border-p
3305 ;; horizontal cell border processing 3314 ;; horizontal cell border processing
3306 (if (and (eq (car border-char-list) table-cell-horizontal-char) 3315 (if (and (table--cell-horizontal-char-p (car border-char-list))
3307 (table--uniform-list-p border-char-list)) 3316 (table--uniform-list-p border-char-list))
3308 (with-current-buffer dest-buffer 3317 (with-current-buffer dest-buffer
3309 (insert "\\hline\n")) 3318 (insert "\\hline\n"))
3310 (setq i 0) 3319 (setq i 0)
3311 (while (setq c (nth i border-char-list)) 3320 (while (setq c (nth i border-char-list))
3312 (if (and start (not (eq c table-cell-horizontal-char))) 3321 (if (and start (not (table--cell-horizontal-char-p c)))
3313 (progn 3322 (progn
3314 (with-current-buffer dest-buffer 3323 (with-current-buffer dest-buffer
3315 (insert (format "\\cline{%d-%d}\n" (1+ start) i))) 3324 (insert (format "\\cline{%d-%d}\n" (1+ start) i)))
3316 (setq start nil))) 3325 (setq start nil)))
3317 (if (and (not start) (eq c table-cell-horizontal-char)) 3326 (if (and (not start) (table--cell-horizontal-char-p c))
3318 (setq start i)) 3327 (setq start i))
3319 (setq i (1+ i))) 3328 (setq i (1+ i)))
3320 (if start 3329 (if start
@@ -3534,7 +3543,7 @@ consists from cells of same height."
3534 (delete-char 1) 3543 (delete-char 1)
3535 (insert table-cell-intersection-char)) 3544 (insert table-cell-intersection-char))
3536 (delete-char 1) 3545 (delete-char 1)
3537 (insert table-cell-horizontal-char)) 3546 (insert (string-to-char table-cell-horizontal-chars)))
3538 (setq n (1- n)) 3547 (setq n (1- n))
3539 (setcar coord (1+ (car coord))))) 3548 (setcar coord (1+ (car coord)))))
3540 ;; goto appropriate end point 3549 ;; goto appropriate end point
@@ -3576,9 +3585,11 @@ column must consists from cells of same width."
3576 (table--goto-coordinate coord) 3585 (table--goto-coordinate coord)
3577 (if (save-excursion 3586 (if (save-excursion
3578 (or (and (table--goto-coordinate (cons (1- (car coord)) (cdr coord)) 'no-extension) 3587 (or (and (table--goto-coordinate (cons (1- (car coord)) (cdr coord)) 'no-extension)
3579 (looking-at (regexp-quote (char-to-string table-cell-horizontal-char)))) 3588 (looking-at (regexp-opt-charset
3589 (string-to-list table-cell-horizontal-chars))))
3580 (and (table--goto-coordinate (cons (1+ (car coord)) (cdr coord)) 'no-extension) 3590 (and (table--goto-coordinate (cons (1+ (car coord)) (cdr coord)) 'no-extension)
3581 (looking-at (regexp-quote (char-to-string table-cell-horizontal-char)))))) 3591 (looking-at (regexp-opt-charset
3592 (string-to-list table-cell-horizontal-chars))))))
3582 (progn 3593 (progn
3583 (delete-char 1) 3594 (delete-char 1)
3584 (insert table-cell-intersection-char)) 3595 (insert table-cell-intersection-char))
@@ -4412,9 +4423,9 @@ Returns the coordinate of the final point location."
4412(defun table--spacify-frame () 4423(defun table--spacify-frame ()
4413 "Spacify table frame. 4424 "Spacify table frame.
4414Replace frame characters with spaces." 4425Replace frame characters with spaces."
4415 (let ((frame-char (list table-cell-intersection-char 4426 (let ((frame-char
4416 table-cell-horizontal-char 4427 (append (string-to-list table-cell-horizontal-chars)
4417 table-cell-vertical-char))) 4428 (list table-cell-intersection-char table-cell-vertical-char))))
4418 (while 4429 (while
4419 (progn 4430 (progn
4420 (cond 4431 (cond
@@ -4427,11 +4438,11 @@ Replace frame characters with spaces."
4427 (table--spacify-frame)))) 4438 (table--spacify-frame))))
4428 (delete-char 1) 4439 (delete-char 1)
4429 (insert-before-markers ?\ )) 4440 (insert-before-markers ?\ ))
4430 ((eq (char-after) table-cell-horizontal-char) 4441 ((table--cell-horizontal-char-p (char-after))
4431 (while (progn 4442 (while (progn
4432 (delete-char 1) 4443 (delete-char 1)
4433 (insert-before-markers ?\ ) 4444 (insert-before-markers ?\ )
4434 (eq (char-after) table-cell-horizontal-char)))) 4445 (table--cell-horizontal-char-p (char-after)))))
4435 ((eq (char-after) table-cell-vertical-char) 4446 ((eq (char-after) table-cell-vertical-char)
4436 (while (let ((col (current-column))) 4447 (while (let ((col (current-column)))
4437 (delete-char 1) 4448 (delete-char 1)
@@ -4685,8 +4696,8 @@ of line."
4685 (>= (if columnp (car coord) (cdr coord)) 0)) 4696 (>= (if columnp (car coord) (cdr coord)) 0))
4686 (while (progn 4697 (while (progn
4687 (table--goto-coordinate coord 'no-extension 'no-tab-expansion) 4698 (table--goto-coordinate coord 'no-extension 'no-tab-expansion)
4688 (not (looking-at (format "[%c%c%c]" 4699 (not (looking-at (format "[%s%c%c]"
4689 table-cell-horizontal-char 4700 table-cell-horizontal-chars
4690 table-cell-vertical-char 4701 table-cell-vertical-char
4691 table-cell-intersection-char)))) 4702 table-cell-intersection-char))))
4692 (if columnp (setcar coord (1- (car coord))) 4703 (if columnp (setcar coord (1- (car coord)))
@@ -5037,7 +5048,7 @@ Focus only on the corner pattern. Further cell validity check is required."
5037 (let ((vertical-str (regexp-quote (char-to-string table-cell-vertical-char))) 5048 (let ((vertical-str (regexp-quote (char-to-string table-cell-vertical-char)))
5038 (intersection-str (regexp-quote (char-to-string table-cell-intersection-char))) 5049 (intersection-str (regexp-quote (char-to-string table-cell-intersection-char)))
5039 (v-border (format "[%c%c]" table-cell-vertical-char table-cell-intersection-char)) 5050 (v-border (format "[%c%c]" table-cell-vertical-char table-cell-intersection-char))
5040 (h-border (format "[%c%c]" table-cell-horizontal-char table-cell-intersection-char)) 5051 (h-border (format "[%s%c]" table-cell-horizontal-chars table-cell-intersection-char))
5041 (limit (save-excursion (beginning-of-line) (point)))) 5052 (limit (save-excursion (beginning-of-line) (point))))
5042 (catch 'end 5053 (catch 'end
5043 (while t 5054 (while t
@@ -5075,7 +5086,7 @@ Focus only on the corner pattern. Further cell validity check is required."
5075 (let ((vertical-str (regexp-quote (char-to-string table-cell-vertical-char))) 5086 (let ((vertical-str (regexp-quote (char-to-string table-cell-vertical-char)))
5076 (intersection-str (regexp-quote (char-to-string table-cell-intersection-char))) 5087 (intersection-str (regexp-quote (char-to-string table-cell-intersection-char)))
5077 (v-border (format "[%c%c]" table-cell-vertical-char table-cell-intersection-char)) 5088 (v-border (format "[%c%c]" table-cell-vertical-char table-cell-intersection-char))
5078 (h-border (format "[%c%c]" table-cell-horizontal-char table-cell-intersection-char)) 5089 (h-border (format "[%s%c]" table-cell-horizontal-chars table-cell-intersection-char))
5079 (limit (save-excursion (end-of-line) (point)))) 5090 (limit (save-excursion (end-of-line) (point))))
5080 (catch 'end 5091 (catch 'end
5081 (while t 5092 (while t
@@ -5124,8 +5135,8 @@ the right-bottom is the position after the cell's right bottom corner character.
5124When it fails to find either one of the cell corners it returns nil or 5135When it fails to find either one of the cell corners it returns nil or
5125signals error if the optional ABORT-ON-ERROR is non-nil." 5136signals error if the optional ABORT-ON-ERROR is non-nil."
5126 (let (lu rb 5137 (let (lu rb
5127 (border (format "^[%c%c%c]+$" 5138 (border (format "^[%s%c%c]+$"
5128 table-cell-horizontal-char 5139 table-cell-horizontal-chars
5129 table-cell-vertical-char 5140 table-cell-vertical-char
5130 table-cell-intersection-char))) 5141 table-cell-intersection-char)))
5131 (if (and (condition-case nil 5142 (if (and (condition-case nil