I'm writing an embedded TM and i would like to align the artist picture to the right, but that image should change its height to fit the bottom panel dynamically maintaining the aspect relation. So the x coordinate should decrease if the panel is taller, or decrease if we make the bottom panel shorter.
I have different codes with the following results:
At left border only if resizing bottom panel xAnchor="-Panel.Height" x="-10" y="10"
Shows at the left border xAnchor="-X:Panel.Height" x="0" y="10"
Shows at the left border xAnchor="X:-Panel.Height" x="0" y="10"
Shows at the left border xAnchor="X:Panel.Right-Panel.Height" x="0" y="0"
Shows at the left border xAnchor="X:Panel.Right-Y:Panel.Height" x="0" y="0"
Didn't shown anything xAnchor="Panel.Right" x="-Panel.Height" y="10"
It's something but not aligned to the right xAnchor="Panel.Right" x="-300" y="10"
The album art is included aligned to the left border for comparison:
<?xml version="1.0" encoding="utf-8"?>
<root>
<theaterMode>
<settings enableScaling="false" />
<settings rotationPeriod="300" />
<settings bdr="128,128,128" bg="34,40,42" />
</theaterMode>
<!-- Album cover aligned to the left -->
<element type="AlbumCover" x="10" y="10" widthDock="Panel.Height" width="-20" heightDock="Panel" height="-20" min="100" max="400" brightness="1.0" ></element>
<!-- Artist picture would like to align it to the right
It's something xAnchor="Panel.Right" x="-300" y="10"
At left border only if resizing bottom panel xAnchor="-Panel.Height" x="-10" y="10"
Shows at the left border xAnchor="-X:Panel.Height" x="0" y="10"
Shows at the left border xAnchor="X:-Panel.Height" x="0" y="10"
Shows at the left border xAnchor="X:Panel.Right-Panel.Height" x="0" y="0"
Shows at the left border xAnchor="X:Panel.Right-Y:Panel.Height" x="0" y="0"
Didn't shown anything xAnchor="Panel.Right" x="-Panel.Height" y="10"
-->
<element type="Gallery"
xAnchor="Panel.Right" x="-300" y="10"
widthDock="Panel.Height" width="-10" heightDock="Panel.Height" height="-10" min="100" max="300"
aspectRatio="zoomKeep" interval="20" tags="artist"
></element>
</root>
i have added support for basic expressions (+/-) in the x and y offset values eg. to right align a variable size picture:
<element type="AlbumCover" xAnchor="Panel.Right" x="11-Panel.Height" y="9" widthDock="Panel.Height" width="-20" heightDock="Panel" height="-20" min="100" max="300" brightness="1.0" ></element>
also i have changed it so "enableScaling" is ignored for embeded theatermode skins because as implemented it causes positioning problems for aligning elements (I will leave it in for the normal theatermode skins incase the change causes older skins to not work plus its useful for resizing fonts)