SVG generating unexpected values for top
- Dominant language
- ActionScript
- Stars
- 380
- Forks
- 120
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
while doing the new blog example BE0014 [1] about SVG and graphic API, I found some strange issues with SVG generating top with unexpected values.
If you see the actual examples there's a svg:Rect that shows the problem:
```as3
```
generates this (notice **top: 175px;**):
```
```
Adding a j:Group:
```as3
```
generates this (notice **top: 150px;**), that's the right value:
```
```
So Royale is adding to top 25px for some reason, If we add the Rect alone. But I think I'd not need to add any extra Group to layout right .
Why could this be happening?
Thanks
[1] https://github.com/apache/royale-asjs/blob/develop/examples/blog/BE0014_Working_with_Graphics/src/main/royale/BE0014_Working_with_Graphics.mxml
Contributor guide
No contributing guide indexed for this repository
Research direction
Start with examples/blog/BE0014_Working_with_Graphics/src/main/royale/BE0014_Working_with_Graphics.mxml and compare the generated SVG for the standalone svg:Rect with the version inside j:Group. Reproduce the differing top values, then trace the layout handling for SVG Rect and Group. Done means the Rect receives the expected top value without requiring an extra Group.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- xml
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100