Commit Graph

287 Commits

Author SHA1 Message Date
Sven Neumann c482da6774 draw guides over the grid.
2005-09-02  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_expose): draw guides over the grid.
2005-09-02 16:26:56 +00:00
Sven Neumann 93eab43eef Use the canonical form for signal names.
2005-05-27  Sven Neumann  <sven@gimp.org>

	* (lots of files): Use the canonical form for signal names.
2005-05-27 16:51:39 +00:00
Sven Neumann c671472424 app/display/gimpdisplayshell-callbacks.c hack around with gtk+ widget
2005-05-18  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.c: hack around with gtk+ widget
	styles to get rid of the menubar padding in fullscreen mode.
2005-05-18 13:33:52 +00:00
Sven Neumann 5c4278d003 also zoom on mouse position if the event originates from the canvas (see
2005-05-11  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-scale.c (gimp_display_shell_scale):
	also zoom on mouse position if the event originates from the canvas
	(see bug #79384).

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): replaced a g_warning()
	with g_return_if_fail().
2005-05-11 15:00:49 +00:00
Sven Neumann f595dfa78e app/display/gimpdisplayshell-callbacks.c reduced code duplication.
2005-04-14  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-scale.[ch]: reduced code duplication.
2005-04-14 11:46:07 +00:00
Sven Neumann e3d08ef79b app/display/gimpdisplayshell-callbacks.c when using Ctrl-wheel to zoom
2005-04-13  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-scale.[ch]: when using Ctrl-wheel
	to zoom in/out, center on the mouse position (bug #79384).
2005-04-13 16:34:53 +00:00
Michael Natterer f41e059067 More sample point stuff. Addresses bug #137776.
2005-03-09  Michael Natterer  <mitch@gimp.org>

	More sample point stuff. Addresses bug #137776.

	* app/core/gimpimage-sample-points.c
	* app/core/gimpimage-undo-push.c: append, not prepend the sample
	paints to the image's list because their index matters. Update
	sample points when their index changes.

	* app/display/gimpcanvas.[ch]: added own sytles for the sample
	points.  Added gimp_canvas_draw_text() which uses a PangoLayout
	which is cached in the canvas.

	* app/display/gimpdisplayshell-draw.c
	(gimp_display_shell_draw_sample_point): draw the sample points
	more distinct from guides using the new canvas APIs above.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_[hv]ruler_button_press): factored out all
	code to

	(gimp_display_shell_ruler_burron_press): which takes a boolean
	"horizontal" variable and allows to add sample points with
	<control>+drag.

	* app/tools/gimpcolortool.[ch]: implement adding, moving and
	removing of sample points in the same way as the move tool moves
	guides.

	* app/tools/gimpcolorpickertool.c
	(gimp_color_picker_tool_oper_update): chain up.
2005-03-09 00:23:19 +00:00
Michael Natterer be6a9d2a8b app/actions/view-actions.c app/actions/view-commands.[ch]
2005-03-05  Michael Natterer  <mitch@gimp.org>

	* app/actions/view-actions.c
	* app/actions/view-commands.[ch]
	* app/config/gimprc-blurbs.h
	* app/core/core-enums.[ch]
	* app/core/gimp.c
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-undo-push.[ch]
	* app/core/gimpimage.c
	* app/display/gimpdisplayoptions.[ch]
	* app/display/gimpdisplayshell-appearance.[ch]
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-draw.[ch]
	* app/widgets/gimphelp-ids.h
	* menus/image-menu.xml.in: reordered stuff to be in guides, grid,
	sample points order. Some cleanup and indentation.
2005-03-05 00:10:40 +00:00
William Skaggs ea267753f6 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/core/gimpimage-sample-points.c
	* app/core/gimpimage-sample-points.h: new files

	* app/actions/view-actions.c
	* app/actions/view-commands.c
	* app/actions/view-commands.h
	* app/config/gimprc-blurbs.h
	* app/core/Makefile.am
	* app/core/core-enums.c
	* app/core/core-enums.h
	* app/core/core-types.h
	* app/core/gimp.c
	* app/core/gimp.h
	* app/core/gimpimage-crop.c
	* app/core/gimpimage-duplicate.c
	* app/core/gimpimage-flip.c
	* app/core/gimpimage-rotate.c
	* app/core/gimpimage-scale.c
	* app/core/gimpimage-undo-push.c
	* app/core/gimpimage-undo-push.h
	* app/core/gimpimage.c
	* app/core/gimpimage.h
	* app/display/gimpdisplayoptions.c
	* app/display/gimpdisplayoptions.h
	* app/display/gimpdisplayshell-appearance.c
	* app/display/gimpdisplayshell-appearance.h
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-draw.c
	* app/display/gimpdisplayshell-draw.h
	* app/display/gimpdisplayshell-handlers.c
	* app/display/gimpdisplayshell.c
	* app/display/gimpdisplayshell.h
	* app/widgets/gimphelp-ids.h
	* menus/image-menu.xml.in: add support for a list of "sample
	points" in each image, coded and handled very similarly to
	guides, for use mainly in color correction.  See bug #137776.
2005-03-04 16:34:59 +00:00
Sven Neumann b284772f77 removed redundant casts, made gimp_display_shell_compress_motion() static.
2005-02-22  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c: removed redundant casts,
	made gimp_display_shell_compress_motion() static.
2005-02-22 21:38:04 +00:00
Michael Natterer 4d03c8862d app/tools/gimpmagnifytool.c (gimp_magnify_tool_init)
2005-02-22  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpmagnifytool.c (gimp_magnify_tool_init)
	* app/tools/gimpmeasuretool.c (gimp_measure_tool_init)
	* app/tools/gimpvectortool.c (gimp_vector_tool_init): set
	handles_empty_image to TRUE because all these tools work fine
	without active drawable.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): also look at
	handles_empty_image, not only at gimp_image_is_empty() before
	setting the BAD cursor.
