Jump to content

[SOLVED] stencil - WidgetSprite in HBox.


photo

Recommended Posts

Hey Unigine,

 

stencil isn't working for sprites.

 

<hbox stencil="1" width="10"  export="1" name="statusbarLayer">
    <sprite texture="imagepath.png"/>
</hbox>

 

If I'm using a label:

<hbox stencil="1" width="10"  export="1" name="statusbarLayer">
    <label><text>012345678910111213</text></label>
</hbox>

 

it work's neither. (updated)

In my opinion thats a bug isn't it?

 

PS: I tried to set the align in texture like: align="expand" etc. and it didn't work aswell.

Greetings

Lars

Link to comment

Hey Manguste,

 

HBox is deduced of VBox - so this feature should be inherited there aswell like your documentation.

 

But at all with a VBox or a GroupBox it doesn't work.

Link to comment
  • 2 weeks later...

Lars,

 

The idea is as follows: if stencil is set for a container, it will cut widgets by its bounds. And that happens when its childen you want to cut have the align="overlap" flag. Children that do not have this flag set, will simply increase the container size. And since recalculated bounds include the child widget in this case, there will be absolutely no effect by setting a stencil flag.

Link to comment

Hey Manguste,

 

thanks for your tip, I'll test it this evening and give feedback.

At all it would be cool to find such tips in the documentation.

 

Greetings

Lars

Link to comment
  • 2 weeks later...
×
×
  • Create New...