(OutputStream os)
| 407 | // toStream(pos); |
| 408 | // } catch(Exception e) {IJ.handleException(e);} |
| 409 | void toStream(OutputStream os) throws IOException { |
| 410 | //prepare |
| 411 | for (PlotObject plotObject : pp.getAllPlotObjects()) //make sure all fonts are set properly |
| 412 | if (plotObject != null) |
| 413 | plotObject.setFont(nonNullFont(plotObject.getFont(), currentFont)); |
| 414 | pp.rangeMinMax = currentMinMax; |
| 415 | //write |
| 416 | ObjectOutputStream out = new ObjectOutputStream(os); |
| 417 | out.writeObject(pp); |
| 418 | out.writeObject(allPlotObjects); |
| 419 | } |
| 420 | |
| 421 | /** Writes this plot into a byte array containing (1) the serialized PlotProperties and |
| 422 | * (2) the serialized Vector of all 'added' PlotObjects. |
no test coverage detected