feat(api): expose extmark right_gravity and end_right_gravity

This commit is contained in:
notomo
2022-01-24 09:52:13 +09:00
parent 7e2ce35e3b
commit 3d9ae9d2da
6 changed files with 35 additions and 9 deletions

View File

@@ -106,9 +106,12 @@ static Array extmark_to_array(ExtmarkInfo extmark, bool id, bool add_dict)
if (add_dict) {
Dictionary dict = ARRAY_DICT_INIT;
PUT(dict, "right_gravity", BOOLEAN_OBJ(extmark.right_gravity));
if (extmark.end_row >= 0) {
PUT(dict, "end_row", INTEGER_OBJ(extmark.end_row));
PUT(dict, "end_col", INTEGER_OBJ(extmark.end_col));
PUT(dict, "end_right_gravity", BOOLEAN_OBJ(extmark.end_right_gravity));
}
Decoration *decor = &extmark.decor;