Commit Graph

23794 Commits

Author SHA1 Message Date
Martin Nordholts f45897f6c7 Support axis independence.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scroll.[ch]
	(gimp_display_shell_scroll_center_image_on_next_size_allocate):
	Support axis independence.

	* app/display/gimpdisplayshell.c: Adapt.

svn path=/trunk/; revision=26608
2008-08-16 18:50:38 +00:00
Martin Nordholts 80ff2e82c3 Explain that this function needs to be used with care since it is risky.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scroll.c
	(gimp_display_shell_scroll_center_image_on_next_size_allocate):
	Explain that this function needs to be used with care since it is
	risky.

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_new)
	(gimp_display_shell_fill): Clarify that it is safe to use the
	risky function.

	(gimp_display_shell_configure_event): Make proper comparisions (<=
	not =) and explain that usage of the risky function is safe.

	(gimp_display_shell_shrink_wrap): Always call
	gimp_display_shell_scroll_center_image() and let size-requests be
	handled by GimpDisplayShell::configure_event().

	* app/actions/view-commands.c (view_shrink_wrap_cmd_callback): No
	need to center anything explicitly any longer.

svn path=/trunk/; revision=26607
2008-08-16 18:25:32 +00:00
Sven Neumann 9d56dec5d4 translator comments must not have a line between the comment and the
string

svn path=/trunk/; revision=26606
2008-08-16 18:20:06 +00:00
Sven Neumann d0b0cca94d added translator comments.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* libgimp/gimp.c (gimp_get_pdb_error): added translator 
comments.


svn path=/trunk/; revision=26605
2008-08-16 17:37:26 +00:00
Sven Neumann 52522c3f4e also use gimp_get_pdb_error() here. Easier and safer than looking at the
2008-08-16  Sven Neumann  <sven@gimp.org>

	* plug-ins/pygimp/pygimp-pdb.c (pf_call): also use
	gimp_get_pdb_error() here. Easier and safer than looking at the
	return values to get the error message.


svn path=/trunk/; revision=26604
2008-08-16 17:29:31 +00:00
Sven Neumann 64f070eb12 fixed function name in ChangeLog entry
svn path=/trunk/; revision=26603
2008-08-16 17:20:07 +00:00
Sven Neumann 2fcef8b03e Next step towards fixing bug #344818:
2008-08-16  Sven Neumann  <sven@gimp.org>

	Next step towards fixing bug #344818:

	* libgimp/gimp.[ch]: keep the last error status and error 
message
	in libgimp. Added new functon gimp_pdb_get_error() that allows 
to
	retrieve it.

	* libgimp/gimp.def: updated.

	* plug-ins/pygimp/gimpmodule.c (pygimp_vectors_import_from_file)
	(pygimp_vectors_import_from_string): use the new function to get
	a more useful error message.


svn path=/trunk/; revision=26602
2008-08-16 17:18:13 +00:00
Sven Neumann c4f3f05df4 removed the term 'PDB' from the user-visible error messages.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	removed the term 'PDB' from the user-visible error messages.


svn path=/trunk/; revision=26601
2008-08-16 17:11:22 +00:00
Sven Neumann b025652601 pass error parameter to gimp_vectors_import functions.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* tools/pdbgen/pdb/vectors.pdb: pass error parameter to
	gimp_vectors_import functions.

	* app/pdb/vectors-cmds.c: regenerated.


svn path=/trunk/; revision=26600
2008-08-16 17:07:30 +00:00
Martin Nordholts ec15a39b14 Remove the centering logic because we do not always want to run it when
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-callbacks.c
	(gimp_display_shell_canvas_size_allocate): Remove the centering
	logic because we do not always want to run it when the canvas size
	changes. For example, the canvas size changes if rulers are
	toggled on/off.

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_configure_event): Implement
	GtkWidget::configure_event() for the display shell and put the
	image centering logic here instead, since this class function is
	run when the top level window size changes. Run it only if the
	size (not position) of the window changes.

svn path=/trunk/; revision=26599
2008-08-16 16:52:05 +00:00
Sven Neumann 3c8b0ef24f added missing file
svn path=/trunk/; revision=26598
2008-08-16 16:32:50 +00:00
Michael Natterer 46c7d2518a remove #include "core/gimpguide.h"
2008-08-16  Michael Natterer  <mitch@gimp.org>

	* app/tools/gimpdrawtool.c: remove #include "core/gimpguide.h"


svn path=/trunk/; revision=26597
2008-08-16 15:36:17 +00:00
Sven Neumann 94fafe03ef updated German translation.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* de.po: updated German translation.


