Apply scaling and ascept ratio on Sixel properly
* eat.el (eat--set-term-sixel-params): Make sure both numbers of char-dimension is non-zero.
This commit is contained in:
parent
94fb36161a
commit
8b3a38c1d5
1 changed files with 4 additions and 4 deletions
8
eat.el
8
eat.el
|
@ -5077,10 +5077,10 @@ selection, or nil if none."
|
|||
(scale-y eat-sixel-scale)
|
||||
(font-size (font-get (font-spec :name (face-font 'default))
|
||||
:size)))
|
||||
(setf (car dimensions) (round (/ (car dimensions)
|
||||
(float scale-x))))
|
||||
(setf (cdr dimensions) (round (/ (cdr dimensions)
|
||||
(float scale-y))))
|
||||
(setf (car dimensions) (max 1 (round (/ (car dimensions)
|
||||
(float scale-x)))))
|
||||
(setf (cdr dimensions) (max 1 (round (/ (cdr dimensions)
|
||||
(float scale-y)))))
|
||||
(setf (eat-term-parameter eat-terminal 'sixel-render-format)
|
||||
render-fmt)
|
||||
(setf (eat-term-parameter eat-terminal 'char-dimensions)
|
||||
|
|
Loading…
Add table
Reference in a new issue