2013-10-20, 10:44
I realise this is a little late in the piece, but we're prepping PR3451 for merge in the November window (i.e. it'll be merged around Nov 1).
This is quite a major change in control positioning, in that you now can use <left>, <right>, <centre>, <top> and <bottom> to align things, as well as percentages. As always, "r" does the "from right/bottom" as it was before. % does a percentage of the parent's size.
Everything should still work with this, however, right aligned labels outside of itemlayout/focusedlayout will break, because I've taken the opportunity to also remove the hack that had the <posx> value for right aligned labels meaning the right of the label, rather than the left.
To alleviate some issues updating your skins, I've written an XSLT (xml style sheet transformation) to handle things for you. If you're on a *nix box (Mac, Ubuntu etc.), then you should have xsltproc available, so grab the shell script and XSLT here:
XSLT script to update your skin
The XSLT updates the appropriate <posx> with <right>. If you're on win32, I'm sure there's some XML editing thing that could handle this, but that's outside what I know.
In addition, you'll want to remove any <posx>, <posy>, <width> and <height> from the label in defaults.xml.
What this may not hit is includes for specifying <posx> that are outside the <control type="label"> tags. The xslt isn't smart enough for that...
Note that the xslt processing will also likely alter whitespace in your XMLs. Thus, I recommend using
to check through and just add the fixes you want. (For confluence I added the whitespace changes in a separate commit).
Please let me know if there's any issues.
Builds are available here:
[url http://mirrors.xbmc.org/test-builds/win3....exe]Win32[/url]
[url http://mirrors.xbmc.org/test-builds/darw...os.deb]IOS[/url]
[url http://mirrors.xbmc.org/test-builds/osx/...64.dmg]OSX[/url]
[url http://mirrors.xbmc.org/test-builds/andr...pk]Android[/url]
Jonathan
This is quite a major change in control positioning, in that you now can use <left>, <right>, <centre>, <top> and <bottom> to align things, as well as percentages. As always, "r" does the "from right/bottom" as it was before. % does a percentage of the parent's size.
Everything should still work with this, however, right aligned labels outside of itemlayout/focusedlayout will break, because I've taken the opportunity to also remove the hack that had the <posx> value for right aligned labels meaning the right of the label, rather than the left.
To alleviate some issues updating your skins, I've written an XSLT (xml style sheet transformation) to handle things for you. If you're on a *nix box (Mac, Ubuntu etc.), then you should have xsltproc available, so grab the shell script and XSLT here:
XSLT script to update your skin
The XSLT updates the appropriate <posx> with <right>. If you're on win32, I'm sure there's some XML editing thing that could handle this, but that's outside what I know.
In addition, you'll want to remove any <posx>, <posy>, <width> and <height> from the label in defaults.xml.
What this may not hit is includes for specifying <posx> that are outside the <control type="label"> tags. The xslt isn't smart enough for that...
Note that the xslt processing will also likely alter whitespace in your XMLs. Thus, I recommend using
Code:
git add -p
Please let me know if there's any issues.
Builds are available here:
[url http://mirrors.xbmc.org/test-builds/win3....exe]Win32[/url]
[url http://mirrors.xbmc.org/test-builds/darw...os.deb]IOS[/url]
[url http://mirrors.xbmc.org/test-builds/osx/...64.dmg]OSX[/url]
[url http://mirrors.xbmc.org/test-builds/andr...pk]Android[/url]
Jonathan