2005-02-22 12:16:23 +00:00
Michael Natterer 39fd4b3984 put back some important code that was accidentially removed when fixing
2005-02-21  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): put back some important
	code that was accidentially removed when fixing bug #162823. Also
	moved the calls to gtk_grab_add() and gtk_grab_remove() around a
	bit.
2005-02-21 18:41:05 +00:00
William Skaggs a666d52d84 Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events):  For testing, apply
	patch switching display-wide grab to app-wide grab while
	handling button-release event, see bug #162823.
2005-02-10 03:16:52 +00:00
Sven Neumann c3bb11def3 switched meaning of Ctrl and Shift modifiers used with the mouse scroll
2005-02-05  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): switched meaning of Ctrl
	and Shift modifiers used with the mouse scroll wheel. The HIG
	suggests to use Ctrl for zooming and it makes GIMP more consistent
	with other apps (for example Inkscape).
2005-02-05 20:49:28 +00:00
Michael Natterer aef1cf9306 app/display/Makefile.am app/display/gimpdisplayshell-autoscroll.[ch] new
2005-01-02  Michael Natterer  <mitch@gimp.org>

	* app/display/Makefile.am
	* app/display/gimpdisplayshell-autoscroll.[ch]
	* app/display/gimpdisplayshell-coords.[ch]: new files factored out
	of gimpdisplayshell-callbacks.c

	* app/display/gimpdisplayshell.h (struct GimpDisplayShell): added
	"gpointer scroll_info" needed by autoscroll.

	* app/display/gimpdisplayshell-callbacks.c: removed the stuff
	above. Also removed the static autoscroll struct because it's not
	needed any longer.
2005-01-02 20:42:31 +00:00
Sven Neumann 3be2928e31 simplified code 2005-01-02 01:33:11 +00:00
Sven Neumann 3e1be87099 fixed auto-scrolling for left and bottom display edges. Remove the timeout
2005-01-02  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c: fixed auto-scrolling
	for left and bottom display edges. Remove the timeout on
	button-release event, some minor cleanups.
2005-01-02 01:27:16 +00:00
William Skaggs 398f47529d Bill Skaggs <weskaggs@primate.ucdavis.edu>
* app/display/gimpdisplayshell-callbacks.c: use a timeout for
	autoscrolling, to fix bug #8269.  Happy new year!
2005-01-01 17:58:56 +00:00
Michael Natterer 6d9a69c0a6 pass (gint)-truncated coordinates instead of RINT()-rounded ones to
2004-11-09  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): pass (gint)-truncated
	coordinates instead of RINT()-rounded ones to
	gimp_display_shell_update_cursor(). Restores correct coordinates
	display for zoomed-in display and fixes bug #153534.

	* app/tools/gimpmovetool.c: added statusbar messages including the
	(rounded) guide coordinate. Keeps bug #141719 closed.
