rounded rectangle
See original GitHub issueWhat you think about add a rounded rectangle?
I suggest a property radius
, e.g.
const rectangle = ocanvas.display.rectangle({
width: 200,
height: 100,
x: 0,
y: 0,
stroke: '1px black',
radius: 10,
}
Maybe a radiusTopLeft
, radiusTopRight
, etc… can be useful
Issue Analytics
- State:
- Created 5 years ago
- Comments:8 (7 by maintainers)
Top Results From Across the Web
Rounded Rectangle -- from Wolfram MathWorld
A rounded rectangle is the shape obtained by taking the convex hull of four equal circles of radius r and placing their centers...
Read more >Create rounded squares and rectangles with the ...
Click the Rounded Rectangle tool . · Drag to draw a rounded rectangle. · Drag any of the corner handles within the shape...
Read more >Perimeter and Area of a Rounded Rectangle - Had2Know
Rounded rectangles have corners that are smoothed out with quarter-circle arcs. Rectangles that have rounded corners instead of square corners are pleasing ...
Read more >rounded rectangle - Cairo graphics library
rounded rectangle. /* a custom shape that could be wrapped in a function */ double x = 25.6, /* parameters like cairo_rectangle */...
Read more >Rounded Rectangle Vector Art - Vecteezy
Browse 11786 incredible Rounded Rectangle vectors, icons, clipart graphics, and backgrounds for ... rectangle shape with rounded corner background. vector.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi guys!
These last days I was fighting with a bug. Today I found it was caused by a typo — I missed a
!
before a boolean expression 😅Now I’m trying to clean the code, but I want to share with you this screenshot:
I tested the border-radius feature using fills and strokes with alpha. I also tested the clipChildren property — that’s why you can see those little green rectangles. I compared it with the non-border-radius version of the rectangle, and here are the results.
Thank you very much for your support, guys 😃
Greetings!
Great work! Let’s continue the discussion in the PR! 😃