1. 11 Oct, 2003 6 commits
    • Matthias Clasen's avatar
      Move GET_PRIVATE macros from header to implementation. · 9119557b
      Matthias Clasen authored
      Sun Oct 12 01:10:29 2003  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkalignment.[hc]:
      	* gtk/gtkcombobox.[hc]:
      	* gtk/gtkcomboboxentry.[hc]:
      	* gtk/gtktreemodelfilter.[hc]: Move GET_PRIVATE macros
      	from header to implementation.
      9119557b
    • Matthias Clasen's avatar
      Add G_BEGIN_DECLS/G_END_DECLS to make these usable in C++. (#124351, · c44e5b00
      Matthias Clasen authored
      Sat Oct 11 23:14:36 2003  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkactiongroup.h:
      	* gtk/gtkaction.h:
      	* gtk/gtkradioaction.h:
      	* gtk/gtkradiotoolbutton.h:
      	* gtk/gtkseparatortoolitem.h:
      	* gtk/gtktoggleaction.h:
      	* gtk/gtktoolitem.h:
      	* gtk/gtkuimanager.h: Add G_BEGIN_DECLS/G_END_DECLS to make
      	these usable in C++.  (#124351, Murray Cumming)
      c44e5b00
    • Kristian Rietveld's avatar
      Check if completion is non-NULL before accessing it. Oops. · 407e957c
      Kristian Rietveld authored
      Sat Oct 11 19:09:05 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkentry.c (gtk_entry_set_text): Check if completion is
      	non-NULL before accessing it. Oops.
      407e957c
    • Kristian Rietveld's avatar
      the gchar* parameters should be const (pointed out by both Marco Pesenti · 761a6745
      Kristian Rietveld authored
      Sat Oct 11 15:47:03 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkentrycompletion.[ch] (gtk_entry_completion_insert_action),
      	(gtk_entry_completion_insert_action_text),
      	(gtk_entry_completion_insert_action_markup): the gchar* parameters
      	should be const (pointed out by both Marco Pesenti Gritti and
      	Murray Cumming (#124356).
      761a6745
    • Kristian Rietveld's avatar
      for the custom child list mode, allocate the height allocation->height to · d75b1a1a
      Kristian Rietveld authored
      Sat Oct 11 15:37:19 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombobox.c (gtk_combo_box_size_allocate): for the custom
      	child list mode, allocate the height allocation->height to the
      	button instead of the height requested by the button. (Tiny
      	size allocation screwup noticed by Macro Pesenti Gritti).
      d75b1a1a
    • Kristian Rietveld's avatar
      Fixes based on comments from Marco Pesenti Gritti. · c3841e70
      Kristian Rietveld authored
      Sat Oct 11 15:23:27 2003  Kristian Rietveld  <kris@gtk.org>
      
      	Fixes based on comments from Marco Pesenti Gritti.
      
      	* gtk/gtkentry.c (gtk_entry_set_text): block the completion changed
      	signal handler, avoids the completion popup to popup when text is
      	set programmatically in most cases (we actually have to handle this
      	in the _editable functions as well, but that will break popping up
      	when the user actually typed something :),
      	(gtk_entry_completion_key_press): when handling enter, bail out
      	when nothing has been selected,
      	(gtk_entry_completion_changed): don't popdown when the entry content
      	changed.
      
      	* gtk/gtkentrycompletion.c (gtk_entry_completion_init),
      	(gtk_entry_completion_selected_changed): unselect_all on the
      	first selected changed signal. Avoids having a default row selected,
      	(_gtk_entry_completion_popup): don't select the first row by default.
      
      	* gtk/gtkentryprivate.h (struct _GtkEntryCompletionPrivate): add a
      	first_sel_changed field.
      c3841e70
  2. 10 Oct, 2003 2 commits
    • Matthias Clasen's avatar
      Fixes for (#124212, Marco Pesenti Gritti): · e8bcc9af
      Matthias Clasen authored
      Fri Oct 10 22:50:05 2003  Matthias Clasen  <maclas@gmx.de>
      
      	Fixes for (#124212, Marco Pesenti Gritti):
      
      	* gtk/gtkuimanager.c (update_smart_separators): Don't spit
      	warnings for popups.
      	(_gtk_menu_is_empty): Return FALSE for non-menus.
      e8bcc9af
    • Kristian Rietveld's avatar
      Deprecate. Ditto. · e6100ecd
      Kristian Rietveld authored
      Fri Oct 10 19:10:12 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombo.h: Deprecate.
      	* gtk/gtkoptionmenu.h: Ditto.
      
      	* gtk/gtkcombobox.c (gtk_combo_box_size_request),
      	(gtk_combo_box_size_allocate): Rework, things behave better now. Still
      	needs some work on requesting enough size when taking the items in
      	the list into account.
      
      	* gtk/gtkfilesel.c: put gtkoptionmenu.h include inside "enable
      	deprecated" guards.
      	* gtk/gtkinputdialog.c: ditto.
      	* gtk/gtkitemfactory.c: ditto.
      	* gtk/gtkoptionmenu.c: ditto.
      
      	* demos/gtk-demo/menus.c: remove the option menu.
      	* demos/gtk-demo/sizegroup.c: replace the option menus with
      	GtkComboBox.
      	* demos/gtk-demo/textview.c: ditto.
      	(A general GtkComboBox demo will be added later on).
      e6100ecd
  3. 09 Oct, 2003 2 commits
    • Federico Mena Quintero's avatar
      7d9c4f6e
    • Federico Mena Quintero's avatar
      Autosize the columns after the model is set. (shortcuts_append_path): Add · 3415416b
      Federico Mena Quintero authored
      2003-10-08  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilechooserimpldefault.c (tree_selection_changed): Autosize
      	the columns after the model is set.
      	(shortcuts_append_path): Add optional indentation to items.
      	(shortcuts_append_bookmarks): Indent bookmark items.
      	(create_shortcuts_tree): Set the "xpad" attribute of the name
      	renderer to be fetched from the indent column.
      	(shortcuts_append_bookmarks): Use NULL for the name of the
      	bookmarks node, so that a separator gets drawn.
      	(create_shortcuts_tree): Create a GtkCellRendererSepText.
      
      	* gtkcellrendererseptext.[ch]: New files with a cell renderer that
      	can display text or a separator line.
      
      	* Makefile.am (libgtkfilechooser_la_SOURCES): Added
      	gtkcellrendererseptext.[ch].
      3415416b
  4. 08 Oct, 2003 1 commit
    • Federico Mena Quintero's avatar
      Added methods for ::get_supports_bookmarks(), ::set_bookmarks(), · 462aab4a
      Federico Mena Quintero authored
      2003-10-07  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilesystem.h (struct _GtkFileSystemIface): Added methods for
      	::get_supports_bookmarks(), ::set_bookmarks(), ::list_bookmarks().
      	Added a ::bookmarks_changed() signal.
      
      	* gtkfilesystem.c (gtk_file_system_get_supports_bookmarks): New function.
      	(gtk_file_system_set_bookmarks): New function.
      	(gtk_file_system_list_bookmarks): New function.
      	(gtk_file_system_base_init): Create the "bookmarks-changed" signal.
      	(gtk_file_paths_copy): New function.
      
      	* gtkfilesystemunix.c (gtk_file_system_unix_get_supports_bookmarks): Implement.
      	(gtk_file_system_unix_set_bookmarks): Implement.
      	(gtk_file_system_unix_get_bookmarks): Implement.
      
      	* gtkfilesystemgnomevfs.c (struct _GtkFileSystemGnomeVFS): Added
      	fields for the bookmarks and the GConfClient.
      	(gtk_file_system_gnome_vfs_set_bookmarks): Implement.
      	(gtk_file_system_gnome_vfs_list_bookmarks): Implement.
      
      	* gtkfilechooserprivate.h (struct _GtkFileChooserIface): Added
      	methods for ::set_shortcut_folders(), ::list_shortcut_folders().
      
      	* gtkfilechooser.c (gtk_file_chooser_set_shortcut_folders): New
      	function.
      	(gtk_file_chooser_list_shortcut_folders): New function.
      
      	* gtkfilechooserimpldefault.c (create_shortcuts_model): Unref the
      	old shortcuts model if it exists.  Create the nodes for the
      	app-specific shortcut folders.
      	(struct _GtkFileChooserImplDefault): Added a field for the
      	shortcut_folders.
      	(gtk_file_chooser_impl_default_set_shortcut_folders): Implement.
      	(select_shortcuts_folder): New helper function.
      	(gtk_file_chooser_impl_default_set_current_folder): Use
      	select_shortcuts_folder().
      	(shortcuts_append_path): Get the file info here, instead of the
      	caller.
      	(shortcuts_append_home): Use shortcuts_append_path().
      	(shortcuts_append_file_system_roots): Likewise.
      	(create_shortcuts_model): Add the app-specific shortcut folders
      	and the bookmarks.
      	(gtk_file_chooser_impl_default_list_shortcut_folders): Implement.
      	(create_shortcuts_tree): Added a button to let the user add the
      	current folder to the bookmarks.
      	(gtk_file_chooser_impl_default_set_property): Connect to
      	"bookmarks-changed" on the file system.
      	(shortcuts_append_bookmarks): New function.
      
      	* configure.ac: Depend on GConf.
      462aab4a
  5. 07 Oct, 2003 2 commits
  6. 06 Oct, 2003 1 commit
  7. 05 Oct, 2003 1 commit
  8. 04 Oct, 2003 1 commit
  9. 03 Oct, 2003 1 commit
    • Kristian Rietveld's avatar
      only set the model on ->priv->cell_view if ->priv->cell_view is non-NULL. · 7fc054e9
      Kristian Rietveld authored
      Fri Oct  3 20:50:48 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombobox.c (gtk_combo_box_set_model): only set the model
      	on ->priv->cell_view if ->priv->cell_view is non-NULL.
      
      	* gtk/gtkcomboboxentry.c: include gtkintl.h, add text_renderer
      	field to GtkComboBoxEntryPrivate,
      	(gtk_combo_box_entry_class_init), (gtk_combo_box_entry_init),
      	(gtk_combo_box_entry_set_property), (gtk_combo_box_entry_get_property),
      	(gtk_combo_box_entry_set_text_column), (gtk_combo_box_entry_new): add
      	a construct-only "text_column" property and reorder code to use it
      	and support inheriting this widget.
      7fc054e9
  10. 02 Oct, 2003 1 commit
    • Kristian Rietveld's avatar
      Added API doc comments. · 316109ea
      Kristian Rietveld authored
      Thu Oct  2 23:28:02 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombobox.c: Added API doc comments.
      
      	* gtk/gtkcomboboxentry.c: Ditto.
      316109ea
  11. 01 Oct, 2003 7 commits
    • Matthias Clasen's avatar
      Doc tweaks- · 186f883d
      Matthias Clasen authored
      186f883d
    • Federico Mena Quintero's avatar
      Simplify with a macro. This bloats the compiled code, but at least it · feb412c1
      Federico Mena Quintero authored
      2003-10-01  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilechooserimpldefault.c (name_sort_func): Simplify with a
      	macro.  This bloats the compiled code, but at least it makes the
      	human-readable code not egregiously ugly.
      	(size_sort_func): Likewise.
      	(mtime_sort_func): Likewise.
      feb412c1
    • Kristian Rietveld's avatar
      implement the GtkCellLayout interface, drop packing/attribute/cell data · 40743e12
      Kristian Rietveld authored
      Wed Oct  1 22:43:40 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcellview.[ch]: implement the GtkCellLayout interface, drop
      	packing/attribute/cell data functions from the header,
      	(gtk_cell_view_set_cell_data): added support for cell data funcs.
      
      	* gtk/gtkcombobox.[ch]: implement the GtkCellLayout interface, drop
      	packing/attribute/cell data functions from the header, implemented
      	cell data func support.
      
      	* gtk/gtkcomboboxentry.c (gtk_combo_box_entry_new): updated
      	for the move to GtkCellLayout.
      
      	* tests/testcombo.c (create_combo_box_grid_demo), (main): ditto.
      40743e12
    • Federico Mena Quintero's avatar
      Use enum values instead of plain numbers for the file lists's sort · da293525
      Federico Mena Quintero authored
      2003-10-01  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilechooserimpldefault.c (tree_selection_changed): Use enum
      	values instead of plain numbers for the file lists's sort columns.
      	(create_file_list): Likewise.
      	(tree_selection_changed): Make the file list start up sorted by
      	name, and don't specify a default sorting function, so that there
      	is no unsorted order.  This is for consistency with Nautilus.
      	(list_sort_column_changed_cb): Callback; we cache whether the sort
      	order for the file list's name column is ascending or not.
      	(compare_with_folders_first): New helper function to sort
      	directories before files.
      	(name_sort_func): Use compare_with_folders_first().
      	(size_sort_func): Likewise.
      	(mtime_sort_func): Likewise.
      
      	Of course this callback mess would be easy in a real language:
      
      	  (set-sort-func sortable NAME_COLUMN
      	    (make-comparer impl (lambda (a b) (strcmp (get-name a) (get-name b)))))
      	  (set-sort-func sortable SIZE_COLUMN
      	    (make-comparer impl (lambda (a b) (compare (get-size a) (get-size b)))))
      	  ... etc ...
      
      	  (define (make-comparer impl f)
      	    (lambda (a b)
      	      (if (eq (is-dir? a) (is-dir? b))
      	          (f a b)
      		  (if (sort-ascending? impl)
      		      (if (is-dir? a) -1 1)
      		      (if (is-dir? a) 1 -1)))))
      da293525
    • Matthias Clasen's avatar
      Introduce a separate "hide_if_empty" property for empty menu handling. · 6e87629f
      Matthias Clasen authored
      2003-10-01  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkaction.c (gtk_action_class_init):
      	(gtk_action_[gs]et_property): Introduce a separate
      	"hide_if_empty" property for empty menu handling.
      	(_gtk_action_sync_menu_visible): ...and use it here.
      
      	* tests/testmerge.c (main): ...and here.
      6e87629f
    • Federico Mena Quintero's avatar
      Added fields for the shortcuts tree and its model. (create_file_list): · 39e208d8
      Federico Mena Quintero authored
      2003-09-30  Federico Mena Quintero  <federico@ximian.com>
      
      	* gtkfilechooserimpldefault.c (struct _GtkFileChooserImplDefault):
      	Added fields for the shortcuts tree and its model.
      	(create_file_list): Don't call
      	gtk_tree_view_column_set_sort_column_id() twice.
      	(create_shortcuts_model): New function.
      	(list_icon_data_func): Use an ICON_SIZE macro instead of a
      	hardcoded value.
      	(list_row_activated): Use _gtk_file_chooser_set_current_folder_path()
      	to avoid converting the GtkFilePath to a URI string.
      	(gtk_file_chooser_impl_default_set_current_folder): Select the
      	appropriate item from the shortcuts list when the current folder
      	changes, to let the user know where he is.
      	(tree_selection_changed): Likewise.
      
      	* gtkfilesystem.h (struct _GtkFileSystemIface): Added methods for
      	::supports_shortcuts(), ::list_shortcuts(), ::set_shortcuts().
      39e208d8
    • Matthias Clasen's avatar
      Fix signal doc comments to pacify gtk-doc. · e8ea4808
      Matthias Clasen authored
      	* gtk/gtktoolitem.c (gtk_tool_item_class_init): Fix signal doc
      	comments to pacify gtk-doc.
      e8ea4808
  12. 30 Sep, 2003 8 commits
    • Matthias Clasen's avatar
      Doc formatting tweaks. · dbdc43be
      Matthias Clasen authored
      2003-10-01  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkmain.c: Doc formatting tweaks.
      
      	* gtk/gtktoolitem.c (gtk_tool_item_set_is_important): Fix a typo.
      
      	* gtk/gtkcheckmenuitem.h (gtk_check_menu_item_set_draw_as_radio):
      	Use the same parameter names as in .c file, to pacify gtk-doc.
      
      	* gtk/gtktoggletoolbutton.[hc]:
      	* gtk/gtktoolbutton.[hc]:
      	* gtk/gtktoolitem.[hc]:
      	* gtk/gtktoolbar.[hc]:
      	* gtk/gtkcolorbutton.[hc]:
      	* gtk/gtkfontbutton.[hc]:
      	* gtk/gtkalignment.[hc]: Define GET_PRIVATE macros in the
      	source, not in the header.
      
      	* gtk/gtkcheckmenuitem.c (gtk_check_menu_item_[sg]et_draw_as_radio):
      	Document these as 2.4 API additions.
      
      	* gtk/tmpl/gtkaction.sgml: Fix cross reference to GtkMenuMerge.
      
      	* gtk/gtk-sections.txt: Additions.
      
      	* gtk/tmpl/gtkitemfactory.sgml: Add hint to use #GtkUIManager instead.
      dbdc43be
    • Kristian Rietveld's avatar
      Add API doc comments. · 881df5c4
      Kristian Rietveld authored
      Tue Sep 30 23:42:56 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkentry.c (gtk_entry_set_completion),
      	(gtk_entry_get_completion): Add API doc comments.
      
      	* gtk/gtkentrycompletion.c: Fix #includes and add API doc comments.
      881df5c4
    • Kristian Rietveld's avatar
      Add "Since: 2.4" to all API doc comments. · b65b8538
      Kristian Rietveld authored
      Tue Sep 30 23:12:34 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtktreemodelfilter.c: Add "Since: 2.4" to all API doc comments.
      b65b8538
    • Kristian Rietveld's avatar
      Some API doc comment fixes. · 1c88b37f
      Kristian Rietveld authored
      Tue Sep 30 22:59:58 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtktreeviewcolumn.c: Some API doc comment fixes.
      
      	* gtk/gtkcellayout.c: Fix #include and oooooh API doc comments!
      1c88b37f
    • Matthias Clasen's avatar
      Test handling of empty menus. · 57f13d81
      Matthias Clasen authored
      2003-09-30  Matthias Clasen  <maclas@gmx.de>
      
      	* tests/merge-*.ui:
      	* tests/testmerge.c: Test handling of empty menus.
      
      	* gtk/gtkuimanager.c (_gtk_menu_is_empty): New function to determine
      	whether a menu is empty. Used in gtkaction.c.
      	(update_smart_separators): Also update the visibility of empty menus.
      	(update_node): When creating a new menu proxy, insert an "Empty" menu
      	item which only gets shown if the menu is empty.
      
      	* gtk/gtkaction.c (gtk_action_class_init): Document the meaning of
      	"is_important" for menu proxies.
      	(_gtk_action_sync_menu_visible): New function to sync the visibility
      	of menu proxies. Used in gtkuimanager.c.
      	(gtk_action_sync_visible): New function to sync the visibility of
      	proxies.
      57f13d81
    • Kristian Rietveld's avatar
      set popup_in_progress to TRUE, (gtk_combo_box_menu_show): and back to · 039c6b3b
      Kristian Rietveld authored
      Tue Sep 30 21:43:34 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombobox.c (gtk_combo_box_menu_button_press): set
      	popup_in_progress to TRUE,
      	(gtk_combo_box_menu_show): and back to FALSE here; the menu now
      	won't disappear on the first button release. (Reported by Matthias
      	Clasen).
      039c6b3b
    • Kristian Rietveld's avatar
      actually show the child. · b78ee57e
      Kristian Rietveld authored
      Tue Sep 30 21:08:43 2003  Kristian Rietveld  <kris@gtk.org>
      
      	* gtk/gtkcombobox.c (gtk_combo_box_init): actually show the child.
      
      	* gtk/gtkcomboboxentry.c (gtk_combo_box_entry_init): ditto. (#123543,
      	Marco Pesenti Gritti).
      b78ee57e
    • Murray Cumming's avatar
      The render vfunc takes a GdkDrawable* instead of a GdkWindow*, because · fa7b7509
      Murray Cumming authored
      2003-09-30  Murray Cumming  <murrayc@usa.net>
      
              * gtk/gtkcellrenderer.h: The render vfunc takes a GdkDrawable*
              instead of a GdkWindow*, because that what it is given. The
              documentation was already correct. This should cause no API/ABI
              breakage with C compilers.
              * gtk/gtkcellrenderertext.c, gtkcellrendererpixbuf.c,
              gtkcellrenderertogger.c: Updated the declarations of the render vfunc
              implementation accordingly.
      fa7b7509
  13. 27 Sep, 2003 2 commits
  14. 26 Sep, 2003 3 commits
    • Matthias Clasen's avatar
      Deprecate GtkItemFactory in favor of GtkUIManager. Just leave · 08573c08
      Matthias Clasen authored
      2003-09-27  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkitemfactory.h: Deprecate GtkItemFactory in favor
      	of GtkUIManager. Just leave GtkTranslateFunc undeprecated,
      	since GtkActionGroup uses it.
      08573c08
    • Matthias Clasen's avatar
      Demonstrate the use of the connect-proxy signal. · eeed9d18
      Matthias Clasen authored
      2003-09-27  Matthias Clasen  <maclas@gmx.de>
      
      	* tests/testmerge.c: Demonstrate the use of the
      	connect-proxy signal.
      
      	* gtk/gtkaction.c (connect_proxy): Add connect-proxy and
      	disconnect-proxy signals to do small customizations
      	like displaying tooltips in the statusbar without
      	custom actions.  (#122894, Philip Langdale)
      
      	* gtk/gtkuimanager.c (update_node): Don't leak tooltip.
      eeed9d18
    • Kristian Rietveld's avatar
      Landing the new ComboBox. Note that only gtkcombobox.h and · c920afd9
      Kristian Rietveld authored
      Fri Sep 26 23:49:44 2003  Kristian Rietveld  <kris@gtk.org>
      
      	Landing the new ComboBox. Note that only gtkcombobox.h and
      	gtkcomboboxentry.h are public.
      
      	* gtk/gtkcellview.[ch], gtk/gtkcellviewmenuitem.[ch],
      	gtk/gtkcombobox.[ch], gtk/gtkcomboboxentry.[ch]: new files.
      
      	* gtk/Makefile.am, gtk/gtk.h: adding the new files.
      
      	* tests/testcombo.c: and a new test.
      
      	* tests/Makefile.am: adding the new test.
      c920afd9
  15. 23 Sep, 2003 1 commit
    • Matthias Clasen's avatar
      Sync tooltips on toolitems. · a93cee89
      Matthias Clasen authored
      2003-09-24  Matthias Clasen  <maclas@gmx.de>
      
      	* gtk/gtkaction.c (connect_proxy): Sync tooltips on toolitems.
      
      	* gtk/gtkuimanager.c (update_node): Don't complain about missing
      	actions on popups. Re-set "tooltip" property on toolitems after
      	adding them to parent to trigger proxy update.
      a93cee89
  16. 22 Sep, 2003 1 commit
    • Matthias Clasen's avatar
      Initially activate the JUSTIFY_RIGHT group member to test the fix for · cf639f41
      Matthias Clasen authored
      2003-09-22  Matthias Clasen  <maclas@gmx.de>
      
      	* tests/testmerge.c (main): Initially activate the JUSTIFY_RIGHT
      	group member to test the fix for #122904.
      
      	* gtk/gtkactiongroup.c (gtk_action_group_add_radio_actions_full):
      	Add the action to the group before activating it, otherwise we
      	may end up with multiple active group members.  (#122904, Marco
      	Pesenti Gritti)
      cf639f41