Benjamin Berg [Fri, 8 Jun 2007 12:32:02 +0000 (12:32 +0000)]
Fix shadow painting if the scrollbars-within-bevel style property is set
2007-06-08 Benjamin Berg <benjamin@sipsolutions.net>
* gtk/gtkscrolledwindow.c: (gtk_scrolled_window_paint):
Fix shadow painting if the scrollbars-within-bevel style property is
set and border_width is nozero. (#445054)
add utility function gdk_quartz_fix_cap_not_last_line() which fixes the
2007-06-08 Michael Natterer <mitch@imendio.com>
* gdk/quartz/gdkdrawable-quartz.c: add utility function
gdk_quartz_fix_cap_not_last_line() which fixes the coordinates for
GDK_CAP_NOT_LAST lines at least for horizontal and vertical lines.
(gdk_quartz_draw_segments)
(gdk_quartz_draw_lines): use it here.
use the same code for GDK_XOR as for GDK_INVERT. Xor with an arbitrary
2007-06-07 Michael Natterer <mitch@imendio.com>
* gdk/quartz/gdkgc-quartz.c (_gdk_quartz_gc_update_cg_context):
use the same code for GDK_XOR as for GDK_INVERT. Xor with an
arbitrary color is impossible to implement with quartz.
Matthias Clasen [Thu, 7 Jun 2007 04:23:10 +0000 (04:23 +0000)]
Use g_get_user_special_dir() to obtain the path for the DESKTOP directory.
2007-06-06 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkfilechooserbutton.c (model_add_special):
* gtk/gtkfilechooserdefault.c (shortcuts_append_desktop):
* gtk/gtkfilesystemunix.c (get_icon_name_for_directory):
* gtk/gtkpathbar.c (_gtk_path_bar_set_file_system):
Use g_get_user_special_dir() to obtain the path for the
DESKTOP directory.
add text-[xy]align properties for aligning the text label of the progress
2007-06-06 Kristian Rietveld <kris@imendio.com>
* gtk/gtkcellrendererprogress.c (gtk_cell_renderer_progress_init),
(gtk_cell_renderer_progress_class_init),
(gtk_cell_renderer_progress_[gs]et_property),
(gtk_cell_renderer_progress_render): add text-[xy]align properties
for aligning the text label of the progress bar. (#334576,
suggestion from Steven Sheehy).
Richard Hult [Wed, 6 Jun 2007 18:42:07 +0000 (18:42 +0000)]
Rework how we get the event window: don't get the window from the NSEvent,
2007-06-06 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c (find_mouse_window_for_ns_event)
(find_window_for_ns_event): Rework how we get the event window:
don't get the window from the NSEvent, always use the mouse window
instead. Fix mouse window tracking by only using MouseExited for
non-gdk windows, and to always use the NSEvent window to get the
right gdk window in MouseEntered. Add comments to the code. Fixes bug
#350460.
Richard Hult [Wed, 6 Jun 2007 16:23:50 +0000 (16:23 +0000)]
Don't do anything if the two windows are the same.
2007-06-06 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c (get_converted_window_coordinates):
Don't do anything if the two windows are the same.
(find_window_for_ns_event): Translate coordinates to be relative
the grab window when appropriate.
Emmanuele Bassi [Wed, 6 Jun 2007 16:07:03 +0000 (16:07 +0000)]
Factor out the search shortcut, the recently used shortcut and the
2007-06-06 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkfilechooserdefault.c:
(get_file_info_finished), (shortcuts_insert_path),
(shortcuts_add_bookmarks), (shortcuts_add_current_folder): Factor
out the search shortcut, the recently used shortcut and the separator
from the shortcut selection combo. (#444734)
(recent_idle_load): Remove the idle source that lazily loads the
recently used files, if the GtkRecentManager returns an empty
list. (#443913)
Ross Burton [Wed, 6 Jun 2007 15:57:58 +0000 (15:57 +0000)]
Set DISPLAY in the child process using g_setenv() instead of constructing
2007-06-06 Ross Burton <ross@openedhand.com>
* gdk/x11/gdkspawn-x11.c:
Set DISPLAY in the child process using g_setenv() instead of
constructing a new envp, which lets callers use child setup
functions which call putenv (#442617).
Johan Dahlin [Wed, 6 Jun 2007 14:24:31 +0000 (14:24 +0000)]
reviewed by: Matthias Clasen <mclasen@redhat.com>
2007-06-06 Johan Dahlin <jdahlin@async.com.br>
reviewed by: Matthias Clasen <mclasen@redhat.com>
* gtk/gtkassistant.c (gtk_assistant_update_buttons_state):
Check if the wizard is empty before trying to access the first page.
(#444310, Johan Dahlin)
Brian Cameron [Wed, 6 Jun 2007 10:15:23 +0000 (10:15 +0000)]
Add gdkmedialib.h to EXTRA_DIST so this header file gets included with the
2007-06-06 Brian Cameron <brian.cameron@sun.com>
* gdk/Makefile.am: Add gdkmedialib.h to EXTRA_DIST so this header
file gets included with the distribution, as needed. Fixes bug
#442888. Reviewed by Matthias Clasen.
Richard Hult [Wed, 6 Jun 2007 08:29:20 +0000 (08:29 +0000)]
Update comment to be more clear and print a warning if we try to create a
2007-06-06 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c (synthesize_crossing_events):
Update comment to be more clear and print a warning if we try to
create a crossing event without knowing what the current mouse
window is, to help track down focus bugs.
* gtk/gtkliststore.[ch] (gtk_list_store_set_vector_internal): new
function, factored out code iterating (columns, values) vectors from
gtk_list_store_new_with_valuesv to here,
(gtk_list_store_set_valuesv): new public function to set list store
values using (columns, values) vectors,
(gtk_list_store_new_with_valuesv): call new _set_vector_internal
instead.
Cody Russell [Mon, 4 Jun 2007 18:57:55 +0000 (18:57 +0000)]
gtk/gtklinkbutton.h Change function argument "link" to "link_" to fix
2007-06-04 Cody Russell <bratsche@gnome.org>
* gtk/gtklinkbutton.h
* gtk/gtkaboutdialog.h: Change function argument "link"
to "link_" to fix warnings for applications compiling
with -Wshadow. (#379213)
Cody Russell [Mon, 4 Jun 2007 18:17:14 +0000 (18:17 +0000)]
Check if down_button is NULL. This happens when the pathbar button for the
2007-06-04 Cody Russell <bratsche@gnome.org>
* gtk/gtkpathbar.c (gtk_path_bar_scroll_down): Check
if down_button is NULL. This happens when the pathbar button
for the current directory is too large to fit in the
space, e.g. on Windows for directories named something like
"My Documents and Settings".
Move "move-focus" signals from several widgets to GtkWidget to enable more
2007-06-04 Michael Natterer <mitch@imendio.com>
Move "move-focus" signals from several widgets to GtkWidget to
enable more flexible costomization of keyboard navigation via
bindings. Fixes bug #414947.
* gtk/gtkwidget.c: add "move-focus" binding signal, default to
calling the toplevel GtkWindow's "move-focus" vfunc.
* gtk/gtktextview.[ch]
* gtk/gtkwindow.[ch]: remove "move-focus" signals and add compat
code that makes sure that both emitting the signal on the widget
and overriding the virtual functions keeps working as before.
* gtk/gtktoolbar.c: remove "move-focus" signal here too and use
GtkWidget's signal. This change slightly changes keyboard
navigation in toolbars. I'll fix the behavior if somebody can
explain me if and how exactly the new behavior is broken.
Matthias Clasen [Mon, 4 Jun 2007 14:39:56 +0000 (14:39 +0000)]
Add a create-window signal that allows to override the global
2007-06-04 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkmarshalers.list:
* gtk/gtknotebook.[hc]: Add a create-window signal that allows
to override the global create-window-hook on a per-notebook
basis. The default handler falls back to the global hook.
(#386935, Christian Hammond)
Emmanuele Bassi [Sun, 3 Jun 2007 23:39:43 +0000 (23:39 +0000)]
Add gtk_radio_button_set_value(), gtk_radio_button_get_current_value() and
2007-06-04 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkradiobutton.h:
* gtk/gtkradiobutton.c:
* gtk/gtk.symbols: Add gtk_radio_button_set_value(),
gtk_radio_button_get_current_value() and gtk_radio_button_get_value().
Use these functions to set and get an arbitrary integer associated to
a GtkRadioButton in a group, like the value associated to a
GtkRadioAction.
* tests/testgtk.c:
(create_radio_buttons), (radio_toggled_cb): Exercise the new API.
Initialize unthemed_icon to NULL to avoid accessing uninitialized memory
* gtk/gtkicontheme.c (choose_icon): Initialize unthemed_icon to NULL
to avoid accessing uninitialized memory when
gtk_icon_theme_choose_icon() is called with an empty names list.
Richard Hult [Sun, 3 Jun 2007 18:48:47 +0000 (18:48 +0000)]
Make pointer grab emulation work a bit better:
2007-06-03 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c: Make pointer grab emulation work a bit
better:
(gdk_display_pointer_is_grabbed): Do what the docs say and don't
consider implicit grabs here.
(gdk_pointer_grab): Overriding a grab by the same app should always be
succesful.
(gdk_event_translate): Implicit grabs should not be owner events.
Richard Hult [Fri, 1 Jun 2007 21:46:45 +0000 (21:46 +0000)]
Fix the coordinates in crossing events so they are relative to the right
2007-06-01 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c:
(get_converted_window_coordinates), (create_crossing_event): Fix the
coordinates in crossing events so they are relative to the right
window.
don't switch submenu opening direction for overlapping reasons if there is
2007-06-01 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenuitem.c (gtk_menu_item_position_menu): don't switch
submenu opening direction for overlapping reasons if there is even
less space on the other side (bug #441863, Tommi Komulainen).
Yevgen Muntyan [Fri, 1 Jun 2007 06:25:43 +0000 (06:25 +0000)]
Avoid recreating pangolayouts in GtkTextView on cursor movement (#435405,
2007-06-01 Yevgen Muntyan <muntyan@tamu.edu>
Avoid recreating pangolayouts in GtkTextView on cursor movement
(#435405, Behdad Esfahbod).
* gtk/gtktextlayout.c:
* gtk/gtktextlayout.h: new GtkTextLayout method invalidate_cursors(),
and functions gtk_text_layout_invalidate_cursors() and
gtk_text_layout_cursors_changed(), to use when invalidation is due
to moved marks or changed selection.
* gtk/gtktextbtree.c:
* gtk/gtktextbtree.h: use what's appropriate when invalidating layout.
* gtk/gtk.symbols: add new functions.
* README.in: added a note about changed GtkTextLayout API.
Yevgen Muntyan [Fri, 1 Jun 2007 05:02:05 +0000 (05:02 +0000)]
use text colors from widget style to draw cursor instead of hardcoded
2007-05-31 Yevgen Muntyan <muntyan@tamu.edu>
* gtk/gtkstyle.c (get_insertion_cursor_gc): use text colors from
widget style to draw cursor instead of hardcoded black and grey
(#79585, comment #30).
Tor Lillqvist [Wed, 30 May 2007 15:44:28 +0000 (15:44 +0000)]
Subtract the multi-monitor offset from x and y before setting up the
2007-05-30 Tor Lillqvist <tml@novell.com>
* gdk/win32/gdkevents-win32.c (gdk_pointer_grab): Subtract the
multi-monitor offset from x and y before setting up the rectangle
for ClipCursor(). Fixes #442326.
Emmanuele Bassi [Wed, 30 May 2007 12:27:47 +0000 (12:27 +0000)]
Fix to update the file chooser entry
Return after setting the file chooser entry instead of falling through. Also
remove the handling for the search and recent files operation modes, since
they don't have a location entry to update.
Richard Hult [Mon, 28 May 2007 21:11:55 +0000 (21:11 +0000)]
Break out code that was repeated into separate functions and call them
2007-05-28 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c (get_child_coordinates_from_ancestor)
(get_ancestor_coordinates_from_child): Break out code that was
repeated into separate functions and call them instead.
(find_window_for_mouse_nsevent): Break out this from
find_window_for_nsevent to make the code clearer.
(find_window_for_nsevent): Use the above and fix the returned
coordinates in the process so that they are always relative the
found window, both for the normal case and during grabs. Still
needs fixing for the case where we get nsevents for a window other
than than grab window during grabs.
Richard Hult [Mon, 28 May 2007 20:51:11 +0000 (20:51 +0000)]
Reset all the grab state, to help debugging. (gdk_event_translate): Use
2007-05-28 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkevents-quartz.c (pointer_ungrab_internal): Reset
all the grab state, to help debugging.
(gdk_event_translate): Use pointer_ungrab_internal instead of
duplicating the code here.
Richard Hult [Mon, 28 May 2007 20:42:51 +0000 (20:42 +0000)]
Refactored version of _gdk_quartz_window_find_child_by_point, that doesn't
2007-05-28 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkprivate-quartz.h:
* gdk/quartz/gdkwindow-quartz.c (find_child_window_helper)
(_gdk_quartz_window_find_child): Refactored version of
_gdk_quartz_window_find_child_by_point, that doesn't return any
coordinates as the users of this function already have the
coordinates and need to translate them differently.
(_gdk_windowing_window_get_pointer): Fixup coordinate translation.
(_gdk_windowing_window_at_pointer): Likewise.