Commit Graph

2967 Commits

Author SHA1 Message Date
Jehan e5c08832cb Issue #1509 - GIMP master Git zoom in/out scrolling is reversed. 2018-05-26 22:41:54 +02:00
Michael Natterer d9e016bd37 app: undeprecate gimpdisplayshell-scale.c and fix "unused variable" warning 2018-05-23 23:44:19 +02:00
Michael Natterer b33c6bc072 app: fix drawing of the canvas padding color
Remove all clipping hacks for drawing the canvas background, turns out
they never worked and we were relying on the pattern set on the
window, gah!

Also remove deprecated attempts to get a backgroud color and simply
don't show a color box in the menus for "from theme" cases.
2018-05-23 22:46:54 +02:00
Michael Natterer a628511a4e app: don't use gtk_window_parse_geometry() in GimpImageWindow 2018-05-22 12:33:58 +02:00
Timm Bäder f677a5abe8 app: remove RC style from GimpImageWindow
without replacement, we can always add CSS later if we don't like it
with whatever theme.
2018-05-22 11:14:50 +02:00
Michael Natterer 3c9272ef96 app: fix positioning of the text tool's style overlay 2018-05-22 01:59:26 +02:00
Michael Natterer 602dfb9a38 app: the last s/GdkDeviceManager/GdkSeat/ 2018-05-20 21:06:35 +02:00
Michael Natterer f3f61379f7 app: remove the option to enable tearoff menus 2018-05-20 21:06:35 +02:00
Michael Natterer e76c1305a5 app: derive GimpStatusbar from GtkFrame not GtkStatusbar
we were not using a single GtkStatusBar features, it was only in the
way. Remove broken size allocation logic and simply set a minimum
height of 3em in CSS. Also ellipsize the label, long labels had funny
effects since changing the overall GimpDisplayShell packing to pure
GtkGrid.
2018-05-20 21:06:35 +02:00
Michael Natterer 7f6b58d6ce app: kill the mess of boxes in GimpDisplayShell, use a grid for everything 2018-05-20 21:06:35 +02:00
Michael Natterer 0c9ac3bca9 app: use a cairo recording surface to measure GimpCanvasPath's extents
This gets rid of using the deprecated gdk_cairo_create().
2018-05-20 21:06:35 +02:00
Michael Natterer 4133a032de Undeprecate/improve GimpScaleComboBox and GimpUnitComboBox
Remove label-scale style properties and gtk_widget_modify_font()
hacks and theme them using CSS.
2018-05-20 21:06:35 +02:00
Michael Natterer 2dd2f1509b Enable and fix smooth scrolling and zooming
- Fix gimp_scroll_adjustment_values() for smooth scroll events
- Set GDK_SMOOTH_SCROLL_MASK on all widgets where we set GDK_SCROLL_MASK
- Add GIMP_ZOOM_SMOOTH to enum GimpZoomType
- Add "gdouble delta" to gimp_zoom_model_step()
- Change the meaning of the "scale" parameter to "scale or delta" in
  all functions that take GimpZoomType and a scale factor.
2018-05-20 21:06:34 +02:00
Michael Natterer e4d05a4758 app: use gimp_scroll_adjustment_values() in GimpNavigationEditor
and change signature of GimpNavigationView::scroll() to have
a GdkEventScroll instead of a GdkScrollDirection.
2018-05-20 21:06:34 +02:00
Michael Natterer fa3abc957b app: set GDK_SCROLL_MASK on widgets that need scroll events 2018-05-20 21:06:34 +02:00
Michael Natterer 613d02ca3a app: use gimp_scroll_adjustment_values() for scrolling the canvas 2018-05-20 21:06:34 +02:00
Michael Natterer bdbec7941c Use the new macros from the last commit in all files
...and gone are the annoying warnings.
2018-05-20 21:06:34 +02:00
Michael Natterer 4e7eead7e3 app: set all GtkPaned widgets to have wide handles
the narrow handles' event areas did overlap with our own widgets close
to the handle.
2018-05-20 21:06:34 +02:00
Michael Natterer 1d8696cd80 Get rid of gdk_flush() globally, use gdk_display_flush() 2018-05-20 21:06:34 +02:00
Ell 6e76cdf4d3 app: fix empty display unstable-version message 2018-05-20 21:06:33 +02:00
Ell ed46a405ae app: fix canvas motion compression
In gimp_display_shell_canvas_tool_events(), use
gdk_window_set_event_compression(), instead of implementing our own
motion compression, which used to introduce all sorts of weird
effects when combined with extended input devices, that we had to
hackishly work around.

For tools that use GIMP_MOTION_MODE_EXACT, we call
gdk_window_set_event_compression() to disable motion compression
for the canvas window upon initializing the tool in response to a
GDK_BUTTON_PRESS event, and again to re-eanble compression upon the
corresponding GDK_BUTTON_RELEASE event.