2004-11-09 13:03:07 +00:00
Michael Natterer 9ce333eb75 don't connect to "event" and don't connect any canvas event to
2004-11-09  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell.c (gimp_display_shell_new): don't
	connect to "event" and don't connect any canvas event to
	gimp_display_shell_events(). Connect all tool events separately
	(doesn't include "configure-event" and thus fixes bug #141543).

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): call
	gimp_display_shell_events() manually before doing tool event
	processing.

	* app/display/gimpdisplayshell.c
	* app/display/gimpdisplayshell-callbacks.[ch]: connect to
	"size_allocate" of the canvas, not to "configure_event"
	(suggested by Owen in bug #141543).

	* app/display/gimpdisplayshell-callbacks.[ch]: removed
	gimp_display_shell_popup_menu().

	(gimp_display_shell_origin_button_press): emit "popup-menu" on the
	shell manually instead of calling above function.

	* app/display/gimpdisplayshell.c: added the whole menu popup code
	here.
2004-11-09 11:38:29 +00:00
Michael Natterer ba92c24d79 app/dialogs/module-dialog.c plug-ins/dbbrowser/gimpprocbrowser.c use
2004-11-03  Michael Natterer  <mitch@gimp.org>

	* app/dialogs/module-dialog.c
	* plug-ins/dbbrowser/gimpprocbrowser.c
	* plug-ins/dbbrowser/plugin-browser.c: use
	gtk_tree_model_get_iter_first() instead of the deprecated
	_get_iter_root().

	* app/display/gimpdisplayshell-callbacks.c: don't include
	"widgets/gimpitemfactory.h".
2004-11-03 17:13:43 +00:00
Michael Natterer dbd941c9f7 dispatch GDK_Escape to GimpTool::key_press().
2004-10-01  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_tool_events): dispatch GDK_Escape to
	GimpTool::key_press().

	* app/tools/gimpcroptool.c (gimp_crop_tool_key_press)
	* app/tools/gimpimagemaptool.c (gimp_image_map_tool_key_press):
	* app/tools/gimptransformtool.c (gimp_transform_tool_key_press):
	cancel the tool on <Escape>.
2004-10-01 15:15:14 +00:00
Sven Neumann 297b53a466 no need to include gimpdisplayshell-render.h here.
2004-10-01  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c: no need to include
	gimpdisplayshell-render.h here.

	* app/display/gimpdisplayshell-draw.c
	* app/display/gimpdisplayshell-render.[ch]

	* app/display/gimpdisplayshell.[ch]: added an API to highlight a
	rectangle (specified in image coordinates). Actually it doesn't
	highlight but dims the area outside the rectangle.

	* app/tools/gimpcroptool.c: use the new functionality to show the
	area to be cropped. Fixes bug #93360.
2004-10-01 09:50:04 +00:00
Simon Budig 4a75d7271e Added boolean parameter to gimp_dialog_factories_toggle to make it
2004-09-11  Simon Budig  <simon@gimp.org>

	* app/widgets/gimpdialogfactory.[ch]: Added boolean parameter to
	gimp_dialog_factories_toggle to make it possible to ensure a visible
	toolbox.

	* app/actions/dialogs-commands.c: Use the new parameter to ensure
	toolbox visibility after the last image window closes.

	* app/display/gimpdisplayshell-callbacks.c: Changed accordingly.

	Fixes bug #137057 (the discussion is in bug #152285)
2004-09-11 19:19:26 +00:00
David Odin f168881c18 app/display/gimpnavigationview.c renamed these files to...
* app/display/gimpnavigationview.c
* app/display/gimpnavigationview.h: renamed these files to...

* app/display/gimpnavigationeditor.c
* app/display/gimpnavigationeditor.h: ... these files, and of course
  changed GimpNavigationView to GimpNavigationEditor since it is really
  inherited from GimpEditor anyway.

This will leave the gimp_navigation_view namespace for the renaming
from gimp_navigation_preview.

* app/display/Makefile.am
* app/display/display-types.h
* app/display/gimpdisplayshell-callbacks.c
* app/gui/dialogs-constructors.c: Changed accordlingly.
2004-08-25 16:02:10 +00:00
Michael Natterer 69ac9e85ff Added support for motion event history as provided by some input device
2004-07-29  Michael Natterer  <mitch@gimp.org>

	Added support for motion event history as provided by some input
	device drivers. If you have a tablet driver supporting this,
	please try and report back.

	* app/display/gimpdisplayshell.h (struct GimpDisplayShell): added
	member "guint32 last_motion_time".

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_tool_events): remember the last_motion_time on
	button_press() and after motion() and ask the current device for
	its motion history; in motion(), if the active_tool asks for exact
	motions, check if the input device recorded a motion history and
	process the history instead of the motion event.

	(gimp_display_shell_get_time_coords): new utility function which
	gets GimpCoords from a GdkTimeCoord struct as used by the motion
	history.
