private static void addFragments(EditorView view, BidiRun run, Chunk chunk, char[] text, int start, int end,
                                   @Nullable TabFragment tabFragment, boolean showSpecialChars, FontFallbackIterator it) {
    assert start < end;
    int last = start;
    for (int i = start; i < end; i++) {
      char c = text[i];
      LineFragment specialFragment = null;
      if (c == '\t') {
        assert run.level == 0;
        specialFragment = tabFragment;
      }
      else if (showSpecialChars) {
        // only BMP special chars are supported currently, so there's no need to check for surrogate pairs
        specialFragment = SpecialCharacterFragment.create(view, c, text, i);
      }
      if (specialFragment != null) {
        addFragmentsNoTabs(run, chunk, text, last, i, it);
        chunk.fragments.add(specialFragment);
        last = i + 1;
      }
    }
    addFragmentsNoTabs(run, chunk, text, last, end, it);
    assert !chunk.fragments.isEmpty();
  }
private static void addFragments(EditorView view, BidiRun run, Chunk chunk, char[] text, int start, int end,
                                   @Nullable TabFragment tabFragment, boolean showSpecialChars, FontFallbackIterator it)