Steven Pena

Members
  • Content count

    4
  • Joined

  • Last visited

Everything posted by Steven Pena

  1. Is it possible to surface the printChart function of the Chart class to Javascript via the ExternalInterface? This would allow us to present an alternative interface to print from (link, button...) outside of the chart. It's not very intuitive to ask the user to right-click and then select print, to print a chart. And as you have noted in several posts - you aren't responsible for browser printing (which isn't reliable across browsers). You should only need to add this line to the Chart constructor: /** * expose printChart function to Javascript */ flash.external.ExternalInterface.addCallback("PrintChart", this, printChart); Thanks, Steven
  2. Printing via Javascript

    Is it possible to surface the printChart function of the Chart class to Javascript via the ExternalInterface? This would allow us to present an alternative interface to print from (link, button...) outside of the chart. It's not very intuitive to ask the user to right-click and then select print, to print a chart. And as you have noted in several posts - you aren't responsible for browser printing (which isn't reliable across browsers). You should only need to add this line to the Chart constructor: /** * expose printChart function to Javascript */ flash.external.ExternalInterface.addCallback("PrintChart", this, printChart); Thanks, Steven
  3. Export to JPEG

    It's a little tricky to do it with Flash, but it can be done. It would, however, require some server side support. With the many advancements in Flash it's now possible to create a bitmap image within flash, render a flash drawing to that and then capture the bitmap data. You could then send that data to an external script which could re-render that bitmap data into an image for saving or viewing on a web browser. There are other techniques out there to compress the data (which is essentially a raw bitmap, so you can imagine how big those can get) so that it saves on bandwith. Here's just one solution: http://sephiroth.it/tutorials/flashPHP/print_screen/ Steven
  4. Copy chart to clipboard from browser

    That's not entirely true. The limitation isn't with Flash. It used to be, but there have been many advancements in Flash. It's now possible to create a bitmap image within flash, render a flash drawing to that and then capture the bitmap data. You could then send that data to an external script which could re-render that bitmap data into an image for saving. Here's just one solution: http://sephiroth.it/tutorials/flashPHP/print_screen/ Steven