Skip to content

Commit

Permalink
`twittering-fill-string' works even if the buffer is not displayed.
Browse files Browse the repository at this point in the history
* twittering-mode.el (twittering-fill-string): use `frame-width'
only if no windows display the `*twittering*' buffer.
  • Loading branch information
cvmat committed Jan 29, 2010
1 parent 3805dac commit 32efcf1
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 3 deletions.
5 changes: 5 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
2010-01-30 Tadashi MATSUO <tad@mymail.twin.jp>

* twittering-mode.el (twittering-fill-string): use `frame-width'
only if no windows display the `*twittering*' buffer.

2010-01-29 Satoshi Yatagawa <yata_github@y.hauN.org>

* twittering-mode.el (twittering-fill-string): Add an extra
Expand Down
9 changes: 6 additions & 3 deletions twittering-mode.el
Original file line number Diff line number Diff line change
Expand Up @@ -458,9 +458,12 @@ and its contents(BUFFER)"
0))
(min-width
(apply 'min
(window-width) ;; for avoiding "wrong number of arguments"
(mapcar 'window-width
(get-buffer-window-list (current-buffer) nil t))))
(or
(mapcar 'window-width
(get-buffer-window-list (current-buffer) nil t))
;; Use `(frame-width)' if no windows display
;; the current buffer.
`(,(frame-width)))))
(temporary-fill-column
(or column
(- (1- min-width) adjustment))))
Expand Down

0 comments on commit 32efcf1

Please sign in to comment.