0

Oblique ellipse in HTML5

How to draw an oblique ellipse in HTML5?

10th Feb 2020, 3:14 AM
Apologetica911
Apologetica911 - avatar
7 odpowiedzi
+ 5
you can use css border-radius property to round the corners of an HTML element. and transform property to rotate and make it oblique. https://code.sololearn.com/WxntFDdz4vW8/?ref=app
10th Feb 2020, 3:44 AM
🇮🇳Omkar🕉
🇮🇳Omkar🕉 - avatar
+ 2
Apologetica911, Yes. it's possible in HTML. Have you seen svg lesson from HTML tutorial here? svg provides an <ellipse> element. you need to specify dimensions for ellipse by using its attributes. cx - x coordinate of center of ellipse cy - y coordinate of center of ellipse. rx - radius along x axis ry - radius along y axis. fill - fill color of element. also as you want to rotate ellipse use transform attribute. It allows basic transformations like translate, rotate, scale ,skew. for rotating syntax is as : transform ="rotate(a x y)" where a is angle of rotation x and y specify center of rotation. answer to second question - vh and vw are relative units. 100vh is equal to full height of viewport. 100vw is equal to full width of viewport. see this example , if you are unsure search on net , especially MDN: https://code.sololearn.com/Wkrx5GH4412Y/?ref=app
10th Feb 2020, 5:00 AM
🇮🇳Omkar🕉
🇮🇳Omkar🕉 - avatar
+ 2
Apologetica911 , stroke attribute to specify border color. stroke-width attribute to specify border width. stroke ="blue" stroke-width="10" You can see complete tutorial about SVG here : https://developer.mozilla.org/en-US/docs/Web/SVG/Tutorial
10th Feb 2020, 7:53 AM
🇮🇳Omkar🕉
🇮🇳Omkar🕉 - avatar
+ 1
Omkar thank you very much for these complete answers!
10th Feb 2020, 5:47 AM
Apologetica911
Apologetica911 - avatar
0
Directly in HTML5, without CSS, is it not possible? In your CSS code, what does vh / vw?
10th Feb 2020, 4:18 AM
Apologetica911
Apologetica911 - avatar
0
If I want to add an outline to this ellipse, what attribute should I use?
10th Feb 2020, 6:11 AM
Apologetica911
Apologetica911 - avatar
0
Thank you verry much!
10th Feb 2020, 8:14 AM
Apologetica911
Apologetica911 - avatar