Req Suggestion: Include directive with parameters
#61
(2015-04-07, 20:03)Jayz2K Wrote: If we don't consider the new include, $VAR works for <label>, <texture>, and as I discovered, <property> tags. It won't work for <posx>, <posy>, <width>, <height> tags, etc. Neither for StringCompare, etc.

So if those don't work outside the include, it won't in $PARAM. Still don't know why $VAR is not universal in the skinning engine but there should be a reason.

you are right, but I'm not sure why this is not possible. could be something to do with the position calculation.
Reply
#62
Hi, I'm using the new include for some special cases, works fine and much more flexible. Noticed that the conditional tag works only at the include level :

Exemple :
Code:
    <include name="SeasonPreview" condition="Skin.String(VDO.View1.B3SizeY,1ROW)">
        <param name="tilew" value="212" />
        <param name="tileh" value="119" />
    </include>
    <include name="SeasonPreview" condition="Skin.String(VDO.View1.B3SizeY,2ROW)">
        <param name="tilew" value="424" />
        <param name="tileh" value="238" />
    </include>
    <include name="SeasonPreview" condition="Skin.String(VDO.View1.B3SizeY,3ROW)">
        <param name="tilew" value="636" />
        <param name="tileh" value="357" />
    </include>

And not in param level which should be :

Code:
    <include name="SeasonPreview">
        <param name="tilew" condition="Skin.String(VDO.View1.B3SizeY,1ROW)" value="212" />
        <param name="tilew" condition="Skin.String(VDO.View1.B3SizeY,2ROW)" value="424" />
        <param name="tilew" condition="Skin.String(VDO.View1.B3SizeY,3ROW)" value="636" />
        <param name="tileh" condition="Skin.String(VDO.View1.B3SizeY,1ROW)" value="119" />
        <param name="tileh" condition="Skin.String(VDO.View1.B3SizeY,2ROW)" value="238" />
        <param name="tileh" condition="Skin.String(VDO.View1.B3SizeY,3ROW)" value="357" />
    </include>

Any chance to have conditional tag usable at param level ? Reduces a lot more the code when there's a large amount of params (ex : if I compare values for 3 different strings, I have to call the include 9 times to satisfiy all possibilities. With conditional param, I call it 1 time with 9 lines). It should also be a $VAR substitution for tags that don't support it (posx, posy, width, etc.)
[Skin] KOver - V1.1.0 Stable (Repo version)
[WIP] ReKOver - Skinning tool project

If I've been helpful or you like my work, hit "THANK USER" button ;) ...
Reply
#63
This was one of my suggestions we discussed while the feature was developed but it was denied because you could use $VAR to overcome it. In general I would prefer conditional params instead of defining a $VAR for each param which needs conditional values.
Reply
#64
(2015-05-24, 09:12)xhaggi Wrote: This was one of my suggestions we discussed while the feature was developed but it was denied because you could use $VAR to overcome it.
That makes sense ... but still, $VAR is not universal.

(2015-05-24, 09:12)xhaggi Wrote: In general I would prefer conditional params instead of defining a $VAR for each param which needs conditional values.
Agree.

Right now, I'm sizing / positioning all things dynamically with slide animations (which support conditions). Not the cleanest way for my opinion (however it works). So I'm not sure where to place my request : conditions for $PARAM or a fix for <posx>,<posy>,<height>,<width> $VAR support ...
[Skin] KOver - V1.1.0 Stable (Repo version)
[WIP] ReKOver - Skinning tool project

If I've been helpful or you like my work, hit "THANK USER" button ;) ...
Reply
#65
I'm trying to use create fade animation to work with this new include,
I wonder if there a way to replace the old method to let the user set the transparency for skin\image (which is create a lot of includes with fade animation and use conditions)

I Tried this one:
Code:
<include name="fade_level">
    <param name="Fade" default="100"/>
    <definition><animation effect="fade" start="100" end="$PARAM[Fade]" time="0" condition="true">Conditional</animation></definition>
</include>

then In the image I want to fade I put:
Code:
<include name="fade_level"><param name="Fade" value="70" /></include>

It Worked... but, when I tried to replace the "70" value with some $INFO[skin.string...] or $VAR - It not worked... only real number is working... so the whole method it pointless again...
Am I missing something and it can be done ?
Phenomenal™ Skin • ForumWebsiteGitHub
Reply
#66
$VAR[] or $INFO[] stuff works for exactly the same cases as usual.

Code:
end="$VAR[....]"
does not work without parametrized includes, so it also wont work when using them.
Donate: https://kodi.tv/contribute/donate (foundation), 146Gr48FqHM7TPB9q33HHv6uWpgQqdz1yk (BTC personal)
Estuary: Kodis new default skin - ExtendedInfo Script - KodiDevKit
Reply
#67
so currently no way to achieve custom fade level? (without make 100 includes)
Phenomenal™ Skin • ForumWebsiteGitHub
Reply
#68
(2015-07-31, 14:24)tomer953 Wrote: so currently no way to achieve custom fade level? (without make 100 includes)
Depends on use case. colordiffuse / textcolor can also be used to achieve custom fade levels.
Donate: https://kodi.tv/contribute/donate (foundation), 146Gr48FqHM7TPB9q33HHv6uWpgQqdz1yk (BTC personal)
Estuary: Kodis new default skin - ExtendedInfo Script - KodiDevKit
Reply
#69
the use is to apply transparency on images on the skin (main menu background, list backgrounds, dialog bg etc..)
I will glad to see any example how to make it work with colordiffuse or any other trick that make things easier to code and let the user a big range of choise.
Phenomenal™ Skin • ForumWebsiteGitHub
Reply

Logout Mark Read Team Forum Stats Members Help
Suggestion: Include directive with parameters0