svn path=/trunk/; revision=26596
2008-08-16 14:18:45 +00:00
Sven Neumann f0c60f8779 added missing space
svn path=/trunk/; revision=26595
2008-08-16 14:13:44 +00:00
Sven Neumann c2f12f7e64 changed error message to be similar to the message thrown from
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/pdb/gimppdb.c (gimp_pdb_execute_procedure_by_name): 
changed
	error message to be similar to the message thrown from
	gimp_procedure_validate_args().


svn path=/trunk/; revision=26594
2008-08-16 14:12:38 +00:00
Sven Neumann f84608d539 If a procedure call fails, pass a string describing the error as the
2008-08-16  Sven Neumann  <sven@gimp.org>

	If a procedure call fails, pass a string describing the error as
	the second return value. First step towars fixing bug #344818.

	* app/pdb/gimpprocedure.[ch] (gimp_procedure_get_return_values):
	added a GError parameter. If it is set, pass the error message 
to
	the return values.

	* app/pdb/gimppdberror.h: added some more error codes.

	* app/pdb/gimppdb.c
	* app/xcf/xcf.c: pass errors to 
gimp_procedure_get_return_values().

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	show a different error message for execution vs. calling errors.

	* app/plug-in/gimpplugin-progress.c
	(gimp_plug_in_progress_cancel_callback): pass the error
	GIMP_PDB_CANCELLED to gimp_procedure_get_return_values().

	* app/plug-in/gimppluginmanager-call.[ch]
	(gimp_plug_in_manager_call_run): removed the 
'destroy_return_vals'
	parameter.

	* app/plug-in/gimppluginprocedure.c: destroy the return values 
