2007-05-25 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkimage-quartz.c: (_gdk_quartz_image_copy_to_image):
Implement copying from a window, part of bug #348493.
svn path=/trunk/; revision=17917
2007-05-25 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation-unix.c (unix_end_run): Hold a
refence on the print operation until gtk_print_job_send()
is done. (#440040, Chris Vine)
svn path=/trunk/; revision=17915
2007-05-25 Michael Natterer <mitch@imendio.com>
Merge fix from maemo-gtk:
* gtk/gtkmenushell.c (gtk_menu_shell_enter_notify): open submenus
also if the menu item we're entering is already selected. Also, it
makes no sense to forward the event to the parent menu shell if we
are entering a menu item of *this* menu shell.
svn path=/trunk/; revision=17911
2007-05-24 Michael Natterer <mitch@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer): apply patch from
Bogdan Nicula which fixes a crash on GdkWindows which have no
GtkWidget as user_data (bug #440890).
svn path=/trunk/; revision=17906
2007-05-23 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_widget_under_pointer): translate coordinates
from the window they were received on to the event widget's window;
correct for no-window widgets after that, bail out on failure. This
makes the coordinates given by GtkWidget::query-tooltip truly relative
to widget->window. (#435188).
* gtk/gtkwidget.c (gtk_widget_class_init): update docs for
GtkWidget::query-tooltip.
svn path=/trunk/; revision=17896
2007-05-21 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkdisplay-quartz.c: (gdk_display_open): Set the
resolution.
* gdk/quartz/gdkscreen-quartz.c: Use the autorelease pool macros.
svn path=/trunk/; revision=17887
2007-05-21 Tor Lillqvist <tml@novell.com>
* gtk/gtkscalebutton.c (gtk_scale_popup): Make it work better with
multiple monitors.
svn path=/trunk/; revision=17881
2007-05-20 Bastien Nocera <hadess@hadess.net>
* gtk/Makefile.am:
* gtk/gtk.h:
* gtk/gtk.symbols:
* gtk/gtkvolumebutton.[ch]: Add the GtkVolumeButton widget,
a button that pops up a scale when clicked (Closes: #415775)
* tests/Makefile.am:
* tests/testvolumebutton.c: Add a test program for the
volume button
2007-05-20 Bastien Nocera <hadess@hadess.net>
* POTFILES.in: Add volume button to the list
2007-05-20 Bastien Nocera <hadess@hadess.net>
* gtk/gtk-sections.txt: Add the GtkVolumeButton widget
to the docs
svn path=/trunk/; revision=17877
2007-05-19 Bastien Nocera <hadess@hadess.net>
reviewed by: Matthias Clasen <mclasen@redhat.com>
* gtk/Makefile.am:
* gtk/gtk.h:
* gtk/gtk.symbols:
* gtk/gtkscalebutton.[ch]: Add the GtkScaleButton widget,
a button that pops up a scale when pressed
2007-05-19 Bastien Nocera <hadess@hadess.net>
* POTFILES.in: Add scale button to the list
2007-05-20 Bastien Nocera <hadess@hadess.net>
* gtk/gtk-docs.sgml:
* gtk/gtk-sections.txt: add the GtkScaleButton widget
to the docs
svn path=/trunk/; revision=17876
2007-05-19 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtknotebook.[hc]: Deprecate gtk_notebook_[gs]et_group_id
in favour of new functions gtk_notebook_[gs]et_group, which
takes a pointer as group identifier and makes it easier to
avoid group id collisions. (#386930, Christian Hammond)
* tests/testnotebookdnd.c: Use new grouping api.
svn path=/trunk/; revision=17873
2007-05-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktextview.c: Add a toggle-cursor-visibility keybinding
signal, and bind F7 to it. (#380048, Tim Miao)
svn path=/trunk/; revision=17869
2007-05-18 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkicontheme.h:
* gtk/gtkicontheme.c: Add a function to look up an icon from
a list of icon names. (#396901, Luca Ferretti)
svn path=/trunk/; revision=17868
2007-05-18 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchooserdefault.c:
(gtk_recent_chooser_default_dispose): Reset the state on dispose.
(cleanup_after_load): load_id != 0 && load_state == LOAD_EMPTY
is a valid state, if the main loop never had the chance to
properly spin at least once. (#438671)
svn path=/trunk/; revision=17866
2007-05-18 Michael J. Chudobiak <mjc@cvs.gnome.org>
* INSTALL.in:
* README.in:
* configure.in: Bump libtiff requirement to 3.6.0, by requiring
presence of TIFFReadRGBAImageOriented.
* gdk-pixbuf-scaled-anim.c: (get_scaled_pixbuf):
Preserve pixbuf options when generating a new scaled pixbuf.
* io-jpeg.c: (get_orientation), (gdk_pixbuf__jpeg_image_load),
(gdk_pixbuf__jpeg_image_load_increment): Read the exif
orientation tag and associate it with the "orientation" pixbuf
option. Renders libexif unnecessary in some applications.
* io-tiff.c: (tiff_image_parse): Read the tiff orientation tag,
compensate for the partial rotations performed by libtiff,
and generate an "orientation" option for the pixbuf.
svn path=/trunk/; revision=17863
2007-05-18 Carlos Garnacho <carlos@imendio.com>
Make combobox menu popdown keybindable (#433593)
* gtk/gtkcombobox.c (gtk_combo_box_class_init): Add "popdown" binding
signal and keybindings.
(gtk_combo_box_real_popdown): Added, "popdown" keybinding signal
handler.
(gtk_combo_box_menu_key_press):
(gtk_combo_box_list_key_press): forward the event to the combobox if
it wasn't handled by the menu.
svn path=/trunk/; revision=17861
2007-05-18 Carlos Garnacho <carlos@imendio.com>
* gtk/gtknotebook.c (gtk_notebook_init) (gtk_notebook_drag_motion)
(gtk_notebook_drag_drop): Allow widgets up in the hierarchy to run
their DnD handlers if the target doesn't match with anything the
notebook manages. (#350665, Joakim Lundborg).
svn path=/trunk/; revision=17860
2007-05-18 Carlos Garnacho <carlos@imendio.com>
Refactor GtkFileChooserDialog sizing.
* gtkfilechooserembed.[ch] (delegate_get_resizable_hints)
(_gtk_file_chooser_embed_get_resizable_hints):
s/resizable_hints/resizable/, return just one boolean value to
determine whether the filechooser should be resizable or not.
* gtkfilechooserprivate.h (struct GtkFileChooserDialogPrivate): remove
variables related to the GtkFileChooserEmbed get_default_size() and
get_resizable() implementations.
(struct GtkFileChooserDefault): Move default size management here.
* gtkfilechooserdefault.c (gtk_file_chooser_default_size_allocate):
Added, store currently allocated size to calculate default size later.
(gtk_file_chooser_default_get_resizable_hints):
s/resizable_hints/resizable/.
(gtk_file_chooser_default_set_property): Reload settings if the file
chooser action changes, this way the save expander state will be known
before mapping the window, avoiding wrong window positioning and
flickering. (#424299, #424309)
(find_good_size_from_style): Only get size from style if it wasn't set
previously.
(gtk_file_chooser_default_get_default_size): return default size based
on stored default size and preview/extra widget sizes.
* gtkfilechooserdialog.c (file_chooser_widget_update_hints)
(file_chooser_widget_realized_size_changed)
(file_chooser_widget_unrealized_size_changed): simplified to
(file_chooser_widget_size_changed): set window size and resizability
based on the GtkFileChooserEmbed interface implementation. (Bug
#420285, Tomeu Vizoso)
(gtk_file_chooser_dialog_map): force a dialog size change, so it's
clamped for sure to the 75% of the screen size.
svn path=/trunk/; revision=17859
2007-05-18 Carlos Garnacho <carlos@imendio.com>
* gtk/gtknotebook.c (gtk_notebook_real_insert_page): Do not unset
the brand new current page if there was none set previously. Fixes
#425138 (Reported by Michail Crayson). Some code simplifications.
(gtk_notebook_draw_arrow): code style fix.
svn path=/trunk/; revision=17858
2007-05-16 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkpathbar.c: Add ATK names to the Up, Down, and Root
buttons. Keep the focus from vanishing when Up or Down arrows
become insensitive or invisible. (#357005, Patrick Wade)
svn path=/trunk/; revision=17856
2007-05-16 Brian Cameron <brian.cameron@sun.com>
* acconfig.h, configure.in, gdk/Makefile.am, gdkprivate.h, gdkrgb.c,
gdkdraw.c, gdk-pixbuf/gdk-pixbuf-scale.c,
gdk-pixbuf/pixops/Makefile.am, gdk-pixbuf/pixops/pixops.[ch],
gdk-pixbuf/pixops/timescale.c: Add Sun mediaLib support so that
hardware acceleration via mediaLib is enabled if mediaLib is
detected via configure. Enhancement request #344813. I was given
permission to commit in the bug report by Matthias Clasen.
* gdk/medialib.[ch]: New files added for mediaLib support.
* docs/reference/gdk-pixbuf/tmpl/scaling.sgml,
docs/reference/gdk/tmpl/rgb.sgml, gdk/gdkdraw.c: Add docs for
mediaLib support.
svn path=/trunk/; revision=17855
2007-05-15 Torsten Schoenfeld <kaffeetisch@gmx.de>
* gtk/gtkprintoperation.c (pdf_end_run): Unset priv->platform_data and
priv->free_platform_data to prevent gtk_print_operation_finalize()
from freeing the cairo surface a second time.
svn path=/trunk/; revision=17851
* gtk/gtkaboutdialog.c: Functions: gtk_about_dialog_get/set_name()
were deprecated in favour of gtk_about_dialog_get/set_program_name(),
the GtkAboutDialog now uses the "program-name" property instead of
the conflicting "name" property (fixes bug 345822).
svn path=/trunk/; revision=17845
2007-05-14 Emmanuele Bassi <ebassi@gnome.org>
* configure.in: Add check for GNU extensions to ftw()/nftw().
* gtk/gtksearchenginesimple.c: Fix compilation on systems with
only POSIX-compliant ftw(). (#435797, based on a patch by
Richard Hult)
svn path=/trunk/; revision=17844
2007-05-14 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkfilechooserdefault.c:
Convert the GtkTreeIter inside the sorting functions for the
search and recent modes. This doesn't yet fix the segfault when
clicking the 'Name' column in recent mode, though.
svn path=/trunk/; revision=17843
2007-05-13 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtksearchenginesimple.c: Include <ftw.h> and use nftw() and
all the symbols defined in <ftw.h> conditionally.
svn path=/trunk/; revision=17836
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserdefault.c: Support drag and drop for
adding shortcuts of folders when in search or recent files
mode.
svn path=/trunk/; revision=17829
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserprivate.h:
* gtk/gtkfilechooserdefault.c: Follow the sorting order of
the GtkTreeView displaying the files list.
(shortcuts_get_index), (shortcuts_insert_separator),
(shortcuts_model_create), (shortcuts_combo_filter_func): Remove
the separator between the Search and the Recently Used shortcuts.
(list_select_func), (list_icon_data_func), (list_name_data_func),
(list_mtime_data_func): Update the sensitivity of the row
depending on the GtkFileChooserAction used.
svn path=/trunk/; revision=17828
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserprivate.h:
* gtk/gtkfilechooserdefault.c: Update the contents of the
files list when changing the filter of the GtkFileChooserDefault
widget.
svn path=/trunk/; revision=17827
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserdefault.c: Update the add bookmark button
sensitivity when in search or recent files mode, and allow
adding a bookmark for a folder.
svn path=/trunk/; revision=17826
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserdefault.c: UI fixes in the Search mode: add
a mnemonic to the label, de-boldify the label's text and assign
focus to the search entry when switching to the search mode.
(list_name_data_func): Split the text in both search and recent
files mode: on the first line use the short name and on the
second line use the full path.
svn path=/trunk/; revision=17825
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserprivate.h:
* gtk/gtkfilechooserdefault.c: Add support for showing the
recently used files list as a special shortcut item.
svn path=/trunk/; revision=17824
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
GtkFileChooser search fixes and recent files support. (#435342)
* gtk/gtkfilechooserdefault.c: Overall whitespace fixes and
indentation style consistency.
(list_row_activated): If the search hit is a folder, follow it
when activating the row, and switch back to browse mode.
(search_clear_model), (search_start_query),
(search_entry_activate_cb), (search_setup_widgets): Remember
the last query when switching between modes.
svn path=/trunk/; revision=17823
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkfilechooserdefault.c:
(_gtk_file_chooser_default_class_init): Add key binding for
the Search shortcut; default to MOD1+S.
(search_shortcut_handler): Handle the key binding.
(search_hit_get_info_cb), (search_add_hit), (search_clear_model),
(search_setup_model): Retrieve informations on the search hits
when adding them to the model.
(list_icon_data_func): Show the search hit icon.
svn path=/trunk/; revision=17822
2007-05-11 Michael Natterer <mitch@imendio.com>
* gtk/gtktextview.c (selection_motion_event_handler): call
gdk_event_request_motions(event) so selecting works with
XInput devices too. Spotted by Tommi Komulainen.
svn path=/trunk/; revision=17820
2007-05-11 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtksearchengine.c (_gtk_search_engine_new): Fall back
to GtkSearchEngineSimple only if gthread has already been
initialiased; otherwise, disable search support in the file
chooser widget. (#435847)
svn path=/trunk/; revision=17819
2007-05-10 Matthias Clasen <mclasen@redhat.com>
* gdk/gdkdraw.c (gdk_draw_pixbuf): Don't call into
the backend if the region is empty. (#437081, Sven Neumann)
svn path=/trunk/; revision=17813
2007-05-09 Dom Lachowicz <domlachowicz@gmail.com>
* modules/engines/ms-windows/Theme/gtk-2.0/gtkrc: GtkTreeView
doesn't
expand/collapse with Right/Left cursor keys on Windows
(#436269, Daniel Atallah)
svn path=/trunk/; revision=17810
007-05-05 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkdrawable-quartz.c:
(gdk_quartz_drawable_get_context),
(gdk_quartz_drawable_release_context): Fix bugs #428733 and #433301.
Turns out the lockFocus logic was flawed, now we only lock/unlock
when called outside a real expose event and never flush manually.
svn path=/trunk/; revision=17798
Thu May 3 16:27:34 2007 Tim Janik <timj@imendio.com>
* tests/testgtk.c (create_handle_box): made handle box test non-modal,
so other test can interact with handle boxes.
svn path=/trunk/; revision=17785
2007-05-02 Emmanuele Bassi <ebassi@gnome.org>
Add search file support in the GtkFileChooser. Original patch
by Federico Mena Quintero; patch updated by Matthias Clasen.
See bug #344785.
* gtk/gtksearchengine.[ch]: Private search engine abstraction
object.
* gtk/gtksearchenginebeagle.[ch]: Private search engine
implementation using libbeagle (via g_module_open()).
* gtk/gtksearchenginesimple.[ch]: Private search engine
implementation using file tree walking.
* gtk/gtksearchenginetracker.[ch]: Private earch engine
implementation using libtracker (via g_module_open()).
* gtk/gtkquery.[ch]: Private query object for the search
engines.
* gtk/gtkfilechooserprivate.h:
* gtk/gtkfilechooserdefault.c: Use the GtkSearchEngine to
query a search engine backend using GtkQuery; create a new
operating mode, OPERATION_MODE_SEARCH, and call the common
operating mode OPERATION_MODE_BROWSE; add support for virtual
shortcuts inside the shortcuts model and create a new "Search"
virtual shortcut.
* gtk/Makefile.am: Update the build with the new files
svn path=/trunk/; revision=17783
2007-05-02 Armin Burgmeier <armin@openismus.com>
* gtk/gtkcombobox.c: Destroy the menu in dispose instead of
finalize, because the menu might unparent itself from its parent and
cause a signal emission on a finalized object. (#430746)
svn path=/trunk/; revision=17782
2007-05-02 Dom Lachowicz <domlachowicz@gmail.com>
* modules/engines/ms-windows/msw_style.c: MS-Windows Theme top
tabs
rendered upside down for non-XP theme (#435053, Daniel Atallah)
svn path=/trunk/; revision=17773
Wed May 2 11:35:45 2007 Tim Janik <timj@imendio.com>
* docs/faq/gtkfaq.sgml: removed, since this file is long outdated
and fully replaced by docs/faq/gtk-faq.sgml.
svn path=/trunk/; revision=17772
2007-05-02 Kristian Rietveld <kris@imendio.com>
* gtk/gtktreeview.c (gtk_tree_view_grab_notify): stop the rubber band
if it's active.
svn path=/trunk/; revision=17770
* gdk/x11/gdkwindow-x11.c (setup_toplevel_window): Make sure the
leader_window's WM_CLIENT_LEADER points to itself. #435028
svn path=/trunk/; revision=17762
2007-05-02 Christian Persch <chpe@gnome.org>
* gtk/gtkpapersize.c: (gtk_paper_size_get_paper_sizes): Put only
GtkPaperSizes into the list, don't mix it with GtkPageSetups. Bug
#434861.
svn path=/trunk/; revision=17760
2007-05-02 Christian Persch <chpe@gnome.org>
* gtk/gtkstatusbar.c: (gtk_statusbar_get_context_id),
(gtk_statusbar_expose_event): No need to allocate a guint; just stuff
the ID into the pointer directly. Bug #434865.
svn path=/trunk/; revision=17758
2007-05-01 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkfilechooserdefault.c (struct UpdateCurrentFolderData),
(update_current_folder_get_info_cb): add a new struct field to clear
the file entry after the current folder has been updated.
(gtk_file_chooser_default_update_current_folder),
(change_folder_and_display_error): Add a new function parameter to
trigger file entry clearing.
(edited_idle_create_folder_cb),
(file_list_drag_data_received_get_info_cb),
(gtk_file_chooser_default_map),
(gtk_file_chooser_default_set_current_folder),
(switch_to_selected_folder), (save_entry_get_info_cb),
(shortcuts_activate_volume_mount_cb), (shortcuts_activate_volume),
(shortcuts_activate_get_info_cb), (list_row_activated),
(path_bar_clicked): use new function parameter appropriately.
(gtk_file_chooser_default_should_respond): trigger file entry clearing
after the directory is updated instead of clearing it before, this way
we avoid reloading the completion model with the soon to be old folder,
causing a warning and a glitch in the folder where completion happens.
(#379414, Carlos Garnacho)
svn path=/trunk/; revision=17754
2007-05-01 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkiconcachvalidator.[hc]: Add an icon cache validator.
* gtk/updateiconcache.c: Validate the generated cache before
moving it in place. Also add a --validate option to validate
an existing icon cache.
* gtk/gtkiconcache.c: Validate icon caches before using them.
* gtk/Makefile.am: Integrate it.
svn path=/trunk/; revision=17753
2007-05-01 Christian Persch <chpe@gnome.org>
* gtk/gtkprinter.h:
* gtk/gtkprintjob.h: Also move gtk_print_capabilities_get_type() to
the new location. Bug #390437.
svn path=/trunk/; revision=17751
2007-04-30 Matthias Clasen <mclasen@redhat.com>
* gtk/gtksettings.c (settings_update_color_scheme):
Make sure we always have a color_hash. (#423916, Jens Granseuer)
svn path=/trunk/; revision=17748
2007-04-30 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkexpander.c (gtk_expander_realize): A NO_WINDOW widget
must not set the background of its window. (#433972,
Guilherme Polo)
svn path=/trunk/; revision=17744
2007-04-30 Matthias Clasen <mclasen@redhat.com>
* modules/printbackends/cups/gtkprintbackendcups.c: Get all
the printer attributes when getting the list of printers,
not via separate requests. (#387889, Krishan Purahoo)
svn path=/trunk/; revision=17741
2007-04-30 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenushell.c (gtk_menu_shell_enter_notify): pop up the
submenu explicitely only in touchscreen mode since otherwise
selecting the item already pops up the submenu. Restores the
drag-selection timeout (spotted by Søren Sandmann, #128968).
svn path=/trunk/; revision=17735
2007-04-30 Tor Lillqvist <tml@novell.com>
* gtk/gtkpapersize.c (gtk_paper_size_get_paper_sizes):
_gtk_load_custom_papers() exists only on Unix.
svn path=/trunk/; revision=17733
2007-04-30 Tor Lillqvist <tml@novell.com>
Add functionality to set overall opacity of a top-level
window. (#405316)
* gtk/gtk.symbols: Add gtk_window_set_opacity and
gtk_window_get_opacity.
* gtk/gtkwindow.c (struct _GtkWindowPrivate,
(gtk_window_class_init): Add opacity property, a double in the
range [0, 1].
(gtk_window_set_opacity, gtk_window_get_opacity): Implement.
(gtk_window_realize): If opacity is set, call
gdk_window_set_opacity().
* gtk/gtkwindow.h: Declare gtk_window_set_opacity() and
gtk_window_get_opacity().
svn path=/trunk/; revision=17731
2007-04-30 Tor Lillqvist <tml@novell.com>
Add functionality to set overall opacity of a top-level
window. (#405316)
* gdk/gdk.symbols: Add gdk_window_set_opacity.
* gdk/x11/gdkwindow-x11.c
* gdk/win32/gdkwindow-win32.c: Implement
gdk_window_set_opacity(). On X11 use the _NET_WM_WINDOW_OPACITY
property. On Win32 use SetLayeredWindowAttributes(LWA_ALPHA).
* gdk/gdkwindow.h: Declare gdk_window_set_opacity().
* gdk/x11/gdkscreen-x11.c (gdk_screen_get_rgba_colormap): Document
that this is not implemented in the Windows backend. Add reference
to gdk_window_set_opacity().
svn path=/trunk/; revision=17730
2007-04-30 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkpapersize.[hc]: Rename gtk_paper_size_get_builtins()
to gtk_paper_size_get_paper_sizes() and optionally include
custom paper sizes.
* gtk/gtkpagesetupunixdialog.c: Internally export a function
to load custom paper sizes.
* modules/printbackends/file/gtkprintbackendfile.c: Implement
printer_list_papers, returning all paper sizes. (#434329,
Christian Persch)
svn path=/trunk/; revision=17728
2007-04-30 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation.c: Translate the default job
name, and don't utf8-validate the job name in the
setter. (#421993, Morten Welinder)
svn path=/trunk/; revision=17726
2007-04-29 Matthias Clasen <mclasen@redhat.com>
Fix some issues with reference handling in the printing
code. (#429902, Mathias Hasselmann)
* gtk/gtkprintoperation.c (gtk_print_operation_finalize):
Unref the print context, if we have one.
(gtk_print_operation_done): Add a default ::done handler
that unrefs the print context.
(preview_ready): Take a reference on the print operation
preview here.
(print_pages_idle): ...not here,
(preview_print_idle_done): ...and release it here.
* tests/print-editor.c (preview_cb): Take a reference
on the print operation here.
svn path=/trunk/; revision=17722
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation.c (print_pages_idle): Don't get
stuck in a recursive mainloop if a synchronous preview
is cancelled.
svn path=/trunk/; revision=17721
2007-04-29 Matthias Clasen <mclasen@redhat.com>
Make the emission of ::end-print and ::done consistent
for previews. (#347567, Yevgen Muntyan)
* gtk/gtkprintoperation.c (preview_iface_end_preview): Set
the finished status here.
(preview_end_run): ...and not here.
(print_pages_idle_done): Emit ::done for a cancelled preview.
(print_pages_idle): If a preview has been cancelled, don't
emit ::ready, but emit ::end-print.
tests/print-editor.c: Use ::end-print to undo allocations
from ::begin-print.
svn path=/trunk/; revision=17719
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkpapersize.c (gtk_paper_size_new): Mark paper sizes
in the PWG "custom" namespace as custom. Add a link to
the spec in the docs. (#426416, Andreas Guelzow)
svn path=/trunk/; revision=17718
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation.c (gtk_print_operation_run): Document
that a print operation can be run only once, and add a
corresponding g_return_if_fail(). (#379399, Masao Mutoh)
svn path=/trunk/; revision=17715
* gdk/x11/gdkdisplay-x11.c
(gdk_x11_display_broadcast_startup_message): New method to
marshall and send a Startup Notification message. (from #415070)
(gdk_notify_startup_complete_with_id): Use that
svn path=/trunk/; revision=17710
* docs/faq/gtk-faq.sgml: Fix typo in FAQ (#373706,
Diego Escalante Urrelo).
I'm fixing gtk-faq.sgml as it seems this is the file
we actually use...
svn path=/trunk/; revision=17707
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktoolbar.c (_gtk_toolbar_elide_underscores):
Only strip parentheses of the form (_x). (#434261,
Brian Wellington)
svn path=/trunk/; revision=17705
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation-unix.c
(_gtk_print_operation_platform_backend_launch_preview):
Support passing a print settings file to the preview
command. (#403717, Christian Persch)
* gtk/gtksettings.c: Document %s in the
gtk-print-preview-command setting.
svn path=/trunk/; revision=17704
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintoperation.h: Add a new error code
* gtk/gtk.symbols:
* gtk/gtkpagesetup.[hc]:
* gtk/gtkpapersize.[hc]:
* gtk/gtkprintsettings.[hc]: Add functions to serialize
and deserialize page setups and print settings to files
and key files. (#344515, Christian Persch)
* gtk/gtkpagesetupunixdialog.c: Adapt to the new functions.
* tests/print-editor.c: Use the new functions to persist
page setup and print settings.
svn path=/trunk/; revision=17697
2007-04-29 Matthias Clasen <mclasen@redhat.com>
* gtk/gtk.symbols:
* gtk/gtkpapersize.[hc]: Add a function to list the
builtin paper sizes. (#382355, Christian Persch)
svn path=/trunk/; revision=17691
2007-04-28 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkeventbox.c (gtk_event_box_realize): Fix the offsets
of the input-only window if we also have a visible window.
(#405089)
svn path=/trunk/; revision=17683
2007-04-28 Ronald Bultje <rbultje@ronald.bitfreak.net>
* gdk/quartz/gdkeventloop-quartz.c: (select_thread_func),
(poll_func): fix two more potential races that could happen when
an application is polling in the mainloop and a separate thread
tries to wake it up using g_idle_add(). Fixes#425271 comment 5.
svn path=/trunk/; revision=17680
2007-04-28 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkstatusicon.c (gtk_status_icon_get_size): Add
a note about being embedded. (#340107, Christian Persch)
svn path=/trunk/; revision=17677
2007-04-28 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkdnd.[hc]: Add GTK_TARGET_OTHER_{APP,WIDGET} to
restrict drags within an application/widget. (#163141,
Jorn Baayen)
svn path=/trunk/; revision=17676
* gtk/gtkentrycompletion.c (gtk_entry_completion_insert_completion_text):
Use strstr instead of g_strstr with -1 for length.
svn path=/trunk/; revision=17668
* gtk/gtkentry.c:
* gtk/gtkentrycompletion.c:
* gtk/gtkentrycompletion.h:
* gtk/gtkentryprivate.h:
Rember the user input that triggered the completion, add
API to the retrieve it and reset the entry contents to it
if the user cancels the tentative completion during
the inline-selection.
svn path=/trunk/; revision=17666
Support inline-selection in entries (#318459)
* gtk/gtkentry.c:
* gtk/gtkentrycompletion.c:
* gtk/gtkentrycompletion.h:
* gtk/gtkentryprivate.h:
When enabled cursor-match is emited when the cursor is on
a possible completion on the list. The default implementation
will replace the contents on the entry with the contents of
the text column in the completion model.
Review and improvements by Matthias Clasen.
svn path=/trunk/; revision=17660
2007-04-27 Michael Natterer <mitch@imendio.com>
Merged heavily modified patch from maemo-gtk which enables opening
and closing submenus on click, and introduces some usability
changes when gtk-touchscreen-mode is enabled (bug #128968):
* gtk/gtkmenushell.c (struct GtkMenuShellPrivate): added boolean
"activated_submenu" to indicate that the current mouse operation
(click or drag) has opened a submenu.
(gtk_menu_shell_button_press): pop up submenus without delay
and record the fact in "activated_submenu".
(gtk_menu_shell_button_release): if a submenu was explicitely
opened, or not opened by this release's button_press, or enough
time has passed since timeout-opening it, close the submenu here.
(gtk_menu_shell_enter_notify): when entering a menu item with
any mouse button pressed, open its submenu.
(gtk_real_menu_shell_move_current): in touchsreen mode, close the
submenu when moving the focus away from it via keyboard-navigation.
* gtk/gtkmenuitem.[ch] (_gtk_menu_item_popup_submenu): added
parameter "gboolean with_delay" so GtkMenuShell can control this
for the different scenarios of submenu showing.
(_gtk_menu_item_popdown_submenu): new function. also needed by
GtkMenuShell for closing submenus on click.
Renamed internal function gtk_menu_item_select_timeout() to
gtk_menu_item_popup_timeout().
(gtk_menu_item_real_popup_submenu): new utility function which
does the actual popup and records the exact time of the popup when
the menu was timeout-opened (using g_get_current_time()).
(gtk_real_menu_item_select): don't add the popup timeout when in
touchscreen mode.
* gtk/gtkmenu.c (gtk_menu_popup): in touchscreen mode, select the
first item of every opened menu.
svn path=/trunk/; revision=17659
2007-04-26 Matthias Clasen <mclasen@redhat.com>
* demo/gtk-demo/combobox.c: Add a simple validation demo.
* gtk/gtkcomboboxentry.c: Make it possible to add arbitrary
children to a GtkComboBoxEntry. (#426401, Paul Pogonyshev)
svn path=/trunk/; revision=17657
2007-04-26 Tor Lillqvist <tml@novell.com>
* gtk/gtkinputdialog.c (gtk_input_dialog_fill_axes)
(gtk_input_dialog_fill_keys): Remove old child of scrolled window
before adding a new one when switching what input device is being
handled. (#399425)
svn path=/trunk/; revision=17656
2007-04-26 Matthias Clasen <mclasen@redhat.com>
* modules/printbackends/lpr/gtkprintbackendlpr.c
(gtk_print_backend_lpr_init): Mark the printer list as done.
(#428665, Bogdan Gheorghe)
svn path=/trunk/; revision=17653
2007-04-25 Jakub Steiner <jimmac@ximian.com>
* gtk/stock-icons/16/gtk-close.{png,svg}: added 16x16 version of
as per discussion in bug #431740.
svn path=/trunk/; revision=17642
2007-04-25 Matthias Clasen <mclasen@redhat.com>
* gtk/gtktreeview.c (gtk_tree_view_style_set): Set the background
of the header window again. (#431067, Benjamin Berg)
svn path=/trunk/; revision=17640
2007-04-25 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkicontheme.c (theme_lookup_icon): Set the filename to
NULL for builtin icons, sinc gtk_icon_info_get_builtin_pixbuf()
depends on it.
* tests/testicontheme.c: Report builtin icons.
svn path=/trunk/; revision=17638
2007-04-25 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenu.c (gtk_menu_handle_scrolling): fix ACTIVE state of
scroll buttons (we were setting the state to ACTIVE but
immediately overwriting it with NORMAL or PRELIGHT). Also got rid
of many separate calls to gdk_window_invalidate_rect() by
remembering the old button state and only invalidating the area if
the state has changed (addresses parts of bug #433242, Tommi
Komulainen).
(gtk_menu_scroll_to): change the arrow states only if changing
from or to INSENSITIVE state, so we don't overwrite the ACTIVE
state set by above function.
svn path=/trunk/; revision=17630
2007-04-25 Michael Natterer <mitch@imendio.com>
* gtk/gtkprintoperation.c (preview_iface_is_selected): fix the
build. Dunno if the fix is right, but I think it is.
svn path=/trunk/; revision=17629
2007-04-24 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkprintunixdialog.c (dialog_get_page_ranges): Parse
half-open ranges like -2 or 3-, and be a bit more liberal
about whitespace.
(dialog_set_page_ranges): Support half-open ranges.
* gtk/gtkprintoperation.c (print_pages_idle): Substitute the
number of pages in half-open ranges.
(preview_iface_is_selected): Support half-open ranges here, too.
svn path=/trunk/; revision=17627
2007-04-24 Chris Wilson <chris@chris-wilson.co.uk>
* gtk/gtkicontheme.c (scan_directory): Ensure the
icon_theme->all_icons and dir->icons hash tables use the same string
as their keys. (#418531)
svn path=/trunk/; revision=17626
2007-04-23 Matthias Clasen <mclasen@redhat.com>
* modules/printbackends/cups/gtkprintbackendcups.c: Reduce
the amount of debug spew if we are not debugging.
svn path=/trunk/; revision=17619
2007-04-18 Richard Hult <richard@imendio.com>
* gdk/quartz/gdkwindow-quartz.c:
(gdk_window_quartz_process_updates_internal),
(gdk_window_quartz_process_all_updates),
(gdk_window_impl_quartz_process_updates): Refactor the process
updates functions to share code between them. Also fixes bug
#427660 by not updating larger regions than necessary.
svn path=/trunk/; revision=17610
2007-04-18 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentmanager.c (gtk_recent_manager_lookup_item): Fix
a leak by not increasing the refcount of the GtkRecentInfo
object when returning it (thanks to Matthias Clasen).
svn path=/trunk/; revision=17606
2007-04-16 Alexander Larsson <alexl@redhat.com>
* gtk/gtkprintoperation.c (gtk_print_operation_run):
Make async print preview work by actually starting
the print process in that case (#424168)
svn path=/trunk/; revision=17603
2007-04-12 Jakub Steiner <jimmac@ximian.com>
* gtk/stock-icons/*: update the stock icons to follow the Tango
le guidelines
svn path=/trunk/; revision=17599
2007-04-11 Chris Wilson <chris@chris-wilson.co.uk>
* gtk/gtkiconfactory.c (_gtk_icon_factory_list_ids):
* gtk/gtkstock.c (gtk_stock_list_ids):
Switch over to use glib's new g_hash_table_get_keys() rather
than our own static implementation.
* gtk/gtkiconfactory.h: Update to return a GList.
* configure.in: Bump required version to 2.13.1
svn path=/trunk/; revision=17597
* gdk/quartz/gdkeventloop-quartz.c: Protect the polling thread
setup and shutdown function by mutexes and read the wakeup
pipe unconditionally and unblocking. This should make the main
loop always be woken up when using g_idle_add() from another
thread in the Quartz backend (#425271).
svn path=/trunk/; revision=17595
2007-04-10 Matthias Clasen <mclasen@redhat.com>
* gdk/x11/xsettings-client.[hc]: Change the XSettingsWatchFunc
to return a Bool to indicate success. Update callers and
implementors. Based on a patch by Owen Taylor.
* gdk/x11/gdkevents-x11.c (gdk_xsettings_watch_cb): Don't
leak a reference to gdkwin.
svn path=/trunk/; revision=17592
2007-04-06 Richard Hult <richard@imendio.com>
* gdk/quartz/: Clean up namespaces to make the code more
maintainable.
* gdk/quartz/gdkdrawable-quartz.c:
* gdk/quartz/gdkgc-quartz.c: Fix bug #418384, alignment of tiled
images, by setting the pattern phase for the CG pattern.
svn path=/trunk/; revision=17584
2007-04-03 Behdad Esfahbod <behdad@gnome.org>
* gtk/gtksettings.c (settings_update_font_options): Don't set
metrics-hinting font option. Rely on the default value which is
on for all raster cairo surfaces. (#425985)
svn path=/trunk/; revision=17582
2007-04-02 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenushell.c (gtk_real_menu_shell_move_current): remove
artifact from the time when type checking casts warned on NULL,
some whitespace cleanup.
svn path=/trunk/; revision=17578
2007-03-31 Elijah Newren <newren gmail com>
* gdk/x11/gdkwindow-x11.c (setup_toplevel_window,
gdk_x11_window_set_user_time):
Patch from Matthias to add support for the
_NET_WM_USER_TIME_WINDOW EWMH protocol; see #354213.
WARNING: This patch will make metacity <= 2.18.0 freeze on
workspace switch. This is due to a weird problem that should only
affect window managers using gdk in-process for decoration drawing
and which make an unsafe assumption relating to doing so (i.e. it
should only affect metacity). Upgrade your version of metacity if
you hit this bug.
svn path=/trunk/; revision=17574
2007-03-29 Michael Natterer <mitch@imendio.com>
Don't close menus on clicks on their border area (bug #423761).
(modified patch from maemo-gtk).
* gtk/gtkmenu.c (gtk_menu_button_press)
(gtk_menu_button_release): bail out early if the click was on the
menu's border (not on any item and not outside the window).
(pointer_in_menu_window): new utility function which checks if
passed root coords are inside the menu_shell or one of its
parent shells.
svn path=/trunk/; revision=17571
2007-03-29 Michael Natterer <mitch@imendio.com>
* gtk/gtkmenu.c: get rid of local GtkSettings variables by moving
gtk_widget_get_settings() into the g_object_get() call. Some small
indentation fixes.
svn path=/trunk/; revision=17570
2007-03-28 Kristian Rietveld <kris@imendio.com>
* gtk/gtkwidget.c (gtk_widget_set_tooltip_window): don't unref
tooltip_window, since this is handled by set_qdata_full() already.
(#412001, Torsten Schoenfeld).
svn path=/trunk/; revision=17566
2007-03-24 Kristian Rietveld <kris@gtk.org>
* gtk/gtktreeviewcolumn.c (gtk_tree_view_column_cell_process_action):
calculate the depth with the corrected real_cell_area and don't
subtract horizontal_separator/2.
svn path=/trunk/; revision=17562