User Guide
376 Chapter 18: Printing from SWF Files
Printing from the Flash Player context menu . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
Publishing a document with printable frames. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 385
Controlling printing
To control what users can print, remember the following items as you set up documents and
movie clips for printing:
• Adjust the page layout in any frames that you designate as printable to match the desired
printed output. Using Flash Player, you can print all shapes, symbols, bitmaps, text blocks, and
text fields. Levels in a SWF file are not composited on print output.
• The Flash Player printer driver uses the HTML settings for dimension, scale, and alignment in
the Publish Settings dialog box. Use these settings to control the print layout.
• The selected frames print as they appear in the movie clip symbol. You can let users print a
movie clip that is not visible in a browser by setting the movie clip’s
_visible property to
false using the Actions panel. Changing the property of a movie clip with the setProperty
action, tweening, or any transformation tool does not affect how a movie clip prints.
• For a movie clip to be printable, it must be on the Stage or workspace and it must be given an
instance name.
• All elements must be fully loaded to print. You can use the movie clip _framesloaded
property to check whether the printable content is loaded. For more information, see
MovieClip._framesloaded in Flash ActionScript Language Reference.
Supported printers
With Flash Player, you can print to PostScript and non-PostScript printers. For a list of supported
Flash Player printing platforms, see the “Macromedia Flash Player Web Printing FAQ” on the
Macromedia website (www.macromedia.com/software/flash/open/webprinting/faq.html).
Using the ActionScript PrintJob class
The ActionScript PrintJob class, in addition to offering improvements to print functionality
available with the
print() method, lets you also render dynamic content at runtime, prompt
users with a single print dialog box, and print an unscaled document with proportions that map
to the proportions of the content. This capability is especially useful for rendering and printing
external dynamic content, such as database content and dynamic text.
Additionally, with properties populated by the
PrintJob.start()function, your document
can access your user’s printer settings, such as page height, width, and orientation, and you
can configure your document to dynamically format Flash content that is appropriate for the
printer settings.
Building a print job
To build a print job, you use functions that complete the tasks in the order outlined in this
section. The sections that follow the procedure provide explanations of the functions and
properties associated with the PrintJob object.