diff options
| author | Katsumi Yamaoka | 2015-02-10 07:55:14 +0000 |
|---|---|---|
| committer | Katsumi Yamaoka | 2015-02-10 07:55:14 +0000 |
| commit | 2dacd0a7eee1f8fdff028e15ff40640d005c71d7 (patch) | |
| tree | bd17dba88215113e7564f7ab044272f0a9be4d81 /lisp | |
| parent | b88908b6f0775e4275fdad2c80ea0199d277a947 (diff) | |
| parent | f6d781c29456590dfb10e1710171e8d983eeb9e2 (diff) | |
| download | emacs-2dacd0a7eee1f8fdff028e15ff40640d005c71d7.tar.gz emacs-2dacd0a7eee1f8fdff028e15ff40640d005c71d7.zip | |
Merge branch 'master' of git.sv.gnu.org:/srv/git/emacs
Diffstat (limited to 'lisp')
| -rw-r--r-- | lisp/ChangeLog | 3 | ||||
| -rw-r--r-- | lisp/net/shr.el | 21 |
2 files changed, 19 insertions, 5 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5737113a737..eee6744b15e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -38,6 +38,9 @@ | |||
| 38 | (shr-table-widths): Off-by-one error in width computation. | 38 | (shr-table-widths): Off-by-one error in width computation. |
| 39 | (shr-expand-newlines): Remove dead code. | 39 | (shr-expand-newlines): Remove dead code. |
| 40 | (shr-insert-table): Extend background colors to the end of the column. | 40 | (shr-insert-table): Extend background colors to the end of the column. |
| 41 | (shr-insert-table): Only copy the background, not underline and | ||
| 42 | the like. | ||
| 43 | (shr-face-background): New function. | ||
| 41 | 44 | ||
| 42 | 2015-02-10 Fabián Ezequiel Gallina <fgallina@gnu.org> | 45 | 2015-02-10 Fabián Ezequiel Gallina <fgallina@gnu.org> |
| 43 | 46 | ||
diff --git a/lisp/net/shr.el b/lisp/net/shr.el index f40fd34cb8e..a65f7923f57 100644 --- a/lisp/net/shr.el +++ b/lisp/net/shr.el | |||
| @@ -516,9 +516,9 @@ size, and full-buffer size." | |||
| 516 | (when bolp | 516 | (when bolp |
| 517 | (shr-mark-fill start)) | 517 | (shr-mark-fill start)) |
| 518 | (when shr-use-fonts | 518 | (when shr-use-fonts |
| 519 | (add-face-text-property start (point) | 519 | (put-text-property start (point) |
| 520 | (or shr-current-font 'variable-pitch) | 520 | 'face |
| 521 | t))))))) | 521 | (or shr-current-font 'variable-pitch)))))))) |
| 522 | 522 | ||
| 523 | (defun shr-fill-lines (start end) | 523 | (defun shr-fill-lines (start end) |
| 524 | (if (<= shr-internal-width 0) | 524 | (if (<= shr-internal-width 0) |
| @@ -1644,8 +1644,9 @@ The preference is a float determined from `shr-prefer-media-type'." | |||
| 1644 | (propertize " " | 1644 | (propertize " " |
| 1645 | 'display `(space :align-to (,pixel-align)) | 1645 | 'display `(space :align-to (,pixel-align)) |
| 1646 | 'face (and (> (length line) 0) | 1646 | 'face (and (> (length line) 0) |
| 1647 | (get-text-property | 1647 | (shr-face-background |
| 1648 | (1- (length line)) 'face line)) | 1648 | (get-text-property |
| 1649 | (1- (length line)) 'face line))) | ||
| 1649 | 'shr-table-indent shr-table-id) | 1650 | 'shr-table-indent shr-table-id) |
| 1650 | shr-table-vertical-line) | 1651 | shr-table-vertical-line) |
| 1651 | (shr-colorize-region | 1652 | (shr-colorize-region |
| @@ -1668,6 +1669,16 @@ The preference is a float determined from `shr-prefer-media-type'." | |||
| 1668 | (unless (= start (point)) | 1669 | (unless (= start (point)) |
| 1669 | (put-text-property start (1+ start) 'shr-table-id shr-table-id)))) | 1670 | (put-text-property start (1+ start) 'shr-table-id shr-table-id)))) |
| 1670 | 1671 | ||
| 1672 | (defun shr-face-background (face) | ||
| 1673 | (and (consp face) | ||
| 1674 | (let ((background nil)) | ||
| 1675 | (dolist (elem face) | ||
| 1676 | (when (and (consp elem) | ||
| 1677 | (eq (car elem) :background)) | ||
| 1678 | (setq background (cadr elem)))) | ||
| 1679 | (and background | ||
| 1680 | (list :background background))))) | ||
| 1681 | |||
| 1671 | (defun shr-expand-alignments (start end) | 1682 | (defun shr-expand-alignments (start end) |
| 1672 | (while (< (setq start (next-single-property-change | 1683 | (while (< (setq start (next-single-property-change |
| 1673 | start 'shr-table-id nil end)) | 1684 | start 'shr-table-id nil end)) |