소스 검색

org-table: Fix alignment issue with entities

* lisp/org-table.el (org-table-justify-field-maybe): Preserve text
  properties so entities can be properly aligned.
Nicolas Goaziou 8 년 전
부모
커밋
ab79736843
1개의 변경된 파일1개의 추가작업 그리고 4개의 파일을 삭제
  1. 1 4
      lisp/org-table.el

+ 1 - 4
lisp/org-table.el

@@ -963,10 +963,7 @@ Optional argument NEW may specify text to replace the current field content."
 	    (progn
 	      (setq s (match-string 1)
 		    o (match-string 0)
-		    l (max 1
-			   (- (org-string-width
-			       (buffer-substring-no-properties
-				(match-end 0) (match-beginning 0))) 3))
+		    l (max 1 (- (org-string-width o) 3))
 		    e (not (= (match-beginning 2) (match-end 2))))
 	      (setq f (format (if num " %%%ds %s" " %%-%ds %s")
 			      l (if e "|" (setq org-table-may-need-update t) ""))