2006-12-10 05:33:38 +08:00
|
|
|
/* GIMP - The GNU Image Manipulation Program
|
1997-11-25 06:05:25 +08:00
|
|
|
* Copyright (C) 1995 Spencer Kimball and Peter Mattis
|
|
|
|
*
|
2009-01-18 06:28:01 +08:00
|
|
|
* This program is free software: you can redistribute it and/or modify
|
1997-11-25 06:05:25 +08:00
|
|
|
* it under the terms of the GNU General Public License as published by
|
2009-01-18 06:28:01 +08:00
|
|
|
* the Free Software Foundation; either version 3 of the License, or
|
1997-11-25 06:05:25 +08:00
|
|
|
* (at your option) any later version.
|
|
|
|
*
|
|
|
|
* This program is distributed in the hope that it will be useful,
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
*
|
|
|
|
* You should have received a copy of the GNU General Public License
|
2018-07-12 05:27:07 +08:00
|
|
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
1997-11-25 06:05:25 +08:00
|
|
|
*/
|
2000-12-29 23:22:01 +08:00
|
|
|
|
2001-11-11 07:03:22 +08:00
|
|
|
#ifndef __GIMP_DISPLAY_SHELL_SELECTION_H__
|
|
|
|
#define __GIMP_DISPLAY_SHELL_SELECTION_H__
|
1997-11-25 06:05:25 +08:00
|
|
|
|
2000-12-31 12:07:42 +08:00
|
|
|
|
2010-10-09 18:55:11 +08:00
|
|
|
void gimp_display_shell_selection_init (GimpDisplayShell *shell);
|
|
|
|
void gimp_display_shell_selection_free (GimpDisplayShell *shell);
|
2006-09-05 00:13:28 +08:00
|
|
|
|
2010-10-10 02:23:05 +08:00
|
|
|
void gimp_display_shell_selection_undraw (GimpDisplayShell *shell);
|
|
|
|
void gimp_display_shell_selection_restart (GimpDisplayShell *shell);
|
1997-11-25 06:05:25 +08:00
|
|
|
|
2010-10-09 20:26:33 +08:00
|
|
|
void gimp_display_shell_selection_pause (GimpDisplayShell *shell);
|
|
|
|
void gimp_display_shell_selection_resume (GimpDisplayShell *shell);
|
|
|
|
|
2010-10-09 18:55:11 +08:00
|
|
|
void gimp_display_shell_selection_set_show (GimpDisplayShell *shell,
|
|
|
|
gboolean show);
|
1997-11-25 06:05:25 +08:00
|
|
|
|
Issue #5640: Selection tools not showing selection on Wayland.
As suggested in a comment (itself coming from an IRC discussion), we
should not use gdk_window_(begin|end)_draw_frame() functions as this
works on X, but not on Wayland anymore. Instead draw directly during
draw() call of the shell widget, and force it to happen regularly, to
update the marching ants, via gtk_widget_queue_draw_region().
This is tested and works on Wayland. Please everyone, test thoroughly to
make sure it works well in all situations, and also that we don't get
any unexpected slowdowns.
Since the symptoms are very similar, it is highly possible that it also
fixes the issue #5952 too, for selection not showing on macOS since Big
Sur 11 (maybe they changed the same way as Wayland did). Unfortunately I
can't check this myself. Please test, whoever has access to a macOS Big
Sur and can build GIMP!
2021-05-09 08:17:23 +08:00
|
|
|
void gimp_display_shell_selection_draw (GimpDisplayShell *shell,
|
|
|
|
cairo_t *cr);
|
2000-12-29 23:22:01 +08:00
|
|
|
|
2001-11-11 07:03:22 +08:00
|
|
|
#endif /* __GIMP_DISPLAY_SHELL_SELECTION_H__ */
|