Commit Graph

15070 Commits

Author SHA1 Message Date
Mikael Magnusson 18692f318f app: fix header in gimpoperationbrightnesscontrast.[ch] 2012-03-13 21:50:04 +01:00
Massimo Valentini a29c096614 app: initialize also GimpRGB's alpha component
Conditional jump or move depends on uninitialised value(s)
==29000==    at 0x4C33CBC: gimp_color_area_set_color (gimp/libgimpwidgets/gimpcolorarea.c:425)
==29000==    by 0x4C3505B: gimp_color_button_set_color (gimp/libgimpwidgets/gimpcolorbutton.c:642)
==29000==    by 0x5DA5BE: gimp_text_style_editor_set_color (gimp/app/widgets/gimptextstyleeditor.c:700)
==29000==    by 0x5DB0D4: gimp_text_style_editor_update_idle (gimp/app/widgets/gimptextstyleeditor.c:1090)
==29000==    by 0x57E9E95: gdk_threads_dispatch (gtk-2-24/gdk/gdk.c:512)

Steps to reproduce:

<Ctrl>N <Enter> T
click on canvas
type something

select the text entered and change its color using
the color button from the text style editor
2012-03-13 20:44:47 +01:00
Massimo Valentini 62ebb4a1e5 app: initialize all members of a GimpAnchor
Conditional jump or move depends on uninitialised value(s)
==28817==    at 0x6AA386: gimp_coords_manhattan_dist (gimp/app/core/gimpcoords.c:175)
==28817==    by 0x6AB428: gimp_coords_bezier_is_straight (gimp/app/core/gimpcoords-interpolate.c:213)
==28817==    by 0x67663B: gimp_bezier_stroke_segment_nearest_point_get (gimp/app/vectors/gimpbezierstroke.c:676)
==28817==    by 0x676C86: gimp_bezier_stroke_nearest_point_get (gimp/app/vectors/gimpbezierstroke.c:631)
==28817==    by 0x4D79E3: gimp_draw_tool_on_vectors_curve (gimp/app/tools/gimpdrawtool.c:1175)
==28817==    by 0x4D7CD5: gimp_draw_tool_on_vectors (gimp/app/tools/gimpdrawtool.c:1242)
==28817==    by 0x511CE7: gimp_vector_tool_oper_update (gimp/app/tools/gimpvectortool.c:989)
==28817==    by 0x50B059: gimp_tool_oper_update (gimp/app/tools/gimptool.c:970)
==28817==    by 0x546F3C: gimp_display_shell_canvas_tool_events (gimp/app/display/gimpdisplayshell-tool-events.c:401)
==28817==    by 0x52A42E2: _gtk_marshal_BOOLEAN__BOXED (gtk-2-24/gtk/gtkmarshalers.c:86)

Steps to reproduce:

