@RequiresEdt
  public void onEncodingChanged() {
    isLocalScrollBarStabilized = false;
    pagesCache.clear();
    runCaretAndSelectionListeningTransparentCommand(() -> {
      documentOfPagesModel.removeAllPages(dataProvider.getProject());
    });
    requestUpdate();
  }
@RequiresEdt
  public void onEncodingChanged()