haxeui / hxWidgets

Haxe externs (and wrappers) for wxWidgets
MIT License
77 stars 22 forks source link

Corrects button bar with button that has an icon #96

Open Shallowmallow opened 1 year ago

Shallowmallow commented 1 year ago

If you a had a button in a button bar, it would cause problem

<button-bar>
            <button text="Item 1" icon="haxeui-core/styles/default/haxeui_small.png" iconPosition="top" />
 </button-bar>

You would have

../src/gtk/anybutton.cpp(403): assert ""Assert failure"" failed in DoSetBitmapPosition(): invalid position

That's because the bitmapPosition would be set even the value is "enum(0)".

Now, the line seems quite useless, because it seems the basic buttons page in the component explorer work without.