Mercurial > vim
comparison src/proto/textprop.pro @ 20583:d067be761cd7 v8.2.0845
patch 8.2.0845: text properties crossing lines not handled correctly
Commit: https://github.com/vim/vim/commit/87be9be1db6b6d8fb57ef14e05f23a84e5e8bea0
Author: Bram Moolenaar <Bram@vim.org>
Date: Sat May 30 15:32:02 2020 +0200
patch 8.2.0845: text properties crossing lines not handled correctly
Problem: Text properties crossing lines not handled correctly.
Solution: When joining lines merge text properties if possible.
(Axel Forsman, closes #5839, closes #5683)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Sat, 30 May 2020 15:45:04 +0200 |
parents | 91bb12995034 |
children | 78ef12e0ce8c |
comparison
equal
deleted
inserted
replaced
20582:49d2f01322db | 20583:d067be761cd7 |
---|---|
1 /* textprop.c */ | 1 /* textprop.c */ |
2 int find_prop_type_id(char_u *name, buf_T *buf); | 2 int find_prop_type_id(char_u *name, buf_T *buf); |
3 void f_prop_add(typval_T *argvars, typval_T *rettv); | 3 void f_prop_add(typval_T *argvars, typval_T *rettv); |
4 void prop_add_common(linenr_T start_lnum, colnr_T start_col, dict_T *dict, buf_T *default_buf, typval_T *dict_arg); | 4 void prop_add_common(linenr_T start_lnum, colnr_T start_col, dict_T *dict, buf_T *default_buf, typval_T *dict_arg); |
5 int get_text_props(buf_T *buf, linenr_T lnum, char_u **props, int will_change); | 5 int get_text_props(buf_T *buf, linenr_T lnum, char_u **props, int will_change); |
6 int count_props(linenr_T lnum, int only_starting); | |
6 int find_visible_prop(win_T *wp, int type_id, int id, textprop_T *prop, linenr_T *found_lnum); | 7 int find_visible_prop(win_T *wp, int type_id, int id, textprop_T *prop, linenr_T *found_lnum); |
7 proptype_T *text_prop_type_by_id(buf_T *buf, int id); | 8 proptype_T *text_prop_type_by_id(buf_T *buf, int id); |
8 void f_prop_clear(typval_T *argvars, typval_T *rettv); | 9 void f_prop_clear(typval_T *argvars, typval_T *rettv); |
9 void f_prop_find(typval_T *argvars, typval_T *rettv); | 10 void f_prop_find(typval_T *argvars, typval_T *rettv); |
10 void f_prop_list(typval_T *argvars, typval_T *rettv); | 11 void f_prop_list(typval_T *argvars, typval_T *rettv); |
16 void f_prop_type_list(typval_T *argvars, typval_T *rettv); | 17 void f_prop_type_list(typval_T *argvars, typval_T *rettv); |
17 void clear_global_prop_types(void); | 18 void clear_global_prop_types(void); |
18 void clear_buf_prop_types(buf_T *buf); | 19 void clear_buf_prop_types(buf_T *buf); |
19 int adjust_prop_columns(linenr_T lnum, colnr_T col, int bytes_added, int flags); | 20 int adjust_prop_columns(linenr_T lnum, colnr_T col, int bytes_added, int flags); |
20 void adjust_props_for_split(linenr_T lnum_props, linenr_T lnum_top, int kept, int deleted); | 21 void adjust_props_for_split(linenr_T lnum_props, linenr_T lnum_top, int kept, int deleted); |
21 void adjust_props_for_join(linenr_T lnum, textprop_T **prop_line, int *prop_length, long col, int removed); | 22 void prepend_joined_props(char_u *new_props, int propcount, int *props_remaining, linenr_T lnum, int add_all, long col, int removed); |
22 void join_prop_lines(linenr_T lnum, char_u *newp, textprop_T **prop_lines, int *prop_lengths, int count); | |
23 /* vim: set ft=c : */ | 23 /* vim: set ft=c : */ |