]> git.lyx.org Git - features.git/commit
Attempt to fix #11457
authorJosé Matos <jamatos@lyx.org>
Tue, 28 May 2019 15:22:32 +0000 (16:22 +0100)
committerRichard Kimberly Heck <rikiheck@lyx.org>
Wed, 30 Oct 2019 23:27:50 +0000 (19:27 -0400)
commitb1860e301acfef3586143d240ae00716beb8c61c
tree46ff0041c739525f5ec1ba71795523c5133d00d0
parentaf43420165965c2477e57c9d96ed747b067005f0
Attempt to fix #11457

In python 3 the colors need to be strings and not bytes:

This was the equivalent of

>> print("%s" % b"1")
"b'1'"

since the colors were bytes the call to dvipng was something like

dvipng -Ttight -depth -height -D 115 -fg "b'rgb 0.937255 0.941176 0.945098'" -bg "b'rgb 0.137255 0.149020 0.160784'"  "lyxpreviewxBJEqm.dvi"

Note the "b'rgb after both -fg and -bg that wrecked havoc and thus dvipng failed. That was the difference between python2 and python3 calls.

(cherry picked from commit 8dd31803b16d1fb6b30772955188c3595437f64a)
lib/scripts/lyxpreview2bitmap.py
status.23x