position from right

Positioning a background image a certain distance from the right and bottom edges

'Background-position' in levelÂ 2 can position an image relative to the top left corner or at a certain percentage of the width/height. You can thus put it against the right edge, but not, e.g., 10px from the right edge.

One solution is the 'calc()' functional notation from the Values and Units module: 'calc(100% - 10px)'. Another is extra keywords: '10px from-right', or 'background-position: bottom 10px right 25px'.

Related notes:

Eric Meyer suggested (ACTION-65) that 'background-origin' could be yet another way to specify the edges from which 'background-position' is calculated. After all, that is what the word "origin" suggests. E.g., 'background-origin: bottom left padding-box' chooses the padding box as the basis for 'background-size' calculations and the bottom left corner of that edge as the origin for 'background-position'.