2008-06-18 Michael Natterer <mitch@imendio.com>
* gtk/gtktypeutils.[ch]: deprecate gtk_type_class().
* gtk/gtk.symbols: changed accordingly.
* gtk/gtksettings.c (gtk_settings_install_property)
(gtk_settings_install_property_parser): get rid of using
gtk_type_class() by keeping a static reference to GtkSettingsClass
around in both functions and passing that pointer on to
settings_install_property_parser().
* tests/testgtk.c: use g_type_class_ref()/unref() instead of
gtk_type_class().
* gtk/gtkobject.c: #undef GTK_DISABLE_DEPRECATED around including
gtktypeutils.h.
svn path=/trunk/; revision=20444
2008-05-27 Matthias Clasen <mclasen@redhat.com>
Bug 522084 – GIcon support for GtkIconTheme & GtkImage
* gtk/gtkicontheme.[hc]: Add support for GIcon based lookups.
* gtk/gtkimage.[hc]: Allow setting an image from a GIcon.
* gtk/gtk.symbols: Additions
* tests/testimage.c: Add a GIcon test
svn path=/trunk/; revision=20236
2008-05-29 Michael Natterer <mitch@imendio.org>
* gtk/Makefile.am
* gtk/gtkunixprint.h: add a single-include header for the unix
print stuff.
* gtk/gtkpagesetupunixdialog.h
* gtk/gtkprinter.h
* gtk/gtkprintjob.h
* gtk/gtkprintunixdialog.h: add single-include guards that #error
out if GTK_DISABLE_SINGLE_INCLUDES is defined and any of these
files is included individually.
* gtk/gtkprintbackend.h
* gtk/gtkprinter-private.h
* modules/printbackends/cups/gtkprintbackendcups.c
* modules/printbackends/cups/gtkprintercups.h
* modules/printbackends/lpr/gtkprintbackendlpr.c
* tests/buildertest.c
* tests/defaultvaluetest.c
* docs/tools/widgets.c: include <gtk/gtkunixprint.h> instead of
individual files.
svn path=/trunk/; revision=20230
2008-05-25 Jan Arne Petersen <jpetersen@jpetersen.org>
* gtk/gtkliststore.c: (list_store_text): Use type of the correct
column (#529535).
* tests/buildertest.c: (test_list_store): Add test.
svn path=/trunk/; revision=20142
2008-03-18 10:49:20 Tim Janik <timj@imendio.com>
* Applied pixmap redirection patch by Alexander Larsson with
various updates from:
Bug 318807 – Offscreen windows and window redirection.
Updates:
* updated docs to mention "Since 2.16".
* tests/testgtk.c: fixed snapshooting pixmap leak.
convert pixmap to pixbuf after snapshooting, to compensate for different
bit depths (occurs when snapshooting ARGB visuals and displaying the
pixmap in an RGB visual).
* gdk/gdkwindow.[hc]: made GdkWindowRedirect private.
* gdk/gdkwindow.c: removed damage idle handler, there's no aparent
need for it. enqueue damage notification as GDK_DAMAGE events
for each painting redirection at the start of the event queue.
consider windows with a redirection fully visible when invalidating,
and when updating from backing store. cleaned up stale variables.
* gdk/gdkevents.c: added _gdk_event_queue_prepend().
* gtk/gtkwidget.c: fixed coordinates for !NO_WINDOW widgets in
gtk_widget_get_snapshot; this fixes garbage snap offsets for gammacurve,
tree, drawingarea, text, handlebox, etc.
clip the redirected window hierarchy to window sizes, the visible
rectangles don't need to be taken into account here.
extended snapshooting docs to recommend gdk_pixbuf_get_from_drawable()
in case pixmap visuals could mismatch.
* gdk/x11/gdkwindow-x11.c: removed _gdk_windowing_window_get_visible_rect().
Base patch:
* tests/testgtk.c: add a "Snapshot" test to demonstrate snapshooting
of possibly obscured widgets into an offscreen pixmap.
* gtk/gtkwidget.[hc]: add GtkWidget::damage-event signal, add
gtk_widget_get_snapshot() to render a widget's contents to a GdkPixmap.
* gtk/gtkmain.c: dispatch GDK_DAMAGE events.
* gdk/gdkwindow.c: moved outer gdk_window_new() and gdk_window_reparent()
implementations here, adapted them to propagate redirects to child windows.
gdk_window_end_paint(): copy repainted window contents to redirection pixmap,
clipped to visible region. queue GDK_DAMAGE event delivery.
gdk_window_redirect_to_drawable(): install window painting redirection.
gdk_window_remove_redirection(): remove previously installed redirection.
* gdk/x11/gdkwindow-x11.c: added _gdk_windowing_window_get_visible_rect(),
renamed _gdk_window_new() and _gdk_window_reparent().
* gdk/gdkwindow.h: added GdkWindowRedirect* to GdkWindowObject, export
gdk_window_redirect_to_drawable() and gdk_window_remove_redirection().
* gdk/gdkevents.h: added GDK_DAMAGE event type.
* gdk/gdkevents.c: extract time and state from GDK_DAMAGE events.
* gdk/gdkinternals.h: added internal prototypes.
svn path=/trunk/; revision=20122
2008-04-02 Björn Lindqvist <bjourne@gmail.com>
* tests/autotestfilechooser.c: Cover
GTK_FILE_CHOOSER_ACTION_CREATE_FOLDER action in tests for current
name. (#346058, Joe Halliwell)
svn path=/trunk/; revision=19967
2008-03-20 Tor Lillqvist <tml@novell.com>
* tests/testfilechooserbutton.c (chooser_update_preview_cb): Don't
pass NULL for %s to g_message().
(main): Drop unnecessary call to gtk_widget_destroy().
svn path=/trunk/; revision=19908
2008-03-17 Christian Kellner <gicmo@gnome.org>
Implement GtkMountOperation, a subclass of GMountOperation
to be used with gio wherever there is the need to ask the
user for credentials or questions while mounting a volume.
This is bug #522245
* gtk/gtkmountoperation.c:
* gtk/gtkmountoperation.h:
Implement GtkMountOperation.
* gtk/gtk.h: Add gtkmountoperation.h
* gtk/Makefile.am: Add gtkmountoperation.[hc]
* gtk/gtk.symbols: Add symbols of GtkMountOperation.
* tests/testmountoperation.c: Test program for it.
* tests/Makefile.am: Add testmountoperation.
svn path=/trunk/; revision=19894
2008-03-10 Tor Lillqvist <tml@novell.com>
* tests/teststatusicon.c (do_exit, popup_menu): Add the
possibility to test what happens if the process just calls exit()
without any orderly cleanup of GTK+.
svn path=/trunk/; revision=19745
2008-03-07 Johan Dahlin <johan@gnome.org>
* gtk/gtkbuilder.c:
* gtk/gtkbuilderparser.c:
* gtk/gtkbuilderprivate.h:
* gtk/gtkiconfactory.c:
* tests/buildertest.c:
- Treat enums like enums and not values
- Avoid invalid free, in case of more than two sources
- Add better error messages
- Add much improved tests
(#520979, Christian Persch)
svn path=/trunk/; revision=19732
2008-03-06 Johan Dahlin <jdahlin@async.com.br>
* docs/reference/gtk/tmpl/gtkiconfactory.sgml:
* gtk/gtkbuilder.c:
* gtk/gtkbuilderprivate.h:
* gtk/gtkiconfactory.c:
* tests/buildertest.c:
Implement GtkBuildable on GtkIconFactory, to make
it possible to register custom stock icons.
Fixes#517066
svn path=/trunk/; revision=19726
2008-02-29 Johan Dahlin <johan@gnome.org>
* demos/gtk-demo/demo.ui:
* gtk/gtkbuilderparser.c:
* gtk/gtkbuilderprivate.h:
* gtk/gtkliststore.c:
* tests/buildertest.c:
Add translatable/context and comment attributes on
<col> tags under a GtkListStore. Refactor parts of the
translation api and make it available inside gtk+ itself.
Update tests and example.
Fixes a part of #518642
svn path=/trunk/; revision=19685
2008-02-29 Johan Dahlin <johan@gnome.org>
* gtk/gtkbuilder.c:
* gtk/gtkbuilderparser.c:
* gtk/gtkbuilderprivate.h:
Do not use g_error for a few more errors, instead set
the GError sent in through add_from_file/add_from_string.
* tests/buildertest.c:
Add a couple of new parsing tests.
(#519199, Pavel Syomin)
svn path=/trunk/; revision=19681
2008-02-11 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchoosermenu.c:
(gtk_recent_chooser_menu_constructor): Set no-show-all flag
on the placeholder menu item.
* tests/testrecentchoosermenu.c:
(create_recent_chooser_menu): Use gtk_widget_show_all() to test
whether the placeholder menu item gets shown.
svn path=/trunk/; revision=19509
2008-02-01 Michael Natterer <mitch@imendio.com>
* tests/testgtk.c: initialize GdkColor structs to fix warning
about uninitialized "pixel" member.
* tests/testactions.c: connect the toolbar_style() callback so it
does something useful and doesn't warn about being defined but not
used.
svn path=/trunk/; revision=19454
2008-01-30 Michael Natterer <mitch@imendio.com>
* gtk/gtkbuilderparser.c (parse_custom): use the right type for
"subparser_data" and remove the (gpointer*) cast. Fixes bogus
aliasing warning.
* gtk/updateiconcache.c (add_string): cast const gchar* to
gpointer when inserting in a GHashTable.
* tests/testcalendar.c (calendar_detail_cb): remove const from
return value since it's a newly allocated string.
(calendar_update_details): free the detail.
svn path=/trunk/; revision=19431
2008-01-26 Johan Dahlin <johan@gnome.org>
* tests/Makefile.am:
* tests/textbuffertest.c:
Rename textbuffer test and port it to the new test framework
svn path=/trunk/; revision=19410
2008-01-25 Johan Dahlin <johan@gnome.org>
* gtk/gtkwidget.c: (gtk_widget_buildable_interface_init),
(gtk_widget_buildable_get_internal_child), (free_action),
(free_relation), (gtk_widget_buildable_parser_finished),
(accessibility_start_element),
(gtk_widget_buildable_custom_tag_start),
(gtk_widget_buildable_custom_finished):
Implement accessible support, fixes#454653.
* gtk/gtk-builder-convert:
Add support for migrating old glade files
* tests/buildertest.c: (test_widget), (test_file):
Add accessible tests and improve the test_file function to display
toplevels and run dialogs.
svn path=/trunk/; revision=19403
* gtk/gtkcalendar.c: Release the memory returned by the detail_func.
* gtk/gtkcalendar.h: Remove G_CONST_RETURN from GtkCalendarDetailFunc.
* tests/testcalendar.c: Duplicate calendar details before returning.
svn path=/trunk/; revision=19382
2008-01-14 Michael Natterer <mitch@imendio.com>
* tests/testdnd.c (source_drag_data_get): fix another call to
gtk_selection_data_set().
svn path=/trunk/; revision=19369
2008-01-10 Tor Lillqvist <tml@novell.com>
* tests/Makefile.am: Build defaultvaluetest only on Unix as it
uses gtkprintunixdialog API.
svn path=/trunk/; revision=19347
2008-01-06 Johan Dahlin <johan@gnome.org>
* tests/buildertest.c (test_domain):
Update, GtkBuilder::translation-domain is no longer set
svn path=/trunk/; revision=19317
2008-01-05 Christian Persch <chpe@gnome.org>
* tests/defaultvaluetest.c: Fix mem leak, and don't pass
GType as integer through gpointer. Bug #507395.
svn path=/trunk/; revision=19307
2008-01-02 Johan Dahlin <johan@gnome.org>
* tests/defaultvaluetest.c (test_type): Ignore a few more tests to
make it pass on Ubuntu.
(main): Use gtk_test_list_all_types () instead of providing our
own list.
And it no longer passes.
svn path=/trunk/; revision=19298
2007-12-30 Johannes Schmid <jhs@gnome.org>
* gtk/gtknotebook.c: (gtk_notebook_stop_reorder):
Also reorder menu when reordering tabs by drag & drop
(Bug #506474)
* tests/testnotebookdnd.c: (create_notebook_with_notebooks):
Add a menu to one of the notebooks to have a test-case for
the change mentioned above.
svn path=/trunk/; revision=19294
2007-12-28 Johan Dahlin <johan@gnome.org>
* gtk/gtkdialog.c (gtk_dialog_buildable_custom_finished)
(gtk_dialog_buildable_custom_tag_start): Chain up.
This makes it possible to have accelerators tags on GtkDialog
subclasses.
svn path=/trunk/; revision=19268
* gtk/gtkcalendar.c, gtk/gtkcalendar.h: Add "show-details" property
aka. GTK_CALENDAR_SHOW_DETAILS, and use it.
* tests/testcalendar.c: Test GTK_CALENDAR_SHOW_DETAILS. Reduce padding
in flags vbox.
svn path=/trunk/; revision=19267
2007-12-20 Johan Dahlin <johan@gnome.org>
* tests/Makefile.am (TEST_PROGS):
* tests/defaultvaluetest.c: Add a test for default property values,
based on program by Christan Perch
svn path=/trunk/; revision=19215
2007-12-19 Johan Dahlin <johan@gnome.org>
* tests/buildertest.c (test_object_properties):
Add another call to gtk_builder_add_string after using
delayed properties, as reported in #504393 but already
fixed in #495769.
svn path=/trunk/; revision=19197
2007-12-11 15:44:01 Tim Janik <timj@imendio.com>
* buildertest.c: made unnecessarily exported symbols static.
switched g_return_if_fail() statements in tests to assertions.
special cased currently failing Widget/accesibility test to
run only for g_test_thorough(), so it doesn't break make check.
some coding style fixes.
* Makefile.am: added buildertest to TEST_PROGS.
svn path=/trunk/; revision=19157
2007-12-06 13:38:36 Tim Janik <timj@imendio.com>
* tests/floatingtest.c: ported to new testing framework.
* tests/Makefile.am: run floatingtest as testing framework test.
svn path=/trunk/; revision=19118
2007-12-06 10:44:52 Tim Janik <timj@imendio.com>
* tests/autotestfilechooser.c: majorly speed up execution by reducing
timeouts and converting main loop sleeps to pending/iterate loops with
very low priority async handlers. eliminate output for non-verbose
tests. assert successfull subtests in all test functions. use testing
framework in main().
* tests/Makefile.am: add autotestfilechooser to TEST_PROGS, so it's
executed inside Xvfb upon make check.
svn path=/trunk/; revision=19117
2007-12-06 08:23:38 Tim Janik <timj@imendio.com>
* tests/objecttests.c: use string comparisons for string property
values and get rid of referencing symbols in array initialization.
svn path=/trunk/; revision=19116
2007-12-05 18:59:59 Tim Janik <timj@imendio.com>
* gtk+/Makefile.decl: run tests in current dir after setting up the
logging directory, so their results get properly merged into the
resulting test log.
* gtk+/gtk/gtktestutils.[hc]: added gtk_test_list_all_types() for
tests to loop over registered Gdk/Gtk+ types.
* gtk+/tests/objecttests.c: new test program, implements automated
property tests. several properties are blacklisted because they
seem to trigger Gdk/Gtk+ bugs. ./objecttests -m thorough --verbose
can be used to test blacklisted properties and see which proprty failed.
svn path=/trunk/; revision=19115
2007-10-24 Johan Dahlin <jdahlin@async.com.br>
* gtk/gtkbuilderparser.c (end_element): Allow empty property nodes
so we can set empty strings. (#486420, Xavier Claessens)
svn path=/trunk/; revision=18943
2007-10-16 Matthias Clasen <mclasen@redhat.com>
* tests/testxinerama.c: Change testcase to not update
screen information on configure-event, since it hides
information for all available screens but add a button
to query current monitor instead (#485437, Frederic Crozat)
svn path=/trunk/; revision=18913
2007-07-23 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchooserdefault.c: Port the GtkRecentChooser default
implementation widget to the new tooltips API, and make it look
like the GtkFileChooser widget in recent files mode (move the
full path from the widget to a tooltip on the row) to improve
consistency.
* gtk/gtkrecentchoosermenu.c: Port the GtkRecentChooserMenu widget
to the new tooltips API.
* tests/testrecentchooser.c:
* tests/testrecentchoosermenu.c: Exercise the tooltips code paths.
svn path=/trunk/; revision=18526
2007-07-20 Matthias Clasen <mclasen@redhat.com>
Apply a patch by Emmanuele Bassi to limit the number
of shown recent files. (#439715)
* gtk/gtksettings.c: Add a setting for the number
of recent files to display by default.
* gtk/gtkrecentchooserdefault.c:
* gtk/gtkfilechooserdefault.c: Respect the limit.
* gtk/gtkrecentmanager.c: Remove the poll timeout in
dispose, and do not stat more often than every 5 seconds.
* gtk/gtkrecentchooserutils.c:
* gtk/gtkrecentchoosermenu.c: Cleanups
* tests/testrecentchoosermenu.c: Test limits.
svn path=/trunk/; revision=18510
2007-07-19 Kristian Rietveld <kris@imendio.com>
* gtk/gtk.symbols:
* gtk/gtktreeprivate.h:
* gtk/gtktreeview.[ch] (gtk_tree_view_get_tooltip_context),
(gtk_tree_view_[sg]et_tooltip_column): add more convenience API.
* tests/testtooltip.c (query_tooltip_tree_view_cb): use
gtk_tree_view_get_tooltip_context().
* demos/gtk-demo/demo.ui: add a tooltip column to the list store,
set tooltip-column on the tree view.
svn path=/trunk/; revision=18496
2007-07-13 Kristian Rietveld <kris@imendio.com>
#408327, improve tooltip positioning.
* gtk/gtk.symbols: updated.
* gtk/gtktooltip.[ch] (gtk_tooltip_position): factor out
positioning code in here,
(gtk_tooltip_set_tip_area): new function to set the tooltip
area,
(gtk_tooltip_reset), (_gtk_tooltip_handle_event): hide tooltip
once the pointer leaves the tip area.
* gtk/gtktreeview.[ch] (gtk_tree_view_set_tooltip_row),
(gtk_tree_view_set_tooltip_cell): convenience functions to set
tip area for row/column/cell.
* tests/testtooltips.c (query_tooltip_tree_view_cb): use
gtk_tree_view_set_tooltip_row.
svn path=/trunk/; revision=18464
2007-07-09 Kristian Rietveld <kris@imendio.com>
Replace non-deprecated API using old tooltips API, deprecate
old tooltips API for real. (#451575).
* gtk/gtk.symbols: updated.
* gtk/gtkwidget.c (gtk_widget_real_show_help): don't call
_gtk_tooltips_toggle_keyboard_mode() anymore.
* gtk/gtkmenutoolbutton.[ch] (gtk_menu_tool_button_set_arrow_tooltip):
deprecated,
(gtk_menu_tool_button_set_arrow_tooltip_{text,markup}): replacements.
* gtk/gtktoolitem.[ch] (gtk_tool_item_real_set_tooltip): use
new API,
(gtk_tool_item_set_tooltip): deprecated,
(gtk_tool_item_set_tooltip_{text,markup): replacements.
(GtkToolItemClass:set_tooltip): deprecated.
* gtk/gtktooltips.[ch]: strip out all unused parts, made
gtk_tooltips_set_tip() call gtk_widget_set_tooltip_text(),
deprecate all of gtk_tooltips_*.
* gtk/gtktoolbar.[ch] (gtk_toolbar_get_tooltips): always return
TRUE,
(GtkToolbar:tooltips): deprecated, renamed.
* gtk/gtkaction.c (gtk_action_sync_tooltip): use new API to
set the tooltip text.
* tests/autotestfilechooser.c: #undef GTK_DISABLE_DEPRECATED for now,
will be removed GtkFileChooserDefault has been converted.
svn path=/trunk/; revision=18418
2007-07-08 Johan Dahlin <jdahlin@async.com.br>
* gtk/gtkwidget.c (gtk_widget_buildable_custom_tag_start):
Parse <accessibility> but don't do anything yet.
* gtk/gtk-builder-convert (GtkBuilderConverter._parse):
Do not strip atk/accessibility tags
* tests/buildertest.c (test_widget):
Test this
svn path=/trunk/; revision=18399
2007-06-30 Johan Dahlin <jdahlin@async.com.br>
* gtk/gtkbuilderparser.c: (_get_type_by_symbol), (parse_object),
(parse_child):
* tests/buildertest.c: (test_types):
Move type-func to <object> instead of <child>, add a test to
make sure that it works as desired, #452463
svn path=/trunk/; revision=18306
2007-06-29 Ryan Lortie <desrt@desrt.ca>
* tests/testgtk.c (create_composited_window): Connect the "destroy"
signal so that the 'window' pointer is set back to NULL (like for the
other examples).
* gdk/x11/gdkwindow-x11.c (gdk_window_impl_x11_finalize): Don't
destroy the Damage here. By finalize() XDestroyWindow has already
been called (and took the Damage with it).
Bug #452046.
svn path=/trunk/; revision=18290
* gtk/gtkbuilder.h (enum):
* gtk/gtkbuilderparser.c (end_element):
* tests/buildertest.c (test_parser):
Set an error if we encounter properties without values set
(#451303, Philip Withnall)
svn path=/trunk/; revision=18252
* gtk/gtkbuilder.c: (gtk_builder_value_from_string_type): Fix a
bunch of small bugs when parsing property values
(boolean/int/uint/long/ulong/float/double). Bug #451353.
* tests/buildertest.c: Add tests for the above.
svn path=/trunk/; revision=18250
2007-06-22 Mathias Hasselmann <mathias.hasselmann@gmx.de>
* configure.in, tests/Makefile.am, tests/autotestkeywords.cc,
tests/dummy-headers/*: Extend the C++ keyword test
to include internal GDK headers (#449016).
svn path=/trunk/; revision=18244
2007-06-26 Mathias Hasselmann <mathias.hasselmann@gmx.de>
* ChangeLog, configure.in, tests/Makefile.am,
tests/autotestkeywords.cc: Create test for finding
C++ keywords in public header files (#449016).
svn path=/trunk/; revision=18243
Fri Jun 22 12:13:39 2007 Tim Janik <timj@imendio.com>
* gtk/gtkframe.c (gtk_frame_paint): applied patch from Xan Lopez
to eliminate gap in painted frame for yaling=0.0 or yalign=1.0.
* tests/testframe.c: added test application from Xan Lopez to
test xalign/yalign interactions with xthickness/ythickness.
svn path=/trunk/; revision=18216
2007-06-15 Mathias Hasselmann <mathias.hasselmann@gmx.de>
* docs/reference/gtk/gtk-sections.txt, gtk/gtk.symbols,
gtk/gtkwidget.c, gtk/gtkwidget.h, tests/testtooltips.c: Introduce
convenience property "GtkWidget:tooltip-text" taking care of escaping
it for unwanted markup entities. Add functions to set tooltip text:
gtk_widget_set_tooltip_text(), gtk_widget_set_tooltip_markup(),
gtk_widget_get_tooltip_text(), gtk_widget_get_tooltip_markup().
* gtk/gtktooltip.c, gtk/gtktooltip.h: Add gtk_tooltip_set_text()
to set the tooltip text without using markup.
Patches from Emmanuele Bassi (#447643).
svn path=/trunk/; revision=18142
2007-06-15 Hans Breuer <hans@breuer.org>
* gtk/makefile.msc.in tests/makefile.msc : updated
* gdk/win32/gdkwindow-win32.c : explicit usage of RegisterClassExW
to match the WNDCLASSEXW.
True dynamic linking of SetLayeredWindowAttributes
* tests/testprint.c tests/testnouiprint.c : use G_PI
svn path=/trunk/; revision=18140
2007-06-13 Kristian Rietveld <kris@imendio.com>
Audit of GtkTreeView coordinate system usage. (#142494).
* gtk/gtktreeview.[ch]: general documentation updates,
(gtk_tree_view_scroll_to_cell), (gtk_tree_view_get_dest_row_at_pos):
update coordinate translations,
(gtk_tree_view_tree_to_widget_coords),
(gtk_tree_view_widget_to_tree_coords): Deprecated,
(gtk_tree_view_convert_.*_coords): 6 new functions for doing
transformations between coordinate systems.
* gtk/gtk.symbols: updated.
* tests/testtooltips.c (query_tooltip_tree_view_cb): fix testcase
with new gtk_tree_view_convert_widget_to_bin_window_coords().
* docs/reference/gtk/Makefile.am
* docs/reference/gtk/images/tree-view-coordinates.png: add new image.
* docs/reference/gtk/tmpl/gtktreeview.sgml: eloborate on the
different coordinate systems.
svn path=/trunk/; revision=18119
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.
svn path=/trunk/; revision=18019
2007-05-25 Matthias Clasen <mclasen@redhat.com>
Allow to separate GtkTextMark creation from buffer insertion.
(#132818, Gustavo Giráldez, patch by Yevgen Muntyan)
* gtk/gtktextmarkprivate.h:
* gtk/gtktextmark.[hc] (gtk_text_mark_new): New function to
create a GtkTextMark.
* gtk/gtktextbuffer.[hc] (gtk_text_buffer_add_mark): New
function to add an existing mark to a buffer.
* gtk/gtktextbtree.c: Allow adding existing marks.
* gtk/gtk.symbols: Add new functions.
* tests/testtextbuffer.c: Add some tests for new mark
functionality.
svn path=/trunk/; revision=17922
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 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
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-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>
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/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-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-03-21 Rodney Dawes <dobey@novell.com>
* gtk/gtk.symbols:
* gtk/gtkicontheme.[ch]:
* docs/reference/gtk/gtk-sections.txt:
* tests/testicontheme.c:
Add a new API call gtk_icon_theme_list_contexts so that one can
choose icons from a theme by context (#420719)
svn path=/trunk/; revision=17550
2007-03-15 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkaction.[ch]: Add GtkActionClass::get_submenu() vfunc:
actions providing a menu item or a menu tool button with already
a submenu should return the GtkMenu widget.
* gtk/gtkuimanager.c (update_node): If an action provides its
own submenu, use it instead of adding an empty one
* gtk/gtkrecentaction.[ch]: Add GtkRecentAction, an action
implementing the GtkRecentChooser interface for displaying the
list of recently used files into menus and toolbars generated
using GtkUIManager. (#338843)
* gtk/Makefile.am:
* gtk/gtk.h:
* gtk/gtk.symbols: Add GtkRecentAction API to the build.
* tests/testactions.c: Exercise the GtkRecentAction API.
svn path=/trunk/; revision=17524
2007-03-15 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchooserprivate.h:
* gtk/gtkrecentchooserutils.c: Move filtering of the recent
files list into the shared implementation; do the filtering
before the sorting, so that we always clamp on the desired
size. (#418219)
* gtk/gtkrecentchoosermenu.c: Remove the filtering of the
list, as it's already been done.
* gtk/gtkrecentchooserdefault.c: Ditto; also remove the
GtkTreeModelFilter: just reload the view if the sorting and
filtering properties change.
* gtk/testrecentchoosermenu.c: Exercise the limit property.
svn path=/trunk/; revision=17516
2007-02-09 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchoosermenu.c: Add support for both prepending
and appending custom menu items.
(gtk_recent_chooser_menu_constructor): Add a placeholder menu
item for the empty menu case, and for giving us a starting
point for the recent items populating process.
(gtk_recent_chooser_menu_insert_item),
(gtk_recent_chooser_menu_dispose_items): Insert an item at
the position following the placeholder (and find that position
if needed).
(idle_populate_func), (idle_populate_clean_up): Show the
placeholder menu item, instead of creating one each time.
(gtk_recent_chooser_menu_populate): Kill some indirections
and hide the placeholder before populating the menu.
(set_recent_manager): Remember to remove the idle population
source if the manager changes.
* tests/testrecentchoosermenu.c: Test the appending and
prepending of the menu items to the recent chooser menu
widget.
svn path=/trunk/; revision=17281
2007-02-08 Emmanuele Bassi <ebassi@gnome.org>
* gtk/gtkrecentchoosermenu.c (idle_populate_func): Keep count
of the displayed items to build the menu items mnemonic instead
of the overall item count. (#377164)
(idle_populate_clean_up): Append a menu item if all the items
got filtered in the idle populate function. (#405696)
svn path=/trunk/; revision=17277
Thu Feb 8 13:07:08 2007 Tim Janik <timj@imendio.com>
* applied patch from Xan Lopez which adds GTK_BUTTONBOX_CENTER to
GtkButtonBox (bug #336159).
* gtk/gtkenums.h:
* gtk/gtkvbbox.c, gtk/gtkhbbox.c, gtk/gtkbbox.c:
support GTK_BUTTONBOX_CENTER.
* tests/testbbox.c: new button box test, which allows testing of
the various button box properties.
* tests/testgtk.c: added GTK_BUTTONBOX_CENTER. to button box test.
svn path=/trunk/; revision=17276
2007-02-06 Kristian Rietveld <kris@imendio.com>
* gtk/gtktooltip.c (find_topmost_widget_coords_from_event):
remove unused get of has_tooltip.
* tests/testtooltips.c (query_tooltip_tree_view_cb): use the
portable g_snprintf instead of snprintf.
svn path=/trunk/; revision=17266
2007-02-06 Kristian Rietveld <kris@imendio.com>
New tooltips API.
* gtk/Makefile.am
* gtk/gtk.h
* gtk/gtk.symbols: build system foo.
* gtk/gtkmain.c (gtk_main_do_event): call tooltip event handler
hook for appropriate events.
* gtk/gtkmarshalers.list: add BOOLEAN:INT,INT,BOOLEAN,OBJECT.
* gtk/gtkrc.c: add style for gtk-tooltip.
* gtk/gtksettings.c (gtk_settings_class_init): make the
different tooltip timeouts configurable.
* gtk/gtkwidget.[ch]: add new properties, signals, make sure
tooltips are hidden on unmap, destroy, update window event
mask on realize, hook into focus change and show help
handlers.
* gtk/gtkwindow.h: move GtkWindow typdef to gtkwidget.h ...
* gtk/gtktooltip.[ch]: new files.
* tests/Makefile.am
* tests/testtooltips.c: add test application.
svn path=/trunk/; revision=17264
2007-01-27 Matthias Clasen <mclasen@redhat.com>
* gtk/gtkstatusicon.c:
* gtk/gtktrayicon-x11.c: Fix GtkStatusIcon to not
take up space on the panel if it is invisible. (340110, Christian
Persch)
* tests/teststatusicon.c:
* tests/Makefile.am: Updates
svn path=/trunk/; revision=17224
2006-12-22 Matthias Clasen <mclasen@redhat.com>
Make it possible to track the embeddedness of
statusicon (#387215, Martyn Russell, patch by Christian
Persch)
* gtk/gtkstatusicon.c: Add orientation and embedded properties.
* gtk/gtkplug.c:
* gtk/gtkplug-x11.c: Add an embedded property.
* tests/teststatusicon.c: Test the new properties.
2006-11-19 Mark McLoughlin <mark@skynet.ie>
Fixes bug #376502 - multi-screen support for GtkStatusIcon
* gtk/gtkstatusicon.[ch]:
(gtk_status_icon_set_screen),
(gtk_status_icon_get_screen): add multi-screen API. Allows
an app to display an icon on a non-default screen
(gtk_status_icon_class_init),
(gtk_status_icon_set_property),
(gtk_status_icon_get_property): add a "screen" property
* tests/teststatusicon.c: update to test on multiple screens
2006-10-18 Kristian Rietveld <kris@imendio.com>
* tests/testcombo.c (main): connect to notify::popup-shown instead of
popup-show (the latter does not exist).
Tue Sep 19 17:00:04 2006 Tim Janik <timj@imendio.com>
* gtk/gtkarrow.c: added GtkArrow::arrow-scaling style property to
control the arrow/border ratio within the allocation.
* tests/testgtk.c: added a GtkArrow to handle box test.
* tests/testgtkrc: test ::arrow-scaling property.
Thu Sep 14 12:28:51 2006 Tim Janik <timj@imendio.com>
* tests/testrichtext.c (main): intialize random number generator state
upon program start, to enable truely random testing.
2006-09-03 Kristian Rietveld <kris@imendio.com>
* gtk/gtkfilechooserdefault.c (save_entry_get_info_cb),
(file_exists_get_info_cb), (gtk_file_chooser_default_should_respond):
change file_exists_and_is_not_folder checks to get the file info
for the path directly instead of querying the current file folder
of the save entry.
* gtk/gtkfilechooserprivate.h (struct _GtkFileChooserDefault): add
new field.
* tests/autotestfilechooser.c (wait_for_idle_idle), (wait_for_idle),
(test_reload_sequence), (test_button_folder_states_for_action): wait
for idle after setting a folder to ensure the async operations to load
the folder are finished,
(test_confirm_overwrite), (test_confirm_overwrite_for_path):
factor out test_confirm_overwrite code so we can add tests for more
paths more easily.
Tue Aug 29 11:57:40 2006 Tim Janik <timj@imendio.com>
* tests/testgtk.c: allow (most) windows to be resizable.
added ellipsization settings to progress bars.
2006-08-28 Michael Natterer <mitch@imendio.com>
* gtk/gtktextbufferserialize.c (serialize_text): don't write out
</apply_tag> for tags that have already been closed by the logic
which turns overlapping spans into XML-able trees. Fixes broken
XML when there are overlapping tags in the buffer. Also free two
leaked GLists and did some cleanup.
* tests/Makefile.am
* tests/testrichtext.c: new test which creates randomly tagged
GtkTextBuffers and serializes/deserializes them.
2006-08-23 Federico Mena Quintero <federico@novell.com>
* gtk/gtkfilesystem.[ch] (_gtk_file_system_create): Renamed to
gtk_file_system_create() so that it will get exported and we can
use it in the test program.
* gtk/gtk.symbols: Added gtk_file_system_create.
* gtk/gtkfilechooserdefault.c (set_file_system_backend): Use
gtk_file_system_create().
* tests/autotestfilesystem.c: New file with automatic tests for
the async callbacks and cancelation policy of GtkFileSystem.
* tests/Makefile.am: Added autotestfilesystem.
2006-08-17 Federico Mena Quintero <federico@novell.com>
* gtk/gtkfilechooserdefault.c
(_gtk_file_chooser_default_class_init): Enable "/" and "~" as
bindings to activate the location entry again. Fixes bug #340856.
(tree_view_keybinding_cb): Likewise.
(trap_activate_cb): Likewise.
(location_popup_handler): Handle the "path" argument again; set it
as the text on the location entry.
(location_set_user_text): New helper function.
(load_setup_timer): Fix comment.
* tests/autotestfilechooser.c (main): Oops, enable all the tests again.
2006-08-17 Paolo Borelli <pborelli@katamail.com>
* gtk/gtktextbuffer.c: make sure the has-selection property is
updated when the delection is deleted. Bug #329752
* tests/testtext.c: add a copy menu item and show how to
update its sensitivity tracking the has-selection property.
2006-08-06 Matthias Clasen <mclasen@redhat.com>
* gtk/gtknotebook.c (gtk_notebook_drag_motion): Don't allow
dragging a notebook tab to one of its children. (#348626,
Benjamin Otte)
2006-07-19 Federico Mena Quintero <federico@novell.com>
* tests/autotestfilechooser.c (test_black_box): Argh, initialize
"passed"!
(set_filename_timeout_cb): Renamed from timeout_cb().
(test_confirm_overwrite): New function, test confirmation before
overwriting a file in SAVE mode.
2006-07-18 Federico Mena Quintero <federico@novell.com>
Fix https://bugzilla.novell.com/show_bug.cgi?id=184875 - make the
location entry in Save mode preserve the stuff from
set_filename(); it was overwriting it with $cwd.
This is the same fix for
http://bugzilla.gnome.org/show_bug.cgi?id=347066
* tests/autotestfilechooser.c: (test_black_box): Added black-box
test for set_filename() and set_current_name().
* gtk/gtkfilechooser.c (gtk_file_chooser_get_type): Cast to
GClassInitFunc in the call to g_type_register_static_simple(), to
avoid a compiler warning.
* gtk/gtkfilechooserprivate.h (struct _GtkFileChooserDefault):
Added a browse_files_last_selected_name field. We'll copy the
logic from gtkfilesel.c to see when to clear the location entry.
(struct _GtkFileChooserDefault): Removed the
processing_pending_selections field.
* gtk/gtkfilechooserdefault.c (gtk_file_chooser_default_finalize):
Free impl->browse_files_last_selected_name.
(pending_select_paths_process): Don't use
impl->processing_pending_selections.
(update_chooser_entry): Keep track of the name that was last
selected in the file list. We use this to know when to clear the
location entry. The logic is similar to that of
gtkfilesel.c:gtk_file_selection_file_changed(). This also lets us
get rid of the processing_pending_selections flag.
(update_chooser_entry): Clear the entry if we didn't have a
selection before.
(location_switch_to_filename_entry): Do not set $cwd as the
contents of the location entry here...
(location_popup_handler): ... but do it here instead, only as the
result of the user asking to turn on the location entry.
(gtk_file_chooser_default_get_paths): If the location entry is
empty, do the fallback of seeing if it is sensible to say that
$cwd is the selected path.
(gtk_file_chooser_default_update_current_folder): Don't set the
text of the location entry; this is no longer needed with the
fixes above.
(shortcuts_activate_iter): Clear the location entry when
activating a shortcut if we are not in SAVE mode. This keeps the
contents of the location entry consistent even when switching
folders via the shortcuts.
2006-06-18 Matthias Clasen <mclasen@redhat.com>
* tests/testnouiprint.c (main): Don't open a display connection.
* gtk/gtkprintbackend.c (gtk_print_backend_load_modules): Make
this work without a display connection. (339702, Alexander Larsson)