Replies: 1 comment 1 reply
-
|
ActiveSelection is a subclass of Group and so it takes an array of objects in the constructor, not a single one. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi everyone,
I'm use fabric.js 6.7.1 and I'm having trouble with programmatically selecting a group of objects from a given list.
When I try the following:
const newSel = new fabric.ActiveSelection(activeObject, { canvas: canvasInstance });
canvasInstance.setActiveObject(newSel);
the selected objects get shifted away from their original coordinates.
What is the correct way to programmatically create an active selection from a list of objects, while keeping them in place, and still being able to transform (scale, rotate, move) them as a group?
Thanks in advance!


Beta Was this translation helpful? Give feedback.
All reactions