* gtk/gtktextlayout.c (set_para_values): Propagate
pg_bg_color to the display struct.
(gtk_text_layout_free_line_display): Free it here.
* gtk/gtktextdisplay.c (render_para): If pg_bg_color
is set, draw a rectangle in that color behind
the paragraph.
* gtk/gtktexttag.c (gtk_text_tag_class_init): Add
paragraph-background, paragraph-background-gdk and
paragraph-background-set properties.
(set_pg_bg_color): A setter for paragraph-background.
Kjartan Maraas [Fri, 10 Jun 2005 19:53:47 +0000 (19:53 +0000)]
Destroy the cairo surface when done with it. Plugs a fairly large leak in
2005-06-10 Kjartan Maraas <kmaraas@gnome.org>
* gdk/gdkcairo.c: (gdk_cairo_set_source_pixbuf): Destroy the
cairo surface when done with it. Plugs a fairly large leak in
some cases.
==6014== 1999824 (115640 direct, 1884184 indirect) bytes in
826 blocks are definitely lost in loss record 25239 of 25250
Like this from nautilus.
Matthias Clasen [Fri, 10 Jun 2005 06:41:04 +0000 (06:41 +0000)]
Generate N_() calls for translatable key names.
2005-06-10 Matthias Clasen <mclasen@redhat.com>
* gdk/gen-keyname-table.pl: Generate N_() calls for
translatable key names.
* gdk/keynames.txt: Mark some key names as translatable.
* gdk/keyname-table.h: Regenerated.
* gtk/gtkaccellabel.c (gtk_accel_label_class_init): Add
some context to the msg ids for keyboard modifiers and
key names.
(_gtk_accel_label_class_get_accelerator_label): Try to
translate key names. (#300224, Christian Rose)
2005-06-10 Federico Mena Quintero <federico@ximian.com>
Merged from gtk-2-6:
Fixes #162358:
* gtk/gtkfilechooserdefault.c (update_chooser_entry): Don't return
immediately if we are in CREATE_FOLDER mode, so that we can fill
the entry with the newly-selected folder.
(gtk_file_chooser_default_set_property): Warn against turning on
multiple selection for CREATE_FOLDER mode, or about setting that
action while multiple selection is on.
(update_chooser_entry): Change the entry's contents as well if we
are in CREATE_FOLDER mode. If nothing is selected, clear the
chooser entry.
(trap_activate_cb): Don't trap enter/space if modifiers are
pressed. This lets one use Ctrl-space to toggle rows in multiple
selection mode.
(gtk_file_chooser_default_should_respond): Clean up the if-chain
mess of special cases by using an array to determine what to do.
Also, for the save-entry case in CREATE_FOLDER mode, actually fix
the bug where the file chooser would switch to an existing folder
rather than confirming with it, and create the folder ourselves.
(error_creating_folder_over_existing_file_dialog): New function.
* gtk/gtkfilechooserentry.c (check_completion_callback): Only
insert the common prefix if we are in an "open" mode. Use a
helper function.
(append_common_prefix): New helper function; code moved over from
check_completion_callback().
(find_common_prefix): New helper function.
(gtk_file_chooser_entry_focus): Append the common prefix if the
user requests it explicitly.
Matthias Clasen [Thu, 9 Jun 2005 17:13:58 +0000 (17:13 +0000)]
Update the user time on the window when a drop happens. (#169364,
2005-06-09 Matthias Clasen <mclasen@redhat.com>
* gdk/x11/gdkdnd-x11.c (motif_drop_start, xdnd_drop_filter): Update
the user time on the window when a drop happens. (#169364, Alexander
Hunziker, patch by Elijah Newren)
Matthias Clasen [Thu, 9 Jun 2005 06:07:57 +0000 (06:07 +0000)]
New function to scroll to a path. (#306838, Jonathan Blandford)
2005-06-09 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkiconview.h:
* gtk/gtkiconview.c (gtk_icon_view_scroll_to_path): New function
to scroll to a path. (#306838, Jonathan Blandford)
Matthias Clasen [Wed, 8 Jun 2005 20:25:21 +0000 (20:25 +0000)]
Check for negative before appending the index, to avoid double error
2005-06-08 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktreemodel.c (gtk_tree_path_new_from_string): Check for
negative before appending the index, to avoid double error
message. (#306393, Morten Welinder)
Matthias Clasen [Wed, 8 Jun 2005 20:14:03 +0000 (20:14 +0000)]
Don't crash if search_window is NULL. (#304914, Victor Osadci, testcase by
2005-06-08 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktreeview.c (gtk_tree_view_real_start_interactive_search):
Don't crash if search_window is NULL. (#304914, Victor Osadci,
testcase by Olaf Vitters)
Tor Lillqvist [Sun, 5 Jun 2005 10:34:20 +0000 (10:34 +0000)]
Return NULL unless screen number is zero. We have only one screen on
2005-06-05 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkscreen-win32.c
(_gdk_windowing_substitute_screen_number): Return NULL unless
screen number is zero. We have only one screen on Win32.
(gdk_screen_make_display_name): Call gdk_display_get_name() and
return that.
Tor Lillqvist [Sat, 4 Jun 2005 22:08:50 +0000 (22:08 +0000)]
modules/engines/Makefile.am Decide whether to build the ms-windows theme
2005-06-05 Tor Lillqvist <tml@novell.com>
* modules/engines/Makefile.am
* modules/input/Makefile.am: Decide whether to build the
ms-windows theme engine based on the GDK backend, not based on
platform. (I.e., if building for Cygwin with the X11 backend, we
shouldn't build the ms-windows engine, but if building for Cygwin
but with the Win32 backend, we should.) Ditto for the IME
(Windows) input module. (#305832)
Tor Lillqvist [Sat, 4 Jun 2005 21:43:03 +0000 (21:43 +0000)]
gdk/win32/gdkcursor-win32.c gdk/win32/gdkwindow-win32.c Support
2005-06-04 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkcursor-win32.c
* gdk/win32/gdkwindow-win32.c
* gdk/win32/gdkprivate-win32.h: Support full-colour cursors.
Support cursors with alpha on XP. Use code in common with the
support for alpha icons that already was present. (#306101, Tim
Evans)
Matthias Clasen [Thu, 26 May 2005 19:49:51 +0000 (19:49 +0000)]
Queue the redisplay after modifying the tag in the btree, otherwise we end
2005-05-26 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktextbtree.c (_gtk_text_btree_tag): Queue the
redisplay after modifying the tag in the btree, otherwise
we end up showing the old tags until the next redraw comes
around. (#143537, Gary Kramlich)
Michael Natterer [Wed, 25 May 2005 10:22:37 +0000 (10:22 +0000)]
block the text_layout's "changed" handler when changing cursor visibility
2005-05-25 Michael Natterer <mitch@imendio.com>
* gtk/gtktextview.c (blink_cb): block the text_layout's "changed"
handler when changing cursor visibility because it would expose
the whole paragraph where the cursor is. Instead, expose the
cursors' areas manually. (#173047).
(text_window_invalidate_cursors): new function which exposes the
cursors.
* gtk/gtkstyle.c (draw_insertion_cursor): added comment that the
same cursor size calculation is in text_window_invalidate_cursors().
Matthias Clasen [Mon, 23 May 2005 16:45:57 +0000 (16:45 +0000)]
Don't grab the focus away from the file list when operating the filter
2005-05-23 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkfilechooserdefault.c (filter_create): Don't grab
the focus away from the file list when operating the filter
combo with the pointer. (#304844, Sven Neumann)
Tor Lillqvist [Sun, 22 May 2005 21:23:45 +0000 (21:23 +0000)]
If the keysym isn't one of the special cases this function takes care of,
2005-05-23 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkkeys-win32.c (handle_dead): If the keysym isn't one
of the special cases this function takes care of, us it as
such. This takes care of for instance the Bengali Virama, see bug
#165723.
Anders Carlsson [Wed, 18 May 2005 17:10:46 +0000 (17:10 +0000)]
If the horizontal adjustment changes because of a change in the layout
2005-05-18 Anders Carlsson <andersca@imendio.com>
* gtk/gtktextview.c: (gtk_text_view_flush_scroll),
(gtk_text_view_update_adjustments), (gtk_text_view_value_changed):
* gtk/gtktextview.h:
If the horizontal adjustment changes because of a change in the
layout width, then do a complete redraw. This is because there
might be right-aligned or centered text that needs to be redrawn.