here.

	* app/plug-in/gimppluginprocframe.c: pass an error to
	gimp_procedure_get_return_values().

	* tools/pdbgen/app.pl
	* tools/pdbgen/pdb/fileops.pdb: generate code that passes the
	error to gimp_procedure_get_return_values().

	* app/pdb/*-cmds.c: regenerated.
	
	* plug-ins/pygimp/pygimp-pdb.c: extract the error message from 
the
	return values and pass it to the exception that is thrown.


svn path=/trunk/; revision=26593
2008-08-16 13:57:57 +00:00
Martin Nordholts b9acd50751 Also handle the case when only the offset is wrong. Not pretty but simple.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/actions/view-commands.c (view_shrink_wrap_cmd_callback):
	Also handle the case when only the offset is wrong. Not pretty but
	simple.

svn path=/trunk/; revision=26592
2008-08-16 13:53:18 +00:00
Sven Neumann 750a56ef74 removed unused includes
svn path=/trunk/; revision=26591
2008-08-16 11:54:25 +00:00
Sven Neumann f9ebb8c9fd app/display/Makefile.am app/display/gimpdisplayshell-scale.[ch] split
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/display/Makefile.am
	* app/display/gimpdisplayshell-scale.[ch]
	* app/display/gimpdisplayshell-scale-dialog.[ch]: split scale
	dialog into a new file.

	* app/actions/view-commands.c: changed accordingly.

svn path=/trunk/; revision=26590
2008-08-16 11:51:10 +00:00
Martin Nordholts 1250993fe1 New function.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_viewport_coord_almost_centered): New
	function.

	(gimp_display_shell_scale): Center the image on zoom also if it is
	almost centered. This makes the image centered all the way when
	zooming out far away.

svn path=/trunk/; revision=26589
2008-08-16 10:25:50 +00:00
Sven Neumann 659b1f727f app/tools/gimpfreeselecttool.c formatting.
2008-08-16  Sven Neumann  <sven@gimp.org>

	* app/tools/gimpfreeselecttool.c
	* app/tools/gimprectangletool.c: formatting.


svn path=/trunk/; revision=26588
2008-08-16 10:07:43 +00:00
Martin Nordholts 8d7b13ae01 Reimplement to increase readability.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_to): Reimplement to increase
	readability.

svn path=/trunk/; revision=26587
2008-08-16 08:59:58 +00:00
Martin Nordholts 46f7ce1a01 Nice-ify.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_to): Nice-ify.

svn path=/trunk/; revision=26586
2008-08-16 07:15:33 +00:00
Martin Nordholts ab419f2e70 Support axis independence.
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.[ch]
	(gimp_display_shell_scale_get_zoom_focus)
	(gimp_display_shell_scale_image_is_within_viewport): Support axis
	independence.

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_zoom_button_callback): Adapt to new
	gimp_display_shell_scale_image_is_within_viewport().

svn path=/trunk/; revision=26585
2008-08-16 07:06:26 +00:00
Martin Nordholts aaa6336664 Make proper tests (>= not >)...
2008-08-16  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_image_is_within_viewport): Make proper
	tests (>= not >)...

svn path=/trunk/; revision=26584
2008-08-16 05:45:41 +00:00
Daniel Eddeland dbd8d44c7c corrected gimp_text_set_property for "box-unit" , fixing bug #547126
2008-08-16  Daniel Eddeland  <danedde@svn.gnome.org>

	* app/text/gimptext.c: corrected gimp_text_set_property for
	"box-unit" , fixing bug #547126


svn path=/trunk/; revision=26583
2008-08-16 00:27:32 +00:00
Sven Neumann d225115ea8 formatting.
2008-08-15  Sven Neumann  <sven@gimp.org>

	* plug-ins/common/pixelize.c: formatting.


svn path=/trunk/; revision=26582
2008-08-15 21:46:09 +00:00
Martin Nordholts d9454d7045 More elegantly deal with the 'Resize window on zoom'-case.
2008-08-15  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c (gimp_display_shell_scale):
	More elegantly deal with the 'Resize window on zoom'-case.

svn path=/trunk/; revision=26581
2008-08-15 19:46:39 +00:00
Daniel Eddeland 55a9b2beb1 make text align correctly if text-box is FIXED.
2008-08-15  Daniel Eddeland  <danedde@svn.gnome.org>

	* app/text/gimptextlayout-render.c: make text align correctly if
	text-box is FIXED.


svn path=/trunk/; revision=26580
2008-08-15 19:31:09 +00:00
Michael Natterer d32b325567 when stroking multiple segments, set paint_core->cur_coords to the start
2008-08-15  Michael Natterer  <mitch@gimp.org>

	* app/paint/gimppaintcore-stroke.c
	(gimp_paint_core_stroke_boundary)
	(gimp_paint_core_stroke_vectors): when stroking multiple segments,
	set paint_core->cur_coords to the start of each segment. It
	normally gets assigned by gimp_paint_core_start(), but that's not
	called for subsequent segments. Fixes stroking multiple segments
	with the ink tool. The other tools were not affected since they
	plot individual brushes rather than a shape from the last to the
	current coordinates. Spotted by Alexia.


svn path=/trunk/; revision=26578
2008-08-15 19:10:25 +00:00
Sven Neumann 5e304419f1 formatting.
2008-08-15  Sven Neumann  <sven@gimp.org>

	* plug-ins/common/mosaic.c: formatting.	


svn path=/trunk/; revision=26577
2008-08-15 18:40:20 +00:00
Sven Neumann a9e30dad1b converted a g_print() call to g_warning() and unmarked the string for
2008-08-15  Sven Neumann  <sven@gimp.org>

	* plug-ins/common/mosaic.c (polygon_add_point): converted a
	g_print() call to g_warning() and unmarked the string for
	translation.


svn path=/trunk/; revision=26576
2008-08-15 18:00:24 +00:00
Sven Neumann 98d7a372f0 applied patch from Aurimas Juška that fixes an endianness issue (bug
2008-08-15  Sven Neumann  <sven@gimp.org>

	* plug-ins/file-ico/ico-save.c: applied patch from Aurimas Juška
	that fixes an endianness issue (bug #529629).


svn path=/trunk/; revision=26574
2008-08-15 17:50:15 +00:00
Sven Neumann ccadb5fc03 fixed last entry
svn path=/trunk/; revision=26573
2008-08-15 16:37:10 +00:00
Sven Neumann 644ad1ef2c added some logic to avoid that an info message replaces a warning. Allow
2008-08-15  Sven Neumann  <sven@gimp.org>

	* app/display/gimpstatusbar.[ch]: added some logic to avoid that
	an info message replaces a warning. Allow info messages to
	replaced other info messages.

	* app/display/gimpdisplay-handlers.c: changed accordingly.


svn path=/trunk/; revision=26572
2008-08-15 16:32:09 +00:00
Sven Neumann 8977c477ad save new images, even if they are not marked dirty.
2008-08-15  Sven Neumann  <sven@gimp.org>

	* app/actions/file-commands.c (file_save_cmd_callback): save new
	images, even if they are not marked dirty.


svn path=/trunk/; revision=26571
2008-08-15 07:38:32 +00:00
Sven Neumann ada401fe48 use G_STRFUNC in another error message that I missed earlier.
2008-08-14  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_proc_run):
	use G_STRFUNC in another error message that I missed earlier.


svn path=/trunk/; revision=26570
2008-08-14 21:57:39 +00:00
Martin Nordholts 2a3f768c79 Fix ChangeLog entry typo
svn path=/trunk/; revision=26569
2008-08-14 20:47:15 +00:00
Michael Natterer 6d1711e964 search the next match when return or enter is pressed in the search entry.
2008-08-14  Michael Natterer  <mitch@gimp.org>

	* plug-ins/help-browser/dialog.c (search_entry_key_press): search
	the next match when return or enter is pressed in the search
	entry.


svn path=/trunk/; revision=26568
2008-08-14 20:38:07 +00:00
Martin Nordholts a100804747 Make proper tests (<= not <).
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_image_starts_to_fit)
	(gimp_display_shell_scale_image_is_within_viewport): Make
	proper tests (<= not <).

svn path=/trunk/; revision=26567
2008-08-14 20:31:44 +00:00
Sven Neumann f1772dc023 fixed ChangeLog entry
svn path=/trunk/; revision=26566
2008-08-14 20:13:27 +00:00
Sven Neumann 47509e33a1 when we trust the dirty flag and don't save because there are no changes,
2008-08-14  Sven Neumann  <sven@gimp.org>

	* app/actions/file-commands.c (file_save_cmd_callback): when we
	trust the dirty flag and don't save because there are no 
changes,
	display a message in the status-bar telling the user so.

	* app/config/gimpguiconfig.c: changed the default value for 
	"trust-dirty-flag" to TRUE.


svn path=/trunk/; revision=26565
2008-08-14 20:12:54 +00:00
Sven Neumann 9884974e53 use G_STRFUNC to get the proper function name in the error message.
2008-08-14  Sven Neumann  <sven@gimp.org>

	* app/plug-in/gimpplugin-message.c 
(gimp_plug_in_handle_tile_get):
	use G_STRFUNC to get the proper function name in the error 
message.


svn path=/trunk/; revision=26564
2008-08-14 19:59:47 +00:00
Martin Nordholts a56fd032f6 New function. (gimp_display_shell_scale_get_zoom_focus): If the image
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_image_stops_to_fit): New function.
	(gimp_display_shell_scale_get_zoom_focus): If the image stops
	to fit the viewport, we can already now use the mouse cursor
	as the zoom focus point.

svn path=/trunk/; revision=26563
2008-08-14 19:45:35 +00:00
Martin Nordholts c8ae8f67b4 New function.
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-draw.[ch]
	(gimp_display_shell_draw_get_scaled_image_size_for_scale): New
	function.

	* app/display/gimpdisplayshell-scale.[ch]
	(gimp_display_shell_scale): When zooming out and the image
	starts to fit the viewport on a given axis, center on that
	axis.

	(gimp_display_shell_scale_image_starts_to_fit): New function.

	(gimp_display_shell_calculate_scale_x_and_y): New function.

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_scale_changed): Use
	gimp_display_shell_calculate_scale_x_and_y().

	* app/display/gimpdisplayshell-scroll.c
	(gimp_display_shell_scroll_center_image): Bail out if neither
	vertical nor horizontal centering is requested.

svn path=/trunk/; revision=26562
2008-08-14 19:23:28 +00:00
Martin Nordholts 0fe3208158 When the image is within the viewport, also use the center of the image as
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_get_zoom_focus): When the image is
	within the viewport, also use the center of the image as the zoom
	focus point when zooming it. It feels way too weird not to do it
	this way.

svn path=/trunk/; revision=26561
2008-08-14 17:49:36 +00:00
Martin Nordholts de82d2f7ec If the image is within the viewport and we are zooming out, make the focus
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_get_zoom_focus): If the image is within
	the viewport and we are zooming out, make the focus point be the
	center of the image.

svn path=/trunk/; revision=26560
2008-08-14 17:41:38 +00:00
Martin Nordholts 57ec836f3e Move calculation of the actual new scale to use from here
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-scale.c
	(gimp_display_shell_scale_to): Move calculation of the actual new
	scale to use from here
	(gimp_display_shell_scale): to here, because we need this
	information in order to determine what point to focus on while
	zooming.

svn path=/trunk/; revision=26559
2008-08-14 16:41:31 +00:00
Martin Nordholts c9dc5bf940 No need to update scrollbars, only rulers. (gimp_display_shell_reconnect):
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell.c
	(gimp_display_shell_set_unit): No need to update scrollbars, only
	rulers.
	(gimp_display_shell_reconnect): A
	gimp_display_shell_scroll_clamp_and_update() makes more sense
	here.

svn path=/trunk/; revision=26558
2008-08-14 15:55:56 +00:00
Martin Nordholts 052d859c6a When the screen resolution changes and we are not in Dot by dot, we also
2008-08-14  Martin Nordholts  <martinn@svn.gnome.org>

	* app/display/gimpdisplayshell-handlers.c
	(gimp_display_shell_monitor_res_notify_handler): When the screen
	resolution changes and we are not in Dot by dot, we also need to
	clamp the display shell offsets.

svn path=/trunk/; revision=26557
2008-08-14 15:44:25 +00:00