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

Pigments don't update their geometry when font-related attributes change #51

Closed
AlexTuduran opened this issue Jul 10, 2015 · 6 comments
Closed
Labels

Comments

@AlexTuduran
Copy link

When changing the font family, font size, font height or any other attribute that causes the characters to shift, the pigments overlay do not update their position and size.

@abe33
Copy link
Owner

abe33 commented Jul 10, 2015

Hmm, that's actually not true for font size and line height when modified from the settings, but it's true I don't listen to stylesheets changes. It shouldn't be too hard to fix.

@AlexTuduran
Copy link
Author

Actually I remember I've tested changing font attributes from settings as well just to check if there's a different behavior, but it seems I get the same results. The only way to heal it is to edit the line containing the color declaration, only then the pigments relocate.

@abe33 abe33 added the bug label Jul 14, 2015
@abe33
Copy link
Owner

abe33 commented Jul 14, 2015

Are you sure about changing the settings not affecting the markers?

Because as far as I can tell it works, and there's even tests for that:

pigments-resize

The tests:
https://github.com/abe33/atom-pigments/blob/master/spec/color-buffer-element-spec.coffee#L254-L270

@AlexTuduran
Copy link
Author

I've checked this usecase specifically then and the problem existed, but now it seems the pigments update when changing font attributes from settings, so it seems you're right on this one, my apologies.

@abe33
Copy link
Owner

abe33 commented Jul 15, 2015

No pb, there's always some cases I didn't foresee that may not work, but if I've written tests for a given use case I'm generally pretty confident about them working properly. To being cautious I'll also add a listener to the stylesheets changes events in the next release.

@AlexTuduran
Copy link
Author

Sounds great! Really useful package btw!

@abe33 abe33 closed this as completed in 61f0089 Jul 17, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants