[kepler-users] saving workflow in eps format

Edward A. Lee eal at eecs.berkeley.edu
Mon Mar 1 14:58:29 PST 2010


I've been using the itextPDF mechanism Christopher describes below,
and it's far more convenient than the other alternatives if you
are going to use the PDF in Latex.  The reason it is more convenient
is that it exports the PDF on a correctly sized page.  With the printing
mechanisms you get it on an 8.5x11 (or A4) page, or you have to manually
set the page size, which is a royal pain...

Too bad that code is AGPL'd. If it weren't, we could just include
it with Ptolemy II.  But AGPL is not truly "free software."
It is encumbered quasi-free software...

Edward


On 3/1/10 1:05 PM, Christopher Brooks wrote:
> Hi,
> If you have Adobe Acrobat installed, the you can print to PDF as
> you would print to a regular printer. Adobe Acrobat costs money though.
>
> The Ptolemy vergil script has a hacked in option "-printPDF"
> which will print a model to the first printer that has the string "PDF"
> in its name. For example, if you have Adobe Acrobat installed,
>
> $PTII/bin/vergil -printPDF
> $PTII/ptolemy/domains/sdf/demo/Butterfly/Butterfly.xml
>
> will create a file called "Java Printing.pdf" on the Desktop.
> It looks like there is a problem with the background not being set to
> white though.
>
>
>
> We have prototype code that uses the AGPL'd itextPDF library from
> http://itextpdf.com/
>
> This code can be enabled in Vergil by editing
> ptII/ptolemy/vergil/basic/BasicGraphFrame.java
> and uncommenting a section of code and recompiling
>
> // Uncomment the next block to have Export PDF *ALWAYS* enabled.
> // We don't want it always enabled because ptiny, the applets and
> // Web Start should not included this AGPL'd piece of software
>
> // if (_exportPDFAction == null) {
> // //String exportPDFActionClassName =
> exportPDFActionClassNameParameter.stringValue();
> // String exportPDFActionClassName =
> "ptolemy.vergil.basic.itextpdf.ExportPDFAction";
> // try {
> // Class exportPDFActionClass = Class
> // .forName(exportPDFActionClassName);
> // Constructor exportPDFActionConstructor =
> exportPDFActionClass.getDeclaredConstructor(BasicGraphFrame.class);
> // _exportPDFAction = (AbstractAction)
> exportPDFActionConstructor.newInstance(this);
> // } catch (Throwable throwable) {
> // new InternalErrorException(null, throwable, "Failed to construct
> export PDF class \""
> // + exportPDFActionClassName
> // + "\", which was read from the configuration.");
> // }
> // }
> // End of block to uncomment.
>
>
> This should add an Export PDF menu choice to Vergil's File menu.
> This menu choice will not be available in Kepler unless you add it.
>
> This code is prototype code, so you are on your own.
>
> The reason it is not folded in is because it uses GPL'd software.
> Edward and I are looking at various possibilities.
>
> _Christopher
>
>
>
> On 3/1/10 12:52 PM, u.utku.turuncoglu at be.itu.edu.tr wrote:
>> Hi,
>>
>> Is it possible to save created workflow in eps or pdf format? Now, i am
>> using simple screen shots but the quality of them are worse than i
>> expected (especially for the publications). Any suggestion can be
>> helpful.
>>
>> Best regards,
>>
>> --ufuk
>>
>>
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: eal.vcf
Type: text/x-vcard
Size: 351 bytes
Desc: not available
URL: <http://lists.nceas.ucsb.edu/kepler/pipermail/kepler-users/attachments/20100301/c1bb4d63/attachment.vcf>


More information about the Kepler-users mailing list