Kodi Community Forum

Full Version: Slider Control Textures explanation
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
HI Everybody,

can some please provide an explanation as to how the individual texture tags of the slider control work, specially the border attribute which can contain for digits

e.g. whats does <textureslidernib border="10"> mean?
e.g. whats does <textureslidernib border="0,10"> mean?
e.g. whats does <textureslidernib border="0,0,10"> mean?
​​​​​​​​​​​​​​e.g. whats does <textureslidernib border="0,0,0,10"> mean?

And how does this relate to the height and width of the slider control if at all?

If have tried playing with the values and see how it looks like, but I can make proper sense of what the values do.

​​​​​​​Thanks
it's explained in the wiki:
Texture_Attributes (wiki)
(2019-02-22, 19:26)ronie Wrote: [ -> ]it's explained in the wiki:
Texture_Attributes (wiki)
 Sorry, maybe I did not state my question appropriately.

There is:
<texturesliderbar>: this is the image for the slider bar, which takes the dimensions width and height of the slider control. So the image is stretched according to that dimensions.

Then there is:
<textureslidernib>
<textureslidernibfocus> : this are the images for the nib, now how does this relate to the size of the slider control. (I was using the border attribute to play with the size but I guess this is not the correct way. 

What I want is: 
A Slider Image which is 400px wide and 10px high. And a nib which is a  circle image with 30x30 px  centered in the middle of the slider mage.

How can I achieve that?

Any help is greatly appreciated
(2019-02-22, 20:28)DjCisco Wrote: [ -> ]What I want is: 
A Slider Image which is 400px wide and 10px high. And a nib which is a  circle image with 30x30 px  centered in the middle of the slider mage.
 For the slider background (texturesliderbar) create a PNG with the dimensions 400x30px and leave 10px at the top and the bottom empty (transparent). Alternatively you could also use a diffuse texture to make parts of the image invisible.
(2019-02-22, 21:42)JackTirol Wrote: [ -> ]
(2019-02-22, 20:28)DjCisco Wrote: [ -> ]What I want is: 
A Slider Image which is 400px wide and 10px high. And a nib which is a  circle image with 30x30 px  centered in the middle of the slider mage.
 For the slider background (texturesliderbar) create a PNG with the dimensions 400x30px and leave 10px at the top and the bottom empty (transparent). Alternatively you could also use a diffuse texture to make parts of the image invisible. 
 Ah ok, so does this mean that the nib always gets scaled to the dimensions of the slider control?
(2019-02-22, 22:41)DjCisco Wrote: [ -> ]
(2019-02-22, 21:42)JackTirol Wrote: [ -> ]
(2019-02-22, 20:28)DjCisco Wrote: [ -> ]What I want is: 
A Slider Image which is 400px wide and 10px high. And a nib which is a  circle image with 30x30 px  centered in the middle of the slider mage.
 For the slider background (texturesliderbar) create a PNG with the dimensions 400x30px and leave 10px at the top and the bottom empty (transparent). Alternatively you could also use a diffuse texture to make parts of the image invisible. 
 Ah ok, so does this mean that the nib always gets scaled to the dimensions of the slider control?

Pretty much. It works basically the same as a progress bar.