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

Put 'roundToTwoDecimalPlaces' back in at higher levels. #95

Closed
luciansmith opened this issue Sep 18, 2024 · 1 comment
Closed

Put 'roundToTwoDecimalPlaces' back in at higher levels. #95

luciansmith opened this issue Sep 18, 2024 · 1 comment

Comments

@luciansmith
Copy link
Collaborator

The functions:

AutoLayoutNode::getX
AutoLayoutNode::getY
AutoLayoutNode::getWidth
AutoLayoutNode::getHeight

and

AutoLayoutCentroidNode::getX
AutoLayoutCentroidNode::getY
AutoLayoutCentroidNode::getWidth
AutoLayoutCentroidNode::getHeight

and

AutoLayoutPoint::getX
AutoLayoutPoint::getY

are all called extensively by the autolayout algorithm, and need to not waste time rounding values, as they're all called potentially thousands of times or more. But we do still need to round off values when requesting them, so the 'round' function needs to be added back in at a higher level that autolayout doesn't call.

@adelhpour
Copy link
Owner

RoundToTwoDecimalNumber is moved to the libsbmlnetwork_layout layer with PR #97.

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

2 participants