Committed by
David PHAM-VAN
make pdf background transparent on windows
Showing
1 changed file
with
2 additions
and
2 deletions
| @@ -361,8 +361,8 @@ void PrintJob::rasterPdf(std::vector<uint8_t> data, | @@ -361,8 +361,8 @@ void PrintJob::rasterPdf(std::vector<uint8_t> data, | ||
| 361 | auto bWidth = static_cast<int>(width * scale); | 361 | auto bWidth = static_cast<int>(width * scale); |
| 362 | auto bHeight = static_cast<int>(height * scale); | 362 | auto bHeight = static_cast<int>(height * scale); |
| 363 | 363 | ||
| 364 | - auto bitmap = FPDFBitmap_Create(bWidth, bHeight, 0); | ||
| 365 | - FPDFBitmap_FillRect(bitmap, 0, 0, bWidth, bHeight, 0xffffffff); | 364 | + auto bitmap = FPDFBitmap_Create(bWidth, bHeight, 1); |
| 365 | + FPDFBitmap_FillRect(bitmap, 0, 0, bWidth, bHeight, 0x00ffffff); | ||
| 366 | 366 | ||
| 367 | FPDF_RenderPageBitmap(bitmap, page, 0, 0, bWidth, bHeight, 0, | 367 | FPDF_RenderPageBitmap(bitmap, page, 0, 0, bWidth, bHeight, 0, |
| 368 | FPDF_ANNOT | FPDF_LCD_TEXT); | 368 | FPDF_ANNOT | FPDF_LCD_TEXT); |
-
Please register or login to post a comment