wxUiEditor icon indicating copy to clipboard operation
wxUiEditor copied to clipboard

Resolve wxPython code generation for SVG, XMP and Animation files

Open KeyWorksRW opened this issue 2 years ago • 1 comments

Description:

Currently, SVG, XMP and Animation images have to be external (animation images are currently broken until we decide how to handle these three types).

zlib.decompress(string) supposedly takes a compressed binary string and decompresses it into a string. That means we should be able to create a Base64 rendering of an SVG file and decompress it into an actual SVG string to hand to FromSVG.

If we can get zlib.decompress(string) to work, then we could also compress XMP files as well (we already compress SVG files). I think we're stuck with animation files being external unless we can figure out how to convert the results of zlib.decompress(string) to a stream.

KeyWorksRW avatar Feb 16 '23 17:02 KeyWorksRW

Embedding an SVG file now works. For the 1.x release, we should probably take the same approach to XPM files so that they can be embedded. Animation files could be done this way, but we'll need to add python stream code in order to get it into the animation control.

KeyWorksRW avatar Mar 06 '23 16:03 KeyWorksRW