Export vector graphics v05

Visuals, audio, animation. Blended, not stirred. If LiveCode is part of your rich media production toolbox, this is the forum for you.

Moderators: FourthWorld, heatherlaine, Klaus, kevinmiller, robinmiller

Post Reply
capellan
Posts: 654
Joined: Wed Aug 15, 2007 11:09 pm

Export vector graphics v05

Post by capellan » Mon Sep 11, 2017 12:01 am

Hi All,

This download is an update to a stack posted 10 years ago in the mail list.

This stack exports all vector graphics pasted in the first card as PDF, Adobe Ilustrator (v7) or SVG.
Please test first if you could open every type of file produced by this stack.

Before pasting your graphics, export all included graphics as PDF, Adobe Ilustrator and SVG and open these files using programs installed in your computer or tablet.

After you verify that files exported by this stack open correctly, you are ready to delete all included graphics and paste your own graphics on the first card. Report any errors, read the source code and include your own improvements. I hope that one of you become motivated enough and helps in the creation of code that exports gradients in each format (or just for svg format)

By the way, only latest Inkscape versions (0.92 and later) could edit correctly these exported svg. Previous Inkscape versions do not understand how to handle polylines and polygons...

Al
export_vector_graphics_v05.zip

MaxV
Posts: 1579
Joined: Tue May 28, 2013 2:20 pm
Location: Italy
Contact:

Re: Export vector graphics v05

Post by MaxV » Fri Sep 22, 2017 3:25 pm

Hi,
quait all mi programs get this bugged image from the SVG, also firefox:
Screenshot.jpg
Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w

capellan
Posts: 654
Joined: Wed Aug 15, 2007 11:09 pm

Re: Export vector graphics v05

Post by capellan » Sat Sep 23, 2017 6:36 pm

Hi Max,

I think that you found a bug! :oops:
Compare your own svg file with the svg attached to this post.
Please include the zipped svg file in a post in this forum thread
to compare with files exported correctly.

Does exporting as pdf and adobe ilustrator produce the same problem?

By the way, Which OS and Livecode version are you using?
I used LC 8.1.3 and LC 6.7.1 in Windows to create all 3 zipped
svg, pdf and ai. Svg file exported from LiveCode is editable
using Inkscape v 0.92

Al
vector2export svg output.PNG
vector2export_svg-pdf-ai-samples.zip

MaxV
Posts: 1579
Joined: Tue May 28, 2013 2:20 pm
Location: Italy
Contact:

Re: Export vector graphics v05

Post by MaxV » Mon Sep 25, 2017 10:17 am

Hi,
I added the SVG I obtainied with livecode 9.
Attachments
vector2export 90365399354.svg.zip
(17.78 KiB) Downloaded 267 times
Livecode Wiki: http://livecode.wikia.com
My blog: https://livecode-blogger.blogspot.com
To post code use this: http://tinyurl.com/ogp6d5w

capellan
Posts: 654
Joined: Wed Aug 15, 2007 11:09 pm

Re: Export vector graphics v05

Post by capellan » Tue Sep 26, 2017 3:15 am

I tested the stack in LC9 under Windows and produces an strange error. Looks like the script could not find the same group that is referenced at the beginning of the handler... :shock:

Until LC find the cause of this error, try this new version that allows to copy the converted graphics to the clipboard and/or save them as a file.

Just notice the following: If you need to copy your graphics as PDF into the clipboard, select the option "PDF" and one
of the following options: "No encoding" or "Ascii85Encode" or "AsciiHexEncode". Do not select "FlateEncode".

Only then you could copy the PDF into the clipboard and paste it into a text or hex editor. From this other program, you could save this new file as pdf.

SVG and Adobe Ilustrator are already plain text file formats, unlike PDFs that could contain binary data.

Please test this new version 06 and report back any new error that you find.

Al
export_vector_graphics_v06.zip

Post Reply

Return to “Multimedia”