annotorious-openseadragon icon indicating copy to clipboard operation
annotorious-openseadragon copied to clipboard

Annotations can be moved

Open RahelaPogacean opened this issue 2 years ago • 6 comments

Hello! I am developing an application using Annotorious with OSD and I can move the annotations with drag & drop. Is there any possibility to disable this option?

RahelaPogacean avatar Sep 15 '23 07:09 RahelaPogacean

The readOnly option is probably what you're looking for: https://annotorious.github.io/api-docs/osd-plugin/#readonly

rsimon avatar Sep 15 '23 07:09 rsimon

If you want to make the shape locked, but keep the comments editable, I think you can do something like this:

var anno = Annotorious.init({
  image: 'hallstatt',
  readOnly: true,
  widgets: [
    { widget: 'COMMENT', editable: true }
  ]
});

But actually not quite sure anymore... Annotorious v3 is already on the horizon and will allow for more flexibility concerning permissions and editing rules.

rsimon avatar Sep 15 '23 09:09 rsimon

@rsimon I want to not be able to move the annotation, but still be able to edit the points

RahelaPogacean avatar Sep 15 '23 12:09 RahelaPogacean

Only change the shape but not move it? Sorry that's not possible. You might be able to work around by making the shape transparent to pointer events using CSS perhaps.

rsimon avatar Sep 15 '23 12:09 rsimon

Is the reverse possible? That is for a user to be able to move selection frame around, but not to change it's shape?

ferropasha avatar Oct 05 '23 19:10 ferropasha

No sorry. Not possible either. But likewise, you could try removing the handles via CSS.

rsimon avatar Oct 05 '23 19:10 rsimon