Adds non-UI option to disable the use of often buggy history buffer.
This option defaults to false, since a lot of device/X/GDK combos are broken
and the resulting stroke often actually looks better without history events.
Put (use-event-history yes) in gimprc if you want more events and possibly bugs.
X event history buffer is major source of problems. Almost all reports
about painting at an offset from the cursor in GIMP seem to originate
from history buffer bugs either at X or GTK level. There are device&X
combinations that work fine and there are others that are broken.
With current smothing the benefits of using the buffer are almost gone
and more exact does not always mean better to look at.
With the introduction of a single-window mode, not only dock windows
needs to be able to create docks, the image window also needs to. So
give it a "dock-factory" property.
Use more proper API in gimp_statusbar_init() when we rearrange widgets
to get rid of warnings. Requires an up to date GTK+, max 2 weeks old
or so, for gtk_statusbar_get_message_area().
This makes app/tests run again since there are no warnings about wrong
widget parent.
Implement GtkWidget::focus_in_event() and ::focus_out_event() in
GimpCanvas and don't chanin up so the default handler never runs.
Remove code that tries to do the same in the canvas' tool events
callback.
The default impl invalidates the entire widget for no reason (the
canvas doesn't draw a focus indicator anyway), and the old solution
failed for empty displays and was constantly invalidating the entire
drop zone when the toplevel window gained or lost focus.
We must disconnect from the last display shell when it is removed
when rearranging the UI, so connect to GtkNotebook::page-removed
in GimpImageWindow and do that.
Get rid of const qualifier for a bunch of GimpDisplayShell getters to
get rid of a disqualifier warning. The problem is that we call into
GTK+ which sometime misses const which breaks the chain. As a general
guideline we should avoid const for widgets.
(gimp_display_shell_canvas_tool_events): when ignoring events on
overlays, special case key events because they always originate from
the topelvel and never from the canvas' window itself.
- adapt callbacks to ignore / not block events on offscreen children
- use GimpOverlayBox' scroll API which makes sure overlay children
don't scroll along
In places where the pattern
if (show)
gtk_widget_show (widget);
else
gtk_widget_hide (widget);
is used, change to
gtk_widget_set_visible (widget, show);
Also do some other minor cleanups.
but also don't use its accessors because doing that would emit
"changed" multiple times when setting up an adjustment with multiple
utility functions. Instead, use g_object_set() and freeze/thaw
notification around all calls. g_object_thaw_notify() will make sure
"changed" is emitted if anything has changed since freezing.
It makes no sense to distinguish between idle and immediate update in
the public API, the code can simply decide by itself to immediately
update a NULL image's icon.
from gimp_display_shell_reconnect() to gimp_display_set_image()
because it makes unsetting and setting an image in
gimp_display_set_image() more symmetric.
Make the ID a read-only property and set it when the "gimp"
construct-only property gets set. Removes code from gimp_display_new()
where it doesn't belong.