mirror of
https://github.com/tstack/lnav.git
synced 2024-08-16 16:30:25 +03:00
[view_curses] fix for attr ranges that cover tabs
This commit is contained in:
parent
affff589a4
commit
112986da79
@ -150,13 +150,18 @@ void view_curses::mvwattrline(WINDOW *window,
|
||||
|
||||
tab_iter = tab_list.lower_bound(attr_range.lr_start);
|
||||
if (tab_iter != tab_list.end()) {
|
||||
attr_range.lr_start += (tab_iter->second - tab_iter->first) - 1;
|
||||
if (attr_range.lr_start > tab_iter->first) {
|
||||
attr_range.lr_start += (tab_iter->second - tab_iter->first) - 1;
|
||||
}
|
||||
}
|
||||
|
||||
if (attr_range.lr_end != -1) {
|
||||
tab_iter = tab_list.lower_bound(attr_range.lr_end);
|
||||
if (tab_iter != tab_list.end()) {
|
||||
attr_range.lr_end += (tab_iter->second - tab_iter->first) - 1;
|
||||
if (attr_range.lr_end > tab_iter->first) {
|
||||
attr_range.lr_end += (
|
||||
tab_iter->second - tab_iter->first) - 1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user