2004-07-29 13:21:55 +00:00
Michael Natterer 178d7d3ff1 massively changed: removed message_ids, the message mem chunk and all
2004-07-14  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpstatusbar.[ch]: massively changed: removed
	message_ids, the message mem chunk and all signals. Added new
	function gimp_statusbar_replace() which updates a message without
	moving it to the top of the stack. Fixes bug #120175.

	* app/display/gimpdisplayshell-title.[ch]: renamed
	gimp_display_shell_update_title() to
	gimp_display_shell_title_update() and switched from pop()/push()
	to replace() so the title message keeps its place in the stack.
	Added new function gimp_display_shell_title_init() which push()es
	the title message to the stack.

	* app/display/gimpdisplayshell.c (gimp_display_shell_new): call
	gimp_display_shell_title_init() so the "title" message is at the
	bottom of the stack.

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-handlers.c: changed accordingly.
2004-07-14 16:37:13 +00:00
Michael Natterer a31bbed6c7 #define MIN and MAX values for GimpCoords.pressure, .tilt and .wheel.
2004-07-05  Michael Natterer  <mitch@gimp.org>

	* app/core/core-types.h: #define MIN and MAX values for
	GimpCoords.pressure, .tilt and .wheel.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_get_event_coords)
	(gimp_display_shell_get_device_coords): use the #defines instead
	of hardcoded magic values when CLAMP()ing event or device values.
2004-07-05 18:48:43 +00:00
Michael Natterer 11dfbae2f6 renamed function gimp_controller_wheel_scrolled() to
2004-06-24  Michael Natterer  <mitch@gimp.org>

	* app/widgets/gimpcontrollerwheel.[ch]: renamed function
	gimp_controller_wheel_scrolled() to
	gimp_controller_wheel_scroll().

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): changed accordingly.
2004-06-24 15:29:19 +00:00
Michael Natterer 02b91f6628 app/tools/gimptool.[ch] added boolean return value to
2004-06-24  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimptool.[ch]
	* app/tools/tool_manager.[ch]: added boolean return value to
	GimpTool::key_press() which indicates if the event was handled.

	* app/tools/gimpcroptool.c
	* app/tools/gimpeditselectiontool.[ch]
	* app/tools/gimptransformtool.c
	* app/tools/gimpvectortool.c: return TRUE if the key event was handled.

	* app/tools/gimppainttool.c: removed key_press() implementation.

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpcontrollerkeyboard.[ch]: new controller class
	which takes GdkEventKey and emits controller events for all
	combinations of modifiers and cursor keys.

	* app/widgets/gimpcontrollers.[ch]: added new function
	gimp_controllers_get_keyboard().

	* app/display/gimpdisplayshell-callbacks.c: if a key event was not
	handled by the active tool, dispatch it to the keyboard controller.

	* etc/controllerrc: add a keyboard controller which is configured
	to do the same as the removed gimp_paint_tool_key_press().
2004-06-24 10:16:08 +00:00
Michael Natterer 9fe8e84963 app/actions/view-actions.c added actions & callbacks to configure the
2004-06-22  Michael Natterer  <mitch@gimp.org>

	* app/actions/view-actions.c
	* app/actions/view-commands.[ch]: added actions & callbacks to
	configure the canvas padding color.

	* app/widgets/gimphelp-ids.h
	* menus/image-menu.xml.in: added the actions' help IDs and menu entries.

	* app/display/display-enums.h: added /*< skip >*/'ed enum value
	GIMP_CANVAS_PADDING_MODE_RESET.

	* app/display/gimpdisplayshell-appearance.c
	* app/display/gimpdisplayshell-callbacks.[ch]
	* app/display/gimpdisplayshell-handlers.c
	* app/display/gimpdisplayshell.[ch]: removed the canvas padding
	button and its popup menu (fixes bug #142996). Instead, added a
	toggle button which allows to zoom the image when the window is
	resized (as known from sodipodi, except it doesn't work as nice
	yet :-) improvements to the algorithm are welcome).
	Cleaned up the GimpDisplayShell struct a bit and renamed some
	of its members.

	* libgimpwidgets/gimpstock.[ch]
	* themes/Default/images/Makefile.am
	* themes/Default/images/stock-zoom-follow-window-12.png: added new
	icon for the new display toggle button.
