Issue #2906Opened July 21, 2020by neon123450 reactions

BUG: editor.refresh() not working in custom setup

Question

I have a problem with a custom setup where the canvas iframe is moved around with js. The "editor.refresh()" call does not fix the positioning of the tools after the move.

I think the problem is due to the offset cache not cleared on refresh.

If I call this before refresh, the tools are positioned as expected:

                editor.trigger('test:canvasOffset');
                editor.trigger('frame:updated');

Version: 0.16.18

Answers (3)

artfAugust 3, 20200 reactions

@nedim1511 can you please provide a reproducible demo, please?

neon12345August 3, 20200 reactions

https://jsfiddle.net/3gqh6p5a/

Click select the "Hello World" and drag the vertical splitter to the left to resize the split window. The "editor.refresh()" called on dragEnd should align the tools but it does not seem to work.

It is more obvious on horizontal drag resize.

artfAugust 26, 20200 reactions

On my local copy, your example works correctly so probably in the next release it will be fixed

Related Questions and Answers

Continue research with similar issue discussions.

Paid Plugins That Match This Issue

Curated by issue keywords and label relevance to help you ship faster.

View all plugins

Loading paid plugin recommendations...

Browse Plugin Categories

Jump directly to plugin category pages on the marketplace.