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

Implement Margin and fix Padding on Spices #4

Open
leostera opened this issue Dec 14, 2023 · 0 comments
Open

Implement Margin and fix Padding on Spices #4

leostera opened this issue Dec 14, 2023 · 0 comments
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed

Comments

@leostera
Copy link
Owner

At the moment the padding_* properties are happening after the styles are applied to the text, which means padding doesn't behave like you'd expect it to. If you add padding to something with background, the padded space doesn't have the background.

In the Spices.do_render private function there's a section where we're handling the padding, that would become about margin_* instead:

https://github.com/leostera/minttea/blob/main/spices/spices.ml#L120-L124

And then similar code for padding would be added earlier on that function, where we do the core rendering of the string.

@leostera leostera added enhancement New feature or request help wanted Extra attention is needed good first issue Good for newcomers labels Dec 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

1 participant