ikarus1969 wrote: ↑December 10th, 2018, 4:21 pm
Just one question: meters with the container-option are positioned relative to the container.
When i access the position of a meter inside of a acontainer with section-variables (in that case the y-position, but i think that doesn't matter) i still get the position relative to the skin and not relative to the container (what i would have expected before my test).
is this the intended behavior?
I think "intended" might be too strong a word, but yes. The relative positioning is done by simply making the first content meter relative to the container by using an
implied Y=r. That will, as it does with any meter, even before Container was an idea, make the meter draw relative to the starting Y of the container meter, but it doesn't change the absolute Y position of the meter in the skin. Same is of course true with X. The
numeric values of X and Y are
always relative to the skin. Container doesn't change that.
You would have to do some simple math based on the Y of the container meter, subtracting that from the Y of the content meter.
The first "content" meter defined in the container meter will automatically be relative to the starting X and Y (think "r") of the container meter, No "r" relative positioning modifier is needed. It is redundant and ignored.
Y=10 has the effect of
Y=10r.
All subsequent "content" meters in the same container
should use the "R" or "r" relative positioning modifiers, which will be relative to the immediately preceding content meter.
If no "R" or "r" is used on any content meter, it will still automatically be relative to the container meter.
Any subsequent meters that are not "content", that don't have the
Container option, when using the "R" or "r" relative positioning modifiers, will be relative to the immediately preceding meter that also is NOT "content".