[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: TestClearButton
[Thread Prev] | [Thread Next]
- Subject: Re: TestClearButton
- From: Bruce Steers <bsteers4@xxxxxxxxx>
- Date: Wed, 7 Jan 2026 19:39:06 +0000
- To: user@xxxxxxxxxxxxxxxxxxxxxx
On Sat, 3 Jan 2026 at 21:01, Benoît Minisini <
benoit.minisini@xxxxxxxxxxxxxxxx> wrote:
> Le 03/01/2026 à 21:28, Lee a écrit :
> > On 1/3/26 2:52 PM, Benoît Minisini wrote:
> >> It's because the ComboBox searches the clear button icon in the icon
> >> stock, and 'gb.form.stock' is not loaded.
> >>
> >> Maybe it should use in that case a default clear button instead of
> >> raising an error...
> >
> > From what I could tell by looking at the code, it attempts to load
> > "clear.png". And, if it not found in the current directory is moves up
> > the directory tree trying to find it. (I'm not sure of that as I do not
> > understand the use of SUPER in a class that inherits no parent.)
> >
> > A /comp/src/gb.gui.base/clear.png symbolic link exists which points
> > to ../gb.form.stock/gambas-thin/128/clear.png which also exists. If my
> > (mis)understanding of bMoveUp and Super.Load is correct, it seems to me
> > it should work.
> >
>
> The problem should be fixed by the last commits.
>
> Regards,
>
> --
> Benoît Minisini.
I'm still getting issues.
To reproduce..
1. load any project.
2. click a control.
3 click in the "Group" property field.
throws an error.
Unable to load image.
[gb.gui.base].ComboBox.UpdateClearButton.225
I think it is something to do with Image.Load() on that line.
This code...
If Component.IsLoaded("gb.form.stock") Then
$hClearImage = Image.Load("icon:/128/clear")
Else
makes the error.
If i change it to this code...
If Component.IsLoaded("gb.form.stock") Then
$hClearImage = Picture["icon:/128/clear"].Image
Else
Then no error.
(shouldn't you do it similar to that anyway to handle dark theme ? )
Respects
BruceS
| Re: TestClearButton | Bruce Steers <bsteers4@xxxxxxxxx> |
| TestClearButton | CD <dessere.claude@xxxxxx> |
| Re: TestClearButton | Lee <t.lee.davidson@xxxxxxxxx> |
| Re: TestClearButton | Benoît Minisini <benoit.minisini@xxxxxxxxxxxxxxxx> |
| Re: TestClearButton | Lee <t.lee.davidson@xxxxxxxxx> |
| Re: TestClearButton | Benoît Minisini <benoit.minisini@xxxxxxxxxxxxxxxx> |