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

Provide convenience instances of Margins where all sides are the same #1726

Open
JohnMcGuinness opened this issue May 4, 2020 · 0 comments

Comments

@JohnMcGuinness
Copy link
Contributor

JohnMcGuinness commented May 4, 2020

Currently in order to create a margin where all sides are equal we use new Margin(Size.SMALL) if there is more than one place in an application where a small margin is required we create a new instance of a Margin with small size.

I propose that we create constants for these types of margins such as Margin.ZERO, Margin.SMALL and Margin.MEDIUM, etc and deprecate, the new Margin(Size) constructor. This constructor should be made private. It makes no sense recreating identical instances of these Margins all over the place.

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

No branches or pull requests

1 participant