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

center/centerH/centerV causes objects non-selectable #642

Closed
nn1900 opened this issue May 21, 2013 · 1 comment
Closed

center/centerH/centerV causes objects non-selectable #642

nn1900 opened this issue May 21, 2013 · 1 comment

Comments

@nn1900
Copy link

nn1900 commented May 21, 2013

After using center/centerH/centerV to center objects on the canvas, the 'centered' object cannot be selected again.

Repro steps:

  1. Create an object (e.g., a rect) in the canvas
  2. call object.center (or centerH, centerV) to center the object
  3. Click the object to select it

Expected:

  1. Object is centered as instructed
  2. When clicking the object again, it will be selected

Actual:

  1. Object centered as expected.
  2. Object cannot be selected again

Found fix:
After call object's center method, call obejct.setCoords() to update is coordinations, so that selection works again. Is this probably a bug or a missing use of the fabric API?

@kangax
Copy link
Member

kangax commented May 22, 2013

This is expected behavior. We do not update object's coords for performance reasons.

@kangax kangax closed this as completed May 22, 2013
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