2004-06-22 16:31:27 +00:00
Michael Natterer d0117ef5b9 Started to fix bug #106920 in a more genreral way:
2004-06-16  Michael Natterer  <mitch@gimp.org>

	Started to fix bug #106920 in a more genreral way:

	* libgimpwidgets/Makefile.am
	* libgimpwidgets/gimpwidgetstypes.h
	* libgimpwidgets/gimpwidgetsmarshal.list
	* libgimpwidgets/gimpcontroller.[ch]: new abstract base class
	which provides an API for pluggable input controller modules
	(mouse wheel, usb/midi stuff etc.).

	* app/widgets/Makefile.am
	* app/widgets/widgets-types.h
	* app/widgets/gimpcontrollerwheel.[ch]: subclass of the above
	which maps wheel mouse scroll events to controller events.

	* app/widgets/gimpcontrollers.[ch]: manager for controllers.
	reads $(gimpdir)/controllerrc and keeps a mapping of controller
	events to GtkActions.

	* app/gui/gui.c: initialize and shut down the controller stuff.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): if a wheel controller
	exists, dispatch GdkEventScroll to it first and return if it was
	handled.
2004-06-15 22:59:26 +00:00
Philip Lafleur afb3f5c16c Fixed incorrect logic that caused perfect-but-slow pointer tracking to be
2004-06-12  Philip Lafleur  <plafleur@cvs.gnome.org>

	* app/display/gimpdisplayshell-callbacks.c: Fixed incorrect logic that
	caused perfect-but-slow pointer tracking to be used in tools that
	don't request exact mode.

	* app/display/Makefile.am:
	* app/display/gimpdisplayshell-appearance.[ch]:
	* app/display/gimpdisplayshell-callbacks.c:
	* app/display/gimpdisplayshell.[ch]:
	* app/display/gimpdisplayshell-preview.[ch]: added
	* app/tools/gimpperspectivetool.c:
	* app/tools/gimprotatetool.c:
	* app/tools/gimpscaletool.c:
	* app/tools/gimpsheartool.c:
	* app/tools/gimptransformoptions.[ch]:
	* app/tools/gimptransformtool.[ch]: Implemented live transformation
	previews, available through tool options. Fixes bug #108172.
2004-06-13 01:37:29 +00:00
Michael Natterer 7fd7442582 ported some forgotten #if 0'ed GtkItemFactory stuff to GtkUIManager.
2004-06-12  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_events): ported some forgotten #if 0'ed
	GtkItemFactory stuff to GtkUIManager.
2004-06-12 18:50:44 +00:00
Simon Budig 39614b34a6 renamed tool_manager_arrow_key_active to tool_manager_key_press_active.
2004-06-12  Simon Budig  <simon@gimp.org>

	* app/tools/tool_manager.[ch]: renamed
	tool_manager_arrow_key_active to tool_manager_key_press_active.

	* app/display/gimpdisplayshell-callbacks.c: Also dispatch
	GDK_Return/KP_Enter/BackSpace/Delete to the tools "arrow_key"
	member of GimpTool probably should be renamed.

	* app/tools/gimpvectortool.c: Use Enter/Return to convert the
	current path to a selection, use Backspace/Delete to delete the
	currently active anchors in a path.

	Implemented on Jimmacs request - thanks for being a great host  :)
2004-06-12 18:03:48 +00:00
Michael Natterer 714d63fcda cursors/Makefile.am cursors/cursor-none.png new empty cursor images.
2004-06-05  Michael Natterer  <mitch@gimp.org>

	* cursors/Makefile.am
	* cursors/cursor-none.png
	* cursors/xbm/cursor-none.xbm: new empty cursor images.

	* app/config/gimpdisplayconfig.[ch]
	* app/config/gimprc-blurbs.h
	* app/widgets/widgets-enums.h
	* app/widgets/gimpcursor.c
	* app/display/gimpdisplayshell-cursor.c
	* app/tools/gimppainttool.[ch]
	* app/tools/gimpinktool.c
	* app/gui/preferences-dialog.c: applied patches from Philip
	Lafleur which implement hiding the cursor completely for paint
	tools. Changed the name of the config option from
	"hide-paint-tool-cursor" to "show-paint-tool-cursor" and default
	to TRUE because this needs the brush outline being visible while
	painting to be really usable. Fixes bug #132163.

	* app/widgets/widgets-enums.h: renamed all GimpCursorType and
	GimpToolCursorType enum values to GIMP_CURSOR_* and
	GIMP_TOOL_CURSOR_*.

	* app/widgets/gimpcursor.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-cursor.c
	* app/tools/gimp*tool.c; changed accordingly.
