feat(extmarks): add sign name to extmark "details" array

Problem:  Unable to identify legacy signs when fetching extmarks with
          `nvim_buf_get_extmarks()`.
Solution: Add "sign_name" to the extmark detail array.

Add some misc. changes as follow-up to #25724
This commit is contained in:
Luuk van Baal
2023-11-18 23:49:11 +01:00
parent 34fa1e1ca4
commit c249058758
5 changed files with 35 additions and 17 deletions

View File

@@ -1022,6 +1022,10 @@ void decor_to_dict_legacy(Dictionary *dict, DecorInline decor, bool hl_name)
PUT(*dict, "sign_text", CSTR_TO_OBJ(sh_sign.text.ptr));
}
if (sh_sign.sign_name) {
PUT(*dict, "sign_name", CSTR_TO_OBJ(sh_sign.sign_name));
}
// uncrustify:off
struct { char *name; const int val; } hls[] = {