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

Number box with a zero won't update when given a zero of opposite sign. #790

Open
danfuzz opened this issue Nov 14, 2019 · 5 comments
Open

Number box with a zero won't update when given a zero of opposite sign. #790

danfuzz opened this issue Nov 14, 2019 · 5 comments
Labels

Comments

@danfuzz
Copy link

@danfuzz danfuzz commented Nov 14, 2019

If you have a number box which shows a positive or negative zero, and you then send a zero of the opposite sign to it, the value stored by and transmitted through the box is properly updated, but the display is not. Here's a quick demo:

number-box-zero-display

Note that when you hit the bang for the positive and negative zeros, the value gets propagated correctly, but neither of the intermediate number boxes ever changes its display. And when you hit the bang to resend the value of the top number box, the correct stored value is sent.

This was observed on Pd 0.50.0.

@Spacechild1

This comment has been minimized.

Copy link
Contributor

@Spacechild1 Spacechild1 commented Nov 14, 2019

as an optimization, graphics are only updated if the new value is different from the old one, and as you've mentioned in another issue, positive and negative zero compare equal. we could add additional logic, but I'm not sure it's worth it...

BTW, since you're an experienced software engineer, many of your feature requests could be pull requests ;-)

@danfuzz

This comment has been minimized.

Copy link
Author

@danfuzz danfuzz commented Nov 14, 2019

many of your feature requests could be pull requests ;-)

I'm certainly up for submitting PRs, but it hasn't been clear to me whether the project would actually be receptive. (Same goes with the other issue you commented on similarly, though I think that one was perhaps using "PRs gladly accepted" more in the euphemistic sense :-p .)

@Spacechild1

This comment has been minimized.

Copy link
Contributor

@Spacechild1 Spacechild1 commented Nov 14, 2019

whether the project would actually be receptive.

it certainly is! if you make a good PR, the chances for the feature to get included is much higher than just making a feature request and waiting for someone to implement it ;-) I'm only telling you this because I know you're an experienced software developer

@Spacechild1

This comment has been minimized.

Copy link
Contributor

@Spacechild1 Spacechild1 commented Nov 14, 2019

Pd needs more developers, so you're highly welcome to dive into the source code! if you have any questions, you can always ask me.

@danfuzz

This comment has been minimized.

Copy link
Author

@danfuzz danfuzz commented Nov 15, 2019

BTW I just tested the new-style number box, and in addition to not changing its display when presented with a zero of opposite sign, it also fails to store or propagate the new value (that is, not just a display bug). E.g., if it stores a positive zero and you send a negative zero to it, it will re-output a positive zero.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.