2004-06-04 23:08:29 +00:00
Michael Natterer cf3533ba9c put the image popup menu into a dummy menubar to work around the silly
2004-05-17  Michael Natterer  <mitch@gimp.org>

	* menus/menus.xsl: put the image popup menu into a dummy menubar
	to work around the silly GtkUIManager restriction that popup menus
	can't have tearoff items.

	* app/menus/menus.c
	* app/menus/image-menu.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/gui/gui-vtable.c
	* app/menus/plug-in-menus.c: changed accordingly.

	* app/gui/gui.c (gui_restore_after_callback): connect to
	"notify::tearoff-menus" of GimpGuiConfig and reconfigure the
	global image UI manager accordingly.

	* app/config/gimpguiconfig.c: removed GIMP_PARAM_RESTART from the
	"tearoff-menus" property because GtkUIManager can change this on
	the fly.

	* app/display/gimpdisplayshell.[ch]: added the menubar to the
	GimpDisplayShell struct. Some cleanup in gimp_display_shell_new().

	* app/display/gimpdisplayshell-appearance.c
	(gimp_display_shell_set_show_menubar): use shell->menubar instead
	of asking the UI manager.

	* app/widgets/gimpuimanager.[ch]: changed gimp_ui_manager_ui_get()
	to transparently load the XML files even if a sub-widget was
	requested. Reordered parameters of gimp_ui_manager_ui_popup().
	Lots of internal cleanups.

	* app/widgets/gimpdockable.c
	* app/widgets/gimptooloptionseditor.c: simplified accordingly.

	* app/widgets/gimpeditor.[ch]: added new function
	gimp_editor_popup_menu() which takes a GimpMenuPositionFunc and
	updates/shows the editor's menu.

	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcomponenteditor.c
	* app/widgets/gimpcontainereditor.c
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimppaletteeditor.c: use gimp_editor_popup_menu().

	* app/widgets/gimptoolbox.c: moved all code from
	gimp_toolbox_new() to GObject::constructor().
2004-05-17 13:38:03 +00:00
Michael Natterer de7a940501 app/config/gimpconfig-deserialize.c app/config/gimpscanner.c
2004-05-12  Michael Natterer  <mitch@gimp.org>

	* app/config/gimpconfig-deserialize.c
	* app/config/gimpscanner.c
	* app/core/gimp-edit.c
	* app/core/gimpchannel-combine.c
	* app/core/gimpcontainer.c
	* app/core/gimpdrawable-bucket-fill.c
	* app/core/gimpdrawable-combine.c
	* app/core/gimpdrawable.c
	* app/core/gimpgradient.c
	* app/core/gimpimage-flip.c
	* app/core/gimpimage-merge.c
	* app/core/gimpimage-projection.c
	* app/core/gimpimage.c
	* app/display/gimpdisplay-handlers.c
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpprogress.c
	* app/gui/info-dialog.c
	* app/gui/module-browser.c
	* app/gui/offset-dialog.c
	* app/plug-in/plug-in.c
	* app/tools/gimpdrawtool.c
	* app/tools/tool_manager.c
	* app/widgets/gimpactiongroup.c
	* app/widgets/gimpdialogfactory.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpitemfactory.c
	* app/widgets/gimppropwidgets.c
	* app/widgets/gimpwidgets-utils.c
	* app/xcf/xcf-save.c
	* libgimp/gimpexport.c
	* libgimpwidgets/gimphelpui.c
	* libgimpwidgets/gimppixmap.c
	* libgimpwidgets/gimpunitmenu.c: replaced G_GNUC_FUNCTION,
	G_GNUC_PRETTY_FUNCTION, G_STRLOC and hardcoded function names in
	g_warning()s by G_STRFUNC.
2004-05-12 08:13:33 +00:00
Sven Neumann a08d648a47 added a stock icon for "view-zoom-1-1".
2004-05-10  Sven Neumann  <sven@gimp.org>

	* app/actions/view-actions.c: added a stock icon for "view-zoom-1-1".

	* app/widgets/gimpunitcombobox.[ch]: added functions to get and
	set the active unit.

	* app/widgets/gimpunitstore.c (gimp_unit_store_tree_model_get_value):
	need to special case GIMP_UNIT_PIXEL.

	* app/display/Makefile.am
	* app/display/display-types.h
	* app/display/gimpscalecombobox.[ch]: new widget to be used in the
	display's statusbar.

	* app/display/gimpdisplayshell-cursor.[ch]: always display the
	cursor position, not only if the cursor is inside the image. Added
	new function gimp_display_shell_clear_cursor() to clear the cursor
	label.

	* app/display/gimpdisplayshell-callbacks.c: changed accordingly.

	* app/display/gimpstatusbar.[ch]
	* app/display/gimpdisplayshell.c
	* app/display/gimpdisplayshell-handlers.c
	* app/display/gimpdisplayshell-scale.c: do not explicitely resize
	the statusbar cursor label, connect to GimpDisplayShell::scaled
	instead. Added a GimpScaleComboBox to the status bar.
