mirror of
https://github.com/Smaug123/KaTeX
synced 2025-10-06 19:58:40 +00:00
Fix texcmp issues related to bit depth and kerning (#549)
* Ensure bit depth 8 * Print affected file if PNG failed to read (e.g. due to wrong bit depth) * Disable running Kern test case through TeX as doing so fails
This commit is contained in:
committed by
Kevin Barabash
parent
d50745d5a9
commit
d5025c61e8
@@ -86,7 +86,7 @@ function processTestCase(key) {
|
||||
// Step 3: call "convert ... key.pdf key.png" to create key.png
|
||||
return execFile("convert", [
|
||||
"-density", dpi, "-units", "PixelsPerInch", "-flatten",
|
||||
pdfFile, pngFile,
|
||||
"-depth", "8", pdfFile, pngFile,
|
||||
]);
|
||||
}).then(function() {
|
||||
console.log("Rasterized " + key);
|
||||
@@ -209,6 +209,7 @@ function readPNG(file) {
|
||||
stream.on("error", onerror);
|
||||
pngparse.parseStream(stream, function(err, image) {
|
||||
if (err) {
|
||||
console.log("Failed to load " + file);
|
||||
onerror(err);
|
||||
return;
|
||||
}
|
||||
|
Reference in New Issue
Block a user