G_SLICE=always-malloc valgrind gimp-2.7 app/tests/*/*.xcf

B (Activate Path tool)
2012-03-13 20:44:47 +01:00
Massimo Valentini a80a63443d app: initialize a GtkTreeIter
Conditional jump or move depends on uninitialised value(s)
==28871==    at 0x4A09863: bcmp (/builddir/build/BUILD/valgrind-3.6.1/memcheck/mc_replace_strmem.c:692)
==28871==    by 0x4C487C7: gimp_int_store_row_inserted (gimp/libgimpwidgets/gimpintstore.c:220)
==28871==    by 0x8342B03: g_closure_invoke (glib/gobject/gclosure.c:774)
==28871==    by 0x8353129: signal_emit_unlocked_R (glib/gobject/gsignal.c:3232)
==28871==    by 0x835A72A: g_signal_emit_valist (glib/gobject/gsignal.c:3033)
==28871==    by 0x835A8F1: g_signal_emit (glib/gobject/gsignal.c:3090)
==28871==    by 0x529EF63: gtk_list_store_insert (gtk-2-24/gtk/gtkliststore.c:1039)
==28871==    by 0x5CEB6B: gimp_stroke_editor_constructed (gimp/app/widgets/gimpstrokeeditor.c:229)
==28871==    by 0x8348222: g_object_newv (glib/gobject/gobject.c:1731)
==28871==    by 0x8348565: g_object_new_valist (glib/gobject/gobject.c:1820)
==28871==    by 0x8348873: g_object_new (glib/gobject/gobject.c:1535)
==28871==    by 0x5CEE74: gimp_stroke_editor_new (gimp/app/widgets/gimpstrokeeditor.c:320)
==28871==    by 0x4C3842: stroke_dialog_new (gimp/app/dialogs/stroke-dialog.c:176)
==28871==    by 0x4A3B5C: select_stroke_cmd_callback (gimp/app/actions/select-commands.c:349)

Steps to reproduce:

On a 64 bits machine run gimp-2.7

<Ctrl>N <Enter> <Ctrl>A
and activate <Edit>/Stroke Selection... (<Alt>E S)
2012-03-13 20:44:47 +01:00
Michael Natterer b262c93048 app: create an own GimpOperationBrightnessContrast
and use it instead of gegl:brightness-contrast because the GEGL op is
giving different reaults.
2012-03-13 15:02:17 +01:00
Michael Natterer 216133b2d0 app: the usual formatting cleanup in GimpTileBackendTileManager 2012-03-13 14:53:09 +01:00
Øyvind Kolås 2ea41ea3f6 tests: update API usage of gimptilebackendtilemanager test 2012-03-13 13:09:59 +00:00
Øyvind Kolås 5d6662ad00 gimptilebackendtilemanager: add utility call to construct buffer
For this utility call as well as the backend constructor itself pass a boolean
to indicate if write access to the buffer is desired.
2012-03-13 12:49:35 +00:00
Øyvind Kolås 5362448044 GimpTileBackendTileManager: make it work
remove dead code, simplify existing code and make full width tiles be 0-copy.
2012-03-13 10:32:48 +00:00
Michael Natterer ddf0d9e6b7 app: use G_GUINT64_FORMAT to print guint64 2012-03-12 20:26:51 +01:00
Michael Natterer aa7e7c153c app: remove another bunch of one-line GtkTables 2012-03-12 20:12:11 +01:00
Michael Natterer 5e94863c8e app: get rid of a GtkTable in gimp_paint_options_gui(), and some cleanup 2012-03-09 20:30:05 +01:00
Massimo Valentini 7fed1b6e93 Bug 651956: Text tool misremembers point size upon reloading file
When setting the unit of a property shared with a gimp_prop_size_entry,
a conversion is applied to the corresponding size property (to preserve
size_entry's ref-value), but the conversion risks to change the size
property already updated.

To update, at the same time, size and unit, it is better to start updating
size_entry's unit in order to trigger the useless conversion on the stale
size.
2012-03-09 19:21:44 +01:00
Massimo Valentini 71cb4fbd71 Bug 667368: Bug in Histogram egalization 2012-03-08 18:20:45 +01:00
Alexis Wilhelm c7c752f5df Bug 541859 - Colour Balance Range to Adjust has no Effect
This makes the different ranges have a clearly different effect,
plus speeds up the gegl op quite a lot.

NOTE: this might affect the result of scripts using color-balance
2012-03-07 21:45:59 +01:00
Michael Natterer f2f1eab753 app: add "ERROR" to the values of enum GimpPdbErrorCode
so they are now GIMP_PDB_ERROR_FOO instead of just GIMP_PDB_FOO,
because it was just too confusing wrt enum GimpPdbStatusType.
2012-03-05 19:36:59 +01:00
Michael Natterer 435feea20a app: use gimp_cairo_set_source_rgb() wheh setting a GimpRGB 2012-03-05 19:19:47 +01:00
Massimo Valentini 1658460523 app: don't g_assert_not_reached on GIMP_PDB_FAILED errors
calling in a script (gimp-file-load-layer 1 image "notexists.bmp")
used to crash GIMP with the following message:

**
Gimp-PDB:ERROR:gimpprocedure.c:491:gimp_procedure_get_return_values:
code should not be reached
gimp-2.7: terminated: Aborted
2012-03-05 18:36:03 +01:00
Michael Natterer 0c236cbc48 app: don't draw the grid if it covers the image entirely
Regardless of the elaborate discussion in bug #599267, as soon as the
grid starts covering the image completely (when the is no more spacing
between grid lines), it is entirely useless, so skip drawing it.
2012-03-04 20:19:57 +01:00
Ville Sokk 082d758a34 Bug 558795 - Using same quick mask color across sessions
Add configuration option for quick mask color.
2012-03-03 02:45:10 +01:00
Michael Natterer b952f80be0 Bug 658477 - add PDB support for more paint and ink options
Apply heavily modified patch from Es Swartz which adds PDB API for
brush size, angle and aspect ratio, as well as a full interface for
ink. Changed to patch to add all procedures to the "context" group
instead of creating new PDB groups, properly use the new
GimpPDBContext APIs for paint options, and did some general cleanup.
(Warning, completely untested).
2012-03-01 12:58:26 +01:00
Michael Natterer 8ea6d3a94f app: when scaling, use the proper image api to move guides and sample points
so the image's "foo-moved" signals are emitted and the display can
follow. Moving them around manually was needed before the displayed
guides and sample points were proper views of the resp. core objects.
2012-02-24 00:31:27 +01:00
Richard Bowers e507f406d7 Bug 589229 - Keyboard shortcuts for zoom do not work as expected
Add extra actions for KP_1 ... KP_5 because they are separate keys.
2012-02-23 20:17:35 +01:00
Martin Nordholts f7aa27a7e8 app: Remove "Far from completely implemented!" in SWM action
Unfortunately this is a string change, but we simply can't not let it
say "Far from completely implemented!". Single-window mode works fine
now.
2012-02-23 19:29:56 +01:00
Michael Natterer b1483144cf app: remove unused variable in GimpSpinScale 2012-02-22 23:38:35 +01:00
Michael Natterer aadfc82f11 app: various GimpSpinScale fixes
- make it respect RTL mode better, something is still weird though
- don't fiddle with the entry's inner_border
- place label and number on the same line
- adjust size_request to respect the label's requisition
- set the label to ellipsize
2012-02-22 22:48:42 +01:00
Michael Natterer 71e8fc8c3a app: make sure undrawing the selection doesn't leave right/bottom pixel garbage
gimp_display_shell_mask_bounds(): transform the selection bounds with
sub-pixel precision and then apply floor()/ceil() accordingly.
2012-02-21 16:01:53 +01:00
Michael Natterer fbd746f95a app: don't rely on gtk_container_remove() to always destroy the child
Instead, either destroy the child instead of removing it, or remove
*and* destroy it in cases where the remove() api on the "parent"
doesn't match GTK+'s parent/child relation (like with all our dock
widgets). We can't rely on remove() to implicitly detstroy, because
there might be arbitrary other code holding references, such as
accessibility modules and whatnot. Most likely fixes unclear crashes
in accessibility code and other crashes we blamed GTK+ for.
2012-02-21 00:36:18 +01:00
malay.keshav 848460d9a5 about-dialog: Add ifdef GIMP_UNSTABLE around about_dialog_add_unstable_message() 2012-02-19 22:14:36 +05:30
Michael Natterer c63f34ff17 Bug 670352 - Tool tip for "Zoom Out" and "Zoom In" are not translated
Apply patch from Kiyotaka NISHIBORI that makes the actions use the
right translation context.
2012-02-19 12:15:41 +01:00
malay.keshav 9bf7d9d08a Rename function (about_dialog_add_unstable_message) 2012-02-19 16:43:37 +05:30
Mikael Magnusson cd002dd0c6 app: remove two duplicated variable inits 2012-02-16 11:30:38 +01:00
Mikael Magnusson 5c19c75f71 app: fix typo in error message 2012-02-16 11:25:23 +01:00
Michael Natterer 8559a28fd4 app: don't mess with the dialog's sensitivity while checking the extension
so the same widget (e.g. the entry) stays focused after dismissing the
extension mismatch message dialog.
2012-02-14 12:18:34 +01:00
Michael Natterer 7f5a43f3e1 app: rename GimpToolInfo::menu_path to ::menu_label
"path" is a really ancient pre-GtkAction terminology here.
2012-02-14 10:00:26 +01:00
Michael Natterer f2fc342101 Bug 670024 - Zoom Tool menu label is not translated
Remove the message context from the zoom tool's menu label. It's not
needed and can't work like that for menu items.
2012-02-14 09:54:29 +01:00
Christian Krippendorf 43b6d6922c Bug 615227 - Undo while scaling layer freezes GIMP
Don't run into an infinite loop when the undo editor is used
while we're in the middle of an undo group.
2012-02-13 08:17:47 +01:00
Michael Natterer b3c8cbd5a5 app: remove all docks from GimpImageWindow in dispose()
Seems to fix irregularly occuring warnings on exit about dialogs
being still around.
2012-02-13 00:12:50 +01:00
Michael Natterer ddb1f968b5 app: fix include guards in gimpbrush-transform.h to not use the old filename 2012-02-12 18:41:52 +01:00
Michael Natterer 90065a517e app: try harder to show filename and file size in Image -> Properties
by using gimp_image_get_any_uri() instead of get_filename() or get_uri().
2012-02-11 22:54:06 +01:00
Michael Natterer 0e6b703794 app: remove unused typedef GimpDynamicsOptions 2012-02-11 18:12:42 +01:00
Michael Natterer f70bc837fa app: remove gimpdisplay-utils.[ch], move its only function to gimpdisplay.[ch] 2012-02-11 17:57:27 +01:00
Nils Philippsen 4ec7def1d0 put operators on end of line in long expressions
This fixes commit 3a151bd1a9, GIMP is
deviating from the GNU coding style here.
2012-02-11 16:50:44 +01:00
Nils Philippsen 3a151bd1a9 app: check top_directory for plausibility 2012-02-10 16:20:15 +01:00
Massimo Valentini 2303d292c3 app: initialize var before usage
to silence valgrind

==12105== Conditional jump or move depends on uninitialised value(s)
==12105==    at 0x6B069C: gimp_data_set_folder_tags (gimp/app/core/gimpdata.c:885)
==12105==    by 0x6B155E: gimp_data_factory_load_data (gimp/app/core/gimpdatafactory.c:922)
==12105==    by 0x64F34D0: gimp_datafiles_read_directories (gimp/libgimpbase/gimpdatafiles.c:155)
==12105==    by 0x6B1293: gimp_data_factory_data_load (gimp/app/core/gimpdatafactory.c:354)
==12105==    by 0x6B1E1C: gimp_data_factory_data_init (gimp/app/core/gimpdatafactory.c:239)
==12105==    by 0x6871D2: gimp_restore (gimp/app/core/gimp.c:952)
==12105==    by 0x47EABA: app_run (gimp/app/app.c:217)
==12105==    by 0x47E64D: main (gimp/app/main.c:440)
==12105==  Uninitialised value was created by a stack allocation
==12105==    at 0x6B1190: gimp_data_factory_data_load (gimp/app/core/gimpdatafactory.c:319)
2012-02-10 12:24:32 +01:00
Alexia Death f0a7d04cfa app: Fix a segfault in paint core 2012-02-09 21:59:25 +02:00
Michael Natterer af6b840aaf Bug 666561 - Clicking on the expand icon next to a group expands the wrong group
gimp_item_tree_view_row_expanded(): only select the active item if its
immediate parent was expanded, not if *any* group was expanded.
2012-02-09 20:38:46 +01:00
Massimo Valentini b994280473 Bug 668814: Cannot move cursor right in on canvas editor
One possible way to decrease the incompatibilities
between letter spacing in a tagged gtk_text_buffer
and in an equivalent pango_layout

Remove also a valgrind reported invalid write in
gimptextbuffer.c
2012-02-09 12:36:43 +01:00
Michael Natterer 0729c25bc0 app: set tags for all subdirectories a data file lives in
GimpData: add gimp_data_set_folder_tags() and remove the tag logic
from gimp_data_set_filename(). The function gets the toplevel data
directory passed so it knows where to stop assigning tags.

GimpDataFactory: when loading data, keep track of the currently
processed data hierachy's toplevel directory, and pass it to above new
function. Also make sure obsolete files don't get folder-tagged.
2012-02-09 10:02:49 +01:00
Michael Natterer 2414301799 Review the last few commits and apply some style fanaticism
some completely unrelated,
2012-02-07 20:36:55 +01:00