Forum > BGRABitmap and LazPaint

Changing a Graphic Resource

(1/1)

J-G:
I have a few .PNG Images which are added to the Project>Options>Resources list and selected for display at run-time. For esoteric reasons I decided to change the basic colour of two of them by recreating the .PNG's from the original vector graphics and the new files do show the new colour.

Even though I've 'Deleted' the resources and 'Added' it again by selecting the new files, the program still displays the old colour.

In an attempt to circumvent any 'retained' information I renamed the .RES file and (as expected) it was recreated at the next compile  -  this did not resolve the issue -  so - where is the 'Resource' information held?

Another 'oddity' is that one of the images can be 'moved' by user input and that image takes on the new colour when activated ???

circular:
Resources can be in the following locations:
- RES file
- LRS file
- embedded in a form (Picture property)
- loaded from a file at runtime (LoadFromFile)

Are you sure the image is not in one of these locations?

J-G:
 :-[ :-[ :-[  D'oh!  :-[ :-[ :-[

It seems that this old mind gets stuck in a groove   -  I'd been working on the placement of 'dynamic' images (which are 'Loaded from resource') and completely forgot that the two images in question are initialised using the 'Picture' property  %)

Thanks Circular.

circular:
I thought so, that it was stored somewhere.

You're welcome.  :)

Navigation

[0] Message Index

Go to full version