diff options
author | Artur Malabarba <bruce.connor.am@gmail.com> | 2014-12-18 22:37:42 -0200 |
---|---|---|
committer | Artur Malabarba <bruce.connor.am@gmail.com> | 2014-12-22 10:46:41 -0200 |
commit | 06ec0c89a1ecf437d30c3a796f1611a8d8d3dbc0 (patch) | |
tree | c69ab041c7f5d6cece23b64d18657fa58cb9aa7e | |
parent | 3f472b25a166509e1724199ff7eb136374cc00e3 (diff) |
Properly skip invisible sections.
-rw-r--r-- | sx-question-mode.el | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/sx-question-mode.el b/sx-question-mode.el index 807eeea..cc7799d 100644 --- a/sx-question-mode.el +++ b/sx-question-mode.el @@ -120,10 +120,8 @@ Prefix argument N moves N sections down or up." ;; If all we did was move out the current one, then move again ;; and we're guaranteed to reach the next section. (sx-question-mode--goto-property-change 'section n)) - (let ((ov (car-safe (sx-question-mode--section-overlays-at (point))))) - (unless (and (overlayp ov) - (overlay-get ov 'invisible)) - (cl-decf count))))) + (unless (get-char-property (point) 'invisible) + (cl-decf count)))) (when (equal (selected-window) (get-buffer-window)) (when sx-question-mode-recenter-line (let ((ov (sx-question-mode--section-overlays-at (line-end-position)))) |