diff options
| author | Quentin Carbonneaux | 2014-07-22 16:43:23 -0400 |
|---|---|---|
| committer | Quentin Carbonneaux | 2014-07-22 16:43:23 -0400 |
| commit | fe7c7145f0e8653f8e8e7e454b47b2e47aba9515 (patch) | |
| tree | ece9ee0acebad30d7c68332505d73a8b27957930 | |
| parent | fdf85ec4ac7881daca1b4072431204a93c38eb1d (diff) | |
fix tag display bug related to w->rev
The revision of the tag needs to be updated
when drawn. I moved the revision bumping code
in draw() to handle both the tag and regular
windows uniformly.
It is unclear if this use of rev == 0 is sane
or not. Indeed, the dirty(W *) code will update
the window only if rev != 0, this implies that
the following invariant holds:
! Whenever rev == 0, the l[] array is !
! up-to-date with the buffer. !
I do not know if this is true now.
| -rw-r--r-- | win.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -132,7 +132,6 @@ win_redraw_frame() for (w=wins; w-wins<MaxWins; w++) if (w->eb && dirty(w)) { draw(w, GPaleYellow); - w->rev = eb_revision(w->eb); if (tag.owner == w) tag.win.rev = 0; } @@ -399,6 +398,7 @@ draw(W *w, GColor bg) flushfrag(&f, w, 0, 0, sel); if (cw != 0) g->drawrect(&w->gr, cx, cy, cw, font.height, GXBlack); + w->rev = eb_revision(w->eb); } /* move - Resize and recompute appearance |
