public static int toOffset(@NotNull Document document, int line, int col) {
    return new LineCol(line, col).toOffset(document);
  }
public static int toOffset(@NotNull Document document, int line, int col)