Text is appearing blurry as you get further into the report - pdf.js

We have some reports generated with JasperReports 6.2.0 that have this bizarre affect where as you get further into pages of the report the text gets more blurry as you go. The first page or two is crisp text, but get to page 30 or so and it becomes unreadable. In our scenario we are printing checks, so I can only post close up shots of some text. But the first image is the first page, and the second image is about page 28. Notice the difference.
We have two font extensions set up with Calibri and MICR fonts, They are added correctly and have the pdfEncoding set to Cp1250 and pdfEmbedded to true (I have tried other values).
How can we make the text not become blurry? Thanks
UPDATE: I am removing Jasper Reports from the equation/cause of the issue. And believe it might be in the component PDF.js that we are using that renders the PDF into the print preview.

Related

autoPaging in jsPdf .html() method

I have updated jsPdf to version "jspdf": "^2.4.0", and saw an option called autoPaging in the html() method of jspdf, anyone knows what is it used for ? I tried using it but didnt see anything different on the generated pdf.
I am guessing it might be related to paging like "Page 1 of 2".
As jspdf documentation:
Autopaging is used to set the auto paging mode.
false: Auto paging is disabled.
true or 'slice': Will cut shapes or text chunks across page breaks. Will possibly slice text in half, making it difficult to read.
'text': Trys not to cut text in half across page breaks. Works best for documents consisting mostly of a single column of text.
Default is true.

Managing page breaks on PDF document generated through HTML [iOS]

I am trying to create a PDF using HTML content. Everything is fine but i have one problem where the page breaks on PDF get inserted between content and cause it to divide between pages.
Example:
A portrait image with height>width get a page break half way in between and causes half image to be on page 1 and the other half to be on page 2. This is just an example, the content on my PDF is dynamic, meaning the user has control over generating amount of content. Therefore its not necessary that image be always on page 1 it could be anywhere on the document.
I have tried to search for some libraries also but as per my understanding of how PDF files are rendered in iOS, I don't have any clue how to manage content that gets divided due to the page breaks.
Platform: iOS 10, xcode 8, Objective-C
Try to add something like the following to your css.
img {
page-break-inside:avoid
}
See also:
Print styles: How to ensure image doesn't span a page break

printing with custom page size and print preview settings for IE/Firefox/Safari

I am currently trying to add a "Print Label" functionality. After clicking the button, the print preview dialog should open and print in the label format (which is different and hidden from the screen view).
I had tested in chrome, IE, Firefox and safari in Windows 7. However, only chrome works as expected, printing in the expected page size and style. For IE and Firefox, although the label format stays intact when I save in PDF, I can only print in the letter (default) page size, which means a disaster when I use the label printer to print. When I attempt to change the page size to the custom label size, IE crashes while Firefox does not let me open the properties in the system print dialog. For safari (IN WINDOWS), I can print in the custom label size, however, I cannot remove the header and footer, resulting the label format to split into many pages.
The questions I have are:
1. Is the culprit the custom label size, or is it because of the limitations of the other browsers?
2. How can I remove headers and footers in Safari (windows)? My findings are pessimistic about that for now...
3. Are there any ways for me to generate print preview dialog, instead of print dialog, for other browsers? (Something like chrome)
4. Are there any ways for me to use Javascript to preset print settings, to set the printer to the label printer and change page size to the custom label size?
Thanks if anyone can enlighten me.

sIFR text getting stretched vertically in IE9

I've got a site that's using sIFR, and some of the replaced text is being stretched vertically in IE9. It's only happening in places where the text wraps 2 lines, and it fixes itself when I hover my cursor over it. The sIFR text is a link, but I'm not sure if that has any correlation.
I've tried various settings changes like fitExactly, forceClear, and forceSingleLine (though I want it to be able to wrap), and those didn't work. I've tried changing the font-size, line-height, and all other dimensions to px instead of em. innerHTML isn't being used anywhere on the page. It's frustrating that it works after being hovered on, but not before.
And I know you're probably thinking "use cufon or #font-face, dummy" but I'm stuck with sIFR for now. The client wants what the client wants...
I've found a solution,
if you try to hover with mouse cursor the text will display correct so..
I write few line of code to put in sifr-config.js
forcing flash reset "onReplacemment" callback only when IE9 is detected
you must use Jquery for browser detection or use another javascript way
see the link below:
http://www.voo-doo.net/robotphobia/2011/05/fix-sifr-ie9

fitExactly not working in r-436

I just recently upgraded to 436 from 419, and have found that fitExactly will no longer have any effect.
You can see an example here:
(With 419)
(With 436)
The javascript config is in the page head.
I checked the versions in between, and the latest it works with is 419.
I could adjust the width in the Javascript configuration, but then there would be a gap left on the side of the dropcap I'm using it on, and the fact that I'm integrating it with a Wordpress theme that automatically applies sifr (other than the one in the example), meaning that each can't be adjusted by changing the width or font size.
I would much prefer to use 436, especially due to there being less page shifting, so, is there a remedy?
Thanks for your time.
If you compare the width and height of the Flash movie on both pages, you'll see that it's the same. In other words, it looks like fitExactly works fine. I wouldn't know though why Flash is clipping the rendered text.
Just to test, could you open the r436 JavaScript file, search for '419' and replace by '436', and then use the r419 Flash movie? Perhaps that provides further clues.

Resources