private static @NotNull StringBuilder appendStyledSpan(
    boolean doHighlighting,
    @NotNull StringBuilder buffer,
    @NotNull TextAttributesKey attributesKey,
    @Nullable String value
  ) {
    if (doHighlighting) {
      QuickDocHighlightingHelper.appendStyledFragment(buffer, value, attributesKey);
    }
    else {
      buffer.append(value);
    }
    return buffer;
  }
private static @NotNull StringBuilder appendStyledSpan(
    boolean doHighlighting,
    @NotNull StringBuilder buffer,
    @NotNull TextAttributesKey attributesKey,
    @Nullable String value
  )