[fxruby-users] How to make a copy of an existing image instance
stroemarius84 at yahoo.com
Thu Jun 26 05:50:35 EDT 2008
Maybe someone know the answer. How to make an exact copy of a previously instanced FXImage object?
I need that because image manipulation like crop or scale methods
affect the current object. I have tried to use clone or dup method to
create an exact copy of image but when I tried to use cloned object I
`getWidth': This FXDrawable * already released (RuntimeError)
Here is some code:
dataBuffer = File.open("someFile.jpg","rb").read
img = FXJPGImage.new(getApp(), dataBuffer, IMAGE_OWNED|IMAGE_KEEP|IMAGE_SHMI|IMAGE_SHMP)
clonedImage = img.clone
I need some idea to make multiple copies of a current image. Thanks
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the fxruby-users