[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] scratch/add-vdiff 016518f 016/258: Fix folds at end of buffer
From: |
Justin Burkett |
Subject: |
[elpa] scratch/add-vdiff 016518f 016/258: Fix folds at end of buffer |
Date: |
Wed, 17 May 2017 08:13:13 -0400 (EDT) |
branch: scratch/add-vdiff
commit 016518f78e5b73fcf8a8b22ff7a15f7e7a5b7679
Author: justbur <address@hidden>
Commit: justbur <address@hidden>
Fix folds at end of buffer
---
vdiff.el | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
diff --git a/vdiff.el b/vdiff.el
index 916c9fc..c358d2c 100644
--- a/vdiff.el
+++ b/vdiff.el
@@ -375,12 +375,12 @@ lines hidden."
(vdiff--remove-all-overlays)
(vdiff--refresh-line-maps)
(save-excursion
- (let ((a-last-post-end 1)
+ (let ((a-buffer (car vdiff--buffers))
+ (b-buffer (cadr vdiff--buffers))
+ (a-last-post-end 1)
(b-last-post-end 1))
(dolist (header vdiff--diff-data)
- (let* ((a-buffer (car vdiff--buffers))
- (b-buffer (cadr vdiff--buffers))
- (code (nth 0 header))
+ (let* ((code (nth 0 header))
(a-range (nth 1 header))
(b-range (nth 2 header))
(a-beg (car a-range))
@@ -433,7 +433,15 @@ lines hidden."
(vdiff--add-change-overlays
a-buffer a-beg a-length b-norm-range)
(vdiff--add-change-overlays
- b-buffer b-beg b-length a-norm-range))))))))
+ b-buffer b-beg b-length a-norm-range)))))
+ (vdiff--add-folds
+ a-buffer b-buffer
+ (cons a-last-post-end
+ (with-current-buffer a-buffer
+ (line-number-at-pos (point-max))))
+ (cons b-last-post-end
+ (with-current-buffer b-buffer
+ (line-number-at-pos (point-max))))))))
;; * Moving changes
- [elpa] scratch/add-vdiff 8842469 184/258: Allow point to leave overlay on target selection, (continued)
- [elpa] scratch/add-vdiff 8842469 184/258: Allow point to leave overlay on target selection, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff b4c3e09 195/258: Ensure sentinel runs in correct context, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 28c939f 194/258: Document new option, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 133e187 193/258: Allow folds to close on point but make optional, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 4dd194b 190/258: Update screenshot with refinements, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff b840935 202/258: Use more specific faces for refinements, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff f4332f2 212/258: Fix typo in Commentary section, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 1549115 005/258: Add option to lock scrolling by default, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 0f640d3 007/258: Add header info, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 72c20a5 010/258: Add gitignore, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 016518f 016/258: Fix folds at end of buffer,
Justin Burkett <=
- [elpa] scratch/add-vdiff 10b7760 018/258: Add faces, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 952440e 002/258: Initial commit, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 245850f 028/258: Load cl-lib for using its function, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 988c476 027/258: Add new defcustoms to README, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff b77efe3 008/258: Add README and improve docstrings, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff ce10994 003/258: Introduce defcustoms and use lists instead of .., Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff ad6035d 015/258: Implement folding of unchanged lines, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff af75c6d 036/258: Add vdiff-exit, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff e8834fa 035/258: Fix fold size calcs, Justin Burkett, 2017/05/17
- [elpa] scratch/add-vdiff 9547850 041/258: Use diff faces from theme, Justin Burkett, 2017/05/17