haxeui / haxeui-hxwidgets

The hxWidgets backend of the HaxeUI framework -
http://haxeui.org
MIT License
23 stars 7 forks source link

Default size for Slider #16

Closed R3D9477 closed 3 years ago

R3D9477 commented 6 years ago

Hi. Is it possible to evaluate default size of vslider and hslider?

For example this markup will not wirks correctly: <hslider pos="50" width="100"/> 1

needed to set value height manually: <hslider pos="50" width="100" height="25" /> 2

Same defect actually for vslider and property width.

(all of these samples are correctly works with haxeui-html5, haxeui-kha and haxeui-openfl) Thanks.

ianharrigan commented 6 years ago

The width is quite hard to auto size to be honest, that said, the height should be fine. Let me check the default theme.

ianharrigan commented 6 years ago

what happens with:

<hslider pos="50" width="100" style="height:auto;" />

?

Ah - just noticed this is hxwidgets

ianharrigan commented 6 years ago

image

This works for me... Have you tried the "validation" branches of haxeui-core and haxeui-hxwidgets?

R3D9477 commented 6 years ago

@ianharrigan Thanks for your answer!

  1. hslider:height = vslider:width
  2. I'm on Linux Mint 18.2 x64 (with MATE de, based on GTK+), does it tested with non-windows platforms (linux/mac)?
  3. Sure, I've Haxe 3.4.2, hxWidgets, haxeui-core and haxeui-hxwidgets from git
  4. wxWidgets 3.0.2
  5. Whether to move an issue to hxWidgets repo?

Another example:

<vbox width="100%" height="100%">
    <hslider pos="50" width="100" height="25" />
    <vslider pos="50" width="25" height="100" />
</vbox>

1

<vbox width="100%" height="100%">
    <hslider pos="50" width="100" />
    <vslider pos="50" height="100" />
</vbox>

2

ianharrigan commented 6 years ago

"validation" branches of haxeui-core and haxeui-hxwidgets the same?

R3D9477 commented 6 years ago

@ianharrigan yes, with "validation" branches I have same result.

But, this sample is works fine (answering the previous question):

<vbox width="100%" height="100%">
    <hslider pos="50" width="100" style="height:auto;" />
    <vslider pos="50" height="100" style="width:auto;" />
</vbox>