Skip to content

Commit

Permalink
Avoid fringe-columns for backwards compatibility
Browse files Browse the repository at this point in the history
It is not defined in Emacs 24.5. Fixes jrblevinGH-32.
  • Loading branch information
jrblevin committed Jun 11, 2016
1 parent a040f04 commit 59173ba
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion deft.el
Original file line number Diff line number Diff line change
Expand Up @@ -1155,7 +1155,8 @@ Case is ignored."
If the frame has a fringe, it will absorb the newline.
Otherwise, we reduce the line length by a one-character offset."
(let* ((window (get-buffer-window deft-buffer))
(offset (if (> (fringe-columns 'right) 0) 0 1)))
(fringe-right (ceiling (or (cadr (window-fringes)) 0)))
(offset (if (> fringe-right 0) 0 1)))
(when window
(- (window-text-width window) offset))))

Expand Down

0 comments on commit 59173ba

Please sign in to comment.