Re: [csswg-drafts] [css-shapes][css-backgrounds] percentage values for `object-view-box` inconsistent with percentage values for `background-position` (#7941)

Yes, this is intentional. `background-position` is not trying to position the top left corner of the tile, it's considering the tile as a whole. Length values are offsets from its position, whatever that would have been, and percentages are representing alignment between left-aligned and right-aligned, with center-aligned as 50%.

xywh on the other hand is a notation (more broadly used than in CSS) which represents a rectangle using the x and y coordinates of its top left corner, plus a width and a height.

(I suppose if there was a need for a background-position style notation, which gives the rectangle's dimensions plus a `<position>` value, we could add that to css-shapes; but it'd be a different notation than xywh.)

Let me know if that answers your question, or if you think there's something to follow up here. :)

-- 
GitHub Notification of comment by fantasai
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/7941#issuecomment-1317468029 using your GitHub account


-- 
Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config

Received on Wednesday, 16 November 2022 18:22:14 UTC