[Gambas-user] Inherit Button, looks bad in the IDE?
Bruce Steers
bsteers4 at gmail.com
Wed Feb 17 15:57:22 CET 2021
On Wed, 17 Feb 2021 at 13:57, Tobias Boege <tobs at taboege.de> wrote:
> On Wed, 17 Feb 2021, Bruce Steers wrote:
> > --------------------------
> > ' Gambas class file
> >
> > Export
> > Inherits Button
> >
> > Public Const _Properties As String = "*,Delay=200"
> > Public Const _Similar As String = "Button"
> >
> > '' Get or set Time between flash on/off in ms , default 500
> > Property Delay As Integer
> > Private $Delay As Integer
> > '' Get or set default Time between flash on/off in ms , default 500
> > Static Public Default_Delay As Integer = 500
> >
> > ----------------------------
> >
> > It works a treat in operation but the button in the IDE looks nothing
> like
> > the other buttons.
> > It looks fine at runtime but any idea how to get it to look right in the
> > IDE?
> > (see attached snapshot, the button called FlashButton)
> >
>
> _Similar is not related to appearance. I think you need the _DrawWith
> constant. See http://gambaswiki.org/wiki/dev/gambas
>
> Best,
> Tobias
>
> Brilliant , Thank you Tobias.
_Similar i used so i could use the "Change into" function to quickly change
a button to a flashbutton in the IDE
It was almost perfect except for how it looked in the IDE.
_DrawWith sorted it out a treat :)
i have just recently discovered the power of using Inherit on controls in a
class and getting into customizing them.
Loving it, so far all i have is a flashy colour button and a GridView that
has built in Sort and MoveRowUp and MoverowDown functions but feeling a new
area of an awesomely handy library of custom controls ready for import into
my projects in the making..
:)
Wishing well
BruceS
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20210217/4a82f73f/attachment.htm>
More information about the User
mailing list