I added an Image to a form, then I uploaded an image from the IDE and the quality of the image was low.
The file I uploaded was a png screenshot with some text and graphics and the size of 1096 x 759. The text was readable, but was ugly.
I uploaded the same file as an asset and I added this code:
def form_show(self, **event_args):
self.image_1.source = '_/theme/image.png'
And the screenshot came up perfect.
I assume there is some undocumented size reduction or compression going on. Is it possible to know what’s going on here?
EDIT
Instead of using the form_show
event I replaced the text in the source
property with _/theme/image.png
.
As a side note, when I selected the long text that represents the bitmap previously uploaded to the form and pressed delete, the IDE hung for about minute.