This commit also merges
gimp_display_shell_canvas_tool_events_internal() back into
gimp_display_shell_canvas_tool_events().  The split was a detail
of our custom motion compression implementation.
2018-05-20 21:06:33 +02:00
Michael Natterer 885f66158a app: kill all except one GtkAlignment, the tag popup one is a bit tricky 2018-05-20 21:06:33 +02:00
Michael Natterer c2763afd30 app: port gimp_display_shell_set_initial_scale() to the monitor's workarea 2018-05-20 21:06:33 +02:00
Michael Natterer 4a39edf241 app: disable motion compression, have to figure how to control GTK+'s 2018-05-20 21:06:33 +02:00
Michael Natterer 7f3f1afa28 app: port gimp_navigation_editor_popup() to GdkMonitor's workarea 2018-05-20 21:06:33 +02:00
Ell 75b9fa0aea app: take window scale-factor into account when rendering image
In gimp_display_shell_draw_image(), enable the code that adjusts
the scale-factor used for rendering the image by the window scale
factor, so that we make full use of the screen resolution even on
HiDPI displays.  This also fixes artifacts along render-chunk
borders.
2018-05-20 21:06:33 +02:00
Jehan 7642715c17 app: allow setting parent for dialogs created by GimpDialogFactory.
Fixes a bunch of:
> Gtk-Message: GtkDialog mapped without a transient parent. This is discouraged.
2018-05-20 21:06:33 +02:00
Simon Budig 9d000f749f app/display: get rid of GtkTable 2018-05-20 21:06:33 +02:00
Michael Natterer d5c75afe2f app: honor the use-header-bar setting in GimpToolDialog 2018-05-20 21:06:32 +02:00
Michael Natterer 3571fc3ae2 app: port GimpCursorView to GtkGrid 2018-05-20 21:06:30 +02:00
Michael Natterer 65d4450b3e app, themes: move GimpDisplayShell styling to CSS
Looks half-decent again now.
2018-05-20 21:06:30 +02:00
Michael Natterer 03feaf39c3 app: port GimpDisplayShell to use GtkGrid 2018-05-20 21:06:30 +02:00
Michael Natterer 2f1a4fdc67 app: gimp_ui_manager_ui_popup_at_pointer() and use it where appropriate
Only one call to gimp_ui_manager_ui_popup() left...
2018-05-20 21:06:30 +02:00
Michael Natterer ab1edce8af app: use gimp_ui_menager_up_popup_at_widget() for the quick mask menu 2018-05-20 21:06:30 +02:00
Jehan 26710104ba Revert "Bug 794356 - Rulers always shown for subsequent image views"
This reverts commit ea48b9f31c.
Final revert of GTK+2 hack.
2018-05-20 21:06:30 +02:00
Jehan e7e7f00528 Revert "Bug 784480 - Clicking on-canvas GUI with a tablet stylus crashes..."
This reverts commit a8bc8d202c.
Continue removing the same GTK+2 hack.
2018-05-20 21:06:30 +02:00
Jehan 654ef12d58 Revert "Bug 794356 - Rulers always shown for subsequent image views"
This reverts commit 7230d5d777.
Remove GTK+2 only hack.
2018-05-20 21:06:30 +02:00
Michael Natterer b28228d911 app: add gimp_ui_manager_ui_popup_at_widget()
and use it where we used to pass gimp_button_menu_position() to
gimp_ui_manager_up_popup(), remove gimp_button_menu_position() because
it's now unused.
2018-05-20 21:06:30 +02:00
Michael Natterer 4c68fb70d4 app: use gtk_widget_get_preferred_size() in gimp_tool_gui_canvas_resized() 2018-05-20 21:06:30 +02:00
Michael Natterer 251d2f494e app: port some stuff to gdk_seat_grab/ungrab 2018-05-20 21:06:30 +02:00
Michael Natterer 5ece7a8d1f Port a lot of stuff from GdkScreen/monitor_number to GdkMonitor
including some fixes for getting pointer coords, and needed
API changes in libgimpwidgets.
2018-05-20 21:06:30 +02:00
Michael Natterer 09e6313c14 app: use gimp_color_display_stack_get_filters() instead of stack->filters 2018-05-20 21:06:29 +02:00
Michael Natterer 922f55ab85 app: s/GtkObject/GtkAdjustment/ in gimpdisplayhsell-rotate-dialog.c 2018-05-20 21:06:29 +02:00
Michael Natterer 1fdc472c68 app: make the statusbar's progress label visible again
and remove setting of removed align properties. The label alignment is
broken now until that feature comes back to gtk+.
2018-05-20 21:06:29 +02:00
Michael Natterer 8bb1637013 app: port GimpNavigationEditor to GtkStyleContext 2018-05-20 21:06:29 +02:00
Michael Natterer 76859c3c32 app: make input devices, grabs and therefore generally tools work again
- add new "device from event" apparatus that works on GTK+ 3.x
- fix the active device selection mechanism
- use the new device grabbing functions
- make sure we don't process events while we have a grab on
  another device
- compensate for some really obscure (and likely broken) behavior
  of XI2, it feels like we are the first real users...
2018-05-20 21:06:29 +02:00
Michael Natterer 4b322b8326 app: use GdkRGBA instead of GdkColor in some places 2018-05-20 21:06:29 +02:00
Michael Natterer 8c975484ab app: check whether child widgets exist in GtkWidget::style_updated()
because it is emitted repeatedly during widget construction, when not
everything is in place yet.
2018-05-20 21:06:28 +02:00
Michael Natterer e713ad4a43 app: implement GtkWidget::style_updated() instead of style_set() 2018-05-20 21:06:28 +02:00
Michael Natterer eb312ed55a app: remove calls to gtk_widget_get,set_extension_events() 2018-05-20 21:06:27 +02:00