File tree Expand file tree Collapse file tree 7 files changed +30
-7
lines changed Expand file tree Collapse file tree 7 files changed +30
-7
lines changed Original file line number Diff line number Diff line change @@ -8,6 +8,13 @@ Bug fixes:
8
8
9
9
- Initialise %(head) from command line arguments. (#1366)
10
10
- Make `$GIT_EDITOR` value interpreted by the shell. (#1367)
11
+ - Use correct line from recursively blamed commit. (#1369, #1370)
12
+ - Use correct line when using `:parent` in blame view. (#1372)
13
+ - Fix the incorrect line shift after stage file. (#1371)
14
+
15
+ Improvements:
16
+
17
+ - Add color for cursor in backgrounded view. (#1374)
11
18
12
19
tig-2.5.12
13
20
----------
Original file line number Diff line number Diff line change @@ -1060,7 +1060,8 @@ setting the *default* color option.
1060
1060
[frame="none",grid="none",cols="25<m,75<"]
1061
1061
|=============================================================================
1062
1062
|default |Override default terminal colors (see above).
1063
- |cursor |The cursor line.
1063
+ |cursor |The cursor line for the current view.
1064
+ |cursor-blur |The cursor line of any backgrounded view.
1064
1065
|status |The status window showing info messages.
1065
1066
|title-focus |The title window for the current view.
1066
1067
|title-blur |The title window of any backgrounded view.
@@ -1097,8 +1098,12 @@ setting the *default* color option.
1097
1098
|main-tracked |Label of the remote tracked by the current branch.
1098
1099
|main-tag |Label of a signed tag.
1099
1100
|main-local-tag |Label of a local tag.
1100
- |main-ref |Label of any other reference .
1101
+ |main-ref |Label of a branch .
1101
1102
|main-replace |Label of replaced reference.
1103
+ |main-stash |Label of the stash.
1104
+ |main-note |Label of notes.
1105
+ |main-prefetch |Label of reference prefetched by `git maintenance`.
1106
+ |main-other |Label of any other reference.
1102
1107
|=============================================================================
1103
1108
1104
1109
.Status view
Original file line number Diff line number Diff line change @@ -50,6 +50,7 @@ struct ref;
50
50
_(COMMITTER, "committer "), \
51
51
_(DEFAULT, ""), \
52
52
_(CURSOR, ""), \
53
+ _(CURSOR_BLUR, ""), \
53
54
_(STATUS, ""), \
54
55
_(DELIMITER, ""), \
55
56
_(DATE, ""), \
Original file line number Diff line number Diff line change 15
15
#include "tig/graph.h"
16
16
#include "tig/draw.h"
17
17
#include "tig/options.h"
18
+ #include "tig/display.h"
18
19
#include "compat/hashtab.h"
19
20
20
21
static const enum line_type palette_colors [] = {
@@ -667,7 +668,7 @@ draw_view_line(struct view *view, unsigned int lineno)
667
668
line -> dirty = line -> cleareol = 0 ;
668
669
669
670
if (selected ) {
670
- set_view_attr (view , LINE_CURSOR );
671
+ set_view_attr (view , view == display [ current_view ] ? LINE_CURSOR : LINE_CURSOR_BLUR );
671
672
line -> selected = true;
672
673
view -> ops -> select (view , line );
673
674
}
Original file line number Diff line number Diff line change @@ -244,16 +244,22 @@ view_driver(struct view *view, enum request request)
244
244
{
245
245
int nviews = displayed_views ();
246
246
int next_view = nviews ? (current_view + 1 ) % nviews : current_view ;
247
+ struct view * next = display [next_view ];
247
248
248
249
if (next_view == current_view ) {
249
250
report ("Only one view is displayed" );
250
251
break ;
251
252
}
252
253
253
254
current_view = next_view ;
254
- /* Blur out the title of the previous view. */
255
+ /* Blur out the title and cursor of the previous view. */
255
256
update_view_title (view );
257
+ draw_view_line (view , view -> pos .lineno - view -> pos .offset );
258
+ wnoutrefresh (view -> win );
259
+ /* Brighten the title and cursor of the next view. */
256
260
report_clear ();
261
+ draw_view_line (next , next -> pos .lineno - next -> pos .offset );
262
+ wnoutrefresh (next -> win );
257
263
break ;
258
264
}
259
265
case REQ_REFRESH :
@@ -613,9 +619,6 @@ find_clicked_view(MEVENT *event)
613
619
614
620
if (beg_y <= event -> y && event -> y < beg_y + view -> height
615
621
&& beg_x <= event -> x && event -> x < beg_x + view -> width ) {
616
- if (i != current_view ) {
617
- current_view = i ;
618
- }
619
622
return view ;
620
623
}
621
624
}
@@ -636,6 +639,9 @@ handle_mouse_event(void)
636
639
if (!view )
637
640
return REQ_NONE ;
638
641
642
+ if (view != display [current_view ])
643
+ return REQ_VIEW_NEXT ;
644
+
639
645
#ifdef BUTTON5_PRESSED
640
646
if (event .bstate & (BUTTON2_PRESSED | BUTTON5_PRESSED ))
641
647
#else
Original file line number Diff line number Diff line change @@ -766,6 +766,8 @@ split_view(struct view *prev, struct view *view)
766
766
if (view != prev && view_is_displayed (prev )) {
767
767
/* "Blur" the previous view. */
768
768
update_view_title (prev );
769
+ draw_view_line (prev , prev -> pos .lineno - prev -> pos .offset );
770
+ wnoutrefresh (prev -> win );
769
771
}
770
772
771
773
if (view_has_flags (prev , VIEW_FLEX_WIDTH ) && vsplit && nviews == 1 )
Original file line number Diff line number Diff line change @@ -413,6 +413,7 @@ color " Original-patch-by:" yellow default
413
413
color " Inspired-by:" yellow default
414
414
color default default default normal
415
415
color cursor white green bold
416
+ color cursor-blur white green
416
417
color status green default
417
418
color delimiter magenta default
418
419
color date blue default
You can’t perform that action at this time.
0 commit comments