File tree Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Expand file tree Collapse file tree 1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -370,10 +370,11 @@ void redraw_canvas_win() {
370
370
*/
371
371
void draw_collab_cursors (collab_list_t * collab_list ) {
372
372
collab_t * c = NULL ;
373
+ // calculate visible bounds (in canvas coordinates)
373
374
const int min_x = view -> x ;
374
375
const int min_y = view -> y ;
375
- const int max_x = min (view_max_x , view -> canvas -> num_cols - view -> x ) ;
376
- const int max_y = min (view_max_y , view -> canvas -> num_rows - view -> y ) ;
376
+ const int max_x = min (view -> canvas -> num_cols , view -> x + view_max_x ) - 1 ;
377
+ const int max_y = min (view -> canvas -> num_rows , view -> y + view_max_y ) - 1 ;
377
378
for (int i = 0 ; i < collab_list -> len ; i ++ ) {
378
379
c = collab_list -> list [i ];
379
380
// only draw cursors that exist and are visible on the screen
You can’t perform that action at this time.
0 commit comments