- From: Simon Fraser via GitHub <sysbot+gh@w3.org>
- Date: Sun, 23 Feb 2025 21:13:50 +0000
- To: public-css-archive@w3.org
I've drawn up some diagrams of how I think bevel and scoop should be rendered. Note that with uneven border widths, you can't think of rendering the border as stroking a path; it has to be inner and outer paths computed separately. ### Bevel  The goal is to have the bevel section maintain the border width. Naively joining the points you'd use for `round` result in a thinner diagonal. Proposed algorithm for computing the inner border edge: 1. Take the points where the outer border bevel corners are 2. From each, compute a line perpendicular to the the bevel, with a length given by the border width on that side (w1, w2) 3. Compute a line that intersects the inner ends of the lines from step 2 4. Compute where that line intersects the two inner border sides ### Scoop  The goal here again is to maintain the width of the scoop section, and also to have the inner scoop edge prescribe an ellipse around the outer box corner (this looks better than perpendicular joins at the inner edges). Proposed algorithm for computing the inner border edge: 1. Compute an ellipse whose center is the outer corner, whose x radius is the (border-radius width + border width on the horizontal side) and whose y radius is (border-radius height + border width on the vertical side) 2. Compute the intersections of the relevant ellipse quadrant with the inner border edges -- GitHub Notification of comment by smfr Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/11610#issuecomment-2677118752 using your GitHub account -- Sent via github-notify-ml as configured in https://github.com/w3c/github-notify-ml-config
Received on Sunday, 23 February 2025 21:13:51 UTC