Printing

From ZekrWiki

Jump to: navigation, search

Overview

Zekr supports printing delegating all the job to SWT browser widget. Internet Explorer on Windows works fine with this. A JavaScript method call for window.print() will bring up Windows printer chooser.

More, From Zekr 0.4.0, we made some CSS enhancements, to improve printed document. Browser uses different CSSes for normal screen rendering and printing. Here is a sample code for demonstrating how it works:

<link rel="stylesheet" media="all" type="text/css" href="file:///C:/Documents%20and%20Settings/Mohsen/.zekr/cache/common-style.css">
<link rel="stylesheet" media="print" type="text/css" href="file:///C:/Documents%20and%20Settings/Mohsen/.zekr/cache/print-style.css">

<link rel="stylesheet" media="screen" type="text/css" href="file:///C:/Documents%20and%20Settings/Mohsen/.zekr/cache/screen-style.css">

Problems

Currently printing doesn't work on Linux and Mac. On Linux, although Mozilla brings up printing dialog on window.print() method call, it does nothing. Safari reacts even worse; it does nothing on window.print() call.

Personal tools