2004-05-10 10:33:21 +00:00
Michael Natterer 29e4cf347b Fix bug #141719:
2004-05-04  Michael Natterer  <mitch@gimp.org>

	Fix bug #141719:

	* app/tools/gimpmovetool.c (gimp_move_tool_motion): use RINT()
	instead of ROUND() to round double coords to guide positions.

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): pass RINT()-rounded
	coords to gimp_display_shell_update_cursor() instead of implicitly
	truncating by casting to int.
2004-05-04 13:09:39 +00:00
Michael Natterer 4654280114 Switch from GtkItemFactory to GtkUIManager. The migration is almost
2004-04-29  Michael Natterer  <mitch@gimp.org>

	Switch from GtkItemFactory to GtkUIManager. The migration is
	almost complete, still stuff missing/incomplete, definitely added
	a bunch of new bugs...

	* app/actions/*-commands.[ch]: converted all callback from
	GtkItemFactory callbacks to GtkAction callbacks.

	* app/actions/debug-actions.c
	* app/actions/gradient-editor-actions.c
	* app/actions/help-actions.c
	* app/actions/plug-in-actions.c
	* app/actions/qmask-actions.c
	* app/actions/tool-options-actions.c: various fixes.

	* app/display/gimpdisplay.[ch]
	* app/display/gimpdisplayshell-appearance.[ch]
	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.[ch]: move everything from
	GtkItemFactory to GtkUIManager.

	* app/gui/dialogs.[ch]: added new function dialogs_get_toolbox().
	Needed because the action callbacks don't have a widget parameter
	and sometimes we need a parent window for showing dialogs.

	* app/gui/Makefile.am
	* app/gui/brushes-menu.[ch]
	* app/gui/buffers-menu.[ch]
	* app/gui/channels-menu.[ch]
	* app/gui/colormap-editor-menu.[ch]
	* app/gui/dialogs-menu.[ch]
	* app/gui/documents-menu.[ch]
	* app/gui/error-console-menu.[ch]
	* app/gui/fonts-menu.[ch]
	* app/gui/gradient-editor-menu.[ch]
	* app/gui/gradients-menu.[ch]
	* app/gui/images-menu.[ch]
	* app/gui/layers-menu.[ch]
	* app/gui/palette-editor-menu.[ch]
	* app/gui/palettes-menu.[ch]
	* app/gui/patterns-menu.[ch]
	* app/gui/qmask-menu.[ch]
	* app/gui/templates-menu.[ch]
	* app/gui/vectors-menu.[ch]: removed these files.

	* app/gui/gui.c: create a global UI manager for the image popup
	menu and the toolbox menubar.

	* app/gui/menus.[ch]: removed all GtkItemFactory code.

	* app/gui/image-menu.[ch]
	* app/gui/toolbox-menu.[ch]: removed everything except the trivial
	setup_funcs.

	* app/gui/file-open-menu.c
	* app/gui/file-save-menu.c
	* app/gui/tool-options-menu.c: don't use the macros from menus.h
	any more, they are gone.

	* app/gui/gui-vtable.c
	* app/gui/plug-in-menus.[ch]: create/destroy the dynamic plug-in
	menu entries.

	* app/tools/gimpimagemaptool.c: s/gimp_item_factory_update/
	gimp_ui_manager_update/g

	* app/widgets/gimpuimanager.[ch]: added API to get an action
	group by name.

	* app/widgets/gimpmenufactory.c: don't choke on the item_factory
	entries being NULL.

	* app/widgets/gimpactiongroup.c: make sure booleans set using
	g_object_set() only have TRUE or FALSE values.

	* app/widgets/gimpcolormapeditor.c
	* app/widgets/gimpcomponenteditor.c
	* app/widgets/gimpcontainereditor.[ch]
	* app/widgets/gimpcontainergridview.c
	* app/widgets/gimpcontainertreeview.c
	* app/widgets/gimpdockable.[ch]
	* app/widgets/gimpdocked.[ch]
	* app/widgets/gimpeditor.[ch]
	* app/widgets/gimperrorconsole.c
	* app/widgets/gimpgradienteditor.c
	* app/widgets/gimpitemtreeview.c
	* app/widgets/gimppaletteeditor.c
	* app/widgets/gimptoolbox.c
	* app/widgets/gimptooloptionseditor.c: removed all GtkItemFactory
	code and enable the #if 0'ed UI manager stuff.

	* menus/gradient-editor-menu.xml: fixed typos.

	* menus/image-menu.xml: duplicate everything so we have both
	an image menubar and an image popup menu. Badly cries for an
	XSL processor.

	* menus/toolbox-menu.xml: added an "Extensions" placeholder.
2004-04-29 12:52:29 +00:00
Michael Natterer 25589863a3 app/display/gimpdisplayshell-callbacks.c app/display/gimpdisplayshell.c
2004-04-15  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell.c
	* app/widgets/gimpcontainertreeview.c: removed runtime version
	checks and workarounds for bugs which are fixed in GTK+ 2.4.

	* app/widgets/gimpfiledialog.c
	(gimp_file_dialog_selection_changed): added runtime check for GTK+
	2.4.1 and work around GtkFileChooser's missing "update_preview"
	functionality for multiple selections if the dependency is not
	met.

	* app/widgets/gimpwidgets-utils.c (gimp_menu_position)
	(gimp_menu_button_position): call gtk_menu_set_monitor() until
	bug #139187 is fixed.
2004-04-15 16:54:44 +00:00
Sven Neumann f87c500007 app/display/gimpdisplayshell-callbacks.c
2004-04-04  Sven Neumann  <sven@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	* app/display/gimpdisplayshell-draw.[ch] pass the bounding box of
	the exposed area to gimp_display_shell_draw_grid() and draw only
	the relevant part of the grid. Fixes bug #138606.
2004-04-04 17:17:40 +00:00
Michael Natterer e0d1ddb070 added run-time version check and do the workaround for bug #136636 only if
2004-03-21  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_events): added run-time version
	check and do the workaround for bug #136636 only if
	the Gtk+ version is < 2.2.5.

	* m4macros/gimp-2.0.m4: require gimp >= 2.0.0
2004-03-21 15:58:48 +00:00
Michael Natterer 423837e26e redid last change so it calls tool_manager_cursor_update_active() *before*
2004-03-10  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): redid last change so it
	calls tool_manager_cursor_update_active() *before*
	tool_manager_button_press_active(). Removes the ugly
	"force_cursor_updating" boolean again and adds even more ugly code
	duplication instead.
2004-03-10 17:52:56 +00:00
Michael Natterer a15f6489e8 added new local state "gboolean force_cursor_updating" which makes the
2004-03-10  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_tool_events): added new local state
	"gboolean force_cursor_updating" which makes the function call
	tool_manger_cursor_update_active() even though a mouse button is
	pressed. Fixes tool cursors in click-to-focus mode.  Reported by
	Michael Schumacher.
2004-03-10 17:41:41 +00:00
Michael Natterer 2b7101979a work around bug #136636 (Win32 only) and ask the current device for its
2004-03-10  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_events): work around bug #136636 (Win32 only)
	and ask the current device for its modifier state in order to fill
	in the missing GDK_BUTTON*_MASK bits in GdkEventKey::state.
2004-03-10 17:17:15 +00:00
Michael Natterer 4f59b04454 disabled debugging output when pushing/popping the move too using <space>.
2004-03-10  Michael Natterer  <mitch@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c: disabled debugging
	output when pushing/popping the move too using <space>.
2004-03-10 15:32:27 +00:00
Michael Natterer eb7f99bb8f added #defines for GimpCoords' default pressure, tilt and wheel values.
2004-02-23  Michael Natterer  <mitch@gimp.org>

	* app/core/core-types.h: added #defines for GimpCoords' default
	pressure, tilt and wheel values.

	* app/display/gimpdisplayshell-callbacks.c
	* app/paint/gimppaintcore-stroke.c
	* app/text/gimptext-vectors.c
	* tools/pdbgen/pdb/paint_tools.pdb: use them. Fixes lots more
	buggy default values for tilt (in fact all of them were wrong).

	* app/pdb/paint_tools_cmds.c: regenerated.
2004-02-23 22:36:50 +00:00
Simon Budig 8b18fc8547 corrected the value ranges and default values for GDK_AXIS_XTILT and
2004-02-23  Simon Budig  <simon@gimp.org>

	* app/display/gimpdisplayshell-callbacks.c: corrected the
	value ranges and default values for GDK_AXIS_XTILT and
	GDK_AXIS_YTILT. Now the ink-tool behaves sane with a mouse
	again  :)
2004-02-23 20:30:44 +00:00