Page 1 of 1

TextGadget and Mouse Click

Posted: Fri Mar 14, 2025 8:28 pm
by jak64
TextGadget and Mouse Click

Hello everyone,
I used Tess's code from 2015 in a program I'm writing (Windows 11 64-bit, PureBasic v6.20).

Here's the link to Tess's code:

https://www.purebasic.fr/english/viewto ... se#p471103

I've been looking for a long time for a way to have a TextGadget that responds to mouse clicks.

Her code is perfect, and I congratulate her for it.

In my program, I use a ScrollArea in which I put several hundred lines. I first used ButtonGadgets, but I couldn't change the colors.

I then used CanvasGadgets, but then the mouse wheel didn't work (which is normal).

Using Tess's code, I've created several hundred TextGadgets, and I can change the text and background colors, of course, but these TextGadgets react to mouse clicks, and what's more, they're fast even with several hundred lines.
Finally, the mouse wheel works to move up or down in the ScrollArea.

Congratulations again to Tess.

Why isn't the parameter Tess uses in the documentation?

Re: TextGadget and Mouse Click

Posted: Fri Mar 14, 2025 8:56 pm
by Caronte3D
jak64 wrote: Fri Mar 14, 2025 8:28 pm Why isn't the parameter Tess uses in the documentation?
None of the "#SS_" constants are in the documentation, I think because is a Windows only

Re: TextGadget and Mouse Click

Posted: Fri Mar 14, 2025 10:56 pm
by jak64
Hello Caronte3D,
That's a shame... I searched for a long time before finding it, especially if you're not an expert on "#SS_" constants.

Do you know where I can find documentation on these constants?

Re: TextGadget and Mouse Click

Posted: Fri Mar 14, 2025 11:38 pm
by mk-soft
MSDN SS_ -> Google

Re: TextGadget and Mouse Click

Posted: Fri Mar 14, 2025 11:59 pm
by jacdelad

Re: TextGadget and Mouse Click

Posted: Sat Mar 15, 2025 12:38 am
by jak64
Thanks jacdelad and mk-soft