So here you can find the last version of Print.it. It works for both
1.4 and 1.5.
You can supply a DOCTYPE do be used to render the printing frame
and you can alter the way the printing frame is generated and printed
on slow machines,

http://code.google.com/p/gwt-print-it/source/browse/trunk/src/br/com/freller/tool/client/Print.java

/**
 * <pre>
 *
 * Description:
 *
 *      Generic printing class
 *      Can be used to print the Window it self, DOM.Elements,
UIObjects (Widgets) and plain HTML
 *
 * Usage:
 *
 *      You must insert this iframe in your host page:
 *              <iframe id="__printingFrame" style="width:0;height:
0;border:0"></iframe>
 *
 *      Window:
 *              Print.it();
 *
 *      Objects/HTML:
 *              Print.it(RootPanel.get("myId"));
 *              Print.it(DOM.getElementById("myId"));
 *              Print.it("Just <b>Print.it()</b>!");
 *
 *      Objects/HTML using styles:
 *              Print.it("<link rel=StyleSheet type=text/css
media=paper href=/paperStyle.css>", RootPanel.get("myId"));
 *              Print.it("<style type=text/css media=paper> .newPage
{ page-break-after: always; } </style>",
 *                              "Hi<p class=newPage></p>By");
 *
 *      Objects/HTML using styles and DocType:
 *              Print.it("<!DOCTYPE HTML PUBLIC '-//W3C//DTD HTML
4.01//EN' 'http://www.w3.org/TR/html4/strict.dtd'>",
 *                       "<link rel=StyleSheet type=text/css
media=paper href=/paperStyle.css>",
 *                       RootPanel.get("myId"));
 *
 * OBS:
 *
 *      Warning: You can't use \" in your style String
 *
 *      Obs: If your machine is to slow to render the page and you
keep getting blank pages, change USE_TIMER to true and
 *           play with TIMER_DELAY
 *
 *      Obs: If you try to print Form elements, like TextArea and
ListBox they will show default status
 *
 * </pre>
 */


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to