java - JavaFx: webview print with fit to size 100% -
to print html page use following code:
printerjob job = printerjob.createprinterjob(); if (job != null && job.showprintdialog(null)){ webview.getengine().print(job); job.endjob(); } the problem webview changes scale of printing page. example, when print html page in ie fit size 100% 16.8 cm. when print in java application 11.4cm. size in html file set in pt - width 475pt(a4 width=595pt,so 475pt=16.8cm). how print in webview fit size 100%? possible do?
p.s. if understand wrong->i asking wrong question, please correct me.
there bug report may related issue. https://bugs.openjdk.java.net/browse/jdk-8088509 far can tell there no solution far. michael
Comments
Post a Comment