Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Horizontal and vertical are not able to parse correctly #605

Open
Gautam2010 opened this issue Aug 23, 2024 · 0 comments
Open

Horizontal and vertical are not able to parse correctly #605

Gautam2010 opened this issue Aug 23, 2024 · 0 comments

Comments

@Gautam2010
Copy link
Contributor

Req svg path

image

const x="M302.574 300.259H343.717C354.115 300.259 362.12 298.538 367.656 295.059 373.228 291.619 375.996 285.372 375.996 276.283 375.996 269.027 373.715 263.305 369.114 259.115 367.02 257.245 364.626 255.861 361.9697 254.925 359.837 254.178 357.481 253.617 354.8259 253.243 352.506 252.943 350.1509 252.832 347.794 252.832H347.794 302.574 302.574V300.259Z"
let baseModel: IModel = {};
baseModel.models = {}
baseModel.models[`x`]=importer.fromSVGPathData(path);
const chains = model.findChains() as IChain[];
const response = chainToSVGPathData(chains[0], [0, 0]);

response is as below
image

M302.574 300.259 L 343.717 300.259 A 75.5473785 75.5473785 0 0 0 352.6573831 299.7662396 A 47.2568676 47.2568676 0 0 0 360.5601638 298.182895 A 28.7335701 28.7335701 0 0 0 367.656 295.0590001 A 16.317001 16.317001 0 0 0 374.623102 285.9554424 A 27.6662737 27.6662737 0 0 0 375.8845043 279.3273737 A 40.1308876 40.1308876 0 0 0 375.9960002 276.2829999 A 27.8225639 27.8225639 0 0 0 375.0714504 268.9104358 A 20.1783028 20.1783028 0 0 0 369.114 259.115 A 21.1811901 21.1811901 0 0 0 361.97 254.925 A 33.8195518 33.8195518 0 0 0 358.1460987 253.84117 A 42.3360022 42.3360022 0 0 0 354.826 253.243 A 54.88622 54.88622 0 0 0 347.794 252.832 L 347.794 300.259 L 302.574 300.259 Z

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant