[Gambas-user] IDE doesn't show picture property of a custom Button control

Bruce Steers bsteers4 at gmail.com
Wed May 10 13:31:37 CEST 2023


On Wed, 10 May 2023 at 11:04, Jorge Carrión <shordi at gmail.com> wrote:

> Hi, everybody.
> I'm making a control that is a Button that supports a background image. It
> works reasonably well, but the IDE doesn't show me the selected Stock image. All
> the buttons look the same at develop time and that's confusing. Does
> anyone know how to make the IDE recognize the Picture property and display
> the image as it does with, say, the Button control? I attach a small
> project that illustrates what I say.
>

Not really.

gambas IDE form designer can only show native controls,
The IDE loads the controls internally and that are coded to both construct
at runtime and to display in the IDE also. so it's not a good idea to allow
custom made controls to load into the IDE itself as it can cause
problems/crashes. So they do not.

I added code to my gambas IDE that "does" load custom controls and made
them visible but it's no longer working due to some recent changes.

Maybe if you made your class inherit Button not UserControl you may get it
to show the images but at best all you will see is the generic Button in
the IDE not any of your custom drawings.

BruceS
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20230510/64f2394e/attachment.htm>


More information about the User mailing list