You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As far as I can see from the code and the documentation there is currently no support for clipping content. At a minium the ability to clip content to be inside a block or box would be very useful in many cases.
I propose adding a clip field to block and box that when set to true will clip the content to be inside these.
Yeah, the clip field is also how I would implement this. Adding the field is the easy part though, clipping would also need to be integrated with text and SVG rendering.
Activity
laurmaedje commentedon Mar 29, 2023
Yeah, the clip field is also how I would implement this. Adding the field is the easy part though, clipping would also need to be integrated with text and SVG rendering.
tmbb commentedon Jun 25, 2023
This isn't available in the release version yet, is it?
laurmaedje commentedon Jun 26, 2023
It is already available. Note that the currently clipping is always rectangular though, it does not take into account the corner radius.
Docs: https://typst.app/docs/reference/layout/block/#parameters-clip