소스 검색

Fix cursor movement to a specific column

* lisp/org-compat.el (org-move-to-column): Turn off invisibility stuff
for moving the cursor to a column.

Pathc by Nick Dokos
Carsten Dominik 11 년 전
부모
커밋
7f9d0688d4
1개의 변경된 파일6개의 추가작업 그리고 3개의 파일을 삭제
  1. 6 3
      lisp/org-compat.el

+ 6 - 3
lisp/org-compat.el

@@ -336,9 +336,12 @@ Works on both Emacs and XEmacs."
     (indent-line-to column)))
 
 (defun org-move-to-column (column &optional force buffer)
-  (if (featurep 'xemacs)
-      (org-xemacs-without-invisibility (move-to-column column force buffer))
-    (move-to-column column force)))
+  ;; set buffer-invisibility-spec to nil so that move-to-column
+  ;; does the right thing despite the presence of invisible text.
+  (let ((buffer-invisibility-spec nil))
+    (if (featurep 'xemacs)
+	(org-xemacs-without-invisibility (move-to-column column force buffer))
+      (move-to-column column force))))
 
 (defun org-get-x-clipboard-compat (value)
   "Get the clipboard value on XEmacs or Emacs 21."