Over a million developers have joined DZone.

New Printing Controls and IME APIs in AIR 2.0 Beta 2

· Web Dev Zone

Start coding today to experience the powerful engine that drives data application’s development, brought to you in partnership with Qlik.

This week, Adobe released the second public beta of AIR 2.0 with several key enhancements.  With the aid community feedback, Adobe has fixed hundreds of bugs and added new capabilities for interacting with printers, secure socket support, and Flash Access support.  Tighter desktop integration is the overarching theme Adobe has set for AIR 2.0.  Although Adobe hasn't set date for AIR 2.0's final release, they expect it to be in the first half of 2010.

In the second beta release there are new properties and methods that have been added to the PrintJob class, allowing tighter control over content printing from AIR 2.0.  These options include the choice of printer, paper size, and number of copies. New printer APIs in beta 2 will tell the developer information about the printable area, if the printer will print in color, and if the print job is active.  Developers are now able to print without displaying the print dialog.  In addition, the new PrintJobOptions.printMethod property allows users to select bitmap or vector printing.  AIR developers can also use the PrintJobOptions.pixelsPerInch property to specify the resolution of print jobs.  For Windows and Mac users, the new PrintUIOptions class can set limits on the end users ability to change the page range to be printed.

AIR developers will be happy to know that they can now play protected content managed by Flash Access.  Beta 2 also allows users to connect with a server that requires TLSv1 or SSLv3 for socket communications.  There are several new features added in this release that support better text input handling with IME (input method editor) software.  IME API enhancements in beta 2 are designed for use with the new Flash Text Engine (FTE), but the old IME API still supports the TextField class. The IME APIs in beta 2 are more stable and they enhance IME text input quality. This is a list of the new IME APIs in AIR 2.0 beta 2:

flash.events.IMEEvent Class:
  • imeClient:IIMEClient Property
  • IME_START_COMPOSITION:String Constant

flash.text.ime Package:flash.text.engine Package:
The new features of AIR 2 beta 2 are just a small taste of the full assortment of new features coming in AIR 2.0.  Adobe has an exhaustive list of everything that's new in AIR 2.0 if you're not up to speed.  Here's a short list:

  • Native code integration
  • Global exception handling
  • Improved networking support with server sockets, secure sockets, UDP and IPV6
  • Updated version of WebKit including support for HTML5 and CSS3
  • Improved runtime performance and lower resource requirements via Flash Player 10.1
  • Multi-touch and gesture support
  • Tighter integration with the desktop including automatic detection of mass storage devices, improvements to cross-platform printing, opening files with their default application, and a new set of language API's for accessing and processing audio streams from the microphone
  • Screen reader support (Windows only) for creating accessible applications
  • Improved database support with transaction savepoints
  • File Promises

Beta-testers should note that applications built against Adobe AIR 2 beta 1 will not run using the AIR 2 beta 2 runtime.  To get an AIR 2 beta 1 application running on the AIR 2 beta 2 runtime, the namespace of the beta 1 application descriptor file must be updated to "2.0beta2" and compiled against the AIR 2 beta 2 SDK.

People interested in test-driving the new version of Adobe AIR 2.0 can find the beta 2 runtimeSDK, and documentation on the Adobe Labs website along with some updated sample applications.

Create data driven applications in Qlik’s free and easy to use coding environment, brought to you in partnership with Qlik.

Topics:

Opinions expressed by DZone contributors are their own.

The best of DZone straight to your inbox.

SEE AN EXAMPLE
Please provide a valid email address.

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.
Subscribe

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}