T O P I C R E V I E W |
zerob |
Posted - Jan 12 2025 : 09:47:10 Hi Nigel
When i create a half ellipse and rotate it by -90 degree, the exported SVG isn't rotated and behaves strangely.
Depending on how i resize it (width, height) it either gets cut as the SVG canvas size isn't sized correctly and the rotation isn't applied, or it does some other odd things.
ImageEnView1.LayersAdd(TIEShape.iesHalfEllipse,Rect(20,20,650,250),clBlack,1,clGreen); ImageEnView1.CurrentLayer.Rotate := -90;
I didn't check if this also applies to other Shapes or just to this. |
3 L A T E S T R E P L I E S (Newest First) |
xequte |
Posted - Jan 13 2025 : 17:07:55 Oh, I understand now. Thank you for the detail. Please email me for the fix in the latest beta.
Nigel Xequte Software www.imageen.com
|
zerob |
Posted - Jan 13 2025 : 02:19:19 Yes, i did that, and it doesn't change anything.
Look at these two pictures.
Picture 1 shows the TIEShape.iesHalfEllipse that i at runtime resized by mouse. Picture 2 shows the screenshot of Chrome with the created and loaded svg.
It is too small in width and also is cropped in height, also the height is too large. In the SVG, the width and height of the svg and the viewbox is ok, but the halfellipse is cropped because it isn't created correctly.
When i manipulate the svg height and viewbox to see what is cropped off, i see that the width of the polygon, i saw this:
The Width and Height of the Polygon is switched and now 246 x 1402. It seems that the polygon is written, and then after that, with a "rotate(-270 1037 165)". When i remove this transform, then the width and height are still switched, and the width is larger than the height, which should be the other way around.
What imageen saved: <svg width="1739px" height="289px" viewBox="0 0 1739 289" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <polygon points="336,42 434,42 532,43 628,45 724,47 816,49 906,53 994,56 1080,61 1160,65 1238,71 1310,76 1378,83 1442,89 1498,96 1550,103 1596,111 1636,119 1670,127 1696,135 1716,143 1730,152 1738,160 1738,170 1730,178 1716,187 1696,195 1670,203 1636,211 1596,219 1550,227 1498,234 1442,241 1378,247 1310,254 1238,259 1160,265 1080,269 994,274 906,277 816,281 724,283 628,285 532,287 434,288 336,288 336,164" stroke="#000000" stroke-width="1px" fill="#008000" transform="rotate(-270 1037 165)"></polygon> </svg>
Width and height made bigger to see: <svg width="1739px" height="1289px" viewBox="0 0 1739 1289" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <polygon points="336,42 434,42 532,43 628,45 724,47 816,49 906,53 994,56 1080,61 1160,65 1238,71 1310,76 1378,83 1442,89 1498,96 1550,103 1596,111 1636,119 1670,127 1696,135 1716,143 1730,152 1738,160 1738,170 1730,178 1716,187 1696,195 1670,203 1636,211 1596,219 1550,227 1498,234 1442,241 1378,247 1310,254 1238,259 1160,265 1080,269 994,274 906,277 816,281 724,283 628,285 532,287 434,288 336,288 336,164" stroke="#000000" stroke-width="1px" fill="#008000" transform="rotate(-270 1037 165)"></polygon> </svg>
Transform removed
<svg width="1739px" height="1289px" viewBox="0 0 1739 1289" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"> <polygon points="336,42 434,42 532,43 628,45 724,47 816,49 906,53 994,56 1080,61 1160,65 1238,71 1310,76 1378,83 1442,89 1498,96 1550,103 1596,111 1636,119 1670,127 1696,135 1716,143 1730,152 1738,160 1738,170 1730,178 1716,187 1696,195 1670,203 1636,211 1596,219 1550,227 1498,234 1442,241 1378,247 1310,254 1238,259 1160,265 1080,269 994,274 906,277 816,281 724,283 628,285 532,287 434,288 336,288 336,164" stroke="#000000" stroke-width="1px" fill="#008000"></polygon> </svg>
|
xequte |
Posted - Jan 12 2025 : 19:03:55 Hi
I'm not seeing any issue there. Ensure you call ImageEnView1.Update() after setting a layer property.
Nigel Xequte Software www.imageen.com
|
|
|