ToolbarButton images small

klaus

Expert
Licensed User
Longtime User
I have compiled a program with ToolbarButtons for a VGA device.
The images remain small, no difference if compiled Device Exe or Device(Auto scale) Exe.
The image size has no effect, btnLoad.bmp is 16*16 pixels and btnSave1.bmp is 32*32. Should the image mode somewhere be set to cStrechImage?

The image below shows it, a test program is attached.

Best regards.
 

Attachments

  • Toolbar.JPG
    Toolbar.JPG
    13.9 KB · Views: 147

Erel

B4X founder
Staff member
Licensed User
Longtime User
Thanks Klaus. It is now fixed.

The following lines were missing from ToolBar constructor (il is the ToolBar ImageList).
B4X:
 C#:
            double scaleX = (double)(Thread.GetData(Thread.GetNamedDataSlot("scaleX")));
            double scaleY = (double)(Thread.GetData(Thread.GetNamedDataSlot("scaleY")));
            il.ImageSize = new Size((int)(il.ImageSize.Width * scaleX), (int)(il.ImageSize.Height * scaleY));
 
Top