Compare commits

...

3 Commits

Author SHA1 Message Date
Paul Davis dde59c8e4c temporary fix for X Window and Windows bad canvas drawing with no single expose 2024-04-12 18:55:27 -06:00
Paul Davis 1eb2a345df prevent flickering of snapped cursor during drags when it should be invisible 2024-04-12 18:54:52 -06:00
Paul Davis e7b3b61dbc fix bad redraws caused by TrackingText on canvas
Probably Item::set_position() should call Item::set_bbox_dirty() but
this will do as a first pass at that
2024-04-12 18:50:03 -06:00
3 changed files with 15 additions and 4 deletions

View File

@ -2821,7 +2821,9 @@ Editor::set_snapped_cursor_position (timepos_t const & pos)
{
if (_edit_point == EditAtMouse) {
_snapped_cursor->set_position (pos.samples());
_snapped_cursor->show ();
if (UIConfiguration::instance().get_show_snapped_cursor()) {
_snapped_cursor->show ();
}
}
}
@ -6514,12 +6516,16 @@ Editor::super_rapid_screen_update ()
timepos_t ms (selection->markers.front()->position());
snap_to (ms); // should use snap_to_with_modifier?
_snapped_cursor->set_position (ms.samples());
_snapped_cursor->show ();
if (UIConfiguration::instance().get_show_snapped_cursor()) {
_snapped_cursor->show ();
}
}
} else if (_edit_point == EditAtMouse && mouse_sample (where.sample, ignored)) {
/* cursor is in the editing canvas. show it. */
if (!_drags->active()) {
_snapped_cursor->show ();
if (UIConfiguration::instance().get_show_snapped_cursor()) {
_snapped_cursor->show ();
}
}
} else {
/* mouse is out of the editing canvas, or edit-point isn't mouse. Hide the snapped_cursor */

View File

@ -83,8 +83,12 @@ Editor::initialize_canvas ()
_track_canvas->set_background_color (UIConfiguration::instance().color ("arrange base"));
_track_canvas->use_nsglview (UIConfiguration::instance().get_nsgl_view_mode () == NSGLHiRes);
#ifdef __APPLE__
// as of april 12 2024 on X Window and Windows, setting this to false
// causes redraw errors, but not on macOS as far as we can tell
_track_canvas->set_single_exposure (false);
#endif
/* scroll group for items that should not automatically scroll
* (e.g verbose cursor). It shares the canvas coordinate space.
*/

View File

@ -101,6 +101,7 @@ TrackingText::pointer_motion (Duple const& winpos)
/* move */
set_position (pos);
set_bbox_dirty ();
}
void