Exporting

object Exporting extends Exporting

'' '' Exporting contains enrichments to conveniently export charts to disk.

'' '' Exporting contains enrichments to conveniently export charts to disk.

chart.saveAsPNG("/tmp/chart.png")

== Supported Formats ==

Charts may be exported into the following formats:

  • JPEG
  • PNG
  • PDF, needs the optional dependency "com.itextpdf" % "itextpdf" on your class path
  • SVG, needs the optional dependency "org.jfree" % "jfreesvg" on your class path

== Export Stages ==

There are different stages in which charts may be exported: encoding, writing and the actual saving of the file, which is demonstrated by the following code snippet:

val bytes = chart.encodeAsPNG()

chart.writeAsPNG(System.out)

chart.saveAsPNG("/tmp/chart.png")
Companion
class
trait Exporting
class Object
trait Matchable
class Any

Implicits

Inherited implicits

implicit def ChartJPEGExporter(chart: Chart): JPEGExporter
Inherited from
Exporting
implicit def ChartPDFExporter(chart: Chart): PDFExporter
Inherited from
Exporting
implicit def ChartPNGExporter(chart: Chart): PNGExporter
Inherited from
Exporting
implicit def ChartSVGExporter(chart: Chart): SVGExporter
Inherited from
Exporting