浏览代码

Bug fixes.

Carsten Dominik 17 年之前
父节点
当前提交
9a8d39d865
共有 2 个文件被更改,包括 15 次插入0 次删除
  1. 4 0
      lisp/org-colview-xemacs.el
  2. 11 0
      lisp/org-colview.el

+ 4 - 0
lisp/org-colview-xemacs.el

@@ -34,6 +34,9 @@
 (eval-when-compile (require 'cl))
 (require 'org)
 
+(declare-function org-agenda-redo "org-agenda" ())
+
+
 ;;; Definie additional faces for column view
 
 (when (featurep 'xemacs)
@@ -1060,6 +1063,7 @@ Don't set this, this is meant for dynamic scoping.")
     (org-columns-remove-overlays)
     (if (org-mode-p)
 	(call-interactively 'org-columns)
+      (org-agenda-redo)
       (call-interactively 'org-agenda-columns)))
   (when (featurep 'xemacs)
     (while (not (or (eolp)

+ 11 - 0
lisp/org-colview.el

@@ -32,6 +32,8 @@
 (eval-when-compile (require 'cl))
 (require 'org)
 
+(declare-function org-agenda-redo "org-agenda" ())
+
 ;;; Column View
 
 (defvar org-columns-overlays nil
@@ -204,6 +206,15 @@ This is the compiled version of the format.")
 			  (min (point-max) (1+ (point-at-eol)))
 			  'read-only "Type `e' to edit property")))))
 
+(defun org-columns-add-ellipses (string width)
+  "Truncate STRING with WIDTH characters, with ellipses."
+  (cond 
+   ((<= (length string) width) string)
+   ((<= width (length org-columns-ellipses))
+    (substring org-columns-ellipses 0 width))
+   (t (concat (substring string 0 (- width (length org-columns-ellipses)))
+	      org-columns-ellipses))))
+
 (defvar org-columns-full-header-line-format nil
   "Fthe full header line format, will be shifted by horizontal scrolling." )
 (defvar org-previous-header-line-format nil