From 32d617ce0564e5bb73d640cc24cd0f488aa13ead Mon Sep 17 00:00:00 2001 From: DongHun Kwak Date: Mon, 7 Sep 2020 00:21:00 -0700 Subject: [PATCH] Imported Upstream version 2.55.2 --- COPYING | 9 +- NEWS | 71 ++ build/dk-feature.m4 | 3 +- configure.ac | 2 +- examples/child_watch/main.cc | 3 +- examples/compose/main.cc | 3 +- examples/dbus/client_bus_listnames.cc | 3 +- examples/dbus/server_without_bus.cc | 3 +- examples/dbus/session_bus_service.cc | 3 +- examples/iochannel_stream/fdstream.cc | 3 +- examples/iochannel_stream/fdstream.h | 3 +- examples/iochannel_stream/main.cc | 7 +- examples/keyfile/main.cc | 3 +- examples/markup/parser.cc | 3 +- examples/network/resolver.cc | 8 +- examples/network/socket-client.cc | 4 +- examples/network/socket-server.cc | 6 +- examples/options/main.cc | 3 +- examples/properties/properties_example.cc | 3 +- examples/regex/main.cc | 3 +- gio/giomm.h | 3 +- gio/giomm/contenttype.cc | 5 +- gio/giomm/contenttype.h | 5 +- gio/giomm/init.cc | 3 +- gio/giomm/init.h | 4 +- gio/giomm/slot_async.cc | 5 +- gio/giomm/slot_async.h | 5 +- gio/giomm/wrap_init.h | 4 +- gio/src/action.ccg | 5 +- gio/src/action.hg | 5 +- gio/src/actiongroup.ccg | 5 +- gio/src/actiongroup.hg | 11 +- gio/src/actionmap.ccg | 11 +- gio/src/actionmap.hg | 3 +- gio/src/appinfo.ccg | 5 +- gio/src/appinfo.hg | 31 +- gio/src/applaunchcontext.ccg | 3 +- gio/src/applaunchcontext.hg | 3 +- gio/src/application.ccg | 9 +- gio/src/application.hg | 11 +- gio/src/applicationcommandline.ccg | 3 +- gio/src/applicationcommandline.hg | 3 +- gio/src/asyncinitable.ccg | 3 +- gio/src/asyncinitable.hg | 5 +- gio/src/asyncresult.ccg | 5 +- gio/src/asyncresult.hg | 3 +- gio/src/bufferedinputstream.ccg | 5 +- gio/src/bufferedinputstream.hg | 3 +- gio/src/bufferedoutputstream.ccg | 5 +- gio/src/bufferedoutputstream.hg | 3 +- gio/src/cancellable.ccg | 5 +- gio/src/cancellable.hg | 3 +- gio/src/charsetconverter.ccg | 3 +- gio/src/charsetconverter.hg | 3 +- gio/src/converter.ccg | 5 +- gio/src/converter.hg | 5 +- gio/src/converterinputstream.ccg | 3 +- gio/src/converterinputstream.hg | 3 +- gio/src/converteroutputstream.ccg | 3 +- gio/src/converteroutputstream.hg | 3 +- gio/src/credentials.ccg | 5 +- gio/src/credentials.hg | 13 +- gio/src/datainputstream.ccg | 80 +- gio/src/datainputstream.hg | 138 +-- gio/src/dataoutputstream.ccg | 5 +- gio/src/dataoutputstream.hg | 3 +- gio/src/dbusactiongroup.ccg | 3 +- gio/src/dbusactiongroup.hg | 3 +- gio/src/dbusaddress.ccg | 5 +- gio/src/dbusaddress.hg | 5 +- gio/src/dbusauthobserver.ccg | 5 +- gio/src/dbusauthobserver.hg | 5 +- gio/src/dbusconnection.ccg | 3 +- gio/src/dbusconnection.hg | 23 +- gio/src/dbuserror.ccg | 5 +- gio/src/dbuserror.hg | 5 +- gio/src/dbuserrorutils.ccg | 5 +- gio/src/dbuserrorutils.hg | 5 +- gio/src/dbusinterface.ccg | 5 +- gio/src/dbusinterface.hg | 5 +- gio/src/dbusinterfaceskeleton.ccg | 3 +- gio/src/dbusinterfaceskeleton.hg | 3 +- gio/src/dbusinterfacevtable.ccg | 5 +- gio/src/dbusinterfacevtable.hg | 5 +- gio/src/dbusintrospection.ccg | 5 +- gio/src/dbusintrospection.hg | 7 +- gio/src/dbusmenumodel.ccg | 3 +- gio/src/dbusmenumodel.hg | 3 +- gio/src/dbusmessage.ccg | 5 +- gio/src/dbusmessage.hg | 11 +- gio/src/dbusmethodinvocation.ccg | 5 +- gio/src/dbusmethodinvocation.hg | 5 +- gio/src/dbusobject.ccg | 5 +- gio/src/dbusobject.hg | 3 +- gio/src/dbusownname.ccg | 5 +- gio/src/dbusownname.hg | 3 +- gio/src/dbusproxy.ccg | 3 +- gio/src/dbusproxy.hg | 3 +- gio/src/dbusserver.ccg | 3 +- gio/src/dbusserver.hg | 3 +- gio/src/dbussubtreevtable.ccg | 5 +- gio/src/dbussubtreevtable.hg | 5 +- gio/src/dbusutils.ccg | 5 +- gio/src/dbusutils.hg | 5 +- gio/src/dbuswatchname.ccg | 5 +- gio/src/dbuswatchname.hg | 3 +- gio/src/desktopappinfo.ccg | 5 +- gio/src/desktopappinfo.hg | 3 +- gio/src/drive.ccg | 5 +- gio/src/drive.hg | 3 +- gio/src/emblem.ccg | 5 +- gio/src/emblem.hg | 5 +- gio/src/emblemedicon.ccg | 5 +- gio/src/emblemedicon.hg | 11 +- gio/src/enums.ccg | 5 +- gio/src/enums.hg | 3 +- gio/src/error.ccg | 5 +- gio/src/error.hg | 5 +- gio/src/file.ccg | 3 +- gio/src/file.hg | 3 +- gio/src/fileattributeinfo.ccg | 5 +- gio/src/fileattributeinfo.hg | 5 +- gio/src/fileattributeinfolist.ccg | 5 +- gio/src/fileattributeinfolist.hg | 3 +- gio/src/fileenumerator.ccg | 5 +- gio/src/fileenumerator.hg | 5 +- gio/src/fileicon.ccg | 5 +- gio/src/fileicon.hg | 3 +- gio/src/fileinfo.ccg | 5 +- gio/src/fileinfo.hg | 3 +- gio/src/fileinputstream.ccg | 5 +- gio/src/fileinputstream.hg | 3 +- gio/src/fileiostream.ccg | 5 +- gio/src/fileiostream.hg | 3 +- gio/src/filemonitor.ccg | 5 +- gio/src/filemonitor.hg | 5 +- gio/src/filenamecompleter.ccg | 5 +- gio/src/filenamecompleter.hg | 5 +- gio/src/fileoutputstream.ccg | 5 +- gio/src/fileoutputstream.hg | 3 +- gio/src/filterinputstream.ccg | 3 +- gio/src/filterinputstream.hg | 3 +- gio/src/filteroutputstream.ccg | 3 +- gio/src/filteroutputstream.hg | 3 +- gio/src/gio_docs.xml | 1760 ++++++++++++++++++++++++--- gio/src/gio_docs_override.xml | 13 +- gio/src/gio_enums.defs | 4 +- gio/src/gio_methods.defs | 524 +++++++- gio/src/gio_signals.defs | 324 +++-- gio/src/gio_signals.defs.patch | 78 +- gio/src/icon.ccg | 5 +- gio/src/icon.hg | 3 +- gio/src/inetaddress.ccg | 5 +- gio/src/inetaddress.hg | 3 +- gio/src/inetsocketaddress.ccg | 5 +- gio/src/inetsocketaddress.hg | 16 +- gio/src/initable.ccg | 5 +- gio/src/initable.hg | 5 +- gio/src/inputstream.ccg | 5 +- gio/src/inputstream.hg | 3 +- gio/src/iostream.ccg | 5 +- gio/src/iostream.hg | 3 +- gio/src/listmodel.ccg | 3 +- gio/src/listmodel.hg | 3 +- gio/src/liststore.ccg | 3 +- gio/src/liststore.hg | 3 +- gio/src/loadableicon.ccg | 5 +- gio/src/loadableicon.hg | 3 +- gio/src/memoryinputstream.ccg | 5 +- gio/src/memoryinputstream.hg | 3 +- gio/src/memoryoutputstream.ccg | 3 +- gio/src/memoryoutputstream.hg | 3 +- gio/src/menu.ccg | 3 +- gio/src/menu.hg | 3 +- gio/src/menuattributeiter.ccg | 3 +- gio/src/menuattributeiter.hg | 3 +- gio/src/menuitem.ccg | 3 +- gio/src/menuitem.hg | 3 +- gio/src/menulinkiter.ccg | 3 +- gio/src/menulinkiter.hg | 3 +- gio/src/menumodel.ccg | 3 +- gio/src/menumodel.hg | 3 +- gio/src/mount.ccg | 5 +- gio/src/mount.hg | 3 +- gio/src/mountoperation.ccg | 5 +- gio/src/mountoperation.hg | 3 +- gio/src/networkaddress.ccg | 5 +- gio/src/networkaddress.hg | 5 +- gio/src/networkmonitor.ccg | 3 +- gio/src/networkmonitor.hg | 12 +- gio/src/networkservice.ccg | 5 +- gio/src/networkservice.hg | 5 +- gio/src/outputstream.ccg | 5 +- gio/src/outputstream.hg | 3 +- gio/src/permission.ccg | 3 +- gio/src/permission.hg | 3 +- gio/src/pollableinputstream.ccg | 5 +- gio/src/pollableinputstream.hg | 3 +- gio/src/pollableoutputstream.ccg | 5 +- gio/src/pollableoutputstream.hg | 3 +- gio/src/proxy.ccg | 5 +- gio/src/proxy.hg | 5 +- gio/src/proxyaddress.ccg | 5 +- gio/src/proxyaddress.hg | 13 +- gio/src/proxyresolver.ccg | 5 +- gio/src/proxyresolver.hg | 5 +- gio/src/remoteactiongroup.ccg | 5 +- gio/src/remoteactiongroup.hg | 3 +- gio/src/resolver.ccg | 3 +- gio/src/resolver.hg | 3 +- gio/src/resource.ccg | 3 +- gio/src/resource.hg | 19 +- gio/src/seekable.ccg | 5 +- gio/src/seekable.hg | 5 +- gio/src/settings.ccg | 3 +- gio/src/settings.hg | 19 +- gio/src/settingsschema.ccg | 3 +- gio/src/settingsschema.hg | 3 +- gio/src/settingsschemakey.ccg | 3 +- gio/src/settingsschemakey.hg | 3 +- gio/src/settingsschemasource.ccg | 3 +- gio/src/settingsschemasource.hg | 3 +- gio/src/simpleaction.ccg | 3 +- gio/src/simpleaction.hg | 3 +- gio/src/simpleactiongroup.ccg | 3 +- gio/src/simpleactiongroup.hg | 3 +- gio/src/simplepermission.ccg | 3 +- gio/src/simplepermission.hg | 3 +- gio/src/socket.ccg | 5 +- gio/src/socket.hg | 3 +- gio/src/socketaddress.ccg | 5 +- gio/src/socketaddress.hg | 5 +- gio/src/socketaddressenumerator.ccg | 5 +- gio/src/socketaddressenumerator.hg | 5 +- gio/src/socketclient.ccg | 5 +- gio/src/socketclient.hg | 3 +- gio/src/socketconnectable.ccg | 5 +- gio/src/socketconnectable.hg | 3 +- gio/src/socketconnection.ccg | 5 +- gio/src/socketconnection.hg | 3 +- gio/src/socketcontrolmessage.ccg | 5 +- gio/src/socketcontrolmessage.hg | 5 +- gio/src/socketlistener.ccg | 5 +- gio/src/socketlistener.hg | 5 +- gio/src/socketservice.ccg | 5 +- gio/src/socketservice.hg | 3 +- gio/src/srvtarget.ccg | 5 +- gio/src/srvtarget.hg | 3 +- gio/src/tcpconnection.ccg | 5 +- gio/src/tcpconnection.hg | 5 +- gio/src/tcpwrapperconnection.ccg | 3 +- gio/src/tcpwrapperconnection.hg | 3 +- gio/src/themedicon.ccg | 3 +- gio/src/themedicon.hg | 3 +- gio/src/threadedsocketservice.ccg | 5 +- gio/src/threadedsocketservice.hg | 5 +- gio/src/tlscertificate.ccg | 3 +- gio/src/tlscertificate.hg | 3 +- gio/src/tlsclientconnection.ccg | 3 +- gio/src/tlsclientconnection.hg | 16 +- gio/src/tlsconnection.ccg | 3 +- gio/src/tlsconnection.hg | 3 +- gio/src/tlsdatabase.ccg | 3 +- gio/src/tlsdatabase.hg | 3 +- gio/src/tlsfiledatabase.ccg | 3 +- gio/src/tlsfiledatabase.hg | 11 +- gio/src/tlsinteraction.ccg | 4 +- gio/src/tlsinteraction.hg | 3 +- gio/src/tlspassword.ccg | 3 +- gio/src/tlspassword.hg | 3 +- gio/src/tlsserverconnection.ccg | 3 +- gio/src/tlsserverconnection.hg | 10 +- gio/src/unixconnection.ccg | 5 +- gio/src/unixconnection.hg | 5 +- gio/src/unixcredentialsmessage.ccg | 5 +- gio/src/unixcredentialsmessage.hg | 5 +- gio/src/unixfdlist.ccg | 3 +- gio/src/unixfdlist.hg | 7 +- gio/src/unixfdmessage.ccg | 3 +- gio/src/unixfdmessage.hg | 5 +- gio/src/unixinputstream.ccg | 5 +- gio/src/unixinputstream.hg | 3 +- gio/src/unixmount.ccg | 5 +- gio/src/unixmount.hg | 5 +- gio/src/unixoutputstream.ccg | 5 +- gio/src/unixoutputstream.hg | 3 +- gio/src/unixsocketaddress.ccg | 5 +- gio/src/unixsocketaddress.hg | 3 +- gio/src/volume.ccg | 5 +- gio/src/volume.hg | 3 +- gio/src/volumemonitor.ccg | 5 +- gio/src/volumemonitor.hg | 3 +- gio/src/zlibcompressor.ccg | 3 +- gio/src/zlibcompressor.hg | 3 +- gio/src/zlibdecompressor.ccg | 3 +- gio/src/zlibdecompressor.hg | 3 +- glib/glibmm.h | 3 +- glib/glibmm/base64.cc | 3 +- glib/glibmm/base64.h | 3 +- glib/glibmm/class.cc | 3 +- glib/glibmm/class.h | 3 +- glib/glibmm/containerhandle_shared.h | 9 +- glib/glibmm/debug.cc | 5 +- glib/glibmm/debug.h | 4 +- glib/glibmm/dispatcher.cc | 11 +- glib/glibmm/dispatcher.h | 3 +- glib/glibmm/error.cc | 3 +- glib/glibmm/error.h | 3 +- glib/glibmm/exception.cc | 6 +- glib/glibmm/exception.h | 5 +- glib/glibmm/exceptionhandler.cc | 5 +- glib/glibmm/exceptionhandler.h | 4 +- glib/glibmm/i18n-lib.h | 6 +- glib/glibmm/i18n.h | 6 +- glib/glibmm/init.cc | 3 +- glib/glibmm/init.h | 3 +- glib/glibmm/interface.cc | 3 +- glib/glibmm/interface.h | 6 +- glib/glibmm/main.cc | 53 +- glib/glibmm/main.h | 22 +- glib/glibmm/object.cc | 3 +- glib/glibmm/object.h | 3 +- glib/glibmm/objectbase.cc | 15 +- glib/glibmm/objectbase.h | 3 +- glib/glibmm/pattern.cc | 6 +- glib/glibmm/pattern.h | 6 +- glib/glibmm/priorities.h | 6 +- glib/glibmm/property.cc | 3 +- glib/glibmm/property.h | 3 +- glib/glibmm/propertyproxy.cc | 6 +- glib/glibmm/propertyproxy.h | 4 +- glib/glibmm/propertyproxy_base.cc | 3 +- glib/glibmm/propertyproxy_base.h | 3 +- glib/glibmm/quark.cc | 5 +- glib/glibmm/quark.h | 4 +- glib/glibmm/random.cc | 6 +- glib/glibmm/random.h | 6 +- glib/glibmm/refptr.h | 3 +- glib/glibmm/signalproxy.cc | 3 +- glib/glibmm/signalproxy.h | 3 +- glib/glibmm/signalproxy_connectionnode.cc | 3 +- glib/glibmm/signalproxy_connectionnode.h | 3 +- glib/glibmm/stringutils.cc | 6 +- glib/glibmm/stringutils.h | 6 +- glib/glibmm/timer.cc | 3 +- glib/glibmm/timer.h | 6 +- glib/glibmm/timeval.cc | 6 +- glib/glibmm/timeval.h | 6 +- glib/glibmm/ustring.cc | 14 +- glib/glibmm/ustring.h | 417 +------ glib/glibmm/utility.cc | 7 +- glib/glibmm/utility.h | 3 +- glib/glibmm/value.cc | 6 +- glib/glibmm/value.h | 3 +- glib/glibmm/value_custom.cc | 6 +- glib/glibmm/value_custom.h | 3 +- glib/glibmm/vectorutils.cc | 3 +- glib/glibmm/vectorutils.h | 4 +- glib/glibmm/wrap.cc | 6 +- glib/glibmm/wrap.h | 3 +- glib/glibmm/wrap_init.h | 6 +- glib/src/balancedtree.hg | 3 +- glib/src/bytearray.ccg | 3 +- glib/src/bytearray.hg | 3 +- glib/src/bytes.ccg | 3 +- glib/src/bytes.hg | 3 +- glib/src/checksum.ccg | 3 +- glib/src/checksum.hg | 3 +- glib/src/convert.ccg | 5 +- glib/src/convert.hg | 3 +- glib/src/date.ccg | 3 +- glib/src/date.hg | 3 +- glib/src/datetime.ccg | 3 +- glib/src/datetime.hg | 3 +- glib/src/enums.ccg | 3 +- glib/src/enums.hg | 3 +- glib/src/fileutils.ccg | 3 +- glib/src/fileutils.hg | 3 +- glib/src/glib_docs.xml | 1321 ++++++++++++++++---- glib/src/glib_docs_override.xml | 4 + glib/src/glib_enums.defs | 85 +- glib/src/glib_functions.defs | 383 +++--- glib/src/glib_signals.defs | 3 + glib/src/gmodule_functions.defs | 15 - glib/src/gobject_enums.defs | 5 +- glib/src/gobject_functions.defs | 55 +- glib/src/iochannel.ccg | 3 +- glib/src/iochannel.hg | 16 +- glib/src/keyfile.ccg | 3 +- glib/src/keyfile.hg | 13 +- glib/src/markup.ccg | 3 +- glib/src/markup.hg | 3 +- glib/src/miscutils.ccg | 37 +- glib/src/miscutils.hg | 3 +- glib/src/module.ccg | 3 +- glib/src/module.hg | 6 +- glib/src/nodetree.hg | 3 +- glib/src/optioncontext.ccg | 3 +- glib/src/optioncontext.hg | 11 +- glib/src/optionentry.ccg | 3 +- glib/src/optionentry.hg | 3 +- glib/src/optiongroup.ccg | 3 +- glib/src/optiongroup.hg | 3 +- glib/src/regex.ccg | 3 +- glib/src/regex.hg | 43 +- glib/src/shell.ccg | 3 +- glib/src/shell.hg | 3 +- glib/src/spawn.ccg | 3 +- glib/src/spawn.hg | 3 +- glib/src/template.macros.m4 | 3 +- glib/src/timezone.ccg | 3 +- glib/src/timezone.hg | 3 +- glib/src/unicode.ccg | 3 +- glib/src/unicode.hg | 3 +- glib/src/uriutils.ccg | 3 +- glib/src/uriutils.hg | 3 +- glib/src/value_basictypes.cc.m4 | 3 +- glib/src/value_basictypes.h.m4 | 3 +- glib/src/variant.ccg | 53 +- glib/src/variant.hg | 78 +- glib/src/variant_basictypes.cc.m4 | 3 +- glib/src/variant_basictypes.h.m4 | 3 +- glib/src/variantdict.ccg | 3 +- glib/src/variantdict.hg | 11 +- glib/src/variantiter.ccg | 11 +- glib/src/variantiter.hg | 11 +- glib/src/varianttype.ccg | 3 +- glib/src/varianttype.hg | 8 +- tests/glibmm_bool_vector/main.cc | 3 +- tests/glibmm_null_vectorutils/main.cc | 3 +- tests/glibmm_variant/main.cc | 33 + tests/glibmm_vector/main.cc | 3 +- tools/defs_fixer.pl | 3 +- tools/defs_gen/docextract.py | 12 +- tools/defs_gen/docextract_to_xml.py | 35 +- tools/extra_defs_gen/generate_defs_gio.cc | 8 +- tools/extra_defs_gen/generate_defs_glib.cc | 3 +- tools/extra_defs_gen/generate_extra_defs.cc | 102 +- tools/extra_defs_gen/generate_extra_defs.h | 5 +- tools/gmmproc.in | 3 +- tools/pm/DocsParser.pm | 93 +- tools/pm/Function.pm | 11 +- tools/pm/GtkDefs.pm | 37 +- tools/pm/Output.pm | 46 +- tools/pm/Property.pm | 18 +- tools/pm/Util.pm | 3 +- tools/pm/WrapParser.pm | 38 +- 447 files changed, 5020 insertions(+), 2854 deletions(-) diff --git a/COPYING b/COPYING index c4792dd..5e1f37e 100644 --- a/COPYING +++ b/COPYING @@ -3,7 +3,7 @@ Version 2.1, February 1999 Copyright (C) 1991, 1999 Free Software Foundation, Inc. - 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. @@ -477,14 +477,13 @@ have at least the "copyright" line and a pointer to where the full notice is found. - + Copyright (C) This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published by the Free Software Foundation; either - version 2 of the License, or (at your option) any later version. + version 2.1 of the License, or (at your option) any later version. This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of @@ -493,7 +492,7 @@ does.> You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to the Free Software - Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA + Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA Also add information on how to contact you by electronic and paper mail. diff --git a/NEWS b/NEWS index e2a8c01..7de6b59 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,74 @@ +2.55.2: (unstable): +Distro packagers should probably not package this yet. + +Glib: +* IOCondition: Add an IO_ prefix to the enumerator names + (Kjell Ahlstedt) +* TimeoutSource: Use monotonic time consistently + (Kjell Ahlstedt) Bug #792524 (Dainis Jonitis) +* Source: Remove get_current_time(). + (Kjell Ahlstedt) +* KeyFile, OptionContext, Regex: Add exception specs to errthrow. + (Kjell Ahlstedt) +* ustring: + - Replace 8×format() with 1 variadic template. + - Replace 9×compose() with 1 variadic template. + - Use std::initializer_list instead of pointer + size + (Daniel Boles) Bug #784211 +* VariantBase: + - Add operator==() and operator!=(). + (Kjell Ahlstedt) Bug #789330 (Daniel Boles) + - cast_dynamic(): Remove noexcept(false). + (Kjell Ahlstedt) + +Glib::Gio: +* AppInfo: Update the name of the AppLaunchContext parameters + (Kjell Ahlstedt) +* Action: Add exception specs to errthrow. + (Kjell Ahlstedt) +* Application: Fix property_resource_base_path()'s type + (Kjell Ahlstedt) +* Credentials, et al.: Add exception specs to errthrow. + (Kjell Ahlstedt) +* DataInputStream: + - Remove read_until*(). + - Fix the documentation of read_line_utf8(). + (Kjell Ahlstedt) +* InetSocketAddress, ProxyAddress: No guint16 in _WRAP_PROPERTY(). + (Kjell Ahlstedt) +* Settings: set_int() and friends shall return bool. + (Kjell Ahlstedt) Bug #784211 +* TlsClientConnection: Remove get/set/property_use_ssl3(). + (Kjell Ahlstedt) + +gmmproc: +* Warn if parameter lists are not compatible + (Kjell Ahlstedt) +* _WRAP_METHOD: Accept optional list of exceptions in errthrow + (Kjell Ahlstedt) +* _WRAP_METHOD_DOCS_ONLY: Optionally suppress @return section. + (Kjell Ahlstedt) Bug #787978 +* docextract_to_xml.py: Add --exclude-file option. + (Kjell Ahlstedt) +* Suppress the @return section if return type is void. + (Kjell Ahlstedt) +* generate_extra_defs.cc: + - Write signal flags to .defs files. + - Write default values of properties to .defs files. + - Write default values of properties to generated documentation. + (Kjell Ahlstedt) Bug #785895 (Daniel Boles) +* Warn for unmatched deprecations in signals and properties. + (Kjell Ahlstedt) + +Documentation: +* Glib::ObjectBase: Don't mention GtkObject in comments. + (Kjell Ahlstedt) +* Glib::Variant: Hide namespace Glib::detail from Doxygen + (Kjell Ahlstedt) Bug #787698 (Daniel Boles) +* Glib::Variant: Slightly elaborate Variant docs. + (Daniel Boles) Bug #778219 (Daniel Boles) + + 2.55.1: (unstable): Distro packagers should probably not package this yet. diff --git a/build/dk-feature.m4 b/build/dk-feature.m4 index 8065441..5a36b10 100644 --- a/build/dk-feature.m4 +++ b/build/dk-feature.m4 @@ -13,8 +13,7 @@ ## for more details. ## ## You should have received a copy of the GNU General Public License along -## with danielk's Autostuff; if not, write to the Free Software Foundation, -## Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA +## with danielk's Autostuff. If not, see . #serial 20110910 diff --git a/configure.ac b/configure.ac index 1e1598c..766b542 100644 --- a/configure.ac +++ b/configure.ac @@ -15,7 +15,7 @@ ## You should have received a copy of the GNU Lesser General Public License ## along with this library. If not, see . -AC_INIT([glibmm], [2.55.1], +AC_INIT([glibmm], [2.55.2], [http://bugzilla.gnome.org/enter_bug.cgi?product=glibmm], [glibmm], [http://www.gtkmm.org/]) AC_PREREQ([2.59]) diff --git a/examples/child_watch/main.cc b/examples/child_watch/main.cc index a995f5a..60e6c57 100644 --- a/examples/child_watch/main.cc +++ b/examples/child_watch/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/compose/main.cc b/examples/compose/main.cc index 79952bb..48aa8d9 100644 --- a/examples/compose/main.cc +++ b/examples/compose/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/dbus/client_bus_listnames.cc b/examples/dbus/client_bus_listnames.cc index a0d22fb..0dd336f 100644 --- a/examples/dbus/client_bus_listnames.cc +++ b/examples/dbus/client_bus_listnames.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/dbus/server_without_bus.cc b/examples/dbus/server_without_bus.cc index a4a99bb..23e8bd5 100644 --- a/examples/dbus/server_without_bus.cc +++ b/examples/dbus/server_without_bus.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ /* This is a basic server providing a clock like functionality. Clients can diff --git a/examples/dbus/session_bus_service.cc b/examples/dbus/session_bus_service.cc index 1c137a0..25d3ae7 100644 --- a/examples/dbus/session_bus_service.cc +++ b/examples/dbus/session_bus_service.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ /* This is a basic server providing a clock like functionality. Clients can diff --git a/examples/iochannel_stream/fdstream.cc b/examples/iochannel_stream/fdstream.cc index 51b6c3e..d3e5647 100644 --- a/examples/iochannel_stream/fdstream.cc +++ b/examples/iochannel_stream/fdstream.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "fdstream.h" diff --git a/examples/iochannel_stream/fdstream.h b/examples/iochannel_stream/fdstream.h index 1928344..fdfd3f3 100644 --- a/examples/iochannel_stream/fdstream.h +++ b/examples/iochannel_stream/fdstream.h @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ /* diff --git a/examples/iochannel_stream/main.cc b/examples/iochannel_stream/main.cc index 8234ccd..4fad426 100644 --- a/examples/iochannel_stream/main.cc +++ b/examples/iochannel_stream/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -44,7 +43,7 @@ Glib::RefPtr mainloop; bool MyCallback(Glib::IOCondition io_condition) { - if ((io_condition & Glib::IOCondition::IN) != Glib::IOCondition::IN) + if ((io_condition & Glib::IOCondition::IO_IN) != Glib::IOCondition::IO_IN) { std::cerr << "Invalid fifo response" << std::endl; } @@ -89,7 +88,7 @@ int main(/* int argc, char *argv[] */) } input_stream.attach(read_fd); - input_stream.connect(sigc::ptr_fun(MyCallback), Glib::IOCondition::IN); + input_stream.connect(sigc::ptr_fun(MyCallback), Glib::IOCondition::IO_IN); // and last but not least - run the application main loop mainloop->run(); diff --git a/examples/keyfile/main.cc b/examples/keyfile/main.cc index e4ddae7..c75719d 100644 --- a/examples/keyfile/main.cc +++ b/examples/keyfile/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/markup/parser.cc b/examples/markup/parser.cc index 9caaaf8..7cd5b94 100644 --- a/examples/markup/parser.cc +++ b/examples/markup/parser.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/network/resolver.cc b/examples/network/resolver.cc index d838213..a651a1a 100644 --- a/examples/network/resolver.cc +++ b/examples/network/resolver.cc @@ -13,10 +13,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * - * You should have received a copy of the GNU Lesser General - * Public License along with this library; if not, write to the - * Free Software Foundation, Inc., 59 Temple Place, Suite 330, - * Boston, MA 02111-1307, USA. + * You should have received a copy of the GNU Lesser General Public + * License along with this library. If not, see . */ #ifndef _WIN32 @@ -466,7 +464,7 @@ main(int argc, char** argv) signal(SIGINT, interrupted); chan = Glib::IOChannel::create_from_fd(cancel_fds[0]); - const auto source = chan->create_watch(Glib::IOCondition::IN); + const auto source = chan->create_watch(Glib::IOCondition::IO_IN); watch_conn = source->connect(sigc::bind(sigc::ptr_fun(async_cancel), cancellable)); #endif diff --git a/examples/network/socket-client.cc b/examples/network/socket-client.cc index aacbd6b..5a3718a 100644 --- a/examples/network/socket-client.cc +++ b/examples/network/socket-client.cc @@ -272,7 +272,7 @@ main(int argc, char* argv[]) buffer[to_send] = '\0'; while (to_send > 0) { - ensure_condition(socket, "send", cancellable, Glib::IOCondition::OUT); + ensure_condition(socket, "send", cancellable, Glib::IOCondition::IO_OUT); try { if (use_udp) @@ -305,7 +305,7 @@ main(int argc, char* argv[]) to_send -= size; } - ensure_condition(socket, "receive", cancellable, Glib::IOCondition::IN); + ensure_condition(socket, "receive", cancellable, Glib::IOCondition::IO_IN); try { if (use_udp) diff --git a/examples/network/socket-server.cc b/examples/network/socket-server.cc index 59dd115..a0e6bd1 100644 --- a/examples/network/socket-server.cc +++ b/examples/network/socket-server.cc @@ -218,7 +218,7 @@ main(int argc, char* argv[]) std::cout << Glib::ustring::compose("listening on port %1...\n", port); - ensure_condition(socket, "accept", cancellable, Glib::IOCondition::IN); + ensure_condition(socket, "accept", cancellable, Glib::IOCondition::IO_IN); try { new_socket = socket->accept(cancellable); @@ -257,7 +257,7 @@ main(int argc, char* argv[]) gchar buffer[4096] = {}; gssize size; - ensure_condition(recv_socket, "receive", cancellable, Glib::IOCondition::IN); + ensure_condition(recv_socket, "receive", cancellable, Glib::IOCondition::IO_IN); try { if (use_udp) @@ -289,7 +289,7 @@ main(int argc, char* argv[]) while (to_send > 0) { - ensure_condition(recv_socket, "send", cancellable, Glib::IOCondition::OUT); + ensure_condition(recv_socket, "send", cancellable, Glib::IOCondition::IO_OUT); try { if (use_udp) diff --git a/examples/options/main.cc b/examples/options/main.cc index c0973ad..cf6796f 100644 --- a/examples/options/main.cc +++ b/examples/options/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/properties/properties_example.cc b/examples/properties/properties_example.cc index 98ef1ee..0d6c336 100644 --- a/examples/properties/properties_example.cc +++ b/examples/properties/properties_example.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/examples/regex/main.cc b/examples/regex/main.cc index e634fe5..94fd059 100644 --- a/examples/regex/main.cc +++ b/examples/regex/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/giomm.h b/gio/giomm.h index d39df60..795a3e5 100644 --- a/gio/giomm.h +++ b/gio/giomm.h @@ -16,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/giomm/contenttype.cc b/gio/giomm/contenttype.cc index 816f5b9..abe6733 100644 --- a/gio/giomm/contenttype.cc +++ b/gio/giomm/contenttype.cc @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/giomm/contenttype.h b/gio/giomm/contenttype.h index c9516a6..408adc8 100644 --- a/gio/giomm/contenttype.h +++ b/gio/giomm/contenttype.h @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #ifndef _GIOMM_CONTENTTYPE_H #define _GIOMM_CONTENTTYPE_H diff --git a/gio/giomm/init.cc b/gio/giomm/init.cc index a00c3b4..32c2892 100644 --- a/gio/giomm/init.cc +++ b/gio/giomm/init.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "init.h" diff --git a/gio/giomm/init.h b/gio/giomm/init.h index a7e69e2..345e819 100644 --- a/gio/giomm/init.h +++ b/gio/giomm/init.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GIOMM_INIT_H #define _GIOMM_INIT_H @@ -19,8 +18,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Gio diff --git a/gio/giomm/slot_async.cc b/gio/giomm/slot_async.cc index 06dc7c5..4f2b6e2 100644 --- a/gio/giomm/slot_async.cc +++ b/gio/giomm/slot_async.cc @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "slot_async.h" diff --git a/gio/giomm/slot_async.h b/gio/giomm/slot_async.h index ba840e1..228e1c9 100644 --- a/gio/giomm/slot_async.h +++ b/gio/giomm/slot_async.h @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/giomm/wrap_init.h b/gio/giomm/wrap_init.h index cb9de97..cb7d947 100644 --- a/gio/giomm/wrap_init.h +++ b/gio/giomm/wrap_init.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GIOMM_WRAP_INIT_H #define _GIOMM_WRAP_INIT_H @@ -17,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Gio diff --git a/gio/src/action.ccg b/gio/src/action.ccg index c5a1735..71715d3 100644 --- a/gio/src/action.ccg +++ b/gio/src/action.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2011 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/action.hg b/gio/src/action.hg index 067a230..5075846 100644 --- a/gio/src/action.hg +++ b/gio/src/action.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) @@ -178,7 +177,7 @@ public: static void parse_detailed_name(const Glib::ustring& detailed_name, Glib::ustring& action_name, T_Value& target_value); _WRAP_METHOD(static void parse_detailed_name_variant(const Glib::ustring& detailed_name, - Glib::ustring& action_name{>>}, Glib::VariantBase& target_value{>>}), g_action_parse_detailed_name, errthrow) + Glib::ustring& action_name{>>}, Glib::VariantBase& target_value{>>}), g_action_parse_detailed_name, errthrow "Glib::VariantParseError") /** Formats a detailed action name from the action's action_name and @a target_value. * diff --git a/gio/src/actiongroup.ccg b/gio/src/actiongroup.ccg index 35feb3a..63caf51 100644 --- a/gio/src/actiongroup.ccg +++ b/gio/src/actiongroup.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/actiongroup.hg b/gio/src/actiongroup.hg index 6d250ba..de43abf 100644 --- a/gio/src/actiongroup.hg +++ b/gio/src/actiongroup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) @@ -129,13 +128,13 @@ public: //TODO: Add templated method, renaming this to action_state_changed_variant). _WRAP_METHOD(void action_state_changed (const Glib::ustring& action_name, const Glib::VariantBase& state), g_action_group_action_state_changed) - _WRAP_SIGNAL(void action_added(const Glib::ustring& action_name), "action-added") - _WRAP_SIGNAL(void action_enabled_changed(const Glib::ustring& action_name, bool enabled), "action-enabled-changed") - _WRAP_SIGNAL(void action_removed(const Glib::ustring& action_name), "action-removed") + _WRAP_SIGNAL(void action_added(const Glib::ustring& action_name), "action-added", detail_name action_name) + _WRAP_SIGNAL(void action_enabled_changed(const Glib::ustring& action_name, bool enabled), "action-enabled-changed", detail_name action_name) + _WRAP_SIGNAL(void action_removed(const Glib::ustring& action_name), "action-removed", detail_name action_name) #m4 _CONVERSION(`GVariant*', `const Glib::VariantBase&', `Glib::wrap($3, true)') - _WRAP_SIGNAL(void action_state_changed(const Glib::ustring& action_name, const Glib::VariantBase& value), "action-state-changed") + _WRAP_SIGNAL(void action_state_changed(const Glib::ustring& action_name, const Glib::VariantBase& value), "action-state-changed", detail_name action_name) _WRAP_VFUNC(bool has_action(const Glib::ustring& name) const, "has_action") diff --git a/gio/src/actionmap.ccg b/gio/src/actionmap.ccg index 2907721..c39a242 100644 --- a/gio/src/actionmap.ccg +++ b/gio/src/actionmap.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -83,8 +80,7 @@ static void on_action_radio_string( const Glib::VariantBase& parameter, const Gio::ActionMap::ActivateWithStringParameterSlot& slot) { - // TODO: This syntax is odd: - const auto variantDerived = parameter.cast_dynamic>(parameter); + const auto variantDerived = Glib::VariantBase::cast_dynamic>(parameter); const auto str = variantDerived.get(); slot(str); } @@ -108,8 +104,7 @@ static void on_action_radio_int( const Glib::VariantBase& parameter, const Gio::ActionMap::ActivateWithIntParameterSlot& slot) { - // TODO: This syntax is odd: - const auto variantDerived = parameter.cast_dynamic>(parameter); + const auto variantDerived = Glib::VariantBase::cast_dynamic>(parameter); const auto str = variantDerived.get(); slot(str); } diff --git a/gio/src/actionmap.hg b/gio/src/actionmap.hg index 871be0e..b3fa9e2 100644 --- a/gio/src/actionmap.hg +++ b/gio/src/actionmap.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/appinfo.ccg b/gio/src/appinfo.ccg index dc01c85..6be12b9 100644 --- a/gio/src/appinfo.ccg +++ b/gio/src/appinfo.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/appinfo.hg b/gio/src/appinfo.hg index ef6c288..7833cc0 100644 --- a/gio/src/appinfo.hg +++ b/gio/src/appinfo.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) @@ -90,7 +89,7 @@ public: #m4 _CONVERSION(`const std::vector< Glib::RefPtr >&',`GList*',`Glib::ListHandler >::vector_to_list($3).data ()') /** Launches the application. This passes the @a file to the launched application - * as an argument, using the optional @a launch_context to get information + * as an argument, using the optional @a context to get information * about the details of the launcher (like what screen it is on). * On error, an exception will be thrown accordingly. * @@ -110,14 +109,14 @@ public: * @c GIO_LAUNCHED_DESKTOP_FILE, should it be inherited * by further processes. The @c DISPLAY and * @c DESKTOP_STARTUP_ID environment variables are also - * set, based on information provided in @a launch_context. + * set, based on information provided in @a context. * @param file A File object. - * @param launch_context An AppLaunchContext. + * @param context An AppLaunchContext. * @return true on successful launch, false otherwise. * * @newin{2,30} */ - bool launch(const Glib::RefPtr& file, const Glib::RefPtr& launch_context); + bool launch(const Glib::RefPtr& file, const Glib::RefPtr& context); /** Launches the application. This passes the @a file to the launched application * as an argument. @@ -139,7 +138,7 @@ public: * @c GIO_LAUNCHED_DESKTOP_FILE, should it be inherited * by further processes. The @c DISPLAY and * @c DESKTOP_STARTUP_ID environment variables are also - * set, based on information provided in @a launch_context. + * set, based on information provided in @a context. * @param file A File object. * @return true on successful launch, false otherwise. * @@ -148,7 +147,7 @@ public: bool launch(const Glib::RefPtr& file); _WRAP_METHOD(bool launch(const std::vector< Glib::RefPtr >& files, - const Glib::RefPtr& launch_context{?}), + const Glib::RefPtr& context{?}), g_app_info_launch, errthrow) @@ -159,12 +158,12 @@ public: //TODO: I think we use Glib::ustring elsewhere for URIs: _WRAP_METHOD(bool launch_uris(const std::vector& uris, - const Glib::RefPtr& launch_context{?}), + const Glib::RefPtr& context{?}), g_app_info_launch_uris, errthrow) /** Launches the application. This passes the @a uri to the launched application - * as an arguments, using the optional @a launch_context to get information + * as an arguments, using the optional @a context to get information * about the details of the launcher (like what screen it is on). * On error, an exception will be thrown accordingly. * @@ -172,12 +171,12 @@ public: * can fail to start if it runs into problems during startup. There is * no way to detect this. * @param uris A URIs to launch. - * @param launch_context An AppLaunchContext. + * @param context An AppLaunchContext. * @return true on successful launch, false otherwise. * * @newin{2,30} */ - bool launch_uri(const std::string& uris, const Glib::RefPtr& launch_context); + bool launch_uri(const std::string& uris, const Glib::RefPtr& context); /** A launch_uri() convenience overload. * @@ -216,9 +215,9 @@ public: _WRAP_METHOD(static Glib::RefPtr get_default_for_type(const std::string& content_type, bool must_support_uris = true), g_app_info_get_default_for_type) _WRAP_METHOD(static Glib::RefPtr get_default_for_uri_scheme(const std::string& uri_scheme), g_app_info_get_default_for_uri_scheme) _WRAP_METHOD(static void reset_type_associations(const std::string& content_type), g_app_info_reset_type_associations) - _WRAP_METHOD(static bool launch_default_for_uri(const std::string& uri, const Glib::RefPtr& launch_context{?}), g_app_info_launch_default_for_uri, errthrow) + _WRAP_METHOD(static bool launch_default_for_uri(const std::string& uri, const Glib::RefPtr& context{?}), g_app_info_launch_default_for_uri, errthrow) - _WRAP_METHOD(static void launch_default_for_uri_async(const std::string& uri, const Glib::RefPtr& launch_context{.?}, + _WRAP_METHOD(static void launch_default_for_uri_async(const std::string& uri, const Glib::RefPtr& context{.?}, const SlotAsyncReady& slot{callback?}, const Glib::RefPtr& cancellable{.?}), g_app_info_launch_default_for_uri_async, slot_name slot, slot_callback SignalProxy_async_callback) _IGNORE(g_app_info_launch_default_for_uri_async) _WRAP_METHOD(static bool launch_default_for_uri_finish(const Glib::RefPtr& result), g_app_info_launch_default_for_uri_finish, errthrow) @@ -231,10 +230,10 @@ protected: //_WRAP_VFUNC(std::string get_description() const, "get_description") //_WRAP_VFUNC(std::string get_executable() const, "get_executable") //_WRAP_VFUNC(Glib::RefPtr get_icon() const, "get_icon") - //_WRAP_VFUNC(bool launch(const std::vector& filenames, const Glib::RefPtr& launch_context, GError** error), "launch") + //_WRAP_VFUNC(bool launch(const std::vector& filenames, const Glib::RefPtr& context, GError** error), "launch") //_WRAP_VFUNC(bool supports_uris() const, "supports_uris") //_WRAP_VFUNC(bool supports_files() const, "supports_files") - //_WRAP_VFUNC(bool launch_uris(const std::vector& uris, const Glib::RefPtr& launch_context, GError** error), "launch_uris") + //_WRAP_VFUNC(bool launch_uris(const std::vector& uris, const Glib::RefPtr& context, GError** error), "launch_uris") //_WRAP_VFUNC(bool should_show() const, "should_show") //_WRAP_VFUNC(bool set_as_default_for_type(const std::string& content_type, GError** error), "set_as_default_for_type") //_WRAP_VFUNC(bool set_as_default_for_extension(const std::string& extension, GError** error), "set_as_default_for_extension") diff --git a/gio/src/applaunchcontext.ccg b/gio/src/applaunchcontext.ccg index d0fa26a..be56159 100644 --- a/gio/src/applaunchcontext.ccg +++ b/gio/src/applaunchcontext.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/applaunchcontext.hg b/gio/src/applaunchcontext.hg index cd75aed..f973f08 100644 --- a/gio/src/applaunchcontext.hg +++ b/gio/src/applaunchcontext.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/application.ccg b/gio/src/application.ccg index b344c29..d85ae8d 100644 --- a/gio/src/application.ccg +++ b/gio/src/application.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -273,9 +272,11 @@ Application::custom_class_init() Application::Application(const Glib::ustring& application_id, Flags flags) : // Mark this class as non-derived to allow C++ vfuncs to be skipped. + // GApplication complains about "" but allows nullptr, so we avoid passing "". Glib::ObjectBase(nullptr), - Glib::Object(Glib::ConstructParams(custom_class_init(), "application_id", - Glib::c_str_or_nullptr(application_id), "flags", ((GApplicationFlags)(flags)), nullptr)) + Glib::Object(Glib::ConstructParams(custom_class_init(), + "application_id", Glib::c_str_or_nullptr(application_id), + "flags", static_cast(flags), nullptr)) { } diff --git a/gio/src/application.hg b/gio/src/application.hg index 3042a79..7767854 100644 --- a/gio/src/application.hg +++ b/gio/src/application.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) @@ -367,7 +366,7 @@ public: _WRAP_PROPERTY("inactivity-timeout", guint) _WRAP_PROPERTY("is-registered", bool) _WRAP_PROPERTY("is-remote", bool) - _WRAP_PROPERTY("resource-base-path", bool, newin "2,44") + _WRAP_PROPERTY("resource-base-path", std::string, newin "2,44") _WRAP_PROPERTY("is-busy", bool) _WRAP_SIGNAL(void startup(), "startup") @@ -422,10 +421,8 @@ protected: _WRAP_VFUNC(void dbus_unregister(const Glib::RefPtr& connection, const Glib::ustring& object_path), "dbus_unregister") private: - /** This is just a way to call Glib::init() (which calls g_type_init()) before - * calling application_class_.init(), so that - * g_application_get_type() will always succeed. - * See https://bugzilla.gnome.org/show_bug.cgi?id=639925 + /** This is just a way to call Glib::init() before calling a Glib::Object ctor, + * so that glibmm's GQuarks are created before they are used. */ const Glib::Class& custom_class_init(); diff --git a/gio/src/applicationcommandline.ccg b/gio/src/applicationcommandline.ccg index 7fbee67..474fc42 100644 --- a/gio/src/applicationcommandline.ccg +++ b/gio/src/applicationcommandline.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/applicationcommandline.hg b/gio/src/applicationcommandline.hg index 4b357c4..3c11745 100644 --- a/gio/src/applicationcommandline.hg +++ b/gio/src/applicationcommandline.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/asyncinitable.ccg b/gio/src/asyncinitable.ccg index e91c984..f6fda2f 100644 --- a/gio/src/asyncinitable.ccg +++ b/gio/src/asyncinitable.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/asyncinitable.hg b/gio/src/asyncinitable.hg index 6d7d90f..6961edd 100644 --- a/gio/src/asyncinitable.hg +++ b/gio/src/asyncinitable.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/asyncresult.ccg b/gio/src/asyncresult.ccg index bebc7ab..8f1a012 100644 --- a/gio/src/asyncresult.ccg +++ b/gio/src/asyncresult.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include //We are not allowed to include individual headers. diff --git a/gio/src/asyncresult.hg b/gio/src/asyncresult.hg index f0d2d68..9fa2e4b 100644 --- a/gio/src/asyncresult.hg +++ b/gio/src/asyncresult.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/bufferedinputstream.ccg b/gio/src/bufferedinputstream.ccg index 888b7af..56dfe24 100644 --- a/gio/src/bufferedinputstream.ccg +++ b/gio/src/bufferedinputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/bufferedinputstream.hg b/gio/src/bufferedinputstream.hg index 413d965..d93c665 100644 --- a/gio/src/bufferedinputstream.hg +++ b/gio/src/bufferedinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/bufferedoutputstream.ccg b/gio/src/bufferedoutputstream.ccg index c549775..80e9d07 100644 --- a/gio/src/bufferedoutputstream.ccg +++ b/gio/src/bufferedoutputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/bufferedoutputstream.hg b/gio/src/bufferedoutputstream.hg index 39145e7..846411f 100644 --- a/gio/src/bufferedoutputstream.hg +++ b/gio/src/bufferedoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/cancellable.ccg b/gio/src/cancellable.ccg index 151f478..87d8f66 100644 --- a/gio/src/cancellable.ccg +++ b/gio/src/cancellable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/cancellable.hg b/gio/src/cancellable.hg index a1cc68a..b4cb956 100644 --- a/gio/src/cancellable.hg +++ b/gio/src/cancellable.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ diff --git a/gio/src/charsetconverter.ccg b/gio/src/charsetconverter.ccg index 2353843..a5d5029 100644 --- a/gio/src/charsetconverter.ccg +++ b/gio/src/charsetconverter.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/charsetconverter.hg b/gio/src/charsetconverter.hg index 37a32e2..d5679b7 100644 --- a/gio/src/charsetconverter.hg +++ b/gio/src/charsetconverter.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converter.ccg b/gio/src/converter.ccg index 0f2d200..508a1c7 100644 --- a/gio/src/converter.ccg +++ b/gio/src/converter.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converter.hg b/gio/src/converter.hg index cde99f8..c34ea63 100644 --- a/gio/src/converter.hg +++ b/gio/src/converter.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converterinputstream.ccg b/gio/src/converterinputstream.ccg index 4f46d64..e18a328 100644 --- a/gio/src/converterinputstream.ccg +++ b/gio/src/converterinputstream.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converterinputstream.hg b/gio/src/converterinputstream.hg index 8c0e39a..ae65e59 100644 --- a/gio/src/converterinputstream.hg +++ b/gio/src/converterinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converteroutputstream.ccg b/gio/src/converteroutputstream.ccg index b122ac3..e492031 100644 --- a/gio/src/converteroutputstream.ccg +++ b/gio/src/converteroutputstream.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/converteroutputstream.hg b/gio/src/converteroutputstream.hg index eeb5d9d..1729aac 100644 --- a/gio/src/converteroutputstream.hg +++ b/gio/src/converteroutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/credentials.ccg b/gio/src/credentials.ccg index ed04a99..2961657 100644 --- a/gio/src/credentials.ccg +++ b/gio/src/credentials.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/credentials.hg b/gio/src/credentials.hg index 60fb023..7bbcdef 100644 --- a/gio/src/credentials.hg +++ b/gio/src/credentials.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -65,12 +62,12 @@ public: _WRAP_METHOD(gpointer get_native(Type native_type), g_credentials_get_native) _WRAP_METHOD(void set_native(Type native_type, gpointer native), g_credentials_set_native) - _WRAP_METHOD(bool is_same_user(const Glib::RefPtr& other_credentials), g_credentials_is_same_user, errthrow) + _WRAP_METHOD(bool is_same_user(const Glib::RefPtr& other_credentials), g_credentials_is_same_user, errthrow "Gio::Error") - _WRAP_METHOD(uid_t get_unix_user(), g_credentials_get_unix_user, errthrow, ifdef G_OS_UNIX) - _WRAP_METHOD(bool set_unix_user(uid_t uid), g_credentials_set_unix_user, errthrow, ifdef G_OS_UNIX) + _WRAP_METHOD(uid_t get_unix_user(), g_credentials_get_unix_user, errthrow "Gio::Error", ifdef G_OS_UNIX) + _WRAP_METHOD(bool set_unix_user(uid_t uid), g_credentials_set_unix_user, errthrow "Gio::Error", ifdef G_OS_UNIX) - _WRAP_METHOD(pid_t get_unix_pid() const, g_credentials_get_unix_pid, errthrow, ifdef G_OS_UNIX) + _WRAP_METHOD(pid_t get_unix_pid() const, g_credentials_get_unix_pid, errthrow "Gio::Error", ifdef G_OS_UNIX) }; diff --git a/gio/src/datainputstream.ccg b/gio/src/datainputstream.ccg index 3665ac9..d5b31b4 100644 --- a/gio/src/datainputstream.ccg +++ b/gio/src/datainputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -97,81 +94,6 @@ DataInputStream::read_line_finish(const Glib::RefPtr& result, std:: } bool -DataInputStream::read_until( - std::string& data, const std::string& stop_chars, const Glib::RefPtr& cancellable) -{ - GError* gerror = nullptr; - char* c_str = g_data_input_stream_read_until(gobj(), stop_chars.c_str(), - nullptr, // pass nullptr since we can easily determine the length from the returned std::string - Glib::unwrap(cancellable), &gerror); - if (gerror) - ::Glib::Error::throw_exception(gerror); - if (c_str) - { - data = c_str; - g_free(c_str); - return true; - } - // end of stream reached, return failure status - return false; -} - -/** non-cancellable version of read_until() - */ -bool -DataInputStream::read_until(std::string& data, const std::string& stop_chars) -{ - GError* gerror = nullptr; - char* c_str = g_data_input_stream_read_until(gobj(), stop_chars.c_str(), - nullptr, // pass nullptr since we can easily determine the length from the returned std::string - nullptr, &gerror); - if (gerror) - ::Glib::Error::throw_exception(gerror); - if (c_str) - { - data = c_str; - g_free(c_str); - return true; - } - // end of stream reached, return failure status - return false; -} - -void -DataInputStream::read_until_async(const std::string& stop_chars, const SlotAsyncReady& slot, - const Glib::RefPtr& cancellable, int io_priority) -{ - // Create a copy of the slot. - // A pointer to it will be passed through the callback's data parameter - // and deleted in the callback. - auto slot_copy = new SlotAsyncReady(slot); - - g_data_input_stream_read_until_async(gobj(), stop_chars.c_str(), io_priority, - Glib::unwrap(cancellable), &SignalProxy_async_callback, slot_copy); -} - -bool -DataInputStream::read_until_finish(const Glib::RefPtr& result, std::string& data) -{ - GError* gerror = nullptr; - gsize size = 0; - gchar* buffer = - g_data_input_stream_read_until_finish(gobj(), Glib::unwrap(result), &size, &(gerror)); - if (gerror) - ::Glib::Error::throw_exception(gerror); - - bool retval = false; - if (buffer && size) - { - retval = (buffer != nullptr); - data = std::string(buffer, size); - g_free(buffer); - } - - return retval; -} - -bool DataInputStream::read_upto( std::string& data, const std::string& stop_chars, const Glib::RefPtr& cancellable) { diff --git a/gio/src/datainputstream.hg b/gio/src/datainputstream.hg index 0b5a8bc..da15849 100644 --- a/gio/src/datainputstream.hg +++ b/gio/src/datainputstream.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -72,7 +69,7 @@ public: * another thread. If the operation * was cancelled, a Gio::Error with CANCELLED will be thrown. * - * @param line A string to fill with the read data (without the newlines). + * @param[out] line A string to fill with the read data (without the newlines). * @param cancellable A cancellable object. * @result true if the read succeeded without error. */ @@ -81,25 +78,38 @@ public: /** A non-cancellable version of read_line(). * - * @param line A string to fill with the read data (without the newlines). + * @param[out] line A string to fill with the read data (without the newlines). * @result true if the read succeeded without error. */ bool read_line(std::string& line); -// The below initialization is unusual because it stores the return in a 'tmp' -// variable, sets the output parameter and then frees the return. If this is -// too weird, the methods can probably be just handwritten. -# _INITIALIZATION(`std::string&',`return-char*',`char* tmp = $4; $3 = tmp; g_free(tmp)') - +#m4 _INITIALIZATION(`std::string&',`return-char*',`$3 = Glib::convert_return_gchar_ptr_to_stdstring($4)') + /** Reads a UTF-8 encoded line from the data input stream. + * + * If @a cancellable is supplied and not equal to Glib::RefPtr(), + * then the operation can be cancelled by triggering the cancellable object + * from another thread. If the operation was cancelled, Gio::Error with + * code() == Gio::Error::CANCELLED will be thrown. + * + * @newin{2,30} + * + * @param[out] line A UTF-8 string with the line that was read in (without the newlines). + * Supply @a length to get the length of the read line. On an error, + * @a line is set to an empty string and an exception is thrown. For UTF-8 + * conversion errors, a Glib::ConvertError is thrown. If there's no content + * to read, @a line will still be set to an empty string, but no exception + * will be thrown. + * @param cancellable Optional Cancellable object. + * @param[out] length An optional gsize to get the length of the data read in. + */ _WRAP_METHOD(void read_line_utf8(std::string& line{OUT}, const Glib::RefPtr& cancellable{.?}, gsize& length{.?}), g_data_input_stream_read_line_utf8, errthrow) - /** The asynchronous version of read_until(). It is + /** The asynchronous version of read_line(). It is * an error to have two outstanding calls to this function. * * @param slot The slot to call when the request is satisfied. * @param cancellable A cancellable object. * @param io_priority The I/O priority of the request. - * @result true if the read succeeded without error. */ void read_line_async(const SlotAsyncReady& slot, const Glib::RefPtr& cancellable, int io_priority = Glib::PRIORITY_DEFAULT); _IGNORE(g_data_input_stream_read_line_async) @@ -107,95 +117,34 @@ public: /** Finish an asynchronous call started by read_line_async(). * * @param result The AsyncResult that was provided to the callback slot. - * @param data A string to fill with the read data. + * @param[out] data A string to fill with the read data. * @result true if the read succeeded without error. */ bool read_line_finish(const Glib::RefPtr& result, std::string& data); _IGNORE(g_data_input_stream_read_line_finish) - _WRAP_METHOD(void read_line_finish_utf8(const Glib::RefPtr& result{.}, std::string& data{OUT}, gsize& length{.?}), g_data_input_stream_read_line_finish_utf8, errthrow) - - /** Reads a string from the data input stream, up to the first - * occurrence of any of the stop characters. - * - * Note that, in contrast to read_until_async(), - * this function consumes the stop character that it finds. - * - * Don't use this function in new code. Its functionality is - * inconsistent with read_until_async(). Both - * functions will be marked as deprecated in a future release. Use - * read_upto() instead, but note that that method - * does not consume the stop character. - * - * @param data A string to fill with the read data. - * @param stop_chars Characters to terminate the read. - * @param cancellable A cancellable object. - * @result true if the read succeeded without error. - */ - bool read_until(std::string& data, const std::string& stop_chars, const Glib::RefPtr& cancellable); - _IGNORE(g_data_input_stream_read_until) - - //TODO: This will be really deprecated sometime, maybe sometime after glib 2.30.0. - /** A non-cancellable version of read_until(). - * - * Note that, in contrast to read_until_async(), - * this function consumes the stop character that it finds. - * - * Don't use this function in new code. Its functionality is - * inconsistent with read_until_async(). Both - * functions will be marked as deprecated in a future release. Use - * read_upto() instead, but note that that method - * does not consume the stop character. - * - * @param data A string to fill with the read data. - * @param stop_chars Characters to terminate the read. - * @result true if the read succeeded without error. - */ - bool read_until(std::string& data, const std::string& stop_chars); - - //TODO: This will be really deprecated sometime after glib 2.30.0. - /** The asynchronous version of read_until(). It is - * an error to have two outstanding calls to this function. - * - * Note that, in contrast to ead_until(), - * this function does not consume the stop character that it finds. You - * must read it for yourself. - * + /** Finish an asynchronous call started by read_line_async(). * - * Don't use this function in new code. Its functionality is - * inconsistent with read_until(). Both functions - * will be marked as deprecated in a future release. Use - * read_upto_async() instead. + * @newin{2,30} * - * @param stop_chars Characters to terminate the read. - * @param slot The slot to call when the request is satisfied. - * @param cancellable A cancellable object. - * @param io_priority The I/O priority of the request. - * @result true if the read succeeded without error. - */ - void read_until_async(const std::string& stop_chars, const SlotAsyncReady& slot, const Glib::RefPtr& cancellable, int io_priority = Glib::PRIORITY_DEFAULT); - _IGNORE(g_data_input_stream_read_until_async) - - //TODO: This will be really deprecated sometime after glib 2.30.0. - /** Finish an asynchronous call started by read_until_async(). - * - * @param result The AsyncResult that was provided to the callback slot. - * @param data A string to fill with the read data. - * @result true if the read succeeded without error. + * @param result The AsyncResult that was provided to the callback. + * @param[out] data A UTF-8 string with the line that was read in (without the newlines). + * Supply @a length to get the length of the read line. On an error, + * @a line is set to an empty string and an exception is thrown. For UTF-8 + * conversion errors, a Glib::ConvertError is thrown. If there's no content + * to read, @a line will still be set to an empty string, but no exception + * will be thrown. + * @param[out] length An optional gsize to get the length of the data read in. */ - bool read_until_finish(const Glib::RefPtr& result, std::string& data); - _IGNORE(g_data_input_stream_read_until_finish) - + _WRAP_METHOD(void read_line_finish_utf8(const Glib::RefPtr& result{.}, std::string& data{OUT}, gsize& length{.?}), g_data_input_stream_read_line_finish_utf8, errthrow) /** Reads a string from the data input stream, up to the first * occurrence of any of the stop characters. * - * In contrast to read_until(), this method - * does not consume the stop character. You have - * to use read_byte() to get it before calling - * read_upto() again. + * This method does not consume the stop character. You have + * to use read_byte() to get it before calling %read_upto() again. * - * @param data A string to fill with the read data. + * @param[out] data A string to fill with the read data. * @param stop_chars Characters to terminate the read. * @param cancellable A cancellable object. * @result true if the read succeeded without error. @@ -204,7 +153,7 @@ public: _IGNORE(g_data_input_stream_read_upto) /** A non-cancellable version of read_upto(). - * @param data A string to fill with the read data. + * @param[out] data A string to fill with the read data. * @param stop_chars Characters to terminate the read. * @result true if the read succeeded without error. */ @@ -215,16 +164,13 @@ public: /** The asynchronous version of read_upto(). It is * an error to have two outstanding calls to this function. * - * In contrast to read_until(), this method - * does not consume the stop character. You have - * to use read_byte() to get it before calling - * read_upto() again. + * This method does not consume the stop character. You have + * to use read_byte() to get it before calling %read_upto_async() again. * * @param stop_chars Characters to terminate the read. * @param slot The slot to call when the request is satisfied. * @param cancellable A cancellable object. * @param io_priority The I/O priority of the request. - * @result true if the read succeeded without error. */ void read_upto_async(const std::string& stop_chars, const SlotAsyncReady& slot, const Glib::RefPtr& cancellable, int io_priority = Glib::PRIORITY_DEFAULT); _IGNORE(g_data_input_stream_read_upto_async) @@ -236,7 +182,7 @@ public: * get it before calling read_upto_async() again. * * @param result The AsyncResult that was provided to the callback slot. - * @param data A string to fill with the read data. + * @param[out] data A string to fill with the read data. * @result true if the read succeeded without error. */ bool read_upto_finish(const Glib::RefPtr& result, std::string& data); diff --git a/gio/src/dataoutputstream.ccg b/gio/src/dataoutputstream.ccg index 5e41c70..c2e4ec8 100644 --- a/gio/src/dataoutputstream.ccg +++ b/gio/src/dataoutputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dataoutputstream.hg b/gio/src/dataoutputstream.hg index efd8211..2e87789 100644 --- a/gio/src/dataoutputstream.hg +++ b/gio/src/dataoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusactiongroup.ccg b/gio/src/dbusactiongroup.ccg index b8012ef..2069b14 100644 --- a/gio/src/dbusactiongroup.ccg +++ b/gio/src/dbusactiongroup.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusactiongroup.hg b/gio/src/dbusactiongroup.hg index 991e106..fde6a35 100644 --- a/gio/src/dbusactiongroup.hg +++ b/gio/src/dbusactiongroup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusaddress.ccg b/gio/src/dbusaddress.ccg index 30f2366..09a2188 100644 --- a/gio/src/dbusaddress.ccg +++ b/gio/src/dbusaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusaddress.hg b/gio/src/dbusaddress.hg index ab5acd7..aa105e7 100644 --- a/gio/src/dbusaddress.hg +++ b/gio/src/dbusaddress.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusauthobserver.ccg b/gio/src/dbusauthobserver.ccg index 8c30743..d9f062c 100644 --- a/gio/src/dbusauthobserver.ccg +++ b/gio/src/dbusauthobserver.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusauthobserver.hg b/gio/src/dbusauthobserver.hg index 931af72..03876c0 100644 --- a/gio/src/dbusauthobserver.hg +++ b/gio/src/dbusauthobserver.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusconnection.ccg b/gio/src/dbusconnection.ccg index 5fe37d9..a7464c2 100644 --- a/gio/src/dbusconnection.ccg +++ b/gio/src/dbusconnection.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusconnection.hg b/gio/src/dbusconnection.hg index c779cc5..f17992f 100644 --- a/gio/src/dbusconnection.hg +++ b/gio/src/dbusconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -217,8 +216,6 @@ public: */ static void get(BusType bus_type, const SlotAsyncReady& slot); - _WRAP_METHOD_DOCS_ONLY( g_bus_get_finish, errthrow) - /// @throw Glib::Error. _WRAP_METHOD(static Glib::RefPtr get_finish(const Glib::RefPtr& res), g_bus_get_finish, errthrow) _WRAP_METHOD(static Glib::RefPtr get_sync(BusType bus_type, const Glib::RefPtr& cancellable{?}), g_bus_get_sync, errthrow) @@ -251,8 +248,6 @@ public: const SlotAsyncReady& slot, ConnectionFlags flags = Gio::DBus::ConnectionFlags::NONE); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_finish) - /// @throw Glib::Error. _WRAP_METHOD(static Glib::RefPtr create_finish(const Glib::RefPtr& res), g_dbus_connection_new_finish, errthrow) _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address) @@ -279,12 +274,9 @@ public: const SlotAsyncReady& slot, ConnectionFlags flags = Gio::DBus::ConnectionFlags::NONE); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address_finish) - /// @throw Glib::Error. _WRAP_METHOD(static Glib::RefPtr create_for_address_finish(const Glib::RefPtr& res), g_dbus_connection_new_for_address_finish, errthrow) - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_sync) - /// @throw Glib::Error. + _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_sync, errthrow) static Glib::RefPtr create_sync( const Glib::RefPtr& stream, const std::string& guid, @@ -292,8 +284,7 @@ public: const Glib::RefPtr& cancellable, ConnectionFlags flags = Gio::DBus::ConnectionFlags::NONE); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_sync) - /// @throw Glib::Error. + _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_sync, errthrow) static Glib::RefPtr create_sync( const Glib::RefPtr& stream, const std::string& guid, @@ -313,16 +304,14 @@ public: const std::string& guid, ConnectionFlags flags = Gio::DBus::ConnectionFlags::NONE); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address_sync) - /// @throw Glib::Error. + _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address_sync, errthrow) static Glib::RefPtr create_for_address_sync( const std::string& address, const Glib::RefPtr& observer, const Glib::RefPtr& cancellable, ConnectionFlags flags = Gio::DBus::ConnectionFlags::NONE); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address_sync) - /// @throw Glib::Error. + _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_new_for_address_sync, errthrow) static Glib::RefPtr create_for_address_sync( const std::string& address, const Glib::RefPtr& cancellable, @@ -533,8 +522,6 @@ public: int timeout_msec, const SlotAsyncReady& slot); - _WRAP_METHOD_DOCS_ONLY(g_dbus_connection_send_message_with_reply_finish) - /// @throw Glib::Error. _WRAP_METHOD(Glib::RefPtr send_message_with_reply_finish(const Glib::RefPtr& res), g_dbus_connection_send_message_with_reply_finish, errthrow) /** Synchronously sends @a message to the peer represented by the connection diff --git a/gio/src/dbuserror.ccg b/gio/src/dbuserror.ccg index 555a34b..e3c93dc 100644 --- a/gio/src/dbuserror.ccg +++ b/gio/src/dbuserror.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbuserror.hg b/gio/src/dbuserror.hg index 1e52dbb..95bfe59 100644 --- a/gio/src/dbuserror.hg +++ b/gio/src/dbuserror.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbuserrorutils.ccg b/gio/src/dbuserrorutils.ccg index d4e3490..f9dae85 100644 --- a/gio/src/dbuserrorutils.ccg +++ b/gio/src/dbuserrorutils.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbuserrorutils.hg b/gio/src/dbuserrorutils.hg index a2c8ece..084fa0c 100644 --- a/gio/src/dbuserrorutils.hg +++ b/gio/src/dbuserrorutils.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(giomm,gio) diff --git a/gio/src/dbusinterface.ccg b/gio/src/dbusinterface.ccg index af4aa8e..4d2a74d 100644 --- a/gio/src/dbusinterface.ccg +++ b/gio/src/dbusinterface.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusinterface.hg b/gio/src/dbusinterface.hg index 485d2b5..41cd5ec 100644 --- a/gio/src/dbusinterface.hg +++ b/gio/src/dbusinterface.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusinterfaceskeleton.ccg b/gio/src/dbusinterfaceskeleton.ccg index 50e1f9f..a327e96 100644 --- a/gio/src/dbusinterfaceskeleton.ccg +++ b/gio/src/dbusinterfaceskeleton.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusinterfaceskeleton.hg b/gio/src/dbusinterfaceskeleton.hg index ef7b1a2..c027fba 100644 --- a/gio/src/dbusinterfaceskeleton.hg +++ b/gio/src/dbusinterfaceskeleton.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusinterfacevtable.ccg b/gio/src/dbusinterfacevtable.ccg index c6ffd89..d47b5a9 100644 --- a/gio/src/dbusinterfacevtable.ccg +++ b/gio/src/dbusinterfacevtable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusinterfacevtable.hg b/gio/src/dbusinterfacevtable.hg index c4081e7..0771568 100644 --- a/gio/src/dbusinterfacevtable.hg +++ b/gio/src/dbusinterfacevtable.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusintrospection.ccg b/gio/src/dbusintrospection.ccg index 4a37d37..43f761c 100644 --- a/gio/src/dbusintrospection.ccg +++ b/gio/src/dbusintrospection.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusintrospection.hg b/gio/src/dbusintrospection.hg index a99d4e3..cdebc86 100644 --- a/gio/src/dbusintrospection.hg +++ b/gio/src/dbusintrospection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -136,9 +135,7 @@ class NodeInfo final _IGNORE(g_dbus_node_info_ref, g_dbus_node_info_unref) public: - _WRAP_METHOD_DOCS_ONLY(g_dbus_node_info_new_for_xml) - /// @throw Glib::Error. - _WRAP_METHOD(static Glib::RefPtr create_for_xml(const Glib::ustring& xml_data), g_dbus_node_info_new_for_xml, errthrow) + _WRAP_METHOD(static Glib::RefPtr create_for_xml(const Glib::ustring& xml_data), g_dbus_node_info_new_for_xml, errthrow "Glib::MarkupError") _WRAP_METHOD(Glib::RefPtr lookup_interface(const Glib::ustring& name), g_dbus_node_info_lookup_interface, refreturn) _WRAP_METHOD(Glib::RefPtr lookup_interface(const Glib::ustring& name) const, g_dbus_node_info_lookup_interface, constversion, refreturn) diff --git a/gio/src/dbusmenumodel.ccg b/gio/src/dbusmenumodel.ccg index b8012ef..2069b14 100644 --- a/gio/src/dbusmenumodel.ccg +++ b/gio/src/dbusmenumodel.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusmenumodel.hg b/gio/src/dbusmenumodel.hg index 6ada9ed..f704350 100644 --- a/gio/src/dbusmenumodel.hg +++ b/gio/src/dbusmenumodel.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusmessage.ccg b/gio/src/dbusmessage.ccg index 751fbfd..50fe956 100644 --- a/gio/src/dbusmessage.ccg +++ b/gio/src/dbusmessage.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusmessage.hg b/gio/src/dbusmessage.hg index 0abe21a..52d1208 100644 --- a/gio/src/dbusmessage.hg +++ b/gio/src/dbusmessage.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -76,14 +75,14 @@ public: // Ignore variable argument functions. _IGNORE(g_dbus_message_new_method_error, g_dbus_message_new_method_error_valist) - _WRAP_METHOD(static Glib::RefPtr create_from_blob(const guchar* blob, gsize blob_len, CapabilityFlags capabilities = CapabilityFlags::NONE), g_dbus_message_new_from_blob, errthrow) + _WRAP_METHOD(static Glib::RefPtr create_from_blob(const guchar* blob, gsize blob_len, CapabilityFlags capabilities = CapabilityFlags::NONE), g_dbus_message_new_from_blob, errthrow "Gio::Error") _WRAP_METHOD(Glib::ustring print(guint indent), g_dbus_message_print) _WRAP_METHOD(bool get_locked() const, g_dbus_message_get_locked) _WRAP_METHOD(void lock() ,g_dbus_message_lock) - _WRAP_METHOD(Glib::RefPtr copy() const, g_dbus_message_copy, errthrow) + _WRAP_METHOD(Glib::RefPtr copy() const, g_dbus_message_copy, errthrow "Gio::Error") _WRAP_METHOD(MessageType get_message_type() const, g_dbus_message_get_message_type) _WRAP_METHOD(void set_message_type(MessageType type), g_dbus_message_set_message_type) @@ -159,9 +158,9 @@ public: _WRAP_METHOD(Glib::ustring get_arg0() const, g_dbus_message_get_arg0) - _WRAP_METHOD(static gssize bytes_needed(const guchar* blob, gsize blob_len), g_dbus_message_bytes_needed, errthrow) + _WRAP_METHOD(static gssize bytes_needed(const guchar* blob, gsize blob_len), g_dbus_message_bytes_needed, errthrow "Gio::Error") - _WRAP_METHOD(guchar* to_blob(gsize& out_size, CapabilityFlags capabilities = CapabilityFlags::NONE), g_dbus_message_to_blob, errthrow) + _WRAP_METHOD(guchar* to_blob(gsize& out_size, CapabilityFlags capabilities = CapabilityFlags::NONE), g_dbus_message_to_blob, errthrow "Gio::Error") _WRAP_METHOD(void to_exception(), g_dbus_message_to_gerror, errthrow) diff --git a/gio/src/dbusmethodinvocation.ccg b/gio/src/dbusmethodinvocation.ccg index 02c2c65..870b3f7 100644 --- a/gio/src/dbusmethodinvocation.ccg +++ b/gio/src/dbusmethodinvocation.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusmethodinvocation.hg b/gio/src/dbusmethodinvocation.hg index 84fecef..65e81c0 100644 --- a/gio/src/dbusmethodinvocation.hg +++ b/gio/src/dbusmethodinvocation.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include diff --git a/gio/src/dbusobject.ccg b/gio/src/dbusobject.ccg index 68334df..7e1543d 100644 --- a/gio/src/dbusobject.ccg +++ b/gio/src/dbusobject.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusobject.hg b/gio/src/dbusobject.hg index 6979d82..3be72cf 100644 --- a/gio/src/dbusobject.hg +++ b/gio/src/dbusobject.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusownname.ccg b/gio/src/dbusownname.ccg index db1a37b..81a7a9f 100644 --- a/gio/src/dbusownname.ccg +++ b/gio/src/dbusownname.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusownname.hg b/gio/src/dbusownname.hg index 596171e..f0c660b 100644 --- a/gio/src/dbusownname.hg +++ b/gio/src/dbusownname.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusproxy.ccg b/gio/src/dbusproxy.ccg index 67ad4fa..eb8c311 100644 --- a/gio/src/dbusproxy.ccg +++ b/gio/src/dbusproxy.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusproxy.hg b/gio/src/dbusproxy.hg index fb49e88..332e229 100644 --- a/gio/src/dbusproxy.hg +++ b/gio/src/dbusproxy.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusserver.ccg b/gio/src/dbusserver.ccg index 403bd3b..82f3bac 100644 --- a/gio/src/dbusserver.ccg +++ b/gio/src/dbusserver.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusserver.hg b/gio/src/dbusserver.hg index 914dd17..217ed96 100644 --- a/gio/src/dbusserver.hg +++ b/gio/src/dbusserver.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbussubtreevtable.ccg b/gio/src/dbussubtreevtable.ccg index 0445386..59ea274 100644 --- a/gio/src/dbussubtreevtable.ccg +++ b/gio/src/dbussubtreevtable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbussubtreevtable.hg b/gio/src/dbussubtreevtable.hg index 3c2d6d8..fcfbb99 100644 --- a/gio/src/dbussubtreevtable.hg +++ b/gio/src/dbussubtreevtable.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusutils.ccg b/gio/src/dbusutils.ccg index a614bce..a84de1f 100644 --- a/gio/src/dbusutils.ccg +++ b/gio/src/dbusutils.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbusutils.hg b/gio/src/dbusutils.hg index ac2acf9..85844dc 100644 --- a/gio/src/dbusutils.hg +++ b/gio/src/dbusutils.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(giomm,gio) diff --git a/gio/src/dbuswatchname.ccg b/gio/src/dbuswatchname.ccg index fa7a1ee..04878e7 100644 --- a/gio/src/dbuswatchname.ccg +++ b/gio/src/dbuswatchname.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/dbuswatchname.hg b/gio/src/dbuswatchname.hg index 46d95d8..555bcac 100644 --- a/gio/src/dbuswatchname.hg +++ b/gio/src/dbuswatchname.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/desktopappinfo.ccg b/gio/src/desktopappinfo.ccg index 42cfd45..27a37e7 100644 --- a/gio/src/desktopappinfo.ccg +++ b/gio/src/desktopappinfo.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/desktopappinfo.hg b/gio/src/desktopappinfo.hg index 6a9f130..f9a0604 100644 --- a/gio/src/desktopappinfo.hg +++ b/gio/src/desktopappinfo.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/drive.ccg b/gio/src/drive.ccg index 75bbea6..95186ea 100644 --- a/gio/src/drive.ccg +++ b/gio/src/drive.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/drive.hg b/gio/src/drive.hg index 12b281c..a65d083 100644 --- a/gio/src/drive.hg +++ b/gio/src/drive.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/emblem.ccg b/gio/src/emblem.ccg index fb5dbea..0220a12 100644 --- a/gio/src/emblem.ccg +++ b/gio/src/emblem.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/emblem.hg b/gio/src/emblem.hg index 9a88414..1ee816b 100644 --- a/gio/src/emblem.hg +++ b/gio/src/emblem.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/emblemedicon.ccg b/gio/src/emblemedicon.ccg index faa8e37..ebf9ed1 100644 --- a/gio/src/emblemedicon.ccg +++ b/gio/src/emblemedicon.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/emblemedicon.hg b/gio/src/emblemedicon.hg index 8ccd5ad..de9a291 100644 --- a/gio/src/emblemedicon.hg +++ b/gio/src/emblemedicon.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -82,9 +79,9 @@ public: #m4 _CONVERSION(`GList*',`std::vector>',`Glib::ListHandler>::list_to_vector($3, Glib::OWNERSHIP_NONE)') _WRAP_METHOD(std::vector> get_emblems(), g_emblemed_icon_get_emblems) - -//TODO: #m4 _CONVERSION(`GList*',`std::vector>',`$2($3, Glib::OWNERSHIP_NONE)') -// _WRAP_METHOD(std::vector> get_emblems() const, g_emblemed_icon_get_emblems, constversion) + dnl// Can't use the constversion parameter in _WRAP_METHOD() when a vector is returned. +#m4 _CONVERSION(`GList*',`std::vector>',`Glib::ListHandler>::list_to_vector($3, Glib::OWNERSHIP_NONE)') + _WRAP_METHOD(std::vector> get_emblems() const, g_emblemed_icon_get_emblems) _WRAP_METHOD(void add_emblem(const Glib::RefPtr& emblem), g_emblemed_icon_add_emblem) _WRAP_METHOD(void clear_emblems(), g_emblemed_icon_clear_emblems) diff --git a/gio/src/enums.ccg b/gio/src/enums.ccg index 24ee9e8..1c574d6 100644 --- a/gio/src/enums.ccg +++ b/gio/src/enums.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,6 +11,5 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ diff --git a/gio/src/enums.hg b/gio/src/enums.hg index 7cbe7f5..d306225 100644 --- a/gio/src/enums.hg +++ b/gio/src/enums.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/error.ccg b/gio/src/error.ccg index 3f6ca4c..fd123ae 100644 --- a/gio/src/error.ccg +++ b/gio/src/error.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/error.hg b/gio/src/error.hg index 5369fa4..7df46d2 100644 --- a/gio/src/error.hg +++ b/gio/src/error.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/file.ccg b/gio/src/file.ccg index 846ee18..2e8f428 100644 --- a/gio/src/file.ccg +++ b/gio/src/file.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/file.hg b/gio/src/file.hg index 5df6972..9e3a9f5 100644 --- a/gio/src/file.hg +++ b/gio/src/file.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileattributeinfo.ccg b/gio/src/fileattributeinfo.ccg index e33784c..63ed535 100644 --- a/gio/src/fileattributeinfo.ccg +++ b/gio/src/fileattributeinfo.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileattributeinfo.hg b/gio/src/fileattributeinfo.hg index a76d04d..0c9c9a5 100644 --- a/gio/src/fileattributeinfo.hg +++ b/gio/src/fileattributeinfo.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileattributeinfolist.ccg b/gio/src/fileattributeinfolist.ccg index 98d0efa..eee5028 100644 --- a/gio/src/fileattributeinfolist.ccg +++ b/gio/src/fileattributeinfolist.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileattributeinfolist.hg b/gio/src/fileattributeinfolist.hg index 1dcec02..2ea1dc7 100644 --- a/gio/src/fileattributeinfolist.hg +++ b/gio/src/fileattributeinfolist.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileenumerator.ccg b/gio/src/fileenumerator.ccg index b59cca0..9b975bc 100644 --- a/gio/src/fileenumerator.ccg +++ b/gio/src/fileenumerator.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileenumerator.hg b/gio/src/fileenumerator.hg index ace27e5..6e59340 100644 --- a/gio/src/fileenumerator.hg +++ b/gio/src/fileenumerator.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The glibmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileicon.ccg b/gio/src/fileicon.ccg index 70b732c..06d4e85 100644 --- a/gio/src/fileicon.ccg +++ b/gio/src/fileicon.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileicon.hg b/gio/src/fileicon.hg index f3ac97a..dd4d3d6 100644 --- a/gio/src/fileicon.hg +++ b/gio/src/fileicon.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileinfo.ccg b/gio/src/fileinfo.ccg index fa35995..d18d926 100644 --- a/gio/src/fileinfo.ccg +++ b/gio/src/fileinfo.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileinfo.hg b/gio/src/fileinfo.hg index 93a39a6..ae22d38 100644 --- a/gio/src/fileinfo.hg +++ b/gio/src/fileinfo.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileinputstream.ccg b/gio/src/fileinputstream.ccg index ef1b73e..9280054 100644 --- a/gio/src/fileinputstream.ccg +++ b/gio/src/fileinputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileinputstream.hg b/gio/src/fileinputstream.hg index a9cca15..0159d8c 100644 --- a/gio/src/fileinputstream.hg +++ b/gio/src/fileinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileiostream.ccg b/gio/src/fileiostream.ccg index 21002d3..f358384 100644 --- a/gio/src/fileiostream.ccg +++ b/gio/src/fileiostream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileiostream.hg b/gio/src/fileiostream.hg index 3f2ca9c..e6f66ce 100644 --- a/gio/src/fileiostream.hg +++ b/gio/src/fileiostream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filemonitor.ccg b/gio/src/filemonitor.ccg index 5bcc977..150291f 100644 --- a/gio/src/filemonitor.ccg +++ b/gio/src/filemonitor.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filemonitor.hg b/gio/src/filemonitor.hg index 6348ee9..e51eddf 100644 --- a/gio/src/filemonitor.hg +++ b/gio/src/filemonitor.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include diff --git a/gio/src/filenamecompleter.ccg b/gio/src/filenamecompleter.ccg index 3161de1..3901af9 100644 --- a/gio/src/filenamecompleter.ccg +++ b/gio/src/filenamecompleter.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filenamecompleter.hg b/gio/src/filenamecompleter.hg index 5ec035a..5115c4f 100644 --- a/gio/src/filenamecompleter.hg +++ b/gio/src/filenamecompleter.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include diff --git a/gio/src/fileoutputstream.ccg b/gio/src/fileoutputstream.ccg index 2e8040c..d118060 100644 --- a/gio/src/fileoutputstream.ccg +++ b/gio/src/fileoutputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/fileoutputstream.hg b/gio/src/fileoutputstream.hg index 3539c4c..f8682ab 100644 --- a/gio/src/fileoutputstream.hg +++ b/gio/src/fileoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filterinputstream.ccg b/gio/src/filterinputstream.ccg index f69b83d..2ef4fcf 100644 --- a/gio/src/filterinputstream.ccg +++ b/gio/src/filterinputstream.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filterinputstream.hg b/gio/src/filterinputstream.hg index bd35f73..1549bd4 100644 --- a/gio/src/filterinputstream.hg +++ b/gio/src/filterinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filteroutputstream.ccg b/gio/src/filteroutputstream.ccg index 49d0402..ddcd3ef 100644 --- a/gio/src/filteroutputstream.ccg +++ b/gio/src/filteroutputstream.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/filteroutputstream.hg b/gio/src/filteroutputstream.hg index 6af0821..7a9f762 100644 --- a/gio/src/filteroutputstream.hg +++ b/gio/src/filteroutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/gio_docs.xml b/gio/src/gio_docs.xml index 239e443..38ba91c 100644 --- a/gio/src/gio_docs.xml +++ b/gio/src/gio_docs.xml @@ -519,6 +519,11 @@ Since: 2.26 specified #G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT, then take the name from the other connection. + + If another message bus connection owns the name, immediately +return an error from g_bus_own_name() rather than entering the waiting queue for that name. (Since 2.54) + + @@ -1659,7 +1664,8 @@ Since: 2.30 - A %NULL terminated array of properties that was invalidated. + A %NULL terminated +array of properties that were invalidated. @@ -2125,7 +2131,7 @@ This flag is only meaningful in proxies for well-known names. - If set, the property value for any <emphasis>invalidated property</emphasis> will be (asynchronously) retrieved upon receiving the <ulink url="http://dbus.freedesktop.org/doc/dbus-specification.html#standard-interfaces-properties">PropertiesChanged</ulink> D-Bus signal and the property will not cause emission of the #GDBusProxy::g-properties-changed signal. When the value is received the #GDBusProxy::g-properties-changed signal is emitted for the property along with the retrieved value. Since 2.32. + If set, the property value for any __invalidated property__ will be (asynchronously) retrieved upon receiving the [`PropertiesChanged`](http://dbus.freedesktop.org/doc/dbus-specification.html#standard-interfaces-properties) D-Bus signal and the property will not cause emission of the #GDBusProxy::g-properties-changed signal. When the value is received the #GDBusProxy::g-properties-changed signal is emitted for the property along with the retrieved value. Since 2.32. @@ -2666,7 +2672,7 @@ Since: 2.48 The certificate database to use when verifying this TLS connection. If no certificate database is set, then the default database will be -used. See g_dtls_backend_get_default_database(). +used. See g_tls_backend_get_default_database(). Since: 2.48 @@ -3064,19 +3070,19 @@ Specifies what type of event a monitor event is. the file was renamed within the current directory -- only sent if the %G_FILE_MONITOR_WATCH_MOVES -flag is set. Since: 2.44. +flag is set. Since: 2.46. the file was moved into the monitored directory from another location -- only sent if the -%G_FILE_MONITOR_WATCH_MOVES flag is set. Since: 2.44. +%G_FILE_MONITOR_WATCH_MOVES flag is set. Since: 2.46. the file was moved out of the monitored directory to another location -- only sent if the -%G_FILE_MONITOR_WATCH_MOVES flag is set. Since: 2.44 +%G_FILE_MONITOR_WATCH_MOVES flag is set. Since: 2.46 @@ -3101,7 +3107,7 @@ Flags used to set what a #GFileMonitor will watch for. by file renames (moves) and send a single G_FILE_MONITOR_EVENT_MOVED event instead (NB: not supported on all backends; the default behaviour -without specifying this flag- is to send single DELETED -and CREATED events). Deprecated since 2.44: use +and CREATED events). Deprecated since 2.46: use %G_FILE_MONITOR_WATCH_MOVES instead. @@ -3114,7 +3120,7 @@ via another hard link. Since 2.36. Watch for rename operations on a monitored directory. This causes %G_FILE_MONITOR_EVENT_RENAMED, %G_FILE_MONITOR_EVENT_MOVED_IN and %G_FILE_MONITOR_EVENT_MOVED_OUT -events to be emitted when possible. Since: 2.44. +events to be emitted when possible. Since: 2.46. @@ -3743,9 +3749,12 @@ Emitted when the mount has been changed. -This signal is emitted when the #GMount is about to be +This signal may be emitted when the #GMount is about to be unmounted. +This signal depends on the backend and is only emitted if +GIO was used to unmount. + Since: 2.22 @@ -4683,7 +4692,7 @@ callbacks when the writability of "x" changes. - + The name of the context that the settings are stored in. @@ -5980,7 +5989,7 @@ Deprecated: 2.30: Use GTlsConnection:database instead -Flags for g_tls_database_lookup_certificate_handle(), +Flags for g_tls_database_lookup_certificate_for_handle(), g_tls_database_lookup_certificate_issuer(), and g_tls_database_lookup_certificates_issued_by(). @@ -6507,7 +6516,10 @@ Emitted when a mount changes. -Emitted when a mount is about to be removed. +May be emitted when a mount is about to be removed. + +This signal depends on the backend and is only emitted if +GIO was used to unmount. @@ -6687,6 +6699,48 @@ If a signal handler returns %TRUE, it means the signal handler will handle the i + + +Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddFull">AddFull()</link> D-Bus method. + +If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call gxdp_documents_complete_add_full() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned. + + + + + + A #GXdpDocuments. + + + + A #GDBusMethodInvocation. + + + + A #GUnixFDList or %NULL. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + %TRUE if the invocation was handled, %FALSE to let other signal handlers run. + + + Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddNamed">AddNamed()</link> D-Bus method. @@ -6923,6 +6977,15 @@ If a signal handler returns %TRUE, it means the signal handler will handle the i + + +Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-portal-Documents.version">"version"</link>. + +Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side. + + + + On the client-side, this signal is emitted whenever the D-Bus signal <link linkend="gdbus-signal-org-freedesktop-portal-NetworkMonitor.changed">"changed"</link> is received. @@ -6970,6 +7033,87 @@ Since the D-Bus property for this #GObject property is readable but not writable + + +Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenFile">OpenFile()</link> D-Bus method. + +If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call gxdp_open_uri_complete_open_file() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned. + + + + + + A #GXdpOpenURI. + + + + A #GDBusMethodInvocation. + + + + A #GUnixFDList or %NULL. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + %TRUE if the invocation was handled, %FALSE to let other signal handlers run. + + + + + +Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenURI">OpenURI()</link> D-Bus method. + +If a signal handler returns %TRUE, it means the signal handler will handle the invocation (e.g. take a reference to @invocation and eventually call gxdp_open_uri_complete_open_uri() or e.g. g_dbus_method_invocation_return_error() on it) and no order signal handlers will run. If no signal handler handles the invocation, the %G_DBUS_ERROR_UNKNOWN_METHOD error is returned. + + + + + + A #GXdpOpenURI. + + + + A #GDBusMethodInvocation. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + Argument passed by remote caller. + + + + %TRUE if the invocation was handled, %FALSE to let other signal handlers run. + + + + + +Represents the D-Bus property <link linkend="gdbus-property-org-freedesktop-portal-OpenURI.version">"version"</link>. + +Since the D-Bus property for this #GObject property is readable but not writable, it is meaningful to read from it on both the client- and service-side. It is only meaningful, however, to write to it on the service-side. + + + + Signal emitted when a remote caller is invoking the <link linkend="gdbus-method-org-freedesktop-portal-ProxyResolver.Lookup">Lookup()</link> D-Bus method. @@ -8068,6 +8212,10 @@ Creates a duplicate of a #GAppInfo. Checks if two #GAppInfos are equal. +Note that the check <emphasis>may not</emphasis> compare each individual +field, and only does an identity check. In case detecting changes in the +contents is needed, program code must additionally compare relevant fields. + @@ -8365,7 +8513,7 @@ a list of content types. Launches the application. Passes @files to the launched application -as arguments, using the optional @launch_context to get information +as arguments, using the optional @context to get information about the details of the launcher (like what screen it is on). On error, @error will be set accordingly. @@ -8390,7 +8538,7 @@ environment variable with the path of the launched desktop file and process. This can be used to ignore `GIO_LAUNCHED_DESKTOP_FILE`, should it be inherited by further processes. The `DISPLAY` and `DESKTOP_STARTUP_ID` environment variables are also set, based -on information provided in @launch_context. +on information provided in @context. @@ -8403,7 +8551,7 @@ on information provided in @launch_context. a #GList of #GFile objects - + a #GAppLaunchContext or %NULL @@ -8430,7 +8578,7 @@ required. the uri to show - + an optional #GAppLaunchContext @@ -8462,7 +8610,10 @@ Since: 2.50 an optional #GAppLaunchContext -cancellable: (allow-none): a #GCancellable + + + + a #GCancellable @@ -8502,7 +8653,7 @@ Since: 2.50 Launches the application. This passes the @uris to the launched application -as arguments, using the optional @launch_context to get information +as arguments, using the optional @context to get information about the details of the launcher (like what screen it is on). On error, @error will be set accordingly. @@ -8523,7 +8674,7 @@ no way to detect this. a #GList containing URIs to launch. - + a #GAppLaunchContext or %NULL @@ -8769,8 +8920,8 @@ Since: 2.32 - the -child's environment + +the child's environment @@ -9158,8 +9309,8 @@ Since: 2.28 - the string array -containing the arguments (the argv) + (array length=argc) (element-type filename) (transfer full) +the string array containing the arguments (the argv) @@ -9216,8 +9367,8 @@ Since: 2.28 - the environment -strings, or %NULL if they were not sent + +the environment strings, or %NULL if they were not sent @@ -9728,7 +9879,7 @@ reproduced here: "[A-Z][a-z][0-9]_-." and must not begin with a digit. - Application identifiers must contain at least one '.' (period) -character (and thus at least three elements). +character (and thus at least two elements). - Application identifiers must not begin or end with a '.' (period) character. @@ -9850,6 +10001,10 @@ Upon return to the mainloop, g_application_run() will return, calling only the 'shutdown' function before doing so. The hold count is ignored. +Take care if your code has called g_application_hold() on the application and +is therefore still expecting it to exist. +(Note that you may have called g_application_hold() indirectly, for example +through gtk_application_add_window().) The result of calling g_application_run() again after it returns is unspecified. @@ -10031,7 +10186,8 @@ Since: 2.28 - the argv from main(), or %NULL + +the argv from main(), or %NULL @@ -10354,6 +10510,9 @@ interface. This must be done before any real use of the object after initial construction. If the object also implements #GInitable you can optionally call g_initable_init() instead. +This method is intended for language bindings. If writing in C, +g_async_initable_new_async() should typically be used instead. + When the initialization is finished, @callback will be called. You can then call g_async_initable_init_finish() to get the result of the initialization. @@ -10371,11 +10530,11 @@ g_object_ref() and g_object_unref() are considered to be invalid, and have undefined behaviour. They will often fail with g_critical() or g_warning(), but this must not be relied on. -Implementations of this method must be idempotent: i.e. multiple calls -to this function with the same argument should return the same results. -Only the first call initializes the object; further calls return the result -of the first call. This is so that it's safe to implement the singleton -pattern in the GObject constructor function. +Callers should not assume that a class which implements #GAsyncInitable can +be initialized multiple times; for more information, see g_initable_init(). +If a class explicitly supports being initialized multiple times, +implementation requires yielding all subsequent calls to init_async() on the +results of the first call. For classes that also support the #GInitable interface, the default implementation of this method will run the g_initable_init() function @@ -10574,6 +10733,8 @@ then call g_async_initable_new_finish() to get the new object and check for any errors. Since: 2.22 +Deprecated: 2.54: Use g_object_new_with_properties() and +g_async_initable_init_async() instead. See #GParameter for more information. @@ -10622,8 +10783,8 @@ Gets the source object from a #GAsyncResult. - a new reference to the source object for the @res, -or %NULL if there is none. + a new reference to the source +object for the @res, or %NULL if there is none. @@ -10810,7 +10971,7 @@ Finishes an asynchronous read. - a #gssize of the read stream, or %-1 on an error. + a #gssize of the read stream, or `-1` on an error. @@ -11781,7 +11942,7 @@ same time as the cancellable operation is finished and the signal handler is removed. See #GCancellable::cancelled for details on how to use this. -If @cancellable is %NULL or @handler_id is %0 this function does +If @cancellable is %NULL or @handler_id is `0` this function does nothing. Since: 2.22 @@ -11793,7 +11954,7 @@ Since: 2.22 - Handler id of the handler to be disconnected, or %0. + Handler id of the handler to be disconnected, or `0`. @@ -12366,11 +12527,36 @@ Determines if @type is a subset of @supertype. + + +Determines if @type is a subset of @mime_type. +Convenience wrapper around g_content_type_is_a(). + +Since: 2.52 + + + + + a content type string + + + + a mime type string + + + + %TRUE if @type is a kind of @mime_type, +%FALSE otherwise. + + + + Checks if the content type is the generic "unknown" type. On UNIX this is the "application/octet-stream" mimetype, -while on win32 it is "*". +while on win32 it is "*" and on OSX it is a dynamic type +or octet-stream. @@ -14215,7 +14401,8 @@ Since: 2.32 - the bus name which exports the action group + the bus name which exports the action +group or %NULL if @connection is not a message bus connection @@ -14233,10 +14420,10 @@ Since: 2.32 Escape @string so it can appear in a D-Bus address as the value part of a key-value pair. -For instance, if @string is "/run/bus-for-:0", -this function would return "/run/bus-for-%3A0", +For instance, if @string is `/run/bus-for-:0`, +this function would return `/run/bus-for-%3A0`, which could be used in a D-Bus address like -"unix:nonce-tcp:host=127.0.0.1,port=42,noncefile=/run/bus-for-%3A0". +`unix:nonce-tcp:host=127.0.0.1,port=42,noncefile=/run/bus-for-%3A0`. Since: 2.36 @@ -14260,6 +14447,9 @@ Synchronously looks up the D-Bus address for the well-known message bus instance specified by @bus_type. This may involve using various platform specific mechanisms. +The returned address will be in the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). + Since: 2.26 @@ -14287,7 +14477,8 @@ Since: 2.26 Asynchronously connects to an endpoint specified by @address and sets up the connection so it is in a state to run the client-side -of the D-Bus authentication conversation. +of the D-Bus authentication conversation. @address must be in the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). When the operation is finished, @callback will be invoked. You can then call g_dbus_address_get_stream_finish() to get the result of @@ -14350,7 +14541,8 @@ Since: 2.26 Synchronously connects to an endpoint specified by @address and sets up the connection so it is in a state to run the client-side -of the D-Bus authentication conversation. +of the D-Bus authentication conversation. @address must be in the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). This is a synchronous failable function. See g_dbus_address_get_stream() for the asynchronous version. @@ -15608,7 +15800,8 @@ with g_object_unref(). Asynchronously connects and sets up a D-Bus client connection for exchanging D-Bus messages with an endpoint specified by @address -which must be in the D-Bus address format. +which must be in the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). This constructor can only be used to initiate client-side connections - use g_dbus_connection_new() if you need to act as the @@ -15687,7 +15880,8 @@ g_object_unref(). Synchronously connects and sets up a D-Bus client connection for exchanging D-Bus messages with an endpoint specified by @address -which must be in the D-Bus address format. +which must be in the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). This constructor can only be used to initiate client-side connections - use g_dbus_connection_new_sync() if you need to act @@ -16866,7 +17060,11 @@ g_variant_unref(). Converts a #GVariant to a #GValue. If @value is floating, it is consumed. The rules specified in the g_dbus_gvalue_to_gvariant() function are -used - this function is essentially its reverse form. +used - this function is essentially its reverse form. So, a #GVariant +containing any basic or string array type will be converted to a #GValue +containing a basic value or string array. Any other #GVariant (handle, +variant, tuple, dict entry) will be converted to a #GValue containing that +#GVariant. The conversion never fails - a valid #GValue is always returned in @out_gvalue. @@ -17198,7 +17396,7 @@ emitted immediately. For example, an exported D-Bus interface may queue up property changes and emit the -`org.freedesktop.DBus.Properties::Propert`` +`org.freedesktop.DBus.Properties::PropertiesChanged` signal later (e.g. in an idle handler). This technique is useful for collapsing multiple property changes into one. @@ -17437,7 +17635,8 @@ Since: 2.32 -Checks if @string is a D-Bus address. +Checks if @string is a +[D-Bus address](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). This doesn't check if @string is actually supported by #GDBusServer or #GDBusConnection - use g_dbus_is_supported_address() to do more @@ -17534,9 +17733,10 @@ Since: 2.26 -Like g_dbus_is_address() but also checks if the library suppors the +Like g_dbus_is_address() but also checks if the library supports the transports in @string and that key/value pairs for each transport -are valid. +are valid. See the specification of the +[D-Bus address format](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses). Since: 2.26 @@ -17596,6 +17796,7 @@ Since: 2.32 the bus name which exports the menu model +or %NULL if @connection is not a message bus connection @@ -18946,7 +19147,9 @@ Since: 2.26 Finishes handling a D-Bus method call by returning an error. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.26 @@ -18983,7 +19186,9 @@ If you are writing an application intended to be portable, always register errors with g_dbus_error_register_error() or use g_dbus_method_invocation_return_dbus_error(). -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since 2.48, if the method call requested for a reply not to be sent then this call will free @invocation but otherwise do nothing (as per @@ -19021,7 +19226,9 @@ Since: 2.26 Like g_dbus_method_invocation_return_error() but without printf()-style formatting. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.26 @@ -19052,7 +19259,9 @@ Since: 2.26 Like g_dbus_method_invocation_return_error() but intended for language bindings. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.26 @@ -19087,7 +19296,9 @@ Since: 2.26 Like g_dbus_method_invocation_return_error() but takes a #GError instead of the error domain, error code and message. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.26 @@ -19110,9 +19321,30 @@ Since: 2.26 Finishes handling a D-Bus method call by returning @parameters. If the @parameters GVariant is floating, it is consumed. -It is an error if @parameters is not of the right format. +It is an error if @parameters is not of the right format: it must be a tuple +containing the out-parameters of the D-Bus method. Even if the method has a +single out-parameter, it must be contained in a tuple. If the method has no +out-parameters, @parameters may be %NULL or an empty tuple. -This method will free @invocation, you cannot use it afterwards. +|[<!-- language="C" --> +GDBusMethodInvocation *invocation = some_invocation; +g_autofree gchar *result_string = NULL; +g_autoptr (GError) error = NULL; + +result_string = calculate_result (&error); + +if (error != NULL) +g_dbus_method_invocation_return_gerror (invocation, error); +else +g_dbus_method_invocation_return_value (invocation, +g_variant_new ("(s)", result_string)); + +/<!-- -->* Do not free @invocation here; returning a value does that *<!-- -->/ +]| + +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since 2.48, if the method call requested for a reply not to be sent then this call will sink @parameters and free @invocation, but @@ -19141,7 +19373,9 @@ Like g_dbus_method_invocation_return_value() but also takes a #GUnixFDList. This method is only available on UNIX. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.30 @@ -19168,7 +19402,9 @@ Since: 2.30 Like g_dbus_method_invocation_return_gerror() but takes ownership of @error so the caller does not need to free it. -This method will free @invocation, you cannot use it afterwards. +This method will take ownership of @invocation. See +#GDBusInterfaceVTable for more information about the ownership of +@invocation. Since: 2.30 @@ -21096,8 +21332,9 @@ Since: 2.26 -Gets a D-Bus address string that can be used by clients to connect -to @server. +Gets a +[D-Bus address](https://dbus.freedesktop.org/doc/dbus-specification.html#addresses) +string that can be used by clients to connect to @server. Since: 2.26 @@ -23037,7 +23274,7 @@ Since: 2.48 Sets the certificate database that is used to verify peer certificates. This is set to the default database by default. See -g_dtls_backend_get_default_database(). If set to %NULL, then +g_tls_backend_get_default_database(). If set to %NULL, then peer certificate validation will always set the %G_TLS_CERTIFICATE_UNKNOWN_CA error (meaning #GDtlsConnection::accept-certificate will always be emitted on @@ -23956,6 +24193,10 @@ If the flag #G_FILE_COPY_NOFOLLOW_SYMLINKS is specified then symlinks will be copied as symlinks, otherwise the target of the @source symlink will be copied. +If the flag #G_FILE_COPY_ALL_METADATA is specified then all the metadata +that is possible to copy is copied, not just the default subset (which, +for instance, does not include the owner, see #GFileInfo). + If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. @@ -24817,7 +25058,7 @@ sure resources are released as early as possible. - optional #GCancellable object, %NULL to ignore. + optional #GCancellable object, %NULL to ignore. @@ -24849,7 +25090,7 @@ g_file_enumerator_close_finish(). - optional #GCancellable object, %NULL to ignore. + optional #GCancellable object, %NULL to ignore. @@ -25119,7 +25360,7 @@ priority is %G_PRIORITY_DEFAULT. - the [I/O priority][io-priority] of the request + the [I/O priority][io-priority] of the request @@ -27211,80 +27452,75 @@ This call does no blocking I/O. - + -Loads the content of the file into memory. The data is always -zero-terminated, but this is not included in the resultant @length. -The returned @content should be freed with g_free() when no longer -needed. +Loads the contents of @file and returns it as #GBytes. -If @cancellable is not %NULL, then the operation can be cancelled by -triggering the cancellable object from another thread. If the operation -was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. +If @file is a resource:// based URI, the resulting bytes will reference the +embedded resource instead of a copy. Otherwise, this is equivalent to calling +g_file_load_contents() and g_bytes_new_take(). + +For resources, @etag_out will be set to %NULL. +The data contained in the resulting #GBytes is always zero-terminated, but +this is not included in the #GBytes length. The resulting #GBytes should be +freed with g_bytes_unref() when no longer in use. + +Since: 2.56 - input #GFile + a #GFile - optional #GCancellable object, %NULL to ignore - - - - a location to place the contents of the file - - - - a location to place the length of the contents of the file, -or %NULL if the length is not needed + a #GCancellable or %NULL - a location to place the current entity tag for the file, -or %NULL if the entity tag is not needed + a location to place the current +entity tag for the file, or %NULL if the entity tag is not needed - a #GError, or %NULL + a location for a #GError or %NULL - %TRUE if the @file's contents were successfully loaded. -%FALSE if there were errors. + a #GBytes or %NULL and @error is set + - + -Starts an asynchronous load of the @file's contents. +Asynchronously loads the contents of @file as #GBytes. -For more details, see g_file_load_contents() which is -the synchronous version of this call. +If @file is a resource:// based URI, the resulting bytes will reference the +embedded resource instead of a copy. Otherwise, this is equivalent to calling +g_file_load_contents_async() and g_bytes_new_take(). -When the load operation has completed, @callback will be called -with @user data. To finish the operation, call -g_file_load_contents_finish() with the #GAsyncResult returned by -the @callback. +@callback should call g_file_load_bytes_finish() to get the result of this +asynchronous operation. -If @cancellable is not %NULL, then the operation can be cancelled by -triggering the cancellable object from another thread. If the operation -was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. +See g_file_load_bytes() for more information. + +Since: 2.56 - input #GFile + a #GFile - optional #GCancellable object, %NULL to ignore + a #GCancellable or %NULL - a #GAsyncReadyCallback to call when the request is satisfied + a #GAsyncReadyCallback to call when the +request is satisfied @@ -27295,13 +27531,55 @@ was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. - + -Finishes an asynchronous load of the @file's contents. -The contents are placed in @contents, and @length is set to the -size of the @contents string. The @content should be freed with -g_free() when no longer needed. If @etag_out is present, it will be -set to the new entity tag for the @file. +Completes an asynchronous request to g_file_load_bytes_async(). + +For resources, @etag_out will be set to %NULL. + +The data contained in the resulting #GBytes is always zero-terminated, but +this is not included in the #GBytes length. The resulting #GBytes should be +freed with g_bytes_unref() when no longer in use. + +See g_file_load_bytes() for more information. + +Since: 2.56 + + + + + a #GFile + + + + a #GAsyncResult provided to the callback + + + + a location to place the current +entity tag for the file, or %NULL if the entity tag is not needed + + + + a location for a #GError, or %NULL + + + + a #GBytes or %NULL and @error is set + + + + + + +Loads the content of the file into memory. The data is always +zero-terminated, but this is not included in the resultant @length. +The returned @content should be freed with g_free() when no longer +needed. + +If @cancellable is not %NULL, then the operation can be cancelled by +triggering the cancellable object from another thread. If the operation +was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. @@ -27310,8 +27588,89 @@ set to the new entity tag for the @file. input #GFile - - a #GAsyncResult + + optional #GCancellable object, %NULL to ignore + + + + a location to place the contents of the file + + + + a location to place the length of the contents of the file, +or %NULL if the length is not needed + + + + a location to place the current entity tag for the file, +or %NULL if the entity tag is not needed + + + + a #GError, or %NULL + + + + %TRUE if the @file's contents were successfully loaded. +%FALSE if there were errors. + + + + + +Starts an asynchronous load of the @file's contents. + +For more details, see g_file_load_contents() which is +the synchronous version of this call. + +When the load operation has completed, @callback will be called +with @user data. To finish the operation, call +g_file_load_contents_finish() with the #GAsyncResult returned by +the @callback. + +If @cancellable is not %NULL, then the operation can be cancelled by +triggering the cancellable object from another thread. If the operation +was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. + + + + + input #GFile + + + + optional #GCancellable object, %NULL to ignore + + + + a #GAsyncReadyCallback to call when the request is satisfied + + + + the data to pass to callback function + + + + + + + + +Finishes an asynchronous load of the @file's contents. +The contents are placed in @contents, and @length is set to the +size of the @contents string. The @content should be freed with +g_free() when no longer needed. If @etag_out is present, it will be +set to the new entity tag for the @file. + + + + + + input #GFile + + + + a #GAsyncResult @@ -27363,12 +27722,14 @@ was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. - a #GFileReadMoreCallback to receive partial data + a +#GFileReadMoreCallback to receive partial data and to specify whether further data should be read - a #GAsyncReadyCallback to call when the request is satisfied + a #GAsyncReadyCallback to call +when the request is satisfied @@ -28188,6 +28549,32 @@ the callback function + + +Constructs a #GFile from a series of elements using the correct +separator for filenames. + +Using this function is equivalent to calling g_build_filename(), +followed by g_file_new_for_path() on the result. + +Since: 2.56 + + + + + the first element in the path + + + + remaining elements in path, terminated by %NULL + + + + a new #GFile + + + + Creates a #GFile with the given argument from the command line. @@ -29717,7 +30104,7 @@ Free the returned object with g_object_unref(). Sets an attribute in the file with attribute name @attribute to @value. -Some attributes can be unset by setting @attribute to +Some attributes can be unset by setting @type to %G_FILE_ATTRIBUTE_TYPE_INVALID and @value_p to %NULL. If @cancellable is not %NULL, then the operation can be cancelled by @@ -31654,6 +32041,9 @@ parsed. Initializes the object implementing the interface. +This method is intended for language bindings. If writing in C, +g_initable_new() should typically be used instead. + The object must be initialized before any real use after initial construction, either with this function or g_async_initable_init_async(). @@ -31669,11 +32059,24 @@ error, then all operations on the object except g_object_ref() and g_object_unref() are considered to be invalid, and have undefined behaviour. See the [introduction][ginitable] for more details. -Implementations of this method must be idempotent, i.e. multiple calls -to this function with the same argument should return the same results. -Only the first call initializes the object, further calls return the result -of the first call. This is so that it's safe to implement the singleton -pattern in the GObject constructor function. +Callers should not assume that a class which implements #GInitable can be +initialized multiple times, unless the class explicitly documents itself as +supporting this. Generally, a class’ implementation of init() can assume +(and assert) that it will only be called once. Previously, this documentation +recommended all #GInitable implementations should be idempotent; that +recommendation was relaxed in GLib 2.54. + +If a class explicitly supports being initialized multiple times, it is +recommended that the method is idempotent: multiple calls with the same +arguments should return the same results. Only the first call initializes +the object; further calls return the result of the first call. + +One reason why a class might need to support idempotent initialization is if +it is designed to be used via the singleton pattern, with a +#GObjectClass.constructor that sometimes returns an existing instance. +In this pattern, a caller would expect to be able to call g_initable_init() +on the result of g_object_new(), regardless of whether it is in fact a new +instance. Since: 2.22 @@ -31785,6 +32188,8 @@ similar to g_object_newv() but also initializes the object and returns %NULL, setting an error on failure. Since: 2.22 +Deprecated: 2.54: Use g_object_new_with_properties() and +g_initable_init() instead. See #GParameter for more information. @@ -31885,7 +32290,7 @@ operation. For behaviour details see g_input_stream_close(). -The asyncronous methods have a default fallback that uses threads to implement +The asynchronous methods have a default fallback that uses threads to implement asynchronicity, so they are optional for inheriting classes. However, if you override one you must override all. @@ -32190,7 +32595,7 @@ Any outstanding i/o request with higher priority (lower numerical value) will be executed before an outstanding request with lower priority. Default priority is %G_PRIORITY_DEFAULT. -The asyncronous methods have a default fallback that uses threads to implement +The asynchronous methods have a default fallback that uses threads to implement asynchronicity, so they are optional for inheriting classes. However, if you override one you must override all. @@ -32542,6 +32947,8 @@ value %G_IO_ERROR_FAILED is returned for error codes not currently handled (but note that future GLib releases may return a more specific value instead). +As %errno is global and may be modified by intermediate function +calls, you should save its value as soon as the call which sets it @@ -35855,7 +36262,7 @@ Since: 2.38 -Checks if @mount can be eject. +Checks if @mount can be ejected. @@ -35871,7 +36278,7 @@ Checks if @mount can be eject. -Checks if @mount can be mounted. +Checks if @mount can be unmounted. @@ -37846,7 +38253,7 @@ the result of the operation. For behaviour details see g_output_stream_close(). -The asyncronous methods have a default fallback that uses threads +The asynchronous methods have a default fallback that uses threads to implement asynchronicity, so they are optional for inheriting classes. However, if you override one you must override all. @@ -37996,7 +38403,7 @@ ignore. -Checks if an ouput stream has pending actions. +Checks if an output stream has pending actions. @@ -38370,7 +38777,7 @@ g_output_stream_write(). - location to store the number of bytes that was + location to store the number of bytes that was written to the stream @@ -38506,7 +38913,7 @@ Any outstanding I/O request with higher priority (lower numerical value) will be executed before an outstanding request with lower priority. Default priority is %G_PRIORITY_DEFAULT. -The asyncronous methods have a default fallback that uses threads +The asynchronous methods have a default fallback that uses threads to implement asynchronicity, so they are optional for inheriting classes. However, if you override one you must override all. @@ -40766,6 +41173,10 @@ the data should not be modified or freed. If you want to use this resource in the global resource namespace you need to register it with g_resources_register(). +Note: @data must be backed by memory that is at least pointer aligned. +Otherwise this function will internally create a copy of the memory since +GLib 2.56, or in older versions fail and exit the process. + Since: 2.32 @@ -40912,8 +41323,8 @@ or %NULL if the length is not needed - a location to place the flags about the file, -or %NULL if the length is not needed + a location to place the #GResourceFlags about the file, +or %NULL if the flags are not needed @@ -41049,7 +41460,8 @@ Tests if the stream supports the #GSeekableIface. -Tests if the stream can be truncated. +Tests if the length of the stream can be adjusted with +g_seekable_truncate(). @@ -41129,7 +41541,9 @@ Tells the current position within the stream. -Truncates a stream with a given #offset. +Sets the length of the stream to @offset. If the stream was previously +larger than @offset, the extra data is discarded. If the stream was +previouly shorter than @offset, it is extended with NUL ('\0') bytes. If @cancellable is not %NULL, then the operation can be cancelled by triggering the cancellable object from another thread. If the operation @@ -41137,7 +41551,6 @@ was cancelled, the error %G_IO_ERROR_CANCELLED will be returned. If an operation was partially finished when the operation was cancelled the partial result will be returned, without an error. -Virtual: truncate_fn @@ -41146,7 +41559,7 @@ Virtual: truncate_fn - a #goffset. + new length for @seekable, in bytes. @@ -41464,7 +41877,7 @@ function also establishes a binding between the writability of a boolean property by that name). See g_settings_bind_writable() for more details about writable bindings. -Note that the lifecycle of the binding is tied to the object, +Note that the lifecycle of the binding is tied to @object, and that you can have only one binding per object property. If you bind the same property twice on the same object, the second binding overrides the first one. @@ -41505,7 +41918,7 @@ and the property @property of @object. The binding uses the provided mapping functions to map between settings and property values. -Note that the lifecycle of the binding is tied to the object, +Note that the lifecycle of the binding is tied to @object, and that you can have only one binding per object property. If you bind the same property twice on the same object, the second binding overrides the first one. @@ -41571,7 +41984,7 @@ When the @inverted argument is %TRUE, the binding inverts the value as it passes from the setting to the object, i.e. @property will be set to %TRUE if the key is not writable. -Note that the lifecycle of the binding is tied to the object, +Note that the lifecycle of the binding is tied to @object, and that you can have only one binding per object property. If you bind the same property twice on the same object, the second binding overrides the first one. @@ -43546,8 +43959,7 @@ Since: 2.26 -Ensures that all pending operations for the given are complete for -the default backend. +Ensures that all pending operations are complete for the default backend. Writes made to a #GSettings are handled asynchronously. For this reason, it is very unlikely that the changes have it to disk by the @@ -46963,7 +47375,7 @@ Since: 2.22 -Try to get the remove address of a connected socket. This is only +Try to get the remote address of a connected socket. This is only useful for connection oriented sockets that have been connected. Since: 2.22 @@ -47097,6 +47509,9 @@ If @source_specific is %TRUE, source-specific multicast as defined in RFC 4604 is used. Note that on older platforms this may fail with a %G_IO_ERROR_NOT_SUPPORTED error. +To bind to a given source-specific multicast address, use +g_socket_join_multicast_group_ssm() instead. + Since: 2.32 @@ -47127,6 +47542,55 @@ Since: 2.32 + + +Registers @socket to receive multicast messages sent to @group. +@socket must be a %G_SOCKET_TYPE_DATAGRAM socket, and must have +been bound to an appropriate interface and port with +g_socket_bind(). + +If @iface is %NULL, the system will automatically pick an interface +to bind to based on @group. + +If @source_specific is not %NULL, use source-specific multicast as +defined in RFC 4604. Note that on older platforms this may fail +with a %G_IO_ERROR_NOT_SUPPORTED error. + +Note that this function can be called multiple times for the same +@group with different @source_specific in order to receive multicast +packets from more than one source. + +Since: 2.56 + + + + + a #GSocket. + + + + a #GInetAddress specifying the group address to join. + + + + a #GInetAddress specifying the +source-specific multicast address or %NULL to ignore. + + + + Name of the interface to use, or %NULL + + + + #GError for error reporting, or %NULL to ignore. + + + + %TRUE on success, %FALSE on error. + + + + Removes @socket from the multicast group defined by @group, @iface, @@ -47136,6 +47600,9 @@ when you joined the group). @socket remains bound to its address and port, and can still receive unicast messages after calling this. +To unbind to a given source-specific multicast address, use +g_socket_leave_multicast_group_ssm() instead. + Since: 2.32 @@ -47166,6 +47633,46 @@ Since: 2.32 + + +Removes @socket from the multicast group defined by @group, @iface, +and @source_specific (which must all have the same values they had +when you joined the group). + +@socket remains bound to its address and port, and can still receive +unicast messages after calling this. + +Since: 2.56 + + + + + a #GSocket. + + + + a #GInetAddress specifying the group address to leave. + + + + a #GInetAddress specifying the +source-specific multicast address or %NULL to ignore. + + + + Name of the interface to use, or %NULL + + + + #GError for error reporting, or %NULL to ignore. + + + + %TRUE on success, %FALSE on error. + + + + Marks the socket as a server socket, i.e. a socket that is used @@ -47900,8 +48407,8 @@ pointer, or %NULL - a pointer which -may be filled with an array of #GSocketControlMessages, or %NULL + a pointer +which may be filled with an array of #GSocketControlMessages, or %NULL @@ -49510,7 +50017,8 @@ Since: 2.40 - the value of the environment variable, %NULL if unset + the value of the environment variable, +%NULL if unset @@ -49611,6 +50119,13 @@ g_environ_unsetenv(), etc. As an alternative, you can use g_subprocess_launcher_setenv(), g_subprocess_launcher_unsetenv(), etc. +Pass an empty array to set an empty environment. Pass %NULL to inherit the +parent process’ environment. As of GLib 2.54, the parent process’ environment +will be copied when g_subprocess_launcher_set_environ() is called. +Previously, it was copied when the subprocess was executed. This means the +copied environment may now be modified (using g_subprocess_launcher_setenv(), +etc.) before launching the subprocess. + On UNIX, all strings in this array can be arbitrary byte strings. On Windows, they should be in UTF-8. @@ -49623,7 +50138,8 @@ Since: 2.40 - the replacement environment + +the replacement environment @@ -49771,7 +50287,8 @@ Since: 2.40 - the environment variable to set, must not contain '=' + the environment variable to set, +must not contain '=' @@ -49998,7 +50515,8 @@ Since: 2.40 - the environment variable to unset, must not contain '=' + the environment variable to unset, +must not contain '=' @@ -51600,7 +52118,7 @@ Since: 2.48 the #GType of @backend’s #GDtlsClientConnection -implementation. +implementation, or %G_TYPE_INVALID if this backend doesn’t support DTLS. @@ -51619,7 +52137,7 @@ Since: 2.48 the #GType of @backend’s #GDtlsServerConnection -implementation. +implementation, or %G_TYPE_INVALID if this backend doesn’t support DTLS. @@ -52759,7 +53277,7 @@ Since: 2.30 Finish an asynchronous lookup of a certificate by its handle. See -g_tls_database_lookup_certificate_handle() for more information. +g_tls_database_lookup_certificate_by_handle() for more information. If the handle is no longer valid, or does not point to a certificate in this database, then %NULL will be returned. @@ -53019,11 +53537,11 @@ objects. Use g_object_unref() on each certificate, and g_list_free() on the rele -Verify's a certificate chain after looking up and adding any missing -certificates to the chain. +Determines the validity of a certificate chain after looking up and +adding any missing certificates to the chain. @chain is a chain of #GTlsCertificate objects each pointing to the next -certificate in the chain by its %issuer property. The chain may initially +certificate in the chain by its #GTlsCertificate:issuer property. The chain may initially consist of one or more certificates. After the verification process is complete, @chain may be modified by adding missing certificates, or removing extra certificates. If a certificate anchor was found, then it is added to @@ -53041,6 +53559,15 @@ host by host basis. Currently there are no @flags, and %G_TLS_DATABASE_VERIFY_NONE should be used. +If @chain is found to be valid, then the return value will be 0. If +@chain is found to be invalid, then the return value will indicate +the problems found. If the function is unable to determine whether +@chain is valid or not (eg, because @cancellable is triggered +before it completes) then the return value will be +%G_TLS_CERTIFICATE_GENERIC_ERROR and @error will be set +accordingly. @error is not set when @chain is successfully analyzed +but found to be invalid. + This function can block, use g_tls_database_verify_chain_async() to perform the verification operation asynchronously. @@ -53089,9 +53616,9 @@ result of verification. -Asynchronously verify's a certificate chain after looking up and adding -any missing certificates to the chain. See g_tls_database_verify_chain() -for more information. +Asynchronously determines the validity of a certificate chain after +looking up and adding any missing certificates to the chain. See +g_tls_database_verify_chain() for more information. Since: 2.30 @@ -53140,7 +53667,17 @@ Since: 2.30 Finish an asynchronous verify chain operation. See -g_tls_database_verify_chain() for more information. * +g_tls_database_verify_chain() for more information. + +If @chain is found to be valid, then the return value will be 0. If +@chain is found to be invalid, then the return value will indicate +the problems found. If the function is unable to determine whether +@chain is valid or not (eg, because @cancellable is triggered +before it completes) then the return value will be +%G_TLS_CERTIFICATE_GENERIC_ERROR and @error will be set +accordingly. @error is not set when @chain is successfully analyzed +but found to be invalid. + Since: 2.30 @@ -54585,6 +55122,53 @@ of the OS. + + +Determines if @device_path is considered a block device path which is only +used in implementation of the OS. This is primarily used for hiding +mounted volumes that are intended as APIs for programs to read, and system +administrators at a shell; rather than something that should, for example, +appear in a GUI. For example, the Linux `/proc` filesystem. + +The list of device paths considered ‘system’ ones may change over time. + +Since: 2.56 + + + + + a device path, e.g. `/dev/loop0` or `nfsd` + + + + %TRUE if @device_path is considered an implementation detail of +the OS. + + + + + +Determines if @fs_type is considered a type of file system which is only +used in implementation of the OS. This is primarily used for hiding +mounted volumes that are intended as APIs for programs to read, and system +administrators at a shell; rather than something that should, for example, +appear in a GUI. For example, the Linux `/proc` filesystem. + +The list of file system types considered ‘system’ ones may change over time. + +Since: 2.56 + + + + + a file system type, e.g. `procfs` or `tmpfs` + + + + %TRUE if @fs_type is considered an implementation detail of the OS. + + + Gets a #GUnixMountEntry for a given mount path. If @time_read @@ -54628,6 +55212,48 @@ or less than @mount2, respectively. + + +Makes a copy of @mount_entry. + +Since: 2.54 + + + + + a #GUnixMountEntry. + + + + a new #GUnixMountEntry + + + + + + +Gets a #GUnixMountEntry for a given file path. If @time_read +is set, it will be filled with a unix timestamp for checking +if the mounts have changed since with g_unix_mounts_changed_since(). + +Since: 2.52 + + + + + file path on some unix mount. + + + + guint64 to contain a timestamp. + + + + a #GUnixMountEntry. + + + + Frees a unix mount. @@ -54809,7 +55435,12 @@ Checks if a unix mount is mounted read only. -Checks if a unix mount is a system path. +Checks if a Unix mount is a system mount. This is the Boolean OR of +g_unix_is_system_fs_type(), g_unix_is_system_device_path() and +g_unix_is_mount_path_system_internal() on @mount_entry’s properties. + +The definition of what a ‘system’ mount entry is may change over time as new +file system types and device paths are ignored. @@ -54912,6 +55543,24 @@ or less than @mount2, respectively. + + +Makes a copy of @mount_point. + +Since: 2.54 + + + + + a #GUnixMountPoint. + + + + a new #GUnixMountPoint + + + + Frees a unix mount point. @@ -55895,7 +56544,7 @@ volume_activation_root = g_volume_get_activation_root (volume); // assume not NU then the expression |[<!-- language="C" --> (g_file_has_prefix (volume_activation_root, mount_root) || - g_file_equal (volume_activation_root, mount_root)) +g_file_equal (volume_activation_root, mount_root)) ]| will always be %TRUE. @@ -57654,6 +58303,150 @@ Finishes an operation started with gxdp_documents_call_add(). + + +Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddFull">AddFull()</link> D-Bus method on @proxy. +When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from. +You can then call gxdp_documents_call_add_full_finish() to get the result of the operation. + +See gxdp_documents_call_add_full_sync() for the synchronous, blocking version of this method. + + + + + A #GXdpDocumentsProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + A #GUnixFDList or %NULL. + + + + A #GCancellable or %NULL. + + + + A #GAsyncReadyCallback to call when the request is satisfied or %NULL. + + + + User data to pass to @callback. + + + + + + + + +Finishes an operation started with gxdp_documents_call_add_full(). + + + + + + A #GXdpDocumentsProxy. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for a #GUnixFDList or %NULL. + + + + The #GAsyncResult obtained from the #GAsyncReadyCallback passed to gxdp_documents_call_add_full(). + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + + + +Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddFull">AddFull()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received. + +See gxdp_documents_call_add_full() for the asynchronous version of this method. + + + + + + A #GXdpDocumentsProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + A #GUnixFDList or %NULL. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for a #GUnixFDList or %NULL. + + + + A #GCancellable or %NULL. + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddNamed">AddNamed()</link> D-Bus method on @proxy. @@ -58548,6 +59341,38 @@ This method will free @invocation, you cannot use it afterwards. + + +Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddFull">AddFull()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar. + +This method will free @invocation, you cannot use it afterwards. + + + + + A #GXdpDocuments. + + + + A #GDBusMethodInvocation. + + + + A #GUnixFDList or %NULL. + + + + Parameter to return. + + + + Parameter to return. + + + + + + Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-portal-Documents.AddNamed">AddNamed()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar. @@ -58736,6 +59561,24 @@ This method will free @invocation, you cannot use it afterwards. + + +Gets the value of the <link linkend="gdbus-property-org-freedesktop-portal-Documents.version">"version"</link> D-Bus property. + +Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side. + + + + + + A #GXdpDocuments. + + + + The property value. + + + Gets a machine-readable description of the <link linkend="gdbus-interface-org-freedesktop-portal-Documents.top_of_page">org.freedesktop.portal.Documents</link> D-Bus interface. @@ -58975,6 +59818,26 @@ See gxdp_documents_proxy_new() for the asynchronous version of this constructor. + + +Sets the <link linkend="gdbus-property-org-freedesktop-portal-Documents.version">"version"</link> D-Bus property to @value. + +Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side. + + + + + A #GXdpDocuments. + + + + The value to set. + + + + + + Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-portal-Documents.top_of_page">org.freedesktop.portal.Documents</link>. @@ -59370,6 +60233,587 @@ Creates a skeleton object for the D-Bus interface <link linkend="gdbus-i + + +Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenFile">OpenFile()</link> D-Bus method on @proxy. +When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from. +You can then call gxdp_open_uri_call_open_file_finish() to get the result of the operation. + +See gxdp_open_uri_call_open_file_sync() for the synchronous, blocking version of this method. + + + + + A #GXdpOpenURIProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + A #GUnixFDList or %NULL. + + + + A #GCancellable or %NULL. + + + + A #GAsyncReadyCallback to call when the request is satisfied or %NULL. + + + + User data to pass to @callback. + + + + + + + + +Finishes an operation started with gxdp_open_uri_call_open_file(). + + + + + + A #GXdpOpenURIProxy. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for a #GUnixFDList or %NULL. + + + + The #GAsyncResult obtained from the #GAsyncReadyCallback passed to gxdp_open_uri_call_open_file(). + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + + + +Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenFile">OpenFile()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received. + +See gxdp_open_uri_call_open_file() for the asynchronous version of this method. + + + + + + A #GXdpOpenURIProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + A #GUnixFDList or %NULL. + + + + Return location for return parameter or %NULL to ignore. + + + + Return location for a #GUnixFDList or %NULL. + + + + A #GCancellable or %NULL. + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + + + +Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenURI">OpenURI()</link> D-Bus method on @proxy. +When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from. +You can then call gxdp_open_uri_call_open_uri_finish() to get the result of the operation. + +See gxdp_open_uri_call_open_uri_sync() for the synchronous, blocking version of this method. + + + + + A #GXdpOpenURIProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + A #GCancellable or %NULL. + + + + A #GAsyncReadyCallback to call when the request is satisfied or %NULL. + + + + User data to pass to @callback. + + + + + + + + +Finishes an operation started with gxdp_open_uri_call_open_uri(). + + + + + + A #GXdpOpenURIProxy. + + + + Return location for return parameter or %NULL to ignore. + + + + The #GAsyncResult obtained from the #GAsyncReadyCallback passed to gxdp_open_uri_call_open_uri(). + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + + + +Synchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenURI">OpenURI()</link> D-Bus method on @proxy. The calling thread is blocked until a reply is received. + +See gxdp_open_uri_call_open_uri() for the asynchronous version of this method. + + + + + + A #GXdpOpenURIProxy. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Argument to pass with the method invocation. + + + + Return location for return parameter or %NULL to ignore. + + + + A #GCancellable or %NULL. + + + + Return location for error or %NULL. + + + + %TRUE if the call succeded, %FALSE if @error is set. + + + + + +Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenFile">OpenFile()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar. + +This method will free @invocation, you cannot use it afterwards. + + + + + A #GXdpOpenURI. + + + + A #GDBusMethodInvocation. + + + + A #GUnixFDList or %NULL. + + + + Parameter to return. + + + + + + + + +Helper function used in service implementations to finish handling invocations of the <link linkend="gdbus-method-org-freedesktop-portal-OpenURI.OpenURI">OpenURI()</link> D-Bus method. If you instead want to finish handling an invocation by returning an error, use g_dbus_method_invocation_return_error() or similar. + +This method will free @invocation, you cannot use it afterwards. + + + + + A #GXdpOpenURI. + + + + A #GDBusMethodInvocation. + + + + Parameter to return. + + + + + + + + +Gets the value of the <link linkend="gdbus-property-org-freedesktop-portal-OpenURI.version">"version"</link> D-Bus property. + +Since this D-Bus property is readable, it is meaningful to use this function on both the client- and service-side. + + + + + + A #GXdpOpenURI. + + + + The property value. + + + + + +Gets a machine-readable description of the <link linkend="gdbus-interface-org-freedesktop-portal-OpenURI.top_of_page">org.freedesktop.portal.OpenURI</link> D-Bus interface. + + + + + + A #GDBusInterfaceInfo. Do not free. + + + + + +Overrides all #GObject properties in the #GXdpOpenURI interface for a concrete class. +The properties are overridden in the order they are defined. + + + + + + The class structure for a #GObject<!-- -->-derived class. + + + + The property id to assign to the first overridden property. + + + + The last property id. + + + + + +Asynchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-portal-OpenURI.top_of_page">org.freedesktop.portal.OpenURI</link>. See g_dbus_proxy_new() for more details. + +When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from. +You can then call gxdp_open_uri_proxy_new_finish() to get the result of the operation. + +See gxdp_open_uri_proxy_new_sync() for the synchronous, blocking version of this constructor. + + + + + A #GDBusConnection. + + + + Flags from the #GDBusProxyFlags enumeration. + + + + A bus name (well-known or unique) or %NULL if @connection is not a message bus connection. + + + + An object path. + + + + A #GCancellable or %NULL. + + + + A #GAsyncReadyCallback to call when the request is satisfied. + + + + User data to pass to @callback. + + + + + + + + +Finishes an operation started with gxdp_open_uri_proxy_new(). + + + + + + The #GAsyncResult obtained from the #GAsyncReadyCallback passed to gxdp_open_uri_proxy_new(). + + + + Return location for error or %NULL + + + + The constructed proxy object or %NULL if @error is set. + + + + + +Like gxdp_open_uri_proxy_new() but takes a #GBusType instead of a #GDBusConnection. + +When the operation is finished, @callback will be invoked in the <link linkend="g-main-context-push-thread-default">thread-default main loop</link> of the thread you are calling this method from. +You can then call gxdp_open_uri_proxy_new_for_bus_finish() to get the result of the operation. + +See gxdp_open_uri_proxy_new_for_bus_sync() for the synchronous, blocking version of this constructor. + + + + + A #GBusType. + + + + Flags from the #GDBusProxyFlags enumeration. + + + + A bus name (well-known or unique). + + + + An object path. + + + + A #GCancellable or %NULL. + + + + A #GAsyncReadyCallback to call when the request is satisfied. + + + + User data to pass to @callback. + + + + + + + + +Finishes an operation started with gxdp_open_uri_proxy_new_for_bus(). + + + + + + The #GAsyncResult obtained from the #GAsyncReadyCallback passed to gxdp_open_uri_proxy_new_for_bus(). + + + + Return location for error or %NULL + + + + The constructed proxy object or %NULL if @error is set. + + + + + +Like gxdp_open_uri_proxy_new_sync() but takes a #GBusType instead of a #GDBusConnection. + +The calling thread is blocked until a reply is received. + +See gxdp_open_uri_proxy_new_for_bus() for the asynchronous version of this constructor. + + + + + + A #GBusType. + + + + Flags from the #GDBusProxyFlags enumeration. + + + + A bus name (well-known or unique). + + + + An object path. + + + + A #GCancellable or %NULL. + + + + Return location for error or %NULL + + + + The constructed proxy object or %NULL if @error is set. + + + + + +Synchronously creates a proxy for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-portal-OpenURI.top_of_page">org.freedesktop.portal.OpenURI</link>. See g_dbus_proxy_new_sync() for more details. + +The calling thread is blocked until a reply is received. + +See gxdp_open_uri_proxy_new() for the asynchronous version of this constructor. + + + + + + A #GDBusConnection. + + + + Flags from the #GDBusProxyFlags enumeration. + + + + A bus name (well-known or unique) or %NULL if @connection is not a message bus connection. + + + + An object path. + + + + A #GCancellable or %NULL. + + + + Return location for error or %NULL + + + + The constructed proxy object or %NULL if @error is set. + + + + + +Sets the <link linkend="gdbus-property-org-freedesktop-portal-OpenURI.version">"version"</link> D-Bus property to @value. + +Since this D-Bus property is not writable, it is only meaningful to use this function on the service-side. + + + + + A #GXdpOpenURI. + + + + The value to set. + + + + + + + + +Creates a skeleton object for the D-Bus interface <link linkend="gdbus-interface-org-freedesktop-portal-OpenURI.top_of_page">org.freedesktop.portal.OpenURI</link>. + + + + + + The skeleton object. + + + Asynchronously invokes the <link linkend="gdbus-method-org-freedesktop-portal-ProxyResolver.Lookup">Lookup()</link> D-Bus method on @proxy. diff --git a/gio/src/gio_docs_override.xml b/gio/src/gio_docs_override.xml index cbeaae1..9731c27 100644 --- a/gio/src/gio_docs_override.xml +++ b/gio/src/gio_docs_override.xml @@ -42,13 +42,17 @@ + - - - + + + + + + @@ -63,6 +67,7 @@ + @@ -71,11 +76,13 @@ + + diff --git a/gio/src/gio_enums.defs b/gio/src/gio_enums.defs index 4771d57..7fcc9d3 100644 --- a/gio/src/gio_enums.defs +++ b/gio/src/gio_enums.defs @@ -855,7 +855,8 @@ ;; { ;; G_BUS_NAME_OWNER_FLAGS_NONE = 0, /*< nick=none >*/ ;; G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT = (1<<0), /*< nick=allow-replacement >*/ -;; G_BUS_NAME_OWNER_FLAGS_REPLACE = (1<<1) /*< nick=replace >*/ +;; G_BUS_NAME_OWNER_FLAGS_REPLACE = (1<<1), /*< nick=replace >*/ +;; G_BUS_NAME_OWNER_FLAGS_DO_NOT_QUEUE = (1<<2) /*< nick=do-not-queue >*/ ;; } GBusNameOwnerFlags; (define-flags-extended BusNameOwnerFlags @@ -865,6 +866,7 @@ '("none" "G_BUS_NAME_OWNER_FLAGS_NONE" "0x0") '("allow-replacement" "G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT" "(1<<0)") '("replace" "G_BUS_NAME_OWNER_FLAGS_REPLACE" "(1<<1)") + '("do-not-queue" "G_BUS_NAME_OWNER_FLAGS_DO_NOT_QUEUE" "(1<<2)") ) ) diff --git a/gio/src/gio_methods.defs b/gio/src/gio_methods.defs index 833d822..7e54a15 100644 --- a/gio/src/gio_methods.defs +++ b/gio/src/gio_methods.defs @@ -813,6 +813,26 @@ (gtype-id "G_TYPE_XDP_NETWORK_MONITOR_SKELETON") ) +(define-object OpenURI + (in-module "GXdp") + (c-name "GXdpOpenURI") + (gtype-id "G_TYPE_XDP_OPEN_URI") +) + +(define-object OpenURIProxy + (in-module "GXdp") + (parent "GDBusProxy") + (c-name "GXdpOpenURIProxy") + (gtype-id "G_TYPE_XDP_OPEN_URI_PROXY") +) + +(define-object OpenURISkeleton + (in-module "GXdp") + (parent "GDBusInterfaceSkeleton") + (c-name "GXdpOpenURISkeleton") + (gtype-id "G_TYPE_XDP_OPEN_URI_SKELETON") +) + (define-object ProxyResolver (in-module "GXdp") (c-name "GXdpProxyResolver") @@ -1365,6 +1385,7 @@ '("none" "G_BUS_NAME_OWNER_FLAGS_NONE") '("allow-replacement" "G_BUS_NAME_OWNER_FLAGS_ALLOW_REPLACEMENT") '("replace" "G_BUS_NAME_OWNER_FLAGS_REPLACE") + '("do-not-queue" "G_BUS_NAME_OWNER_FLAGS_DO_NOT_QUEUE") ) ) @@ -2217,7 +2238,7 @@ (return-type "gboolean") (parameters '("GList*" "files") - '("GAppLaunchContext*" "launch_context") + '("GAppLaunchContext*" "context") '("GError**" "error") ) ) @@ -2240,7 +2261,7 @@ (return-type "gboolean") (parameters '("GList*" "uris") - '("GAppLaunchContext*" "launch_context") + '("GAppLaunchContext*" "context") '("GError**" "error") ) ) @@ -2384,7 +2405,7 @@ (return-type "gboolean") (parameters '("const-char*" "uri") - '("GAppLaunchContext*" "launch_context") + '("GAppLaunchContext*" "context") '("GError**" "error") ) ) @@ -2394,7 +2415,7 @@ (return-type "none") (parameters '("const-char*" "uri") - '("GAppLaunchContext*" "launch_context") + '("GAppLaunchContext*" "context") '("GCancellable*" "cancellable") '("GAsyncReadyCallback" "callback") '("gpointer" "user_data") @@ -3437,6 +3458,15 @@ ) ) +(define-function g_content_type_is_mime_type + (c-name "g_content_type_is_mime_type") + (return-type "gboolean") + (parameters + '("const-gchar*" "type") + '("const-gchar*" "mime_type") + ) +) + (define-function g_content_type_is_unknown (c-name "g_content_type_is_unknown") (return-type "gboolean") @@ -6933,6 +6963,16 @@ ) ) +(define-function g_document_portal_add_documents + (c-name "g_document_portal_add_documents") + (return-type "GList*") + (parameters + '("GList*" "uris") + '("const-char*" "app_id") + '("GError**" "error") + ) +) + ;; From gdrive.h @@ -7798,6 +7838,15 @@ ) ) +(define-function g_file_new_build_filename + (c-name "g_file_new_build_filename") + (return-type "GFile*") + (parameters + '("const-gchar*" "first_element") + ) + (varargs #t) +) + (define-method dup (of-object "GFile") (c-name "g_file_dup") @@ -9108,6 +9157,39 @@ (return-type "gboolean") ) +(define-method load_bytes + (of-object "GFile") + (c-name "g_file_load_bytes") + (return-type "GBytes*") + (parameters + '("GCancellable*" "cancellable") + '("gchar**" "etag_out") + '("GError**" "error") + ) +) + +(define-method load_bytes_async + (of-object "GFile") + (c-name "g_file_load_bytes_async") + (return-type "none") + (parameters + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-method load_bytes_finish + (of-object "GFile") + (c-name "g_file_load_bytes_finish") + (return-type "GBytes*") + (parameters + '("GAsyncResult*" "result") + '("gchar**" "etag_out") + '("GError**" "error") + ) +) + ;; From gfileicon.h @@ -11207,10 +11289,6 @@ -;; From gio_probes.h - - - ;; From gioscheduler.h (define-function g_io_scheduler_push_job @@ -11359,12 +11437,21 @@ ;; From gio-tool.h +(define-function print_error + (c-name "print_error") + (return-type "none") + (parameters + '("const-gchar*" "format") + ) + (varargs #t) +) + (define-function print_file_error (c-name "print_file_error") (return-type "none") (parameters '("GFile*" "file") - '("const-char*" "message") + '("const-gchar*" "message") ) ) @@ -13257,6 +13344,64 @@ +;; From gopenuriportal.h + +(define-function g_openuri_portal_open_uri + (c-name "g_openuri_portal_open_uri") + (return-type "gboolean") + (parameters + '("const-char*" "uri") + '("const-char*" "parent_window") + '("GError**" "error") + ) +) + +(define-function g_openuri_portal_open_uri_async + (c-name "g_openuri_portal_open_uri_async") + (return-type "none") + (parameters + '("const-char*" "uri") + '("const-char*" "parent_window") + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-function g_openuri_portal_open_uri_finish + (c-name "g_openuri_portal_open_uri_finish") + (return-type "gboolean") + (parameters + '("GAsyncResult*" "result") + '("GError**" "error") + ) +) + + + +;; From gosxappinfo.h + +(define-function g_osx_app_info_get_type + (c-name "g_osx_app_info_get_type") + (return-type "GType") +) + +(define-method get_filename + (of-object "GOsxAppInfo") + (c-name "g_osx_app_info_get_filename") + (return-type "char*") +) + +(define-function g_osx_app_info_get_all_for_scheme + (c-name "g_osx_app_info_get_all_for_scheme") + (return-type "GList*") + (parameters + '("const-gchar*" "scheme") + ) +) + + + ;; From goutputstream.h (define-function g_output_stream_get_type @@ -16710,6 +16855,30 @@ ) ) +(define-method join_multicast_group_ssm + (of-object "GSocket") + (c-name "g_socket_join_multicast_group_ssm") + (return-type "gboolean") + (parameters + '("GInetAddress*" "group") + '("GInetAddress*" "source_specific") + '("const-gchar*" "iface") + '("GError**" "error") + ) +) + +(define-method leave_multicast_group_ssm + (of-object "GSocket") + (c-name "g_socket_leave_multicast_group_ssm") + (return-type "gboolean") + (parameters + '("GInetAddress*" "group") + '("GInetAddress*" "source_specific") + '("const-gchar*" "iface") + '("GError**" "error") + ) +) + (define-method connect (of-object "GSocket") (c-name "g_socket_connect") @@ -19213,12 +19382,36 @@ ;; From gunixmounts.h +(define-function g_unix_mount_entry_get_type + (c-name "g_unix_mount_entry_get_type") + (return-type "GType") +) + +(define-function g_unix_mount_point_get_type + (c-name "g_unix_mount_point_get_type") + (return-type "GType") +) + +(define-function g_unix_mount_copy + (c-name "g_unix_mount_copy") + (return-type "GUnixMountEntry*") + (parameters + '("GUnixMountEntry*" "mount_entry") + ) +) + (define-method free (of-object "GUnixMountPoint") (c-name "g_unix_mount_point_free") (return-type "none") ) +(define-method copy + (of-object "GUnixMountPoint") + (c-name "g_unix_mount_point_copy") + (return-type "GUnixMountPoint*") +) + (define-function g_unix_mount_compare (c-name "g_unix_mount_compare") (return-type "gint") @@ -19308,15 +19501,6 @@ ) ) -(define-method compare - (of-object "GUnixMountPoint") - (c-name "g_unix_mount_point_compare") - (return-type "gint") - (parameters - '("GUnixMountPoint*" "mount2") - ) -) - (define-method get_mount_path (of-object "GUnixMountPoint") (c-name "g_unix_mount_point_get_mount_path") @@ -19408,6 +19592,15 @@ ) ) +(define-function g_unix_mount_for + (c-name "g_unix_mount_for") + (return-type "GUnixMountEntry*") + (parameters + '("const-char*" "file_path") + '("guint64*" "time_read") + ) +) + (define-function g_unix_mounts_changed_since (c-name "g_unix_mounts_changed_since") (return-type "gboolean") @@ -19457,6 +19650,22 @@ ) ) +(define-function g_unix_is_system_fs_type + (c-name "g_unix_is_system_fs_type") + (return-type "gboolean") + (parameters + '("const-char*" "fs_type") + ) +) + +(define-function g_unix_is_system_device_path + (c-name "g_unix_is_system_device_path") + (return-type "gboolean") + (parameters + '("const-char*" "device_path") + ) +) + ;; From gunixoutputstream.h @@ -20404,6 +20613,18 @@ ) ) +(define-method complete_add_full + (of-object "GXdpDocuments") + (c-name "gxdp_documents_complete_add_full") + (return-type "none") + (parameters + '("GDBusMethodInvocation*" "invocation") + '("GUnixFDList*" "fd_list") + '("const-gchar*-const*" "doc_ids") + '("GVariant*" "extra_out") + ) +) + (define-method complete_grant_permissions (of-object "GXdpDocuments") (c-name "gxdp_documents_complete_grant_permissions") @@ -20583,6 +20804,53 @@ ) ) +(define-method call_add_full + (of-object "GXdpDocuments") + (c-name "gxdp_documents_call_add_full") + (return-type "none") + (parameters + '("GVariant*" "arg_o_path_fds") + '("guint" "arg_flags") + '("const-gchar*" "arg_app_id") + '("const-gchar*-const*" "arg_permissions") + '("GUnixFDList*" "fd_list") + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-method call_add_full_finish + (of-object "GXdpDocuments") + (c-name "gxdp_documents_call_add_full_finish") + (return-type "gboolean") + (parameters + '("gchar***" "out_doc_ids") + '("GVariant**" "out_extra_out") + '("GUnixFDList**" "out_fd_list") + '("GAsyncResult*" "res") + '("GError**" "error") + ) +) + +(define-method call_add_full_sync + (of-object "GXdpDocuments") + (c-name "gxdp_documents_call_add_full_sync") + (return-type "gboolean") + (parameters + '("GVariant*" "arg_o_path_fds") + '("guint" "arg_flags") + '("const-gchar*" "arg_app_id") + '("const-gchar*-const*" "arg_permissions") + '("GUnixFDList*" "fd_list") + '("gchar***" "out_doc_ids") + '("GVariant**" "out_extra_out") + '("GUnixFDList**" "out_fd_list") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + (define-method call_grant_permissions (of-object "GXdpDocuments") (c-name "gxdp_documents_call_grant_permissions") @@ -20797,6 +21065,21 @@ ) ) +(define-method get_version + (of-object "GXdpDocuments") + (c-name "gxdp_documents_get_version") + (return-type "guint") +) + +(define-method set_version + (of-object "GXdpDocuments") + (c-name "gxdp_documents_set_version") + (return-type "none") + (parameters + '("guint" "value") + ) +) + (define-function gxdp_documents_proxy_get_type (c-name "gxdp_documents_proxy_get_type") (return-type "GType") @@ -20865,6 +21148,211 @@ (return-type "GType") ) +(define-function gxdp_open_uri_get_type + (c-name "gxdp_open_uri_get_type") + (return-type "GType") +) + +(define-function gxdp_open_uri_interface_info + (c-name "gxdp_open_uri_interface_info") + (return-type "GDBusInterfaceInfo*") +) + +(define-function gxdp_open_uri_override_properties + (c-name "gxdp_open_uri_override_properties") + (return-type "guint") + (parameters + '("GObjectClass*" "klass") + '("guint" "property_id_begin") + ) +) + +(define-method complete_open_uri + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_complete_open_uri") + (return-type "none") + (parameters + '("GDBusMethodInvocation*" "invocation") + '("const-gchar*" "handle") + ) +) + +(define-method complete_open_file + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_complete_open_file") + (return-type "none") + (parameters + '("GDBusMethodInvocation*" "invocation") + '("GUnixFDList*" "fd_list") + '("const-gchar*" "handle") + ) +) + +(define-method call_open_uri + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_uri") + (return-type "none") + (parameters + '("const-gchar*" "arg_parent_window") + '("const-gchar*" "arg_uri") + '("GVariant*" "arg_options") + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-method call_open_uri_finish + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_uri_finish") + (return-type "gboolean") + (parameters + '("gchar**" "out_handle") + '("GAsyncResult*" "res") + '("GError**" "error") + ) +) + +(define-method call_open_uri_sync + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_uri_sync") + (return-type "gboolean") + (parameters + '("const-gchar*" "arg_parent_window") + '("const-gchar*" "arg_uri") + '("GVariant*" "arg_options") + '("gchar**" "out_handle") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + +(define-method call_open_file + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_file") + (return-type "none") + (parameters + '("const-gchar*" "arg_parent_window") + '("GVariant*" "arg_fd") + '("GVariant*" "arg_options") + '("GUnixFDList*" "fd_list") + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-method call_open_file_finish + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_file_finish") + (return-type "gboolean") + (parameters + '("gchar**" "out_handle") + '("GUnixFDList**" "out_fd_list") + '("GAsyncResult*" "res") + '("GError**" "error") + ) +) + +(define-method call_open_file_sync + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_call_open_file_sync") + (return-type "gboolean") + (parameters + '("const-gchar*" "arg_parent_window") + '("GVariant*" "arg_fd") + '("GVariant*" "arg_options") + '("GUnixFDList*" "fd_list") + '("gchar**" "out_handle") + '("GUnixFDList**" "out_fd_list") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + +(define-method get_version + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_get_version") + (return-type "guint") +) + +(define-method set_version + (of-object "GXdpOpenURI") + (c-name "gxdp_open_uri_set_version") + (return-type "none") + (parameters + '("guint" "value") + ) +) + +(define-function gxdp_open_uri_proxy_get_type + (c-name "gxdp_open_uri_proxy_get_type") + (return-type "GType") +) + +(define-function gxdp_open_uri_proxy_new_finish + (c-name "gxdp_open_uri_proxy_new_finish") + (return-type "GXdpOpenURI*") + (parameters + '("GAsyncResult*" "res") + '("GError**" "error") + ) +) + +(define-function gxdp_open_uri_proxy_new_sync + (c-name "gxdp_open_uri_proxy_new_sync") + (return-type "GXdpOpenURI*") + (parameters + '("GDBusConnection*" "connection") + '("GDBusProxyFlags" "flags") + '("const-gchar*" "name") + '("const-gchar*" "object_path") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + +(define-function gxdp_open_uri_proxy_new_for_bus + (c-name "gxdp_open_uri_proxy_new_for_bus") + (return-type "none") + (parameters + '("GBusType" "bus_type") + '("GDBusProxyFlags" "flags") + '("const-gchar*" "name") + '("const-gchar*" "object_path") + '("GCancellable*" "cancellable") + '("GAsyncReadyCallback" "callback") + '("gpointer" "user_data") + ) +) + +(define-function gxdp_open_uri_proxy_new_for_bus_finish + (c-name "gxdp_open_uri_proxy_new_for_bus_finish") + (return-type "GXdpOpenURI*") + (parameters + '("GAsyncResult*" "res") + '("GError**" "error") + ) +) + +(define-function gxdp_open_uri_proxy_new_for_bus_sync + (c-name "gxdp_open_uri_proxy_new_for_bus_sync") + (return-type "GXdpOpenURI*") + (parameters + '("GBusType" "bus_type") + '("GDBusProxyFlags" "flags") + '("const-gchar*" "name") + '("const-gchar*" "object_path") + '("GCancellable*" "cancellable") + '("GError**" "error") + ) +) + +(define-function gxdp_open_uri_skeleton_get_type + (c-name "gxdp_open_uri_skeleton_get_type") + (return-type "GType") +) + (define-function gxdp_network_monitor_get_type (c-name "gxdp_network_monitor_get_type") (return-type "GType") diff --git a/gio/src/gio_signals.defs b/gio/src/gio_signals.defs index 31a2683..90e1ecb 100644 --- a/gio/src/gio_signals.defs +++ b/gio/src/gio_signals.defs @@ -9,6 +9,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "TRUE") ) (define-property name @@ -18,6 +19,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "") ) (define-property parameter-type @@ -52,7 +54,8 @@ (define-signal action-added (of-object "GActionGroup") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -61,7 +64,8 @@ (define-signal action-removed (of-object "GActionGroup") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -70,7 +74,8 @@ (define-signal action-enabled-changed (of-object "GActionGroup") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") '("gboolean" "p1") @@ -80,7 +85,8 @@ (define-signal action-state-changed (of-object "GActionGroup") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") + (detailed #t) (parameters '("const-gchar*" "p0") '("GVariant*" "p1") @@ -89,28 +95,28 @@ ;; From GApplication -(define-signal activate +(define-signal startup (of-object "GApplication") (return-type "void") - (when "last") + (flags "Run First") ) -(define-signal startup +(define-signal shutdown (of-object "GApplication") (return-type "void") - (when "first") + (flags "Run Last") ) -(define-signal shutdown +(define-signal activate (of-object "GApplication") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal open (of-object "GApplication") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("gpointer" "p0") '("gint" "p1") @@ -121,7 +127,7 @@ (define-signal command-line (of-object "GApplication") (return-type "gint") - (when "last") + (flags "Run Last") (parameters '("GApplicationCommandLine*" "p0") ) @@ -130,7 +136,7 @@ (define-signal handle-local-options (of-object "GApplication") (return-type "gint") - (when "last") + (flags "Run Last") (parameters '("GVariantDict*" "p0") ) @@ -143,6 +149,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property flags @@ -152,6 +159,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_APPLICATION_FLAGS_NONE") ) (define-property resource-base-path @@ -161,6 +169,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property is-registered @@ -170,6 +179,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-remote @@ -179,6 +189,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property inactivity-timeout @@ -188,6 +199,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "0") ) (define-property action-group @@ -207,6 +219,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GAppInfoMonitor @@ -214,7 +227,7 @@ (define-signal changed (of-object "GAppInfoMonitor") (return-type "void") - (when "first") + (flags "Run First") ) ;; From GCancellable @@ -222,7 +235,7 @@ (define-signal cancelled (of-object "GCancellable") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GBufferedInputStream @@ -234,6 +247,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "4096") ) ;; From GBufferedOutputStream @@ -245,6 +259,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "4096") ) (define-property auto-grow @@ -254,6 +269,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) ;; From GCharsetConverter @@ -265,6 +281,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property to-charset @@ -274,6 +291,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property use-fallback @@ -283,6 +301,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) ;; From GConverterInputStream @@ -316,6 +335,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_DATA_STREAM_BYTE_ORDER_BIG_ENDIAN") ) (define-property newline-type @@ -325,6 +345,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_DATA_STREAM_NEWLINE_TYPE_LF") ) ;; From GDataOutputStream @@ -336,6 +357,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_DATA_STREAM_BYTE_ORDER_BIG_ENDIAN") ) ;; From GDrive @@ -343,25 +365,25 @@ (define-signal changed (of-object "GDrive") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal disconnected (of-object "GDrive") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal eject-button (of-object "GDrive") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal stop-button (of-object "GDrive") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GFile @@ -395,7 +417,7 @@ (define-signal changed (of-object "GFileMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GFile*" "p0") '("GFile*" "p1") @@ -410,6 +432,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "800") ) (define-property cancelled @@ -419,6 +442,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GFilenameCompleter @@ -426,7 +450,7 @@ (define-signal got-completion-data (of-object "GFilenameCompleter") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GFileInputStream @@ -451,6 +475,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) ;; From GFilterOutputStream @@ -471,6 +496,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "TRUE") ) ;; From GUnixCredentialsMessage @@ -504,6 +530,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "-1") ) (define-property close-fd @@ -513,6 +540,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) ;; From GUnixOutputStream @@ -524,6 +552,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "-1") ) (define-property close-fd @@ -533,6 +562,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) ;; From GUnixSocketAddress @@ -544,6 +574,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property path-as-array @@ -562,6 +593,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "FALSE") ) (define-property address-type @@ -571,6 +603,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_UNIX_SOCKET_ADDRESS_PATH") ) ;; From GInputStream @@ -580,7 +613,7 @@ (define-signal items-changed (of-object "GListModel") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("guint" "p0") '("guint" "p1") @@ -621,6 +654,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property data-size @@ -630,6 +664,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "0") ) (define-property realloc-function @@ -657,7 +692,7 @@ (define-signal items-changed (of-object "GMenuModel") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("gint" "p0") '("gint" "p1") @@ -670,19 +705,19 @@ (define-signal changed (of-object "GMount") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal unmounted (of-object "GMount") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal pre-unmount (of-object "GMount") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GMountOperation @@ -690,7 +725,7 @@ (define-signal ask-password (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("const-gchar*" "p0") '("const-gchar*" "p1") @@ -702,7 +737,7 @@ (define-signal ask-question (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("const-gchar*" "p0") '("const-gchar**" "p1") @@ -712,7 +747,7 @@ (define-signal reply (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GMountOperationResult" "p0") ) @@ -721,13 +756,13 @@ (define-signal aborted (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal show-processes (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("const-gchar*" "p0") '("GArray*" "p1") @@ -738,7 +773,7 @@ (define-signal show-unmount-progress (of-object "GMountOperation") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("const-gchar*" "p0") '("gint64" "p1") @@ -753,6 +788,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property password @@ -762,6 +798,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property anonymous @@ -771,6 +808,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property domain @@ -780,6 +818,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property password-save @@ -789,6 +828,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_PASSWORD_SAVE_NEVER") ) (define-property choice @@ -798,6 +838,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "0") ) ;; From GNotification @@ -811,6 +852,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property can-acquire @@ -820,6 +862,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property can-release @@ -829,6 +872,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GPropertyAction @@ -840,6 +884,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property parameter-type @@ -858,6 +903,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "TRUE") ) (define-property state-type @@ -894,6 +940,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "") ) (define-property invert-boolean @@ -903,6 +950,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "FALSE") ) ;; From GProxy @@ -916,6 +964,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property destination-protocol @@ -925,6 +974,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property destination-hostname @@ -934,6 +984,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property destination-port @@ -943,6 +994,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property username @@ -952,6 +1004,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property password @@ -961,15 +1014,17 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property uri (of-object "GProxyAddress") (prop-type "GParamString") - (docs "The proxy's URI") + (docs "The proxy’s URI") (readable #t) (writable #t) (construct-only #t) + (default-value "") ) ;; From GProxyAddressEnumerator @@ -981,6 +1036,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property default-port @@ -990,6 +1046,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property connectable @@ -1019,7 +1076,8 @@ (define-signal changed (of-object "GSettings") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -1028,7 +1086,7 @@ (define-signal change-event (of-object "GSettings") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("gpointer" "p0") '("gint" "p1") @@ -1038,7 +1096,8 @@ (define-signal writable-changed (of-object "GSettings") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -1047,7 +1106,7 @@ (define-signal writable-change-event (of-object "GSettings") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GQuark" "p0") ) @@ -1070,6 +1129,7 @@ (writable #t) (construct-only #t) (deprecated #t) + (default-value "") ) (define-property schema-id @@ -1079,6 +1139,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property backend @@ -1097,6 +1158,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property has-unapplied @@ -1106,15 +1168,17 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property delay-apply (of-object "GSettings") (prop-type "GParamBoolean") - (docs "Whether this settings object is in 'delay-apply' mode") + (docs "Whether this settings object is in “delay-apply” mode") (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GSettingsBackend @@ -1126,7 +1190,7 @@ (define-signal activate (of-object "GSimpleAction") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters '("GVariant*" "p0") ) @@ -1135,7 +1199,7 @@ (define-signal change-state (of-object "GSimpleAction") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters '("GVariant*" "p0") ) @@ -1148,6 +1212,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property parameter-type @@ -1166,6 +1231,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property state-type @@ -1215,6 +1281,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "G_SUBPROCESS_FLAGS_NONE") ) (define-property argv @@ -1235,6 +1302,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "G_SUBPROCESS_FLAGS_NONE") ) ;; From GThemedIcon @@ -1246,6 +1314,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "") ) (define-property names @@ -1260,10 +1329,11 @@ (define-property use-default-fallbacks (of-object "GThemedIcon") (prop-type "GParamBoolean") - (docs "Whether to use default fallbacks found by shortening the name at '-' characters. Ignores names after the first if multiple names are given.") + (docs "Whether to use default fallbacks found by shortening the name at “-” characters. Ignores names after the first if multiple names are given.") (readable #t) (writable #t) (construct-only #t) + (default-value "FALSE") ) ;; From GVolume @@ -1271,13 +1341,13 @@ (define-signal changed (of-object "GVolume") (return-type "void") - (when "last") + (flags "Run Last") ) (define-signal removed (of-object "GVolume") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GVolumeMonitor @@ -1285,7 +1355,7 @@ (define-signal volume-added (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GVolume*" "p0") ) @@ -1294,7 +1364,7 @@ (define-signal volume-removed (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GVolume*" "p0") ) @@ -1303,7 +1373,7 @@ (define-signal volume-changed (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GVolume*" "p0") ) @@ -1312,7 +1382,7 @@ (define-signal mount-added (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GMount*" "p0") ) @@ -1321,7 +1391,7 @@ (define-signal mount-removed (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GMount*" "p0") ) @@ -1330,7 +1400,7 @@ (define-signal mount-pre-unmount (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GMount*" "p0") ) @@ -1339,7 +1409,7 @@ (define-signal mount-changed (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GMount*" "p0") ) @@ -1348,7 +1418,7 @@ (define-signal drive-connected (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDrive*" "p0") ) @@ -1357,7 +1427,7 @@ (define-signal drive-disconnected (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDrive*" "p0") ) @@ -1366,7 +1436,7 @@ (define-signal drive-changed (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDrive*" "p0") ) @@ -1375,7 +1445,7 @@ (define-signal drive-eject-button (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDrive*" "p0") ) @@ -1384,7 +1454,7 @@ (define-signal drive-stop-button (of-object "GVolumeMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDrive*" "p0") ) @@ -1399,6 +1469,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_ZLIB_COMPRESSOR_FORMAT_ZLIB") ) (define-property level @@ -1408,6 +1479,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "-1") ) (define-property file-info @@ -1428,6 +1500,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_ZLIB_COMPRESSOR_FORMAT_ZLIB") ) (define-property file-info @@ -1448,6 +1521,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_SOCKET_FAMILY_INVALID") ) (define-property bytes @@ -1466,6 +1540,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-loopback @@ -1475,6 +1550,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-link-local @@ -1484,6 +1560,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-site-local @@ -1493,6 +1570,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-multicast @@ -1502,6 +1580,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-mc-global @@ -1511,6 +1590,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-mc-link-local @@ -1520,6 +1600,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-mc-node-local @@ -1529,6 +1610,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-mc-org-local @@ -1538,6 +1620,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property is-mc-site-local @@ -1547,6 +1630,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GInetSocketAddress @@ -1567,6 +1651,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property flowinfo @@ -1576,6 +1661,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property scope-id @@ -1585,6 +1671,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) ;; From GSocketAddress @@ -1596,6 +1683,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "G_SOCKET_FAMILY_INVALID") ) ;; From GSocketAddressEnumerator @@ -1609,7 +1697,7 @@ (define-signal reload (of-object "GResolver") (return-type "void") - (when "last") + (flags "Run Last") ) ;; From GNetworkAddress @@ -1621,6 +1709,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property port @@ -1630,6 +1719,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "0") ) (define-property scheme @@ -1639,6 +1729,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) ;; From GNetworkMonitor @@ -1646,7 +1737,7 @@ (define-signal network-changed (of-object "GNetworkMonitor") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("gboolean" "p0") ) @@ -1659,6 +1750,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "G_NETWORK_CONNECTIVITY_FULL") ) (define-property network-available @@ -1668,6 +1760,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property network-metered @@ -1677,6 +1770,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GNetworkService @@ -1688,6 +1782,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property protocol @@ -1697,6 +1792,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property domain @@ -1706,6 +1802,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property scheme @@ -1715,6 +1812,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) ;; From GSettings @@ -1722,7 +1820,8 @@ (define-signal changed (of-object "GSettings") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -1731,7 +1830,7 @@ (define-signal change-event (of-object "GSettings") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("gpointer" "p0") '("gint" "p1") @@ -1741,7 +1840,8 @@ (define-signal writable-changed (of-object "GSettings") (return-type "void") - (when "last") + (flags "Run Last") + (detailed #t) (parameters '("const-gchar*" "p0") ) @@ -1750,7 +1850,7 @@ (define-signal writable-change-event (of-object "GSettings") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GQuark" "p0") ) @@ -1773,6 +1873,7 @@ (writable #t) (construct-only #t) (deprecated #t) + (default-value "") ) (define-property schema-id @@ -1782,6 +1883,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property backend @@ -1800,6 +1902,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property has-unapplied @@ -1809,15 +1912,17 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property delay-apply (of-object "GSettings") (prop-type "GParamBoolean") - (docs "Whether this settings object is in 'delay-apply' mode") + (docs "Whether this settings object is in “delay-apply” mode") (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; GSettingsSchema is neither a GObject nor a GInterface. Not checked for signals and properties. @@ -1837,6 +1942,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_SOCKET_FAMILY_INVALID") ) (define-property type @@ -1846,6 +1952,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_SOCKET_TYPE_STREAM") ) (define-property protocol @@ -1855,6 +1962,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_SOCKET_PROTOCOL_UNKNOWN") ) (define-property fd @@ -1864,6 +1972,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "-1") ) (define-property blocking @@ -1873,6 +1982,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property listen-backlog @@ -1882,6 +1992,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "10") ) (define-property keepalive @@ -1891,6 +2002,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property local-address @@ -1918,6 +2030,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "0") ) (define-property ttl @@ -1927,6 +2040,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "0") ) (define-property broadcast @@ -1936,6 +2050,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property multicast-loopback @@ -1945,6 +2060,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property multicast-ttl @@ -1954,6 +2070,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "1") ) ;; From GSocketClient @@ -1961,7 +2078,7 @@ (define-signal event (of-object "GSocketClient") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GSocketClientEvent" "p0") '("GSocketConnectable*" "p1") @@ -1976,6 +2093,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_SOCKET_FAMILY_INVALID") ) (define-property type @@ -1985,6 +2103,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_SOCKET_TYPE_STREAM") ) (define-property protocol @@ -1994,6 +2113,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_SOCKET_PROTOCOL_DEFAULT") ) (define-property local-address @@ -2012,6 +2132,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "0") ) (define-property enable-proxy @@ -2021,6 +2142,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property tls @@ -2030,6 +2152,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property tls-validation-flags @@ -2039,6 +2162,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_TLS_CERTIFICATE_UNKNOWN_CA | G_TLS_CERTIFICATE_BAD_IDENTITY | G_TLS_CERTIFICATE_NOT_ACTIVATED | G_TLS_CERTIFICATE_EXPIRED | G_TLS_CERTIFICATE_REVOKED | G_TLS_CERTIFICATE_INSECURE | G_TLS_CERTIFICATE_GENERIC_ERROR") ) (define-property proxy-resolver @@ -2070,6 +2194,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) ;; From GTcpWrapperConnection @@ -2103,12 +2228,13 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property private-key (of-object "GTlsCertificate") (prop-type "GParamBoxed") - (docs "The DER representation of the certificate's private key") + (docs "The DER representation of the certificate’s private key") (readable #f) (writable #t) (construct-only #t) @@ -2117,10 +2243,11 @@ (define-property private-key-pem (of-object "GTlsCertificate") (prop-type "GParamString") - (docs "The PEM representation of the certificate's private key") + (docs "The PEM representation of the certificate’s private key") (readable #f) (writable #t) (construct-only #t) + (default-value "") ) (define-property issuer @@ -2159,6 +2286,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property validation-flags @@ -2168,6 +2296,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_TLS_CERTIFICATE_UNKNOWN_CA | G_TLS_CERTIFICATE_BAD_IDENTITY | G_TLS_CERTIFICATE_NOT_ACTIVATED | G_TLS_CERTIFICATE_EXPIRED | G_TLS_CERTIFICATE_REVOKED | G_TLS_CERTIFICATE_INSECURE | G_TLS_CERTIFICATE_GENERIC_ERROR") ) ;; From GTlsConnection @@ -2175,7 +2304,7 @@ (define-signal accept-certificate (of-object "GTlsConnection") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GTlsCertificate*" "p0") '("GTlsCertificateFlags" "p1") @@ -2198,6 +2327,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property rehandshake-mode @@ -2207,6 +2337,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_TLS_REHANDSHAKE_SAFELY") ) (define-property use-system-certdb @@ -2216,6 +2347,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) (define-property database @@ -2239,7 +2371,7 @@ (define-property certificate (of-object "GTlsConnection") (prop-type "GParamObject") - (docs "The connection's certificate") + (docs "The connection’s certificate") (readable #t) (writable #t) (construct-only #f) @@ -2248,7 +2380,7 @@ (define-property peer-certificate (of-object "GTlsConnection") (prop-type "GParamObject") - (docs "The connection's peer's certificate") + (docs "The connection’s peer’s certificate") (readable #t) (writable #f) (construct-only #f) @@ -2257,10 +2389,11 @@ (define-property peer-certificate-errors (of-object "GTlsConnection") (prop-type "GParamFlags") - (docs "Errors found with the peer's certificate") + (docs "Errors found with the peer’s certificate") (readable #t) (writable #f) (construct-only #f) + (default-value "0") ) ;; From GTlsDatabase @@ -2274,6 +2407,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) ;; From GTlsInteraction @@ -2287,6 +2421,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_TLS_PASSWORD_NONE") ) (define-property description @@ -2296,6 +2431,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) (define-property warning @@ -2305,6 +2441,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "") ) ;; From GTlsServerConnection @@ -2316,6 +2453,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_TLS_AUTHENTICATION_NONE") ) ;; From GUnixConnection @@ -2325,7 +2463,7 @@ (define-signal event (of-object "GSocketListener") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GSocketListenerEvent" "p0") '("GSocket*" "p1") @@ -2339,6 +2477,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "10") ) ;; From GSocketService @@ -2346,7 +2485,7 @@ (define-signal incoming (of-object "GSocketService") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GSocketConnection*" "p0") '("GObject*" "p1") @@ -2360,6 +2499,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "TRUE") ) ;; From GThreadedSocketService @@ -2367,7 +2507,7 @@ (define-signal run (of-object "GThreadedSocketService") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GSocketConnection*" "p0") '("GObject*" "p1") @@ -2381,6 +2521,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "10") ) ;; From GDBusAuthObserver @@ -2388,7 +2529,7 @@ (define-signal authorize-authenticated-peer (of-object "GDBusAuthObserver") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GIOStream*" "p0") '("GCredentials*" "p1") @@ -2398,7 +2539,7 @@ (define-signal allow-mechanism (of-object "GDBusAuthObserver") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("const-gchar*" "p0") ) @@ -2409,7 +2550,7 @@ (define-signal closed (of-object "GDBusConnection") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("gboolean" "p0") '("GError*" "p1") @@ -2432,6 +2573,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "") ) (define-property flags @@ -2441,6 +2583,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "G_DBUS_CONNECTION_FLAGS_NONE") ) (define-property guid @@ -2450,6 +2593,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property unique-name @@ -2459,6 +2603,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "") ) (define-property closed @@ -2468,6 +2613,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property exit-on-close @@ -2477,6 +2623,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "FALSE") ) (define-property capabilities @@ -2486,6 +2633,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "G_DBUS_CAPABILITY_FLAGS_NONE") ) (define-property authentication-observer @@ -2518,7 +2666,7 @@ (define-signal g-authorize-method (of-object "GDBusInterfaceSkeleton") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GDBusMethodInvocation*" "p0") ) @@ -2531,6 +2679,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "G_DBUS_INTERFACE_SKELETON_FLAGS_NONE") ) ;; From GDBusObject @@ -2538,7 +2687,7 @@ (define-signal interface-added (of-object "GDBusObject") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDBusInterface*" "p0") ) @@ -2547,7 +2696,7 @@ (define-signal interface-removed (of-object "GDBusObject") (return-type "void") - (when "last") + (flags "Run Last") (parameters '("GDBusInterface*" "p0") ) @@ -2564,6 +2713,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) ;; From GDBusMethodInvocation @@ -2573,7 +2723,7 @@ (define-signal g-properties-changed (of-object "GDBusProxy") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters '("GVariant*" "p0") '("const-gchar*const*" "p1") @@ -2583,7 +2733,7 @@ (define-signal g-signal (of-object "GDBusProxy") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters '("const-gchar*" "p0") '("const-gchar*" "p1") @@ -2607,6 +2757,7 @@ (readable #f) (writable #t) (construct-only #t) + (default-value "G_BUS_TYPE_NONE") ) (define-property g-name @@ -2616,6 +2767,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property g-name-owner @@ -2625,6 +2777,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "") ) (define-property g-flags @@ -2634,6 +2787,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_DBUS_PROXY_FLAGS_NONE") ) (define-property g-object-path @@ -2643,6 +2797,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property g-interface-name @@ -2652,6 +2807,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property g-default-timeout @@ -2661,6 +2817,7 @@ (readable #t) (writable #t) (construct-only #f) + (default-value "-1") ) (define-property g-interface-info @@ -2677,7 +2834,7 @@ (define-signal new-connection (of-object "GDBusServer") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters '("GDBusConnection*" "p0") ) @@ -2690,6 +2847,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property client-address @@ -2699,6 +2857,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "") ) (define-property flags @@ -2708,6 +2867,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_DBUS_SERVER_FLAGS_NONE") ) (define-property guid @@ -2717,6 +2877,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property active @@ -2726,6 +2887,7 @@ (readable #t) (writable #f) (construct-only #f) + (default-value "FALSE") ) (define-property authentication-observer diff --git a/gio/src/gio_signals.defs.patch b/gio/src/gio_signals.defs.patch index 06a331f..f3db90f 100644 --- a/gio/src/gio_signals.defs.patch +++ b/gio/src/gio_signals.defs.patch @@ -1,7 +1,9 @@ ---- gio_signals.defs 2012-02-28 13:19:25.000000000 -0500 -+++ gio_signals.defs.new 2012-02-28 12:47:50.000000000 -0500 -@@ -83,7 +83,7 @@ - (when "last") +--- ./../../gio/src/gio_signals.defs.orig 2017-09-11 09:52:55.272837455 +0200 ++++ ./../../gio/src/gio_signals.defs 2017-09-11 14:56:39.662521043 +0200 +@@ -87,11 +87,11 @@ + (return-type "void") + (flags "Run Last, Must Collect") + (detailed #t) (parameters '("const-gchar*" "p0") - '("GVariant" "p1") @@ -9,8 +11,12 @@ ) ) -@@ -579,7 +579,7 @@ - (when "last") + ;; From GApplication + +@@ -738,11 +738,11 @@ + (of-object "GMountOperation") + (return-type "void") + (flags "Run Last") (parameters '("const-gchar*" "p0") - '("GStrv*" "p1") @@ -18,45 +24,62 @@ ) ) -@@ -849,7 +849,7 @@ - (return-type "void") - (when "last") + (define-signal reply + (of-object "GMountOperation") +@@ -1106,11 +1106,11 @@ + (define-signal writable-change-event + (of-object "GSettings") + (return-type "gboolean") + (flags "Run Last") (parameters -- '("GVariant" "p0") -+ '("GVariant*" "p0") +- '("guint" "p0") ++ '("GQuark" "p0") ) ) -@@ -858,7 +858,7 @@ + (define-property settings-schema + (of-object "GSettings") +@@ -1190,20 +1190,20 @@ + (define-signal activate + (of-object "GSimpleAction") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters - '("GVariant" "p0") + '("GVariant*" "p0") ) ) -@@ -1049,6 +1049,6 @@ - (return-type "gboolean") - (when "last") + (define-signal change-state + (of-object "GSimpleAction") + (return-type "void") + (flags "Run Last, Must Collect") (parameters -- '("guint" "p0") -+ '("GQuark" "p0") +- '("GVariant" "p0") ++ '("GVariant*" "p0") ) ) - -@@ -1752,6 +1752,6 @@ + + (define-property name + (of-object "GSimpleAction") +@@ -1850,11 +1850,11 @@ + (define-signal writable-change-event + (of-object "GSettings") (return-type "gboolean") - (when "last") + (flags "Run Last") (parameters - '("guint" "p0") + '("GQuark" "p0") ) ) - -@@ -1824,8 +1824,8 @@ + + (define-property settings-schema + (of-object "GSettings") +@@ -2723,23 +2723,23 @@ + (define-signal g-properties-changed + (of-object "GDBusProxy") (return-type "void") - (when "last") + (flags "Run Last, Must Collect") (parameters - '("GVariant" "p0") - '("GStrv*" "p1") @@ -65,7 +88,10 @@ ) ) -@@ -1836,7 +1836,7 @@ + (define-signal g-signal + (of-object "GDBusProxy") + (return-type "void") + (flags "Run Last, Must Collect") (parameters '("const-gchar*" "p0") '("const-gchar*" "p1") @@ -74,3 +100,5 @@ ) ) + (define-property g-connection + (of-object "GDBusProxy") diff --git a/gio/src/icon.ccg b/gio/src/icon.ccg index fdc6c87..cbd6540 100644 --- a/gio/src/icon.ccg +++ b/gio/src/icon.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/icon.hg b/gio/src/icon.hg index 36888f7..ce9b07a 100644 --- a/gio/src/icon.hg +++ b/gio/src/icon.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inetaddress.ccg b/gio/src/inetaddress.ccg index f8c926f..f61a2c6 100644 --- a/gio/src/inetaddress.ccg +++ b/gio/src/inetaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inetaddress.hg b/gio/src/inetaddress.hg index 6dd4467..e4c0c0a 100644 --- a/gio/src/inetaddress.hg +++ b/gio/src/inetaddress.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inetsocketaddress.ccg b/gio/src/inetsocketaddress.ccg index 5317f38..24667b5 100644 --- a/gio/src/inetsocketaddress.ccg +++ b/gio/src/inetsocketaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inetsocketaddress.hg b/gio/src/inetsocketaddress.hg index 8b20c16..4177cb5 100644 --- a/gio/src/inetsocketaddress.hg +++ b/gio/src/inetsocketaddress.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2009 jonathon jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -57,10 +54,13 @@ public: _WRAP_METHOD(guint32 get_flowinfo() const, g_inet_socket_address_get_flowinfo) _WRAP_METHOD(guint32 get_scope_id() const, g_inet_socket_address_get_scope_id) - _WRAP_PROPERTY("address", Glib::RefPtr) - _WRAP_PROPERTY("port", guint16) - _WRAP_PROPERTY("flowinfo", guint32) - _WRAP_PROPERTY("scope-id", guint32) + _WRAP_PROPERTY("address", Glib::RefPtr) + // Don't use guint16 or guint32 in _WRAP_PROPERTY(). + // There are no Glib::Value<> specializations for those types. + // Glib::Value exists, and guint is a typedef of unsigned int. + _WRAP_PROPERTY("port", guint) + _WRAP_PROPERTY("flowinfo", guint) + _WRAP_PROPERTY("scope-id", guint) }; } // namespace Gio diff --git a/gio/src/initable.ccg b/gio/src/initable.ccg index b3b3256..24c22d9 100644 --- a/gio/src/initable.ccg +++ b/gio/src/initable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2009 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/initable.hg b/gio/src/initable.hg index f47f678..27e9e1b 100644 --- a/gio/src/initable.hg +++ b/gio/src/initable.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inputstream.ccg b/gio/src/inputstream.ccg index 9716003..620f93d 100644 --- a/gio/src/inputstream.ccg +++ b/gio/src/inputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/inputstream.hg b/gio/src/inputstream.hg index 315ed86..1618043 100644 --- a/gio/src/inputstream.hg +++ b/gio/src/inputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/iostream.ccg b/gio/src/iostream.ccg index a278ddf..800932d 100644 --- a/gio/src/iostream.ccg +++ b/gio/src/iostream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/iostream.hg b/gio/src/iostream.hg index 1051b96..f52fe17 100644 --- a/gio/src/iostream.hg +++ b/gio/src/iostream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/listmodel.ccg b/gio/src/listmodel.ccg index b6004fa..aeabe40 100644 --- a/gio/src/listmodel.ccg +++ b/gio/src/listmodel.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/listmodel.hg b/gio/src/listmodel.hg index 3f8cec0..b7abfe9 100644 --- a/gio/src/listmodel.hg +++ b/gio/src/listmodel.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/liststore.ccg b/gio/src/liststore.ccg index 4580c5e..3b2191d 100644 --- a/gio/src/liststore.ccg +++ b/gio/src/liststore.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/liststore.hg b/gio/src/liststore.hg index 3b86e25..8c93c85 100644 --- a/gio/src/liststore.hg +++ b/gio/src/liststore.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/loadableicon.ccg b/gio/src/loadableicon.ccg index f39c6e4..22f6950 100644 --- a/gio/src/loadableicon.ccg +++ b/gio/src/loadableicon.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/loadableicon.hg b/gio/src/loadableicon.hg index a49b8c2..a706f24 100644 --- a/gio/src/loadableicon.hg +++ b/gio/src/loadableicon.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/memoryinputstream.ccg b/gio/src/memoryinputstream.ccg index 38126a4..920e616 100644 --- a/gio/src/memoryinputstream.ccg +++ b/gio/src/memoryinputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/memoryinputstream.hg b/gio/src/memoryinputstream.hg index 5a918fd..1485256 100644 --- a/gio/src/memoryinputstream.hg +++ b/gio/src/memoryinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/memoryoutputstream.ccg b/gio/src/memoryoutputstream.ccg index 45f52e0..8271958 100644 --- a/gio/src/memoryoutputstream.ccg +++ b/gio/src/memoryoutputstream.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/memoryoutputstream.hg b/gio/src/memoryoutputstream.hg index 6768615..310caec 100644 --- a/gio/src/memoryoutputstream.hg +++ b/gio/src/memoryoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menu.ccg b/gio/src/menu.ccg index 969d51e..7f97a55 100644 --- a/gio/src/menu.ccg +++ b/gio/src/menu.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menu.hg b/gio/src/menu.hg index e3f1d6d..99d5ff1 100644 --- a/gio/src/menu.hg +++ b/gio/src/menu.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menuattributeiter.ccg b/gio/src/menuattributeiter.ccg index 83ea74a..7c74164 100644 --- a/gio/src/menuattributeiter.ccg +++ b/gio/src/menuattributeiter.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menuattributeiter.hg b/gio/src/menuattributeiter.hg index 0e2c941..558c240 100644 --- a/gio/src/menuattributeiter.hg +++ b/gio/src/menuattributeiter.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menuitem.ccg b/gio/src/menuitem.ccg index 2f6dc38..4db5c4d 100644 --- a/gio/src/menuitem.ccg +++ b/gio/src/menuitem.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menuitem.hg b/gio/src/menuitem.hg index 3830880..0fff756 100644 --- a/gio/src/menuitem.hg +++ b/gio/src/menuitem.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/menulinkiter.ccg b/gio/src/menulinkiter.ccg index 542e46d..190f557 100644 --- a/gio/src/menulinkiter.ccg +++ b/gio/src/menulinkiter.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menulinkiter.hg b/gio/src/menulinkiter.hg index b3606d0..8cba9df 100644 --- a/gio/src/menulinkiter.hg +++ b/gio/src/menulinkiter.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menumodel.ccg b/gio/src/menumodel.ccg index 48b9b2b..9adbe29 100644 --- a/gio/src/menumodel.ccg +++ b/gio/src/menumodel.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/menumodel.hg b/gio/src/menumodel.hg index bf29a12..81fb877 100644 --- a/gio/src/menumodel.hg +++ b/gio/src/menumodel.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/mount.ccg b/gio/src/mount.ccg index 2ba1001..6a4fd36 100644 --- a/gio/src/mount.ccg +++ b/gio/src/mount.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/mount.hg b/gio/src/mount.hg index 3356ec3..d4d93e0 100644 --- a/gio/src/mount.hg +++ b/gio/src/mount.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include diff --git a/gio/src/mountoperation.ccg b/gio/src/mountoperation.ccg index 4aa7761..228e6fd 100644 --- a/gio/src/mountoperation.ccg +++ b/gio/src/mountoperation.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/mountoperation.hg b/gio/src/mountoperation.hg index 7b2cc68..17b74a8 100644 --- a/gio/src/mountoperation.hg +++ b/gio/src/mountoperation.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/networkaddress.ccg b/gio/src/networkaddress.ccg index 43e2d87..6f2f99d 100644 --- a/gio/src/networkaddress.ccg +++ b/gio/src/networkaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/networkaddress.hg b/gio/src/networkaddress.hg index 5e6aeff..ff5e123 100644 --- a/gio/src/networkaddress.hg +++ b/gio/src/networkaddress.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/networkmonitor.ccg b/gio/src/networkmonitor.ccg index 1b940c5..1cd79ef 100644 --- a/gio/src/networkmonitor.ccg +++ b/gio/src/networkmonitor.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/networkmonitor.hg b/gio/src/networkmonitor.hg index df55fda..d46cbba 100644 --- a/gio/src/networkmonitor.hg +++ b/gio/src/networkmonitor.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -35,8 +34,15 @@ namespace Gio _WRAP_ENUM(NetworkConnectivity, GNetworkConnectivity, NO_GTYPE) -/** TODO +/** Network status monitor. * + * %NetworkMonitor provides an easy-to-use cross-platform API + * for monitoring network connectivity. On Linux, the available + * implementations are based on the kernel's netlink interface and + * on NetworkManager. + * + * There is also an implementation for use inside Flatpak sandboxes. + * @newin{2,44} */ class NetworkMonitor : public Glib::Interface diff --git a/gio/src/networkservice.ccg b/gio/src/networkservice.ccg index 251999b..a081e60 100644 --- a/gio/src/networkservice.ccg +++ b/gio/src/networkservice.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/networkservice.hg b/gio/src/networkservice.hg index e5288e8..581fc78 100644 --- a/gio/src/networkservice.hg +++ b/gio/src/networkservice.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/outputstream.ccg b/gio/src/outputstream.ccg index 46cfdd1..da48f7d 100644 --- a/gio/src/outputstream.ccg +++ b/gio/src/outputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/outputstream.hg b/gio/src/outputstream.hg index d3b517a..c87f23f 100644 --- a/gio/src/outputstream.hg +++ b/gio/src/outputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/permission.ccg b/gio/src/permission.ccg index 6957457..f647cbe 100644 --- a/gio/src/permission.ccg +++ b/gio/src/permission.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/permission.hg b/gio/src/permission.hg index 6405ece..d702b5b 100644 --- a/gio/src/permission.hg +++ b/gio/src/permission.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/pollableinputstream.ccg b/gio/src/pollableinputstream.ccg index 8e0aacb..2bd4c95 100644 --- a/gio/src/pollableinputstream.ccg +++ b/gio/src/pollableinputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/pollableinputstream.hg b/gio/src/pollableinputstream.hg index 9c5aa21..0000620 100644 --- a/gio/src/pollableinputstream.hg +++ b/gio/src/pollableinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/pollableoutputstream.ccg b/gio/src/pollableoutputstream.ccg index 8e0aacb..2bd4c95 100644 --- a/gio/src/pollableoutputstream.ccg +++ b/gio/src/pollableoutputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/pollableoutputstream.hg b/gio/src/pollableoutputstream.hg index 881a92d..d285824 100644 --- a/gio/src/pollableoutputstream.hg +++ b/gio/src/pollableoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/proxy.ccg b/gio/src/proxy.ccg index f744a77..bac28f6 100644 --- a/gio/src/proxy.ccg +++ b/gio/src/proxy.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/proxy.hg b/gio/src/proxy.hg index a7d5808..4fb94d2 100644 --- a/gio/src/proxy.hg +++ b/gio/src/proxy.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/proxyaddress.ccg b/gio/src/proxyaddress.ccg index ab1fdd7..bc4b3d7 100644 --- a/gio/src/proxyaddress.ccg +++ b/gio/src/proxyaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 glibmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/proxyaddress.hg b/gio/src/proxyaddress.hg index f1bb09c..44a9835 100644 --- a/gio/src/proxyaddress.hg +++ b/gio/src/proxyaddress.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2009 The glibmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -68,10 +65,10 @@ public: _WRAP_PROPERTY("protocol", Glib::ustring) _WRAP_PROPERTY("destination_protocol", Glib::ustring) _WRAP_PROPERTY("destination_hostname", Glib::ustring) - -//TODO: This should really be a guint16: - _WRAP_PROPERTY("destination_port", Glib::ustring) - + // Don't use guint16 in _WRAP_PROPERTY(). + // There is no Glib::Value<> specialization for guint16. + // Glib::Value exists, and guint is a typedef of unsigned int. + _WRAP_PROPERTY("destination_port", guint) _WRAP_PROPERTY("username", Glib::ustring) _WRAP_PROPERTY("password", Glib::ustring) _WRAP_PROPERTY("uri", Glib::ustring) diff --git a/gio/src/proxyresolver.ccg b/gio/src/proxyresolver.ccg index f9303e3..9d0a0a3 100644 --- a/gio/src/proxyresolver.ccg +++ b/gio/src/proxyresolver.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/proxyresolver.hg b/gio/src/proxyresolver.hg index 6bf449e..fb2d047 100644 --- a/gio/src/proxyresolver.hg +++ b/gio/src/proxyresolver.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/remoteactiongroup.ccg b/gio/src/remoteactiongroup.ccg index be265e5..a92a9fb 100644 --- a/gio/src/remoteactiongroup.ccg +++ b/gio/src/remoteactiongroup.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Gio diff --git a/gio/src/remoteactiongroup.hg b/gio/src/remoteactiongroup.hg index 74d094e..77c3fe2 100644 --- a/gio/src/remoteactiongroup.hg +++ b/gio/src/remoteactiongroup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/resolver.ccg b/gio/src/resolver.ccg index 7838f19..6efdf6b 100644 --- a/gio/src/resolver.ccg +++ b/gio/src/resolver.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/resolver.hg b/gio/src/resolver.hg index b360f5c..52d7fe2 100644 --- a/gio/src/resolver.hg +++ b/gio/src/resolver.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/resource.ccg b/gio/src/resource.ccg index 7a579b4..d8305b3 100644 --- a/gio/src/resource.ccg +++ b/gio/src/resource.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/resource.hg b/gio/src/resource.hg index 96f3b51..fda236b 100644 --- a/gio/src/resource.hg +++ b/gio/src/resource.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -134,13 +133,13 @@ public: _WRAP_ENUM(Flags, GResourceFlags, newin "2,44") _WRAP_ENUM(LookupFlags, GResourceLookupFlags, newin "2,44") - _WRAP_METHOD(static Glib::RefPtr create_from_data(const Glib::RefPtr& data), g_resource_new_from_data, errthrow, newin "2,44") - _WRAP_METHOD(static Glib::RefPtr create_from_file(const std::string& filename), g_resource_load, errthrow, newin "2,44") - _WRAP_METHOD(Glib::RefPtr open_stream(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_open_stream, errthrow, newin "2,44") - _WRAP_METHOD(Glib::RefPtr lookup_data(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_lookup_data, errthrow, newin "2,44") + _WRAP_METHOD(static Glib::RefPtr create_from_data(const Glib::RefPtr& data), g_resource_new_from_data, errthrow "Glib::FileError", newin "2,44") + _WRAP_METHOD(static Glib::RefPtr create_from_file(const std::string& filename), g_resource_load, errthrow "Glib::FileError", newin "2,44") + _WRAP_METHOD(Glib::RefPtr open_stream(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_open_stream, errthrow "Gio::ResourceError", newin "2,44") + _WRAP_METHOD(Glib::RefPtr lookup_data(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_lookup_data, errthrow "Gio::ResourceError", newin "2,44") #m4 _CONVERSION(`char**',`std::vector',`Glib::ArrayHandler::array_to_vector($3, Glib::OWNERSHIP_DEEP)') - _WRAP_METHOD(std::vector enumerate_children(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_enumerate_children, errthrow, newin "2,44") + _WRAP_METHOD(std::vector enumerate_children(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE) const, g_resource_enumerate_children, errthrow "Gio::ResourceError", newin "2,44") /** Looks for a file at the specified @a path in the resource and * if found returns information about it. @@ -186,9 +185,9 @@ public: // 'register' is a keyword. Can't be the name of a method. _WRAP_METHOD(void register_global(), g_resources_register, newin "2,44") _WRAP_METHOD(void unregister_global(), g_resources_unregister, newin "2,44") - _WRAP_METHOD(static Glib::RefPtr open_stream_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_open_stream, errthrow, newin "2,44") - _WRAP_METHOD(static Glib::RefPtr lookup_data_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_lookup_data, errthrow, newin "2,44") - _WRAP_METHOD(static std::vector enumerate_children_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_enumerate_children, errthrow, newin "2,44") + _WRAP_METHOD(static Glib::RefPtr open_stream_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_open_stream, errthrow "Gio::ResourceError", newin "2,44") + _WRAP_METHOD(static Glib::RefPtr lookup_data_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_lookup_data, errthrow "Gio::ResourceError", newin "2,44") + _WRAP_METHOD(static std::vector enumerate_children_global(const std::string& path, LookupFlags lookup_flags = LookupFlags::NONE), g_resources_enumerate_children, errthrow "Gio::ResourceError", newin "2,44") /** Looks for a file at the specified @a path in the set of * globally registered resources and if found returns information about it. diff --git a/gio/src/seekable.ccg b/gio/src/seekable.ccg index 43f4afe..937ee25 100644 --- a/gio/src/seekable.ccg +++ b/gio/src/seekable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/seekable.hg b/gio/src/seekable.hg index 79c0d07..ec3a635 100644 --- a/gio/src/seekable.hg +++ b/gio/src/seekable.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/settings.ccg b/gio/src/settings.ccg index 183dcf8..05ff5e2 100644 --- a/gio/src/settings.ccg +++ b/gio/src/settings.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/settings.hg b/gio/src/settings.hg index a55a694..c0abb31 100644 --- a/gio/src/settings.hg +++ b/gio/src/settings.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) @@ -135,19 +134,19 @@ public: _IGNORE(g_settings_get_default_value) _WRAP_METHOD(int get_int(const Glib::ustring& key) const, g_settings_get_int) - _WRAP_METHOD(void set_int(const Glib::ustring& key, int value), g_settings_set_int) + _WRAP_METHOD(bool set_int(const Glib::ustring& key, int value), g_settings_set_int) _WRAP_METHOD(gint64 get_int64(const Glib::ustring& key) const, g_settings_get_int64) - _WRAP_METHOD(void set_int64(const Glib::ustring& key, gint64 value), g_settings_set_int64) + _WRAP_METHOD(bool set_int64(const Glib::ustring& key, gint64 value), g_settings_set_int64) _WRAP_METHOD(guint get_uint(const Glib::ustring& key) const, g_settings_get_uint) - _WRAP_METHOD(void set_uint(const Glib::ustring& key, guint value), g_settings_set_uint) + _WRAP_METHOD(bool set_uint(const Glib::ustring& key, guint value), g_settings_set_uint) _WRAP_METHOD(guint64 get_uint64(const Glib::ustring& key) const, g_settings_get_uint64) - _WRAP_METHOD(void set_uint64(const Glib::ustring& key, guint64 value), g_settings_set_uint64) + _WRAP_METHOD(bool set_uint64(const Glib::ustring& key, guint64 value), g_settings_set_uint64) _WRAP_METHOD(bool get_boolean(const Glib::ustring& key) const, g_settings_get_boolean) - _WRAP_METHOD(void set_boolean(const Glib::ustring& key, bool value), g_settings_set_boolean) + _WRAP_METHOD(bool set_boolean(const Glib::ustring& key, bool value), g_settings_set_boolean) _WRAP_METHOD(Glib::ustring get_string(const Glib::ustring& key) const, g_settings_get_string) - _WRAP_METHOD(void set_string(const Glib::ustring& key, const Glib::ustring& value), g_settings_set_string) + _WRAP_METHOD(bool set_string(const Glib::ustring& key, const Glib::ustring& value), g_settings_set_string) _WRAP_METHOD(double get_double(const Glib::ustring& key) const, g_settings_get_double) - _WRAP_METHOD(void set_double(const Glib::ustring& key, double value), g_settings_set_double) + _WRAP_METHOD(bool set_double(const Glib::ustring& key, double value), g_settings_set_double) #m4 _CONVERSION(`gchar**',`std::vector',`Glib::ArrayHandler::array_to_vector($3, Glib::OWNERSHIP_DEEP)') _WRAP_METHOD(std::vector get_string_array(const Glib::ustring& key) const, g_settings_get_strv) @@ -207,7 +206,7 @@ public: _WRAP_SIGNAL(void changed(const Glib::ustring& key), "changed", detail_name key) _WRAP_SIGNAL(bool writable_change_event(GQuark key), "writable-change-event") - _WRAP_SIGNAL(void writable_changed(const Glib::ustring& key), writable_changed) + _WRAP_SIGNAL(void writable_changed(const Glib::ustring& key), writable_changed, detail_name key) }; } // namespace Gio diff --git a/gio/src/settingsschema.ccg b/gio/src/settingsschema.ccg index 27d1a1e..1c73326 100644 --- a/gio/src/settingsschema.ccg +++ b/gio/src/settingsschema.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/settingsschema.hg b/gio/src/settingsschema.hg index c5f6c95..cae4b99 100644 --- a/gio/src/settingsschema.hg +++ b/gio/src/settingsschema.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/settingsschemakey.ccg b/gio/src/settingsschemakey.ccg index 27d1a1e..1c73326 100644 --- a/gio/src/settingsschemakey.ccg +++ b/gio/src/settingsschemakey.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/settingsschemakey.hg b/gio/src/settingsschemakey.hg index cf5f0da..4734ca0 100644 --- a/gio/src/settingsschemakey.hg +++ b/gio/src/settingsschemakey.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/settingsschemasource.ccg b/gio/src/settingsschemasource.ccg index 27d1a1e..1c73326 100644 --- a/gio/src/settingsschemasource.ccg +++ b/gio/src/settingsschemasource.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/settingsschemasource.hg b/gio/src/settingsschemasource.hg index f330945..5975c38 100644 --- a/gio/src/settingsschemasource.hg +++ b/gio/src/settingsschemasource.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/simpleaction.ccg b/gio/src/simpleaction.ccg index 42b236e..d4fb0e1 100644 --- a/gio/src/simpleaction.ccg +++ b/gio/src/simpleaction.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/simpleaction.hg b/gio/src/simpleaction.hg index fe7e669..5874112 100644 --- a/gio/src/simpleaction.hg +++ b/gio/src/simpleaction.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/simpleactiongroup.ccg b/gio/src/simpleactiongroup.ccg index 3a80251..e33de0b 100644 --- a/gio/src/simpleactiongroup.ccg +++ b/gio/src/simpleactiongroup.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/simpleactiongroup.hg b/gio/src/simpleactiongroup.hg index 36dd91b..d12e4a1 100644 --- a/gio/src/simpleactiongroup.hg +++ b/gio/src/simpleactiongroup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/simplepermission.ccg b/gio/src/simplepermission.ccg index e627cda..cb85474 100644 --- a/gio/src/simplepermission.ccg +++ b/gio/src/simplepermission.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/simplepermission.hg b/gio/src/simplepermission.hg index c6a2ea3..cce3b6b 100644 --- a/gio/src/simplepermission.hg +++ b/gio/src/simplepermission.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socket.ccg b/gio/src/socket.ccg index 4e4910c..31cf240 100644 --- a/gio/src/socket.ccg +++ b/gio/src/socket.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socket.hg b/gio/src/socket.hg index 55a3ce9..233e20a 100644 --- a/gio/src/socket.hg +++ b/gio/src/socket.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketaddress.ccg b/gio/src/socketaddress.ccg index eb8adb6..f5d23a7 100644 --- a/gio/src/socketaddress.ccg +++ b/gio/src/socketaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketaddress.hg b/gio/src/socketaddress.hg index ed7cf8f..713986b 100644 --- a/gio/src/socketaddress.hg +++ b/gio/src/socketaddress.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketaddressenumerator.ccg b/gio/src/socketaddressenumerator.ccg index 405773f..9e01483 100644 --- a/gio/src/socketaddressenumerator.ccg +++ b/gio/src/socketaddressenumerator.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2009 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketaddressenumerator.hg b/gio/src/socketaddressenumerator.hg index 01a137a..28cf187 100644 --- a/gio/src/socketaddressenumerator.hg +++ b/gio/src/socketaddressenumerator.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketclient.ccg b/gio/src/socketclient.ccg index c3ec6f0..8339f12 100644 --- a/gio/src/socketclient.ccg +++ b/gio/src/socketclient.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketclient.hg b/gio/src/socketclient.hg index 26f0bd6..1722b65 100644 --- a/gio/src/socketclient.hg +++ b/gio/src/socketclient.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketconnectable.ccg b/gio/src/socketconnectable.ccg index 0f94c18..a4150d7 100644 --- a/gio/src/socketconnectable.ccg +++ b/gio/src/socketconnectable.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2009 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketconnectable.hg b/gio/src/socketconnectable.hg index 812df3d..266a8a6 100644 --- a/gio/src/socketconnectable.hg +++ b/gio/src/socketconnectable.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketconnection.ccg b/gio/src/socketconnection.ccg index 4c71d8f..13c2569 100644 --- a/gio/src/socketconnection.ccg +++ b/gio/src/socketconnection.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketconnection.hg b/gio/src/socketconnection.hg index 5ac0b2d..1c9a738 100644 --- a/gio/src/socketconnection.hg +++ b/gio/src/socketconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketcontrolmessage.ccg b/gio/src/socketcontrolmessage.ccg index e7119a3..b921f77 100644 --- a/gio/src/socketcontrolmessage.ccg +++ b/gio/src/socketcontrolmessage.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketcontrolmessage.hg b/gio/src/socketcontrolmessage.hg index 834393b..96e5f36 100644 --- a/gio/src/socketcontrolmessage.hg +++ b/gio/src/socketcontrolmessage.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketlistener.ccg b/gio/src/socketlistener.ccg index 4185651..c85394e 100644 --- a/gio/src/socketlistener.ccg +++ b/gio/src/socketlistener.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketlistener.hg b/gio/src/socketlistener.hg index d463e44..0db6398 100644 --- a/gio/src/socketlistener.hg +++ b/gio/src/socketlistener.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketservice.ccg b/gio/src/socketservice.ccg index 58f3251..990512f 100644 --- a/gio/src/socketservice.ccg +++ b/gio/src/socketservice.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/socketservice.hg b/gio/src/socketservice.hg index cc025ca..a21eb18 100644 --- a/gio/src/socketservice.hg +++ b/gio/src/socketservice.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/srvtarget.ccg b/gio/src/srvtarget.ccg index 931000c..6dfac73 100644 --- a/gio/src/srvtarget.ccg +++ b/gio/src/srvtarget.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2008 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/srvtarget.hg b/gio/src/srvtarget.hg index 0625461..727182d 100644 --- a/gio/src/srvtarget.hg +++ b/gio/src/srvtarget.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tcpconnection.ccg b/gio/src/tcpconnection.ccg index 6e07769..5a8b3d2 100644 --- a/gio/src/tcpconnection.ccg +++ b/gio/src/tcpconnection.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tcpconnection.hg b/gio/src/tcpconnection.hg index edaa3f7..6352c17 100644 --- a/gio/src/tcpconnection.hg +++ b/gio/src/tcpconnection.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tcpwrapperconnection.ccg b/gio/src/tcpwrapperconnection.ccg index 58b9f17..8571d6d 100644 --- a/gio/src/tcpwrapperconnection.ccg +++ b/gio/src/tcpwrapperconnection.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tcpwrapperconnection.hg b/gio/src/tcpwrapperconnection.hg index a469007..420d17a 100644 --- a/gio/src/tcpwrapperconnection.hg +++ b/gio/src/tcpwrapperconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/themedicon.ccg b/gio/src/themedicon.ccg index e9a7f30..48b7686 100644 --- a/gio/src/themedicon.ccg +++ b/gio/src/themedicon.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/themedicon.hg b/gio/src/themedicon.hg index f077f48..4d3616a 100644 --- a/gio/src/themedicon.hg +++ b/gio/src/themedicon.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/threadedsocketservice.ccg b/gio/src/threadedsocketservice.ccg index 58f3251..990512f 100644 --- a/gio/src/threadedsocketservice.ccg +++ b/gio/src/threadedsocketservice.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/threadedsocketservice.hg b/gio/src/threadedsocketservice.hg index d14a545..ef23974 100644 --- a/gio/src/threadedsocketservice.hg +++ b/gio/src/threadedsocketservice.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlscertificate.ccg b/gio/src/tlscertificate.ccg index 2df281e..3cb4910 100644 --- a/gio/src/tlscertificate.ccg +++ b/gio/src/tlscertificate.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlscertificate.hg b/gio/src/tlscertificate.hg index 80484fb..09c992e 100644 --- a/gio/src/tlscertificate.hg +++ b/gio/src/tlscertificate.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsclientconnection.ccg b/gio/src/tlsclientconnection.ccg index e18f6c7..c2785a4 100644 --- a/gio/src/tlsclientconnection.ccg +++ b/gio/src/tlsclientconnection.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsclientconnection.hg b/gio/src/tlsclientconnection.hg index 599a3de..6eb87d9 100644 --- a/gio/src/tlsclientconnection.hg +++ b/gio/src/tlsclientconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -32,6 +31,10 @@ namespace Gio class SocketConnectable; +// It's unusual that a subclass of Glib::Object is a base class of an interface. +// For a discussion, see https://bugzilla.gnome.org/show_bug.cgi?id=776537 +// especially the last paragraph of comment 6. + /** TlsClientConnection - TLS client-side connection. * TlsClientConnection is the client-side subclass of TlsConnection, * representing a client-side TLS connection. @@ -45,8 +48,8 @@ class TlsClientConnection _CUSTOM_CTOR_CAST public: - //TODO: It's not possible to use _WRAP_CTOR/_WRAP_CREATE to wrap the new - //function because this is an interface. + // It's not possible to use _WRAP_CTOR/_WRAP_CREATE to wrap the new + // function because this is an interface. #m4 _CONVERSION(`GIOStream*',`Glib::RefPtr',`Glib::wrap(G_TLS_CLIENT_CONNECTION($3))') _WRAP_METHOD(static Glib::RefPtr create(const Glib::RefPtr& base_io_stream, const Glib::RefPtr& server_identity{?}), g_tls_client_connection_new, errthrow) @@ -58,8 +61,7 @@ public: _WRAP_METHOD(void set_validation_flags(TlsCertificateFlags flags), g_tls_client_connection_set_validation_flags) _WRAP_METHOD(TlsCertificateFlags get_validation_flags() const, g_tls_client_connection_get_validation_flags) - _WRAP_METHOD(void set_use_ssl3(bool use_ssl3 = true), g_tls_client_connection_set_use_ssl3) - _WRAP_METHOD(bool get_use_ssl3() const, g_tls_client_connection_get_use_ssl3) + _IGNORE(g_tls_client_connection_set_use_ssl3, g_tls_client_connection_get_use_ssl3) dnl// deprecated #m4 _CONVERSION(`GList*',`std::vector< Glib::RefPtr >',`Glib::ListHandler< Glib::RefPtr >::list_to_vector($3, Glib::OWNERSHIP_DEEP)') _WRAP_METHOD(std::vector< Glib::RefPtr > get_accepted_cas(), g_tls_client_connection_get_accepted_cas) @@ -72,8 +74,8 @@ public: _WRAP_PROPERTY("accepted-cas", std::vector< Glib::RefPtr >) _WRAP_PROPERTY("server-identity", Glib::RefPtr) - _WRAP_PROPERTY("use-ssl3", bool) _WRAP_PROPERTY("validation-flags", TlsCertificateFlags) + _IGNORE_PROPERTY(use-ssl3) dnl// deprecated }; } // namespace Gio diff --git a/gio/src/tlsconnection.ccg b/gio/src/tlsconnection.ccg index 61f13d9..4ec8d7e 100644 --- a/gio/src/tlsconnection.ccg +++ b/gio/src/tlsconnection.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsconnection.hg b/gio/src/tlsconnection.hg index 319c052..8206c1f 100644 --- a/gio/src/tlsconnection.hg +++ b/gio/src/tlsconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/tlsdatabase.ccg b/gio/src/tlsdatabase.ccg index 2bf254f..4b36057 100644 --- a/gio/src/tlsdatabase.ccg +++ b/gio/src/tlsdatabase.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsdatabase.hg b/gio/src/tlsdatabase.hg index 610402b..c53ef51 100644 --- a/gio/src/tlsdatabase.hg +++ b/gio/src/tlsdatabase.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsfiledatabase.ccg b/gio/src/tlsfiledatabase.ccg index d76f332..eb7ed06 100644 --- a/gio/src/tlsfiledatabase.ccg +++ b/gio/src/tlsfiledatabase.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsfiledatabase.hg b/gio/src/tlsfiledatabase.hg index 08650c5..0113229 100644 --- a/gio/src/tlsfiledatabase.hg +++ b/gio/src/tlsfiledatabase.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -29,6 +28,9 @@ typedef struct _GTlsFileDatabaseInterface GTlsFileDatabaseInterface; namespace Gio { +// It's unusual that a subclass of Glib::Object is a base class of an interface. +// For a discussion, see https://bugzilla.gnome.org/show_bug.cgi?id=776537 +// especially the last paragraph of comment 6. /** TlsFileDatabase - TLS file based database type. * TlsFileDatabase is implemented by TlsDatabase objects which load their @@ -44,9 +46,8 @@ class TlsFileDatabase _CLASS_INTERFACE(TlsFileDatabase, GTlsFileDatabase, G_TLS_FILE_DATABASE, GTlsFileDatabaseInterface) public: - //TODO: It is not possible to use _WRAP_CTOR()/WRAP_CREATE() here because this - //class is an interface. - // So, should we make it possible to use them? murrayc. + // It's not possible to use _WRAP_CTOR/_WRAP_CREATE to wrap the new + // function because this is an interface. #m4 _CONVERSION(`GTlsDatabase*',`Glib::RefPtr',`Glib::wrap(G_TLS_FILE_DATABASE($3))') _WRAP_METHOD(static Glib::RefPtr create(const std::string& anchors), g_tls_file_database_new, errthrow) diff --git a/gio/src/tlsinteraction.ccg b/gio/src/tlsinteraction.ccg index a55675f..2252149 100644 --- a/gio/src/tlsinteraction.ccg +++ b/gio/src/tlsinteraction.ccg @@ -1,3 +1,4 @@ + /* Copyright (C) 2012 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -11,8 +12,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsinteraction.hg b/gio/src/tlsinteraction.hg index 1f48904..09bb2cb 100644 --- a/gio/src/tlsinteraction.hg +++ b/gio/src/tlsinteraction.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlspassword.ccg b/gio/src/tlspassword.ccg index 5a4c31c..c51f24b 100644 --- a/gio/src/tlspassword.ccg +++ b/gio/src/tlspassword.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlspassword.hg b/gio/src/tlspassword.hg index 7e2ec17..917061c 100644 --- a/gio/src/tlspassword.hg +++ b/gio/src/tlspassword.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsserverconnection.ccg b/gio/src/tlsserverconnection.ccg index 4f97609..01cfc85 100644 --- a/gio/src/tlsserverconnection.ccg +++ b/gio/src/tlsserverconnection.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/tlsserverconnection.hg b/gio/src/tlsserverconnection.hg index dbf1a41..67bd0a9 100644 --- a/gio/src/tlsserverconnection.hg +++ b/gio/src/tlsserverconnection.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -29,6 +28,9 @@ typedef struct _GTlsServerConnectionInterface GTlsServerConnectionInterface; namespace Gio { +// It's unusual that a subclass of Glib::Object is a base class of an interface. +// For a discussion, see https://bugzilla.gnome.org/show_bug.cgi?id=776537 +// especially the last paragraph of comment 6. /** TlsServerConnection - TLS server-side connection. * TlsServerConnection is the server-side subclass of TlsConnection, @@ -41,8 +43,8 @@ class TlsServerConnection : public Glib::Interface, public TlsConnection _CUSTOM_CTOR_CAST public: - //TODO: It's not possible to use _WRAP_CTOR/_WRAP_CREATE to wrap the new - //function because this is an interface. + // It's not possible to use _WRAP_CTOR/_WRAP_CREATE to wrap the new + // function because this is an interface. #m4 _CONVERSION(`GIOStream*',`Glib::RefPtr',`Glib::wrap(G_TLS_SERVER_CONNECTION($3))') _WRAP_METHOD(static Glib::RefPtr create(const Glib::RefPtr& base_io_stream, const Glib::RefPtr& certificate), g_tls_server_connection_new, errthrow) diff --git a/gio/src/unixconnection.ccg b/gio/src/unixconnection.ccg index 20a3cde..3b9929c 100644 --- a/gio/src/unixconnection.ccg +++ b/gio/src/unixconnection.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixconnection.hg b/gio/src/unixconnection.hg index 8134ad6..1ddd1d2 100644 --- a/gio/src/unixconnection.hg +++ b/gio/src/unixconnection.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 Jonathon Jongsma * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixcredentialsmessage.ccg b/gio/src/unixcredentialsmessage.ccg index 47a59dd..f3fc155 100644 --- a/gio/src/unixcredentialsmessage.ccg +++ b/gio/src/unixcredentialsmessage.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixcredentialsmessage.hg b/gio/src/unixcredentialsmessage.hg index 1ad9523..9ba8239 100644 --- a/gio/src/unixcredentialsmessage.hg +++ b/gio/src/unixcredentialsmessage.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixfdlist.ccg b/gio/src/unixfdlist.ccg index d24555c..5a66bd2 100644 --- a/gio/src/unixfdlist.ccg +++ b/gio/src/unixfdlist.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixfdlist.hg b/gio/src/unixfdlist.hg index b85804f..f3885a1 100644 --- a/gio/src/unixfdlist.hg +++ b/gio/src/unixfdlist.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -66,7 +65,7 @@ public: _WRAP_CREATE(const std::vector& fds, int n_fds) _WRAP_METHOD(int get_length() const, g_unix_fd_list_get_length) - _WRAP_METHOD(int get(int index) const, g_unix_fd_list_get, errthrow) + _WRAP_METHOD(int get(int index) const, g_unix_fd_list_get, errthrow "Gio::Error") /** Returns the array of file descriptors that is contained in this object. * @@ -97,7 +96,7 @@ public: _WRAP_METHOD_DOCS_ONLY(g_unix_fd_list_append) ///@throw Glib::Error. - _WRAP_METHOD(int append(int fd), g_unix_fd_list_append, errthrow) + _WRAP_METHOD(int append(int fd), g_unix_fd_list_append, errthrow "Gio::Error") }; } // namespace Gio diff --git a/gio/src/unixfdmessage.ccg b/gio/src/unixfdmessage.ccg index a88cf4f..53ea803 100644 --- a/gio/src/unixfdmessage.ccg +++ b/gio/src/unixfdmessage.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixfdmessage.hg b/gio/src/unixfdmessage.hg index f25dacc..3398a0c 100644 --- a/gio/src/unixfdmessage.hg +++ b/gio/src/unixfdmessage.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -57,7 +56,7 @@ public: _WRAP_METHOD(Glib::RefPtr get_fd_list(), g_unix_fd_message_get_fd_list, refreturn) _WRAP_METHOD(Glib::RefPtr get_fd_list() const, g_unix_fd_message_get_fd_list, refreturn, constversion) - _WRAP_METHOD(bool append_fd(int fd), g_unix_fd_message_append_fd, errthrow) + _WRAP_METHOD(bool append_fd(int fd), g_unix_fd_message_append_fd, errthrow "Gio::Error") /** Returns the array of file descriptors that is contained in this object. * diff --git a/gio/src/unixinputstream.ccg b/gio/src/unixinputstream.ccg index 61fd7b0..30fcbd2 100644 --- a/gio/src/unixinputstream.ccg +++ b/gio/src/unixinputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixinputstream.hg b/gio/src/unixinputstream.hg index f7c71fb..b3521cd 100644 --- a/gio/src/unixinputstream.hg +++ b/gio/src/unixinputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixmount.ccg b/gio/src/unixmount.ccg index 98fab0c..12a276f 100644 --- a/gio/src/unixmount.ccg +++ b/gio/src/unixmount.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixmount.hg b/gio/src/unixmount.hg index 97c27d5..7c8f2f6 100644 --- a/gio/src/unixmount.hg +++ b/gio/src/unixmount.hg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixoutputstream.ccg b/gio/src/unixoutputstream.ccg index 1ecd417..5e6d1de 100644 --- a/gio/src/unixoutputstream.ccg +++ b/gio/src/unixoutputstream.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixoutputstream.hg b/gio/src/unixoutputstream.hg index fc3f1e3..5f00910 100644 --- a/gio/src/unixoutputstream.hg +++ b/gio/src/unixoutputstream.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixsocketaddress.ccg b/gio/src/unixsocketaddress.ccg index 8b5b480..b3751af 100644 --- a/gio/src/unixsocketaddress.ccg +++ b/gio/src/unixsocketaddress.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2010 The giomm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/unixsocketaddress.hg b/gio/src/unixsocketaddress.hg index 263e86b..8be2922 100644 --- a/gio/src/unixsocketaddress.hg +++ b/gio/src/unixsocketaddress.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/volume.ccg b/gio/src/volume.ccg index 9ba1898..e0ad7c4 100644 --- a/gio/src/volume.ccg +++ b/gio/src/volume.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/volume.hg b/gio/src/volume.hg index f6339c9..37b51e2 100644 --- a/gio/src/volume.hg +++ b/gio/src/volume.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/volumemonitor.ccg b/gio/src/volumemonitor.ccg index 48ac82a..59e4bd5 100644 --- a/gio/src/volumemonitor.ccg +++ b/gio/src/volumemonitor.ccg @@ -1,5 +1,3 @@ -// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*- - /* Copyright (C) 2007 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/volumemonitor.hg b/gio/src/volumemonitor.hg index 6eb5c65..d36e0d3 100644 --- a/gio/src/volumemonitor.hg +++ b/gio/src/volumemonitor.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _CONFIGINCLUDE(giommconfig.h) diff --git a/gio/src/zlibcompressor.ccg b/gio/src/zlibcompressor.ccg index 4366e58..37de341 100644 --- a/gio/src/zlibcompressor.ccg +++ b/gio/src/zlibcompressor.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/zlibcompressor.hg b/gio/src/zlibcompressor.hg index 223b617..58e7cc8 100644 --- a/gio/src/zlibcompressor.hg +++ b/gio/src/zlibcompressor.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/zlibdecompressor.ccg b/gio/src/zlibdecompressor.ccg index 4366e58..37de341 100644 --- a/gio/src/zlibdecompressor.ccg +++ b/gio/src/zlibdecompressor.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/gio/src/zlibdecompressor.hg b/gio/src/zlibdecompressor.hg index 7ae8166..aab9763 100644 --- a/gio/src/zlibdecompressor.hg +++ b/gio/src/zlibdecompressor.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm.h b/glib/glibmm.h index 101b80e..44f2ea5 100644 --- a/glib/glibmm.h +++ b/glib/glibmm.h @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #ifndef _GLIBMM_H diff --git a/glib/glibmm/base64.cc b/glib/glibmm/base64.cc index c9c279c..9f098db 100644 --- a/glib/glibmm/base64.cc +++ b/glib/glibmm/base64.cc @@ -12,8 +12,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/base64.h b/glib/glibmm/base64.h index eda3da0..5fae475 100644 --- a/glib/glibmm/base64.h +++ b/glib/glibmm/base64.h @@ -15,8 +15,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/class.cc b/glib/glibmm/class.cc index 29ab8cf..36c3c4b 100644 --- a/glib/glibmm/class.cc +++ b/glib/glibmm/class.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/class.h b/glib/glibmm/class.h index e790715..127b9c9 100644 --- a/glib/glibmm/class.h +++ b/glib/glibmm/class.h @@ -15,8 +15,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/containerhandle_shared.h b/glib/glibmm/containerhandle_shared.h index c798550..e8bfd7b 100644 --- a/glib/glibmm/containerhandle_shared.h +++ b/glib/glibmm/containerhandle_shared.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -85,7 +84,8 @@ struct TypeTraits // be next to the objects that they use. #ifdef GLIBMM_CAN_USE_DYNAMIC_CAST_IN_UNUSED_TEMPLATE_WITHOUT_DEFINITION -/** Partial specialization for pointers to GtkObject instances. +/** Partial specialization for pointers to GObject instances. + * The C++ type is not a Glib::RefPtr<>. It can be a gtkmm widget. * @ingroup ContHelpers */ template @@ -117,7 +117,8 @@ struct TypeTraits // This confuse the SUN Forte compiler, so we ifdef it out: #ifdef GLIBMM_HAVE_DISAMBIGUOUS_CONST_TEMPLATE_SPECIALIZATIONS -/** Partial specialization for pointers to const GtkObject instances. +/** Partial specialization for pointers to const GObject instances. + * The C++ type is not a Glib::RefPtr<>. It can be a gtkmm widget. * @ingroup ContHelpers */ template diff --git a/glib/glibmm/debug.cc b/glib/glibmm/debug.cc index 4fc3699..fd0b757 100644 --- a/glib/glibmm/debug.cc +++ b/glib/glibmm/debug.cc @@ -1,5 +1,3 @@ -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/debug.h b/glib/glibmm/debug.h index 831f246..2c32e54 100644 --- a/glib/glibmm/debug.h +++ b/glib/glibmm/debug.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GLIBMM_DEBUG_H #define _GLIBMM_DEBUG_H @@ -15,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/dispatcher.cc b/glib/glibmm/dispatcher.cc index cd6c43d..d5a96de 100644 --- a/glib/glibmm/dispatcher.cc +++ b/glib/glibmm/dispatcher.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -222,10 +221,10 @@ DispatchNotifier::DispatchNotifier(const Glib::RefPtr& context) // The following code is equivalent to // context_->signal_io().connect( - // sigc::mem_fun(*this, &DispatchNotifier::pipe_io_handler), fd, Glib::IOCondition::IN); + // sigc::mem_fun(*this, &DispatchNotifier::pipe_io_handler), fd, Glib::IOCondition::IO_IN); // except for source->set_can_recurse(true). - const auto source = IOSource::create(fd, Glib::IOCondition::IN); + const auto source = IOSource::create(fd, Glib::IOCondition::IO_IN); // If the signal emission in pipe_io_handler() starts a new main loop, // the event source shall not be blocked while that loop runs. (E.g. while @@ -404,10 +403,10 @@ DispatchNotifier::pipe_is_empty() #ifdef G_OS_WIN32 return notify_queue_.empty(); #else - PollFD poll_fd(fd_receiver_, Glib::IOCondition::IN); + PollFD poll_fd(fd_receiver_, Glib::IOCondition::IO_IN); // GPollFD*, number of file descriptors to poll, timeout (ms) g_poll(poll_fd.gobj(), 1, 0); - return static_cast(poll_fd.get_revents() & Glib::IOCondition::IN) == 0; + return static_cast(poll_fd.get_revents() & Glib::IOCondition::IO_IN) == 0; #endif } diff --git a/glib/glibmm/dispatcher.h b/glib/glibmm/dispatcher.h index f66a523..00c6384 100644 --- a/glib/glibmm/dispatcher.h +++ b/glib/glibmm/dispatcher.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/error.cc b/glib/glibmm/error.cc index 0906336..e3afe5b 100644 --- a/glib/glibmm/error.cc +++ b/glib/glibmm/error.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/error.h b/glib/glibmm/error.h index eb61b4e..c015e75 100644 --- a/glib/glibmm/error.h +++ b/glib/glibmm/error.h @@ -15,8 +15,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/exception.cc b/glib/glibmm/exception.cc index b1e9322..2c25ea9 100644 --- a/glib/glibmm/exception.cc +++ b/glib/glibmm/exception.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* exception.cc * * Copyright 2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include //For g_assert() in glib >= 2.15.0 diff --git a/glib/glibmm/exception.h b/glib/glibmm/exception.h index bc9feae..726f39e 100644 --- a/glib/glibmm/exception.h +++ b/glib/glibmm/exception.h @@ -1,7 +1,5 @@ -// -*- c++ -*- #ifndef _GLIBMM_EXCEPTION_H #define _GLIBMM_EXCEPTION_H -/* $Id$ */ /* exception.h * @@ -18,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/exceptionhandler.cc b/glib/glibmm/exceptionhandler.cc index e80e009..3c15f8c 100644 --- a/glib/glibmm/exceptionhandler.cc +++ b/glib/glibmm/exceptionhandler.cc @@ -1,5 +1,3 @@ -// -*- c++ -*- - /* exceptionhandler.cc * * Copyright 2002 The gtkmm Development Team @@ -15,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/exceptionhandler.h b/glib/glibmm/exceptionhandler.h index acfd6f5..a34fdbf 100644 --- a/glib/glibmm/exceptionhandler.h +++ b/glib/glibmm/exceptionhandler.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GLIBMM_EXCEPTIONHANDLER_H #define _GLIBMM_EXCEPTIONHANDLER_H @@ -17,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/i18n-lib.h b/glib/glibmm/i18n-lib.h index 1a7cd1b..62a19f6 100644 --- a/glib/glibmm/i18n-lib.h +++ b/glib/glibmm/i18n-lib.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_I18N_LIB_H #define _GLIBMM_I18N_LIB_H -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -17,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ // Include this file to define internationalization macros such as _(). diff --git a/glib/glibmm/i18n.h b/glib/glibmm/i18n.h index d35d9a7..17639ac 100644 --- a/glib/glibmm/i18n.h +++ b/glib/glibmm/i18n.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_I18N_H #define _GLIBMM_I18N_H -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -17,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ // Include this file to define internationalization macros such as _(). diff --git a/glib/glibmm/init.cc b/glib/glibmm/init.cc index f42cdf5..0b34447 100644 --- a/glib/glibmm/init.cc +++ b/glib/glibmm/init.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/init.h b/glib/glibmm/init.h index a736093..ac89d22 100644 --- a/glib/glibmm/init.h +++ b/glib/glibmm/init.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Glib diff --git a/glib/glibmm/interface.cc b/glib/glibmm/interface.cc index 34f590e..f01f13d 100644 --- a/glib/glibmm/interface.cc +++ b/glib/glibmm/interface.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/interface.h b/glib/glibmm/interface.h index 0b27914..9e35b5e 100644 --- a/glib/glibmm/interface.h +++ b/glib/glibmm/interface.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_INTERFACE_H #define _GLIBMM_INTERFACE_H -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -17,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/main.cc b/glib/glibmm/main.cc index 1f51e51..7edb8f4 100644 --- a/glib/glibmm/main.cc +++ b/glib/glibmm/main.cc @@ -11,12 +11,9 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ -#include // May define GLIBMM_DISABLE_DEPRECATED - #include #include #include @@ -25,14 +22,11 @@ namespace { -void -time64_to_time_val(gint64 time64, Glib::TimeVal& time_val) +// Convert an interval from milliseconds to microseconds, +// suitable for adding to Source::get_time(). +inline gint64 ms2us(unsigned int ms) { - // This function is not guaranteed to convert correctly if time64 is negative. - const long seconds = static_cast(time64 / G_GINT64_CONSTANT(1000000)); - const long microseconds = - static_cast(time64 - static_cast(seconds) * G_GINT64_CONSTANT(1000000)); - time_val = Glib::TimeVal(seconds, microseconds); + return static_cast(ms) * 1000; } class SourceConnectionNode : public sigc::notifiable @@ -966,7 +960,10 @@ Source::remove_poll(Glib::PollFD& poll_fd) gint64 Source::get_time() const { - return g_source_get_time(const_cast(gobject_)); + if (g_source_get_context(const_cast(gobject_))) + return g_source_get_time(const_cast(gobject_)); + else + return g_get_monotonic_time(); } inline // static @@ -1105,8 +1102,7 @@ TimeoutSource::connect(const sigc::slot& slot) TimeoutSource::TimeoutSource(unsigned int interval) : interval_(interval) { - expiration_.assign_current_time(); - expiration_.add_milliseconds(std::min(G_MAXLONG, interval_)); + expiration_ = get_time() + ms2us(interval_); } TimeoutSource::~TimeoutSource() noexcept @@ -1116,33 +1112,24 @@ TimeoutSource::~TimeoutSource() noexcept bool TimeoutSource::prepare(int& timeout) { - Glib::TimeVal current_time; - time64_to_time_val(get_time(), current_time); - - Glib::TimeVal remaining = expiration_; - remaining.subtract(current_time); + gint64 remaining = expiration_ - get_time(); - if (remaining.negative()) + if (remaining <= 0) { // Already expired. timeout = 0; } else { - const unsigned long milliseconds = static_cast(remaining.tv_sec) * 1000U + - static_cast(remaining.tv_usec) / 1000U; - // Set remaining milliseconds. - timeout = std::min(G_MAXINT, milliseconds); + timeout = std::min(G_MAXINT, remaining / 1000); // Check if the system time has been set backwards. (remaining > interval) - remaining.add_milliseconds(-std::min(G_MAXLONG, interval_) - 1); - if (!remaining.negative()) + if (remaining > ms2us(interval_)) { // Oh well. Reset the expiration time to now + interval; // this at least avoids hanging for long periods of time. - expiration_ = current_time; - expiration_.add_milliseconds(interval_); + expiration_ = get_time() + ms2us(interval_); timeout = std::min(G_MAXINT, interval_); } } @@ -1153,10 +1140,7 @@ TimeoutSource::prepare(int& timeout) bool TimeoutSource::check() { - Glib::TimeVal current_time; - time64_to_time_val(get_time(), current_time); - - return (expiration_ <= current_time); + return expiration_ <= get_time(); } bool @@ -1165,10 +1149,7 @@ TimeoutSource::dispatch(sigc::slot_base* slot) const bool again = (*static_cast*>(slot))(); if (again) - { - time64_to_time_val(get_time(), expiration_); - expiration_.add_milliseconds(std::min(G_MAXLONG, interval_)); - } + expiration_ = get_time() + ms2us(interval_); return again; } diff --git a/glib/glibmm/main.h b/glib/glibmm/main.h index 3306500..c2f799c 100644 --- a/glib/glibmm/main.h +++ b/glib/glibmm/main.h @@ -14,13 +14,10 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ -#include #include -#include #include #include #include @@ -740,17 +737,6 @@ protected: */ void remove_poll(PollFD& poll_fd); -#ifndef GLIBMM_DISABLE_DEPRECATED - /** Gets the "current time" to be used when checking this source. The advantage of calling this - * function over calling get_current_time() directly is that when checking multiple sources, GLib - * can cache a single value instead of having to repeatedly get the system time. - * @param current_time Glib::TimeVal in which to store current time. - * - * @deprecated Use get_time() instead. - */ - void get_current_time(Glib::TimeVal& current_time); -#endif // GLIBMM_DISABLE_DEPRECATED - // TODO: Remove mention of g_get_monotonic time when we wrap it in C++. /** Gets the time to be used when checking this source. The advantage of * calling this function over calling g_get_monotonic_time() directly is @@ -819,10 +805,8 @@ protected: bool dispatch(sigc::slot_base* slot) override; private: - // TODO: Replace with gint64, because TimeVal is deprecated, when we can break ABI. - Glib::TimeVal expiration_; - - unsigned int interval_; + gint64 expiration_; // microseconds + unsigned int interval_; // milliseconds }; class IdleSource : public Glib::Source diff --git a/glib/glibmm/object.cc b/glib/glibmm/object.cc index ce14269..4dc73b3 100644 --- a/glib/glibmm/object.cc +++ b/glib/glibmm/object.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/object.h b/glib/glibmm/object.h index 006d5ea..cda1552 100644 --- a/glib/glibmm/object.h +++ b/glib/glibmm/object.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ // X11 defines DestroyNotify and some other non-prefixed stuff, and it's too late to change that diff --git a/glib/glibmm/objectbase.cc b/glib/glibmm/objectbase.cc index 7e36414..9be57e7 100644 --- a/glib/glibmm/objectbase.cc +++ b/glib/glibmm/objectbase.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -280,9 +279,9 @@ ObjectBase::destroy_notify_callback_(void* data) (void*)cppObject, (void*)cppObject->gobject_, G_OBJECT_TYPE_NAME(cppObject->gobject_)); #endif - if (cppObject) // This will be 0 if the C++ destructor has already run. + if (cppObject) // This will be nullptr if the C++ destructor has already run. { - cppObject->destroy_notify_(); // Virtual - it does different things for GObject and GtkObject. + cppObject->destroy_notify_(); // Virtual - it does different things for Glib::ObjectBase and Gtk::Object. } } @@ -291,13 +290,13 @@ ObjectBase::destroy_notify_() { // The C instance is about to be disposed, making it unusable. Now is a // good time to delete the C++ wrapper of the C instance. There is no way -// to force the disposal of the GObject (though GtkObject has -// gtk_object_destroy()), So this is the *only* place where we delete the -// C++ wrapper. +// to force the disposal of the GObject (though Gtk::Object::destroy_notify_() +// can call g_object_run_dispose()), so this is the *only* place where we delete +// the C++ wrapper. // // This will only happen after the last unreference(), which will be done by // the RefPtr<> destructor. There should be no way to access the wrapper or -// the undobjecterlying instance after that, so it's OK to delete this. +// the underlying object instance after that, so it's OK to delete this. #ifdef GLIBMM_DEBUG_REFCOUNTING g_warning("Glib::ObjectBase::destroy_notify_: gobject_ = %p", (void*)gobject_); diff --git a/glib/glibmm/objectbase.h b/glib/glibmm/objectbase.h index 3faed9d..6beaa59 100644 --- a/glib/glibmm/objectbase.h +++ b/glib/glibmm/objectbase.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/pattern.cc b/glib/glibmm/pattern.cc index 8fb94fc..4493606 100644 --- a/glib/glibmm/pattern.cc +++ b/glib/glibmm/pattern.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* pattern.cc * * Copyright (C) 2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/pattern.h b/glib/glibmm/pattern.h index fddec5c..0446907 100644 --- a/glib/glibmm/pattern.h +++ b/glib/glibmm/pattern.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_PATTERN_H #define _GLIBMM_PATTERN_H -/* $Id$ */ - /* pattern.h * * Copyright (C) 2002 The gtkmm Development Team @@ -19,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ extern "C" { diff --git a/glib/glibmm/priorities.h b/glib/glibmm/priorities.h index a856751..9634c0a 100644 --- a/glib/glibmm/priorities.h +++ b/glib/glibmm/priorities.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_PRIORITIES_H #define _GLIBMM_PRIORITIES_H -/* $Id: priorities.h 420 2007-06-22 15:29:58Z murrayc $ */ - /* Copyright (C) 2002-2008 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -17,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Glib diff --git a/glib/glibmm/property.cc b/glib/glibmm/property.cc index 45d90b3..30de748 100644 --- a/glib/glibmm/property.cc +++ b/glib/glibmm/property.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/property.h b/glib/glibmm/property.h index ca8cde9..0b7835b 100644 --- a/glib/glibmm/property.h +++ b/glib/glibmm/property.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/propertyproxy.cc b/glib/glibmm/propertyproxy.cc index bd02587..db0574e 100644 --- a/glib/glibmm/propertyproxy.cc +++ b/glib/glibmm/propertyproxy.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* propertyproxy.cc * * Copyright 2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/propertyproxy.h b/glib/glibmm/propertyproxy.h index bc27409..67eaab3 100644 --- a/glib/glibmm/propertyproxy.h +++ b/glib/glibmm/propertyproxy.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GLIBMM_PROPERTYPROXY_H #define _GLIBMM_PROPERTYPROXY_H @@ -17,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/propertyproxy_base.cc b/glib/glibmm/propertyproxy_base.cc index 66ebf70..d473c63 100644 --- a/glib/glibmm/propertyproxy_base.cc +++ b/glib/glibmm/propertyproxy_base.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/propertyproxy_base.h b/glib/glibmm/propertyproxy_base.h index c5e6a53..1e84070 100644 --- a/glib/glibmm/propertyproxy_base.h +++ b/glib/glibmm/propertyproxy_base.h @@ -16,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/quark.cc b/glib/glibmm/quark.cc index a528be8..d8b5cf5 100644 --- a/glib/glibmm/quark.cc +++ b/glib/glibmm/quark.cc @@ -1,5 +1,3 @@ -/* $Id$ */ - /* quark.cc * * Copyright 2002 The gtkmm Development Team @@ -15,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/quark.h b/glib/glibmm/quark.h index ae0731c..b860e74 100644 --- a/glib/glibmm/quark.h +++ b/glib/glibmm/quark.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GLIBMM_QUARK_H #define _GLIBMM_QUARK_H @@ -17,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/random.cc b/glib/glibmm/random.cc index 11f5cdf..aec836b 100644 --- a/glib/glibmm/random.cc +++ b/glib/glibmm/random.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* random.cc * * Copyright (C) 2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/random.h b/glib/glibmm/random.h index d934044..3b9893e 100644 --- a/glib/glibmm/random.h +++ b/glib/glibmm/random.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_RANDOM_H #define _GLIBMM_RANDOM_H -/* $Id$ */ - /* random.h * * Copyright (C) 2002 The gtkmm Development Team @@ -19,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/refptr.h b/glib/glibmm/refptr.h index 8edf68b..c77b21d 100644 --- a/glib/glibmm/refptr.h +++ b/glib/glibmm/refptr.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/signalproxy.cc b/glib/glibmm/signalproxy.cc index 9da33cc..c36d713 100644 --- a/glib/glibmm/signalproxy.cc +++ b/glib/glibmm/signalproxy.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/signalproxy.h b/glib/glibmm/signalproxy.h index c537ea5..0f2022b 100644 --- a/glib/glibmm/signalproxy.h +++ b/glib/glibmm/signalproxy.h @@ -16,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ extern "C" { diff --git a/glib/glibmm/signalproxy_connectionnode.cc b/glib/glibmm/signalproxy_connectionnode.cc index 8603e76..af50254 100644 --- a/glib/glibmm/signalproxy_connectionnode.cc +++ b/glib/glibmm/signalproxy_connectionnode.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/signalproxy_connectionnode.h b/glib/glibmm/signalproxy_connectionnode.h index 3099269..da82bdf 100644 --- a/glib/glibmm/signalproxy_connectionnode.h +++ b/glib/glibmm/signalproxy_connectionnode.h @@ -16,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/stringutils.cc b/glib/glibmm/stringutils.cc index 329b1b0..f6ce8fa 100644 --- a/glib/glibmm/stringutils.cc +++ b/glib/glibmm/stringutils.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* Copyright (C) 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -14,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/stringutils.h b/glib/glibmm/stringutils.h index a81d770..e6659e2 100644 --- a/glib/glibmm/stringutils.h +++ b/glib/glibmm/stringutils.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_STRINGUTILS_H #define _GLIBMM_STRINGUTILS_H -/* $Id$ */ - /* Copyright (C) 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -17,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/timer.cc b/glib/glibmm/timer.cc index ad3bd6b..7f32b18 100644 --- a/glib/glibmm/timer.cc +++ b/glib/glibmm/timer.cc @@ -13,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/timer.h b/glib/glibmm/timer.h index 2559ffa..fcee92b 100644 --- a/glib/glibmm/timer.h +++ b/glib/glibmm/timer.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_TIMER_H #define _GLIBMM_TIMER_H -/* $Id$ */ - /* timer.h * * Copyright (C) 2002 The gtkmm Development Team @@ -19,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ extern "C" { diff --git a/glib/glibmm/timeval.cc b/glib/glibmm/timeval.cc index 63e93c5..c8bb9a9 100644 --- a/glib/glibmm/timeval.cc +++ b/glib/glibmm/timeval.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* timeval.cc * * Copyright (C) 2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/timeval.h b/glib/glibmm/timeval.h index 11b3c44..e67a9e0 100644 --- a/glib/glibmm/timeval.h +++ b/glib/glibmm/timeval.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_TIMEVAL_H #define _GLIBMM_TIMEVAL_H -/* $Id$ */ - /* timeval.h * * Copyright (C) 2002 The gtkmm Development Team @@ -19,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/ustring.cc b/glib/glibmm/ustring.cc index d05e986..976289f 100644 --- a/glib/glibmm/ustring.cc +++ b/glib/glibmm/ustring.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -1289,13 +1288,13 @@ ustring::casefold_collate_key() const // static ustring -ustring::compose_argv(const Glib::ustring& fmt, int argc, const ustring* const* argv) +ustring::compose_private(const Glib::ustring& fmt, std::initializer_list const ilist) { std::string::size_type result_size = fmt.raw().size(); // Guesstimate the final string size. - for (int i = 0; i < argc; ++i) - result_size += argv[i]->raw().size(); + for (auto const it: ilist) + result_size += it->raw().size(); std::string result; result.reserve(result_size); @@ -1313,11 +1312,12 @@ ustring::compose_argv(const Glib::ustring& fmt, int argc, const ustring* const* else { const int index = Ascii::digit_value(stop[1]) - 1; + const int size = ilist.size(); - if (index >= 0 && index < argc) + if (index >= 0 && index < size) { result.append(start, stop - start); - result += argv[index]->raw(); + result += (*(ilist.begin() + index))->raw(); start = stop + 2; } else diff --git a/glib/glibmm/ustring.h b/glib/glibmm/ustring.h index 0aee963..0b2a279 100644 --- a/glib/glibmm/ustring.h +++ b/glib/glibmm/ustring.h @@ -14,21 +14,19 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include #include #include +#include // for std::size_t and optionally std::ptrdiff_t +#include #include #include #include #include -#ifndef GLIBMM_HAVE_STD_ITERATOR_TRAITS -#include /* for std::ptrdiff_t */ -#endif namespace Glib { @@ -647,170 +645,75 @@ public: /* Returns fmt as is, but checks for invalid references in the format string. * @newin{2,18} */ - template static inline ustring compose(const ustring& fmt); /*! Substitute placeholders in a format string with the referenced arguments. - * The template string should be in qt-format, that is - * "%1", "%2", ..., "%9" are used as placeholders - * and "%%" denotes a literal "%". Substitutions may be - * reordered. + * + * The template string uses a similar format to Qt’s QString class, in that + * %1, %2, and so on to %9 are used as placeholders + * to be substituted with the string representation of the @a args 1–9, while + * %% inserts a literal % in the output. Placeholders do not + * have to appear in the same order as their corresponding function arguments. + * * @par Example: * @code * using Glib::ustring; * const int percentage = 50; * const ustring text = ustring::compose("%1%% done", percentage); * @endcode - * @param fmt A template string in qt-format. - * @param a1 The argument to substitute for "%1". + * + * @param fmt The template string, in the format described above. + * @param args 1 to 9 arguments to substitute for %1 to %9 + * respectively. + * * @return The substituted message string. + * * @throw Glib::ConvertError * - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose( - const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose( - const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, - const T4& a4, const T5& a5, const T6& a6); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, - const T4& a4, const T5& a5, const T6& a6, const T7& a7); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} - */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, - const T4& a4, const T5& a5, const T6& a6, const T7& a7, const T8& a8); - - /* See the documentation for compose(const ustring& fmt, const T1& a1). - * @newin{2,16} + * @newin{2,56} */ - template - static inline ustring compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, - const T4& a4, const T5& a5, const T6& a6, const T7& a7, const T8& a8, const T9& a9); + template + static inline ustring compose(const ustring& fmt, const Ts&... args); - /*! Format the argument to its string representation. + /*! Format the argument(s) to a string representation. + * * Applies the arguments in order to an std::wostringstream and returns the * resulting string. I/O manipulators may also be used as arguments. This * greatly simplifies the common task of converting a number to a string, as * demonstrated by the example below. The format() methods can also be used * in conjunction with compose() to facilitate localization of user-visible * messages. + * * @code * using Glib::ustring; * double value = 22.0 / 7.0; * ustring text = ustring::format(std::fixed, std::setprecision(2), value); * @endcode + * * @note The use of a wide character stream in the implementation of format() * is almost completely transparent. However, one of the instances where the * use of wide streams becomes visible is when the std::setfill() stream * manipulator is used. In order for std::setfill() to work the argument * must be of type wchar_t. This can be achieved by using the * L prefix with a character literal, as shown in the example. + * * @code * using Glib::ustring; * // Insert leading zeroes to fill in at least six digits * ustring text = ustring::format(std::setfill(L'0'), std::setw(6), 123); * @endcode * - * @param a1 A streamable value or an I/O manipulator. - * @return The string representation of the argument stream. - * @throw Glib::ConvertError - * - * @newin{2,16} - */ - template - static inline ustring format(const T1& a1); - - /* See the documentation for format(const T1& a1). + * @param args One or more streamable values or I/O manipulators. * - * @newin{2,16} - */ - template - static inline ustring format(const T1& a1, const T2& a2); - - /* See the documentation for format(const T1& a1). - * - * @newin{2,16} - */ - template - static inline ustring format(const T1& a1, const T2& a2, const T3& a3); - - /* See the documentation for format(const T1& a1). - * - * @newin{2,16} - */ - template - static inline ustring format(const T1& a1, const T2& a2, const T3& a3, const T4& a4); - - /* See the documentation for format(const T1& a1). - * - * @newin{2,16} - */ - template - static inline ustring format( - const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5); - - /* See the documentation for format(const T1& a1). + * @return The string representation of the argument stream. * - * @newin{2,16} - */ - template - static inline ustring format( - const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, const T6& a6); - - /* See the documentation for format(const T1& a1). + * @throw Glib::ConvertError * - * @newin{2,16} + * @newin{2,56} */ - template - static inline ustring format(const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, - const T6& a6, const T7& a7); + template + static inline ustring format(const Ts&... args); - /* See the documentation for format(const T1& a1). - * - * @newin{2,16} - */ - template - static inline ustring format(const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, - const T6& a6, const T7& a7, const T8& a8); //! @} private: @@ -832,9 +735,16 @@ private: template class Stringify; + + static ustring compose_private(const ustring& fmt, std::initializer_list ilist); + class FormatStream; - static ustring compose_argv(const ustring& fmt, int argc, const ustring* const* argv); + template + static inline void format_private(FormatStream& buf, const T& arg); + + template + static inline void format_private(FormatStream& buf, const T1& a1, const Ts&... args); #endif /* DOXYGEN_SHOULD_SKIP_THIS */ @@ -1149,114 +1059,30 @@ ustring::raw() const return string_; } -template -inline // static - ustring - ustring::format(const T1& a1) -{ - ustring::FormatStream buf; - buf.stream(a1); - return buf.to_string(); -} - -template -inline // static - ustring - ustring::format(const T1& a1, const T2& a2) -{ - ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - return buf.to_string(); -} - -template -inline // static - ustring - ustring::format(const T1& a1, const T2& a2, const T3& a3) -{ - ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - return buf.to_string(); -} - -template -inline // static - ustring - ustring::format(const T1& a1, const T2& a2, const T3& a3, const T4& a4) -{ - ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - buf.stream(a4); - return buf.to_string(); -} - -template -inline // static - ustring - ustring::format(const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5) -{ - ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - buf.stream(a4); - buf.stream(a5); - return buf.to_string(); -} - -template +template inline // static - ustring - ustring::format( - const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, const T6& a6) + void + ustring::format_private(FormatStream& buf, const T& arg) { - ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - buf.stream(a4); - buf.stream(a5); - buf.stream(a6); - return buf.to_string(); + buf.stream(arg); } -template +template inline // static - ustring - ustring::format(const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, - const T6& a6, const T7& a7) + void + ustring::format_private(FormatStream& buf, const T1& a1, const Ts&... args) { - ustring::FormatStream buf; buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - buf.stream(a4); - buf.stream(a5); - buf.stream(a6); - buf.stream(a7); - return buf.to_string(); + return format_private(buf, args...); } -template +template inline // static ustring - ustring::format(const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5, - const T6& a6, const T7& a7, const T8& a8) + ustring::format(const Ts&... args) { ustring::FormatStream buf; - buf.stream(a1); - buf.stream(a2); - buf.stream(a3); - buf.stream(a4); - buf.stream(a5); - buf.stream(a6); - buf.stream(a7); - buf.stream(a8); + format_private(buf, args...); return buf.to_string(); } @@ -1356,155 +1182,22 @@ public: inline const ustring* ptr() const { return &string_; } }; -template inline // static ustring ustring::compose(const ustring& fmt) { - return ustring::compose_argv(fmt, 0, nullptr); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1) -{ - const ustring::Stringify s1(a1); - - const ustring* const argv[] = { s1.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - - const ustring* const argv[] = { s1.ptr(), s2.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); + return ustring::compose_private(fmt, {}); } -template +template inline // static ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4) + ustring::compose(const ustring& fmt, const Ts&... args) { - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); + static_assert(sizeof...(Ts) <= 9, + "ustring::compose only supports up to 9 placeholders."); - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose( - const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, const T5& a5) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); - const ustring::Stringify s5(a5); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr(), s5.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, - const T5& a5, const T6& a6) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); - const ustring::Stringify s5(a5); - const ustring::Stringify s6(a6); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr(), s5.ptr(), s6.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, - const T5& a5, const T6& a6, const T7& a7) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); - const ustring::Stringify s5(a5); - const ustring::Stringify s6(a6); - const ustring::Stringify s7(a7); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr(), s5.ptr(), s6.ptr(), - s7.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, - const T5& a5, const T6& a6, const T7& a7, const T8& a8) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); - const ustring::Stringify s5(a5); - const ustring::Stringify s6(a6); - const ustring::Stringify s7(a7); - const ustring::Stringify s8(a8); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr(), s5.ptr(), s6.ptr(), - s7.ptr(), s8.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); -} - -template -inline // static - ustring - ustring::compose(const ustring& fmt, const T1& a1, const T2& a2, const T3& a3, const T4& a4, - const T5& a5, const T6& a6, const T7& a7, const T8& a8, const T9& a9) -{ - const ustring::Stringify s1(a1); - const ustring::Stringify s2(a2); - const ustring::Stringify s3(a3); - const ustring::Stringify s4(a4); - const ustring::Stringify s5(a5); - const ustring::Stringify s6(a6); - const ustring::Stringify s7(a7); - const ustring::Stringify s8(a8); - const ustring::Stringify s9(a9); - - const ustring* const argv[] = { s1.ptr(), s2.ptr(), s3.ptr(), s4.ptr(), s5.ptr(), s6.ptr(), - s7.ptr(), s8.ptr(), s9.ptr() }; - return ustring::compose_argv(fmt, G_N_ELEMENTS(argv), argv); + return compose_private(fmt, { Stringify(args).ptr()... }); } #endif /* DOXYGEN_SHOULD_SKIP_THIS */ diff --git a/glib/glibmm/utility.cc b/glib/glibmm/utility.cc index 172ff7a..4c21660 100644 --- a/glib/glibmm/utility.cc +++ b/glib/glibmm/utility.cc @@ -1,7 +1,3 @@ -// -*- c++ -*- - -/* $Id$ */ - /* Copyright (C) 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -15,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/utility.h b/glib/glibmm/utility.h index 5e17183..9d65d65 100644 --- a/glib/glibmm/utility.h +++ b/glib/glibmm/utility.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/value.cc b/glib/glibmm/value.cc index 893bb85..34de309 100644 --- a/glib/glibmm/value.cc +++ b/glib/glibmm/value.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -14,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/value.h b/glib/glibmm/value.h index 142e187..c423029 100644 --- a/glib/glibmm/value.h +++ b/glib/glibmm/value.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/value_custom.cc b/glib/glibmm/value_custom.cc index 69354ef..1526070 100644 --- a/glib/glibmm/value_custom.cc +++ b/glib/glibmm/value_custom.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* Copyright 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -14,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/value_custom.h b/glib/glibmm/value_custom.h index 0284888..7c23a8d 100644 --- a/glib/glibmm/value_custom.h +++ b/glib/glibmm/value_custom.h @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #ifndef _GLIBMM_VALUE_CUSTOM_H diff --git a/glib/glibmm/vectorutils.cc b/glib/glibmm/vectorutils.cc index 8a8e711..b4cac1e 100644 --- a/glib/glibmm/vectorutils.cc +++ b/glib/glibmm/vectorutils.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/vectorutils.h b/glib/glibmm/vectorutils.h index 6ea434a..f68903d 100644 --- a/glib/glibmm/vectorutils.h +++ b/glib/glibmm/vectorutils.h @@ -1,4 +1,3 @@ -// -*- c++ -*- #ifndef _GLIBMM_VECTORUTILS_H #define _GLIBMM_VECTORUTILS_H @@ -15,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include #include diff --git a/glib/glibmm/wrap.cc b/glib/glibmm/wrap.cc index ee9ca79..08f0309 100644 --- a/glib/glibmm/wrap.cc +++ b/glib/glibmm/wrap.cc @@ -1,6 +1,3 @@ -// -*- c++ -*- -/* $Id$ */ - /* wrap.cc * * Copyright (C) 1998-2002 The gtkmm Development Team @@ -16,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/wrap.h b/glib/glibmm/wrap.h index eec39bb..dfa4c96 100644 --- a/glib/glibmm/wrap.h +++ b/glib/glibmm/wrap.h @@ -14,8 +14,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/glibmm/wrap_init.h b/glib/glibmm/wrap_init.h index f53ae41..df27023 100644 --- a/glib/glibmm/wrap_init.h +++ b/glib/glibmm/wrap_init.h @@ -1,9 +1,6 @@ -// -*- c++ -*- #ifndef _GLIBMM_WRAP_INIT_H #define _GLIBMM_WRAP_INIT_H -/* $Id$ */ - /* wrap_init.h * * Copyright 2002 The gtkmm Development Team @@ -19,8 +16,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/balancedtree.hg b/glib/src/balancedtree.hg index 6d02c39..31be6e4 100644 --- a/glib/src/balancedtree.hg +++ b/glib/src/balancedtree.hg @@ -11,8 +11,7 @@ * Library General Public License for more details. * * You should have received a copy of the GNU Library General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/bytearray.ccg b/glib/src/bytearray.ccg index 2cb910c..003c58b 100644 --- a/glib/src/bytearray.ccg +++ b/glib/src/bytearray.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace diff --git a/glib/src/bytearray.hg b/glib/src/bytearray.hg index 3ed2d69..ebf385b 100644 --- a/glib/src/bytearray.hg +++ b/glib/src/bytearray.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/bytes.ccg b/glib/src/bytes.ccg index 0ff936a..bc43f2d 100644 --- a/glib/src/bytes.ccg +++ b/glib/src/bytes.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Glib diff --git a/glib/src/bytes.hg b/glib/src/bytes.hg index b4b1f2a..60b92d1 100644 --- a/glib/src/bytes.hg +++ b/glib/src/bytes.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/checksum.ccg b/glib/src/checksum.ccg index 0db13da..c612049 100644 --- a/glib/src/checksum.ccg +++ b/glib/src/checksum.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/checksum.hg b/glib/src/checksum.hg index 9394eb2..4785470 100644 --- a/glib/src/checksum.hg +++ b/glib/src/checksum.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/convert.ccg b/glib/src/convert.ccg index 6a84847..cd08eac 100644 --- a/glib/src/convert.ccg +++ b/glib/src/convert.ccg @@ -1,5 +1,3 @@ -// -*- c++ -*- - /* Copyright (C) 2002 The gtkmm Development Team * * This library is free software; you can redistribute it and/or @@ -13,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include //For g_assert() in glib >= 2.15.0 diff --git a/glib/src/convert.hg b/glib/src/convert.hg index 408ceb3..9c211bc 100644 --- a/glib/src/convert.hg +++ b/glib/src/convert.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/date.ccg b/glib/src/date.ccg index 7aac7a4..75f240b 100644 --- a/glib/src/date.ccg +++ b/glib/src/date.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ //#include //For g_assert() in glib >= 2.15.0 diff --git a/glib/src/date.hg b/glib/src/date.hg index 1f674c1..f3f9442 100644 --- a/glib/src/date.hg +++ b/glib/src/date.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/datetime.ccg b/glib/src/datetime.ccg index d47f05c..fbad36e 100644 --- a/glib/src/datetime.ccg +++ b/glib/src/datetime.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/datetime.hg b/glib/src/datetime.hg index 8a4a4a8..6665950 100644 --- a/glib/src/datetime.hg +++ b/glib/src/datetime.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/enums.ccg b/glib/src/enums.ccg index f3c6be6..55b57e0 100644 --- a/glib/src/enums.ccg +++ b/glib/src/enums.ccg @@ -11,6 +11,5 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ diff --git a/glib/src/enums.hg b/glib/src/enums.hg index 290ee4b..656f285 100644 --- a/glib/src/enums.hg +++ b/glib/src/enums.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/fileutils.ccg b/glib/src/fileutils.ccg index eabe8e2..777aa9d 100644 --- a/glib/src/fileutils.ccg +++ b/glib/src/fileutils.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/fileutils.hg b/glib/src/fileutils.hg index e660ca5..3aa76d7 100644 --- a/glib/src/fileutils.hg +++ b/glib/src/fileutils.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/glib_docs.xml b/glib/src/glib_docs.xml index 0282274..3d3c71e 100644 --- a/glib/src/glib_docs.xml +++ b/glib/src/glib_docs.xml @@ -152,6 +152,10 @@ Since: 2.16 Use the SHA-256 hashing algorithm + + Use the SHA-384 hashing algorithm (Since: 2.51) + + Use the SHA-512 hashing algorithm (Since: 2.36) @@ -601,6 +605,11 @@ a strong "power of 2" basis, like RAM sizes or RAID stripe sizes. Network and storage sizes should be reported in the normal SI units. + + set the size as a quantity in bits, rather than +bytes, and return units in bits. For example, ‘Mb’ rather than ‘MB’. + + @@ -1161,6 +1170,25 @@ forms rather than a maximally decomposed form + + +Error codes returned by functions converting a string to a number. + +Since: 2.54 + + + + + String was not a valid number. + + + + String was a number, but out of bounds. + + + + + The notify signal is emitted on an object when one of its @@ -1456,7 +1484,7 @@ setting. - A dot metacharater (".") in the pattern matches all + A dot metacharacter (".") in the pattern matches all characters, including newlines. Without it, newlines are excluded. This option can be changed within a pattern by a ("?s") option setting. @@ -1475,7 +1503,7 @@ be changed within a pattern by a "(?x)" option setting. it is constrained to match only at the first matching point in the string that is being searched. This effect can also be achieved by appropriate constructs in the pattern itself such as the "^" -metacharater. +metacharacter. @@ -1856,7 +1884,7 @@ Since: 2.14 it is constrained to match only at the first matching point in the string that is being searched. This effect can also be achieved by appropriate constructs in the pattern itself such as the "^" -metacharater. +metacharacter. @@ -2259,7 +2287,7 @@ These two options correspond rather directly to the 'dist' and 'built' terminology that automake uses and are explicitly used to distinguish between the 'srcdir' and 'builddir' being separate. All files in your project should either be dist (in the -`DIST_EXTRA` or `dist_schema_DATA` +`EXTRA_DIST` or `dist_schema_DATA` sense, in which case they will always be in the srcdir) or built (in the `BUILT_SOURCES` sense, in which case they will always be in the builddir). @@ -2323,7 +2351,7 @@ These flags determine what traps to set. Deprecated: #GTestTrapFlags is used only with g_test_trap_fork(), which is deprecated. g_test_trap_subprocess() uses -#GTestTrapSubprocessFlags. +#GTestSubprocessFlags. @@ -2690,7 +2718,7 @@ These are the possible line break classifications. Since new unicode versions may add new types here, applications should be ready to handle unknown values. They may be regarded as %G_UNICODE_BREAK_UNKNOWN. -See <ulink url="http://www.unicode.org/unicode/reports/tr14/">http://www.unicode.org/unicode/reports/tr14/</ulink>. +See [Unicode Line Breaking Algorithm](http://www.unicode.org/unicode/reports/tr14/). @@ -2854,6 +2882,18 @@ See <ulink url="http://www.unicode.org/unicode/reports/tr14/">ht Regional Indicator (RI). Since: 2.36 + + Emoji Base (EB). Since: 2.50 + + + + Emoji Modifier (EM). Since: 2.50 + + + + Zero Width Joiner (ZWJ). Since: 2.50 + + @@ -2866,9 +2906,7 @@ and is interchangeable with #PangoScript. Note that new types may be added in the future. Applications should be ready to handle unknown values. -See <ulink -url="http://www.unicode.org/reports/tr24/">Unicode Standard Annex -#24: Script names</ulink>. +See [Unicode Standard Annex #24: Script names](http://www.unicode.org/reports/tr24/). @@ -3416,6 +3454,46 @@ Old South Arabian. Since 2.26 Signwriting. Since: 2.48 + + Adlam. Since: 2.50 + + + + Bhaiksuki. Since: 2.50 + + + + Marchen. Since: 2.50 + + + + Newa. Since: 2.50 + + + + Osage. Since: 2.50 + + + + Tangut. Since: 2.50 + + + + Masaram Gondi. Since: 2.54 + + + + Nushu. Since: 2.54 + + + + Soyombo. Since: 2.54 + + + + Zanabazar Square. Since: 2.54 + + @@ -3423,7 +3501,7 @@ Old South Arabian. Since 2.26 These are the possible character classifications from the Unicode specification. -See <ulink url="http://www.unicode.org/reports/tr44/#General_Category_Values">Unicode Character Database</unlink>. +See [Unicode Character Database](http://www.unicode.org/reports/tr44/#General_Category_Values). @@ -3948,6 +4026,10 @@ of @array will be set to zero. If array elements contain dynamically-allocated memory, they should be freed separately. +This function is not thread-safe. If using a #GArray from multiple +threads, use only the atomic g_array_ref() and g_array_unref() +functions. + @@ -4158,7 +4240,7 @@ the new elements. Atomically increments the reference count of @array by one. -This function is MT-safe and may be called from any thread. +This function is thread-safe and may be called from any thread. Since: 2.22 @@ -4383,7 +4465,7 @@ This did not actually work, so any such code should be removed. Atomically decrements the reference count of @array by one. If the reference count drops to 0, all memory allocated by the array is -released. This function is MT-safe and may be called from any +released. This function is thread-safe and may be called from any thread. Since: 2.22 @@ -4791,6 +4873,122 @@ old g_strdown(), which modified the string in place.) + + +A convenience function for converting a string to a signed number. + +This function assumes that @str contains only a number of the given +@base that is within inclusive bounds limited by @min and @max. If +this is true, then the converted number is stored in @out_num. An +empty string is not a valid input. A string with leading or +trailing whitespace is also an invalid input. + +@base can be between 2 and 36 inclusive. Hexadecimal numbers must +not be prefixed with "0x" or "0X". Such a problem does not exist +for octal numbers, since they were usually prefixed with a zero +which does not change the value of the parsed number. + +Parsing failures result in an error with the %G_NUMBER_PARSER_ERROR +domain. If the input is invalid, the error code will be +%G_NUMBER_PARSER_ERROR_INVALID. If the parsed number is out of +bounds - %G_NUMBER_PARSER_ERROR_OUT_OF_BOUNDS. + +See g_ascii_strtoll() if you have more complex needs such as +parsing a string which starts with a number, but then has other +characters. + +Since: 2.54 + + + + + a string + + + + base of a parsed number + + + + a lower bound (inclusive) + + + + an upper bound (inclusive) + + + + a return location for a number + + + + a return location for #GError + + + + %TRUE if @str was a number, otherwise %FALSE. + + + + + + +A convenience function for converting a string to an unsigned number. + +This function assumes that @str contains only a number of the given +@base that is within inclusive bounds limited by @min and @max. If +this is true, then the converted number is stored in @out_num. An +empty string is not a valid input. A string with leading or +trailing whitespace is also an invalid input. + +@base can be between 2 and 36 inclusive. Hexadecimal numbers must +not be prefixed with "0x" or "0X". Such a problem does not exist +for octal numbers, since they were usually prefixed with a zero +which does not change the value of the parsed number. + +Parsing failures result in an error with the %G_NUMBER_PARSER_ERROR +domain. If the input is invalid, the error code will be +%G_NUMBER_PARSER_ERROR_INVALID. If the parsed number is out of +bounds - %G_NUMBER_PARSER_ERROR_OUT_OF_BOUNDS. + +See g_ascii_strtoull() if you have more complex needs such as +parsing a string which starts with a number, but then has other +characters. + +Since: 2.54 + + + + + a string + + + + base of a parsed number + + + + a lower bound (inclusive) + + + + an upper bound (inclusive) + + + + a return location for a number + + + + a return location for #GError + + + + %TRUE if @str was a number, otherwise %FALSE. + + + + Compare @s1 and @s2, ignoring the case of ASCII characters and any @@ -5054,7 +5252,8 @@ fails. If the assertion fails (i.e. the expression is not true), an error message is logged and the application is terminated. The macro can be turned off in final releases of code by defining -`G_DISABLE_ASSERT` when compiling the application. +`G_DISABLE_ASSERT` when compiling the application, so code must +not depend on any side effects from @expr. @@ -6899,6 +7098,8 @@ The output buffer must be large enough to fit all the data that will be written to it. It will need up to 4 bytes, or up to 5 bytes if line-breaking is enabled. +The @out array will not be automatically nul-terminated. + Since: 2.12 @@ -8611,6 +8812,30 @@ g_free(). + + +Behaves exactly like g_build_filename(), but takes the path elements +as a va_list. This function is mainly meant for language bindings. + +Since: 2.56 + + + + + the first element in the path + + + + va_list of remaining elements in path + + + + a newly-allocated string that must be freed +with g_free(). + + + + Behaves exactly like g_build_filename(), but takes the path elements @@ -9231,7 +9456,7 @@ Since: 2.32 - the data to be used for the bytes +the data to be used for the bytes @@ -9265,7 +9490,7 @@ Since: 2.32 - the data to be used for the bytes +the data to be used for the bytes @@ -9296,7 +9521,7 @@ Since: 2.32 - the data to be used for the bytes +the data to be used for the bytes @@ -9338,7 +9563,7 @@ Since: 2.32 Releases a reference on @bytes. This may result in the bytes being -freed. +freed. If @bytes is %NULL, it will return immediately. Since: 2.32 @@ -11529,7 +11754,7 @@ the last parameter. - a new #GCClosure + a floating reference to a new #GCClosure @@ -11602,7 +11827,7 @@ the first parameter. - a new #GCClosure + a floating reference to a new #GCClosure @@ -11826,6 +12051,8 @@ source is still active. Typically, you will want to call g_spawn_close_pid() in the callback function for the source. GLib supports only a single callback per process id. +On POSIX platforms, the same restrictions mentioned for +g_child_watch_source_new() apply to this function. This internally creates a main loop source using g_child_watch_source_new() and attaches it to the main loop context @@ -11875,6 +12102,8 @@ is still active. Typically, you should invoke g_spawn_close_pid() in the callback function for the source. GLib supports only a single callback per process id. +On POSIX platforms, the same restrictions mentioned for +g_child_watch_source_new() apply to this function. This internally creates a main loop source using g_child_watch_source_new() and attaches it to the main loop context @@ -11929,14 +12158,24 @@ Note that on platforms where #GPid must be explicitly closed source is still active. Typically, you will want to call g_spawn_close_pid() in the callback function for the source. -Note further that using g_child_watch_source_new() is not -compatible with calling `waitpid` with a nonpositive first -argument in the application. Calling waitpid() for individual -pids will still work fine. +On POSIX platforms, the following restrictions apply to this API +due to limitations in POSIX process interfaces: + +* @pid must be a child of this process +* @pid must be positive +* the application must not call `waitpid` with a non-positive +first argument, for instance in another thread +* the application must not wait for @pid to exit by any other +mechanism, including `waitpid(pid, ...)` or a second child-watch +source for the same @pid +* the application must not ignore SIGCHILD + +If any of those conditions are not met, this and related APIs will +not work correctly. This can often be diagnosed via a GLib warning +stating that `ECHILD` was received by `waitpid`. -Similarly, on POSIX platforms, the @pid passed to this function must -be greater than 0 (i.e. this function must wait for a specific child, -and cannot wait for one of many children by using a nonpositive argument). +Calling `waitpid` for specific processes other than @pid remains a +valid thing to do. Since: 2.4 @@ -12000,6 +12239,35 @@ calls g_error_free() on *@err and sets *@err to %NULL. + + +Clears a numeric handler, such as a #GSource ID. + +@tag_ptr must be a valid pointer to the variable holding the handler. + +If the ID is zero then this function does nothing. +Otherwise, clear_func() is called with the ID as a parameter, and the tag is +set to zero. + +A macro is also included that allows this function to be used without +pointer casts. + +Since: 2.56 + + + + + a pointer to the handler ID + + + + the function to call to clear the handler + + + + + + Clears a reference to a #GObject. @@ -12307,7 +12575,7 @@ return my_closure; - a newly allocated #GClosure + a floating reference to a new #GClosure @@ -13258,8 +13526,8 @@ for the @len parameter is unsafe) UTF-8 string to use in place of character not present in the target encoding. (The string must be representable in the target encoding). - If %NULL, characters not in the target encoding will - be represented as Unicode escapes \uxxxx or \Uxxxxyyyy. +If %NULL, characters not in the target encoding will +be represented as Unicode escapes \uxxxx or \Uxxxxyyyy. @@ -13401,7 +13669,17 @@ example. You can also make critical warnings fatal at runtime by setting the `G_DEBUG` environment variable (see -[Running GLib Applications](glib-running.html)). +[Running GLib Applications](glib-running.html)): + +|[ +G_DEBUG=fatal-warnings gdb ./my-program +]| + +Any unrelated failures can be skipped over in +[gdb](https://www.gnu.org/software/gdb/) using the `continue` command. + +The message should typically *not* be translated to the +user's language. If g_log_default_handler() is used as the log handler function, a new-line character will automatically be appended to @..., and need not be entered @@ -13447,6 +13725,10 @@ function is NOT thread-safe. So unless @datalist can be protected from any modifications during invocation of this function, it should not be called. +@func can make changes to @datalist, but the iteration will not +reflect changes made during the g_datalist_foreach() call, other +than skipping over elements that are removed. + @@ -13482,7 +13764,8 @@ g_datalist_id_get_data() because it compares strings. - the data element, or %NULL if it is not found. + the data element, or %NULL if it +is not found. @@ -13565,7 +13848,8 @@ Retrieves the data element corresponding to @key_id. - the data element, or %NULL if it is not found. + the data element, or %NULL if +it is not found. @@ -13604,7 +13888,8 @@ function. - the data previously stored at @key_id, or %NULL if none. + the data previously stored at @key_id, +or %NULL if none. @@ -13814,8 +14099,8 @@ corresponding to @k. - the function to call when the data element is removed. This -function will be called with the data element and can be used to + the function to call when the data element is removed. +This function will be called with the data element and can be used to free any memory allocated for it. If @d is %NULL, then @f must also be %NULL. @@ -13896,8 +14181,12 @@ destroy functions set for data elements. Calls the given function for each data element which is associated with the given location. Note that this function is NOT thread-safe. -So unless @datalist can be protected from any modifications during -invocation of this function, it should not be called. +So unless @dataset_location can be protected from any modifications +during invocation of this function, it should not be called. + +@func can make changes to the dataset, but the iteration will not +reflect changes made during the g_dataset_foreach() call, other +than skipping over elements that are removed. @@ -13933,8 +14222,8 @@ Gets the data element corresponding to a string. - the data element corresponding to the string, or %NULL if -it is not found. + the data element corresponding to +the string, or %NULL if it is not found. @@ -13954,8 +14243,8 @@ Gets the data element corresponding to a #GQuark. - the data element corresponding to the #GQuark, or %NULL if -it is not found. + the data element corresponding to +the #GQuark, or %NULL if it is not found. @@ -13995,7 +14284,8 @@ function. - the data previously stored at @key_id, or %NULL if none. + the data previously stored at @key_id, +or %NULL if none. @@ -14275,6 +14565,26 @@ greater than zero if @lhs is greater than @rhs + + +Copies a GDate to a newly-allocated GDate. If the input was invalid +(as determined by g_date_valid()), the invalid state will be copied +as is into the new object. + +Since: 2.56 + + + + + a #GDate to copy + + + + a newly-allocated #GDate initialized from @date + + + + Computes the number of days between two dates. @@ -15384,7 +15694,8 @@ Since: 2.26 a newly allocated string formatted to the requested format -or %NULL in the case that there was an error. The string +or %NULL in the case that there was an error (such as a format specifier +not being supported in the current locale). The string should be freed with g_free(). @@ -15840,6 +16151,63 @@ Since: 2.26 + + +Creates a #GDateTime corresponding to the given +[ISO 8601 formatted string](https://en.wikipedia.org/wiki/ISO_8601) +@text. ISO 8601 strings of the form <date><sep><time><tz> are supported. + +<sep> is the separator and can be either 'T', 't' or ' '. + +<date> is in the form: + +- `YYYY-MM-DD` - Year/month/day, e.g. 2016-08-24. +- `YYYYMMDD` - Same as above without dividers. +- `YYYY-DDD` - Ordinal day where DDD is from 001 to 366, e.g. 2016-237. +- `YYYYDDD` - Same as above without dividers. +- `YYYY-Www-D` - Week day where ww is from 01 to 52 and D from 1-7, +e.g. 2016-W34-3. +- `YYYYWwwD` - Same as above without dividers. + +<time> is in the form: + +- `hh:mm:ss(.sss)` - Hours, minutes, seconds (subseconds), e.g. 22:10:42.123. +- `hhmmss(.sss)` - Same as above without dividers. + +<tz> is an optional timezone suffix of the form: + +- `Z` - UTC. +- `+hh:mm` or `-hh:mm` - Offset from UTC in hours and minutes, e.g. +12:00. +- `+hh` or `-hh` - Offset from UTC in hours, e.g. +12. + +If the timezone is not provided in @text it must be provided in @default_tz +(this field is otherwise ignored). + +This call can fail (returning %NULL) if @text is not a valid ISO 8601 +formatted string. + +You should release the return value by calling g_date_time_unref() +when you are done with it. + +Since: 2.56 + + + + + an ISO 8601 formatted time string. + + + + a #GTimeZone to use if the text doesn't contain a +timezone, or %NULL. + + + + a new #GDateTime, or %NULL + + + + Creates a #GDateTime corresponding to the given #GTimeVal @tv in the @@ -16444,7 +16812,8 @@ the domain set with textdomain() -A convenience function/macro to log a debug message. +A convenience function/macro to log a debug message. The message should +typically *not* be translated to the user's language. If g_log_default_handler() is used as the log handler function, a new-line character will automatically be appended to @..., and need not be entered @@ -17014,6 +17383,31 @@ be stack-allocated. + + +Pretty-prints @value in the form of the enum’s name. + +This is intended to be used for debugging purposes. The format of the output +may change in the future. + +Since: 2.54 + + + + + the type identifier of a #GEnumClass type + + + + the value + + + + a newly-allocated text string + + + + Returns the value of the environment variable @variable in the @@ -17024,8 +17418,8 @@ Since: 2.32 - an environment -list (eg, as returned from g_get_environ()), or %NULL + +an environment list (eg, as returned from g_get_environ()), or %NULL for an empty environment list @@ -17052,14 +17446,15 @@ Since: 2.32 - an -environment list that can be freed using g_strfreev() (e.g., as + +an environment list that can be freed using g_strfreev() (e.g., as returned from g_get_environ()), or %NULL for an empty environment list - the environment variable to set, must not contain '=' + the environment variable to set, must not +contain '=' @@ -17071,8 +17466,8 @@ environment list - the -updated environment list. Free it using g_strfreev(). + +the updated environment list. Free it using g_strfreev(). @@ -17087,25 +17482,27 @@ Since: 2.32 - an environment -list that can be freed using g_strfreev() (e.g., as returned from g_get_environ()), -or %NULL for an empty environment list + +an environment list that can be freed using g_strfreev() (e.g., as +returned from g_get_environ()), or %NULL for an empty environment list - the environment variable to remove, must not contain '=' + the environment variable to remove, must not +contain '=' - the -updated environment list. Free it using g_strfreev(). + +the updated environment list. Free it using g_strfreev(). -A convenience function/macro to log an error message. +A convenience function/macro to log an error message. The message should +typically *not* be translated to the user's language. This is not intended for end user error reporting. Use of #GError is preferred for that instead, as it allows calling functions to perform actions @@ -17614,8 +18011,7 @@ encoding used for filenames. - Location to store hostname for the -URI. + Location to store hostname for the URI. If there is no hostname in the URI, %NULL will be stored in this location. @@ -17901,6 +18297,32 @@ GObject keeps a reference to the data, so it cannot be stack-allocated. + + +Pretty-prints @value in the form of the flag names separated by ` | ` and +sorted. Any extra bits will be shown at the end as a hexadecimal number. + +This is intended to be used for debugging purposes. The format of the output +may change in the future. + +Since: 2.54 + + + + + the type identifier of a #GFlagsClass type + + + + the value + + + + a newly-allocated text string + + + + A wrapper for the stdio fopen() function. The fopen() function @@ -18025,6 +18447,8 @@ readable file size An implementation of the standard fprintf() function which supports positional parameters, as specified in the Single Unix Specification. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.2 @@ -18216,8 +18640,8 @@ Since: 2.28 - the list of -environment variables + +the list of environment variables @@ -18309,6 +18733,8 @@ string is owned by GLib and should not be modified or freed. If no name can be determined, a default fixed string "localhost" is returned. +The encoding of the returned string is UTF-8. + Since: 2.8 @@ -18418,9 +18844,11 @@ Since: 2.36 Gets the name of the program. This name should not be localized, in contrast to g_get_application_name(). -If you are using GDK or GTK+ the program name is set in gdk_init(), -which is called by gtk_init(). The program name is found by taking -the last component of @argv[0]. +If you are using #GApplication the program name is set in +g_application_run(). In case of GDK or GTK+ it is set in +gdk_init(), which is called by gtk_init() and the +#GtkApplication::startup handler. The program name is found by +taking the last component of @argv[0]. @@ -18479,12 +18907,15 @@ in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). In this case the list of directories retrieved will be `XDG_CONFIG_DIRS`. -On Windows is the directory that contains application data for all users. -A typical path is C:\Documents and Settings\All Users\Application Data. -This folder is used for application data that is not user specific. -For example, an application can store a spell-check dictionary, a database -of clip art, or a log file in the CSIDL_COMMON_APPDATA folder. -This information will not roam and is available to anyone using the computer. +On Windows it follows XDG Base Directory Specification if `XDG_CONFIG_DIRS` is defined. +If `XDG_CONFIG_DIRS` is undefined, the directory that contains application +data for all users is used instead. A typical path is +`C:\Documents and Settings\All Users\Application Data`. +This folder is used for application data +that is not user specific. For example, an application can store +a spell-check dictionary, a database of clip art, or a log file in the +CSIDL_COMMON_APPDATA folder. This information will not roam and is available +to anyone using the computer. Since: 2.6 @@ -18506,9 +18937,11 @@ system-wide application data. On UNIX platforms this is determined using the mechanisms described in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec) -In this case the list of directories retrieved will be XDG_DATA_DIRS. +In this case the list of directories retrieved will be `XDG_DATA_DIRS`. -On Windows the first elements in the list are the Application Data +On Windows it follows XDG Base Directory Specification if `XDG_DATA_DIRS` is defined. +If `XDG_DATA_DIRS` is undefined, +the first elements in the list are the Application Data and Documents folders for All Users. (These can be determined only on Windows 2000 or later and are not present in the list on other Windows versions.) See documentation for CSIDL_COMMON_APPDATA and @@ -18575,12 +19008,13 @@ data specific to particular user. On UNIX platforms this is determined using the mechanisms described in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). -In this case the directory retrieved will be XDG_CACHE_HOME. +In this case the directory retrieved will be `XDG_CACHE_HOME`. -On Windows is the directory that serves as a common repository for -temporary Internet files. A typical path is -C:\Documents and Settings\username\Local Settings\Temporary Internet Files. -See documentation for CSIDL_INTERNET_CACHE. +On Windows it follows XDG Base Directory Specification if `XDG_CACHE_HOME` is defined. +If `XDG_CACHE_HOME` is undefined, the directory that serves as a common +repository for temporary Internet files is used instead. A typical path is +`C:\Documents and Settings\username\Local Settings\Temporary Internet Files`. +See the [documentation for `CSIDL_INTERNET_CACHE`](https://msdn.microsoft.com/en-us/library/windows/desktop/bb762494%28v=vs.85%29.aspx#csidl_internet_cache). Since: 2.6 @@ -18602,10 +19036,12 @@ in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). In this case the directory retrieved will be `XDG_CONFIG_HOME`. -On Windows this is the folder to use for local (as opposed to -roaming) application data. See documentation for -CSIDL_LOCAL_APPDATA. Note that on Windows it thus is the same as -what g_get_user_data_dir() returns. +On Windows it follows XDG Base Directory Specification if `XDG_CONFIG_HOME` is defined. +If `XDG_CONFIG_HOME` is undefined, the folder to use for local (as opposed +to roaming) application data is used instead. See the +[documentation for `CSIDL_LOCAL_APPDATA`](https://msdn.microsoft.com/en-us/library/windows/desktop/bb762494%28v=vs.85%29.aspx#csidl_local_appdata). +Note that in this case on Windows it will be the same +as what g_get_user_data_dir() returns. Since: 2.6 @@ -18627,10 +19063,12 @@ in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). In this case the directory retrieved will be `XDG_DATA_HOME`. -On Windows this is the folder to use for local (as opposed to -roaming) application data. See documentation for -CSIDL_LOCAL_APPDATA. Note that on Windows it thus is the same as -what g_get_user_config_dir() returns. +On Windows it follows XDG Base Directory Specification if `XDG_DATA_HOME` +is defined. If `XDG_DATA_HOME` is undefined, the folder to use for local (as +opposed to roaming) application data is used instead. See the +[documentation for `CSIDL_LOCAL_APPDATA`](https://msdn.microsoft.com/en-us/library/windows/desktop/bb762494%28v=vs.85%29.aspx#csidl_local_appdata). +Note that in this case on Windows it will be the same +as what g_get_user_config_dir() returns. Since: 2.6 @@ -18662,7 +19100,7 @@ consistent on a machine. On Windows, it is always UTF-8. Returns a directory that is unique to the current user on the local system. -On UNIX platforms this is determined using the mechanisms described +This is determined using the mechanisms described in the [XDG Base Directory Specification](http://www.freedesktop.org/Standards/basedir-spec). This is the directory @@ -18670,11 +19108,6 @@ specified in the `XDG_RUNTIME_DIR` environment variable. In the case that this variable is not set, we return the value of g_get_user_cache_dir(), after verifying that it exists. -On Windows this is the folder to use for local (as opposed to -roaming) application data. See documentation for -CSIDL_LOCAL_APPDATA. Note that on Windows it thus is the same as -what g_get_user_config_dir() returns. - Since: 2.28 @@ -19307,7 +19740,9 @@ The g_direct_equal(), g_int_equal(), g_int64_equal(), g_double_equal() and g_str_equal() functions are provided for the most common types of keys. If @key_equal_func is %NULL, keys are compared directly in a similar fashion to g_direct_equal(), but without the overhead of -a function call. +a function call. @key_equal_func is called with the key from the hash table +as its first parameter, and the user-provided key to check against as +its second. @@ -19336,7 +19771,7 @@ Since version 2.42 it is permissible for destroy notify functions to recursively remove further items from the hash table. This is only permissible if the application still holds a reference to the hash table. This means that you may need to ensure that the hash table is empty by -calling g_hash_table_remove_all before releasing the last reference using +calling g_hash_table_remove_all() before releasing the last reference using g_hash_table_unref(). @@ -19642,6 +20077,7 @@ will be closed and it won't be possible to call g_hmac_update() on it anymore. Support for digests of type %G_CHECKSUM_SHA512 has been added in GLib 2.42. +Support for %G_CHECKSUM_SHA384 was added in GLib 2.52. Since: 2.30 @@ -20968,8 +21404,7 @@ by g_io_channel_new_file (), and %FALSE for all other channels. - Whether the channel will be closed on the final unref of -the GIOChannel data structure. + %TRUE if the channel will be closed, %FALSE otherwise. @@ -21419,8 +21854,12 @@ The default state of the channel is buffered. +Whether to close the channel on the final unref of the #GIOChannel +data structure. The default value of this is %TRUE for channels +created by g_io_channel_new_file (), and %FALSE for all other channels. + Setting this flag to %TRUE for a channel you have already closed -can cause problems. +can cause problems when the final reference to the #GIOChannel is dropped. @@ -21430,9 +21869,7 @@ can cause problems. Whether to close the channel on the final unref of -the GIOChannel data structure. The default value of -this is %TRUE for channels created by g_io_channel_new_file (), -and %FALSE for all other channels. +the GIOChannel data structure. @@ -21604,6 +22041,8 @@ The default encoding for #GIOChannel is UTF-8. If your application is reading output from a command using via pipe, you may need to set the encoding to the encoding of the current locale (see g_get_charset()) with the g_io_channel_set_encoding() function. +By default, the fd passed will not be closed when the final reference +to the #GIOChannel data structure is dropped. If you want to read raw binary data without interpretation, then call the g_io_channel_set_encoding() function with %NULL for the @@ -21653,8 +22092,8 @@ order to meaningfully use this function your code should use the same C runtime as GLib uses, which is msvcrt.dll. Note that in current Microsoft compilers it is near impossible to convince it to build code that would use msvcrt.dll. The last Microsoft compiler -version that supported using msvcrt.dll as the C runtime was version -6. The GNU compiler and toolchain for Windows, also known as Mingw, +version that supported using msvcrt.dll as the C runtime was version 6. +The GNU compiler and toolchain for Windows, also known as Mingw, fully supports msvcrt.dll. If you have created a #GIOChannel for a file descriptor and started @@ -22127,7 +22566,8 @@ integer. If @key cannot be found then 0 is returned and @error is set to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the value associated -with @key cannot be interpreted as an integer then 0 is returned +with @key cannot be interpreted as an integer, or is out of range +for a #gint, then 0 is returned and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -22164,7 +22604,8 @@ integers. If @key cannot be found then %NULL is returned and @error is set to #G_KEY_FILE_ERROR_KEY_NOT_FOUND. Likewise, if the values associated -with @key cannot be interpreted as integers then %NULL is returned +with @key cannot be interpreted as integers, or are out of range for +#gint, then %NULL is returned and @error is set to #G_KEY_FILE_ERROR_INVALID_VALUE. Since: 2.6 @@ -22663,9 +23104,13 @@ of the file, or %NULL This function looks for a key file named @file in the paths specified in @search_dirs, loads the file into @key_file and -returns the file's full path in @full_path. If the file could not -be loaded then an %error is set to either a #GFileError or -#GKeyFileError. +returns the file's full path in @full_path. + +If the file could not be found in any of the @search_dirs, +%G_KEY_FILE_ERROR_NOT_FOUND is returned. If +the file is found but the OS returns an error when opening or reading the +file, a %G_FILE_ERROR is returned. If there is a problem parsing the file, a +%G_KEY_FILE_ERROR is returned. Since: 2.14 @@ -22705,8 +23150,13 @@ of the file, or %NULL Loads a key file into an empty #GKeyFile structure. -If the file could not be loaded then @error is set to -either a #GFileError or #GKeyFileError. + +If the OS returns an error when opening or reading the file, a +%G_FILE_ERROR is returned. If there is a problem parsing the file, a +%G_KEY_FILE_ERROR is returned. + +This function will never return a %G_KEY_FILE_ERROR_NOT_FOUND error. If the +@file is not found, %G_FILE_ERROR_NOENT is returned. Since: 2.6 @@ -23659,6 +24109,9 @@ or %NULL if the #GList has no elements Calls a function for each element of a #GList. +It is safe for @func to remove the element from @list, but it must +not modify any part of the list after that element. + @@ -23728,6 +24181,9 @@ It is usually used after g_list_remove_link(). Convenience method, which frees all the memory used by a #GList, and calls @free_func on every element's data. +@free_func must not modify the list (eg, by removing the freed +element from it). + Since: 2.28 @@ -24077,7 +24533,7 @@ start of the #GList A convenience macro to get the previous element in a #GList. Note that it is considered perfectly acceptable to access -@list->previous directly. +@list->prev directly. @@ -24251,8 +24707,9 @@ Since: 2.8 - a %NULL-terminated -list of strings which must be freed with g_strfreev(). + +a %NULL-terminated list of strings which must be freed with +g_strfreev(). @@ -24614,7 +25071,7 @@ the log levels with the #G_LOG_FLAG_FATAL and -Like g_log_sets_handler(), but takes a destroy notify for the @user_data. +Like g_log_set_handler(), but takes a destroy notify for the @user_data. This has no effect if structured logging is enabled; see [Using Structured Logging][using-structured-logging]. @@ -24691,7 +25148,10 @@ finished with, if non-%NULL Log a message with structured data. The message will be passed through to the log writer set by the application using g_log_set_writer_func(). If the message is fatal (i.e. its log level is %G_LOG_LEVEL_ERROR), the program will -be aborted at the end of this function. +be aborted at the end of this function. If the log writer returns +%G_LOG_WRITER_UNHANDLED (failure), no other fallback writers will be tried. +See the documentation for #GLogWriterFunc for information on chaining +writers. The structured data is provided as key–value pairs, where keys are UTF-8 strings, and values are arbitrary pointers — typically pointing to UTF-8 @@ -24756,8 +25216,8 @@ g_log_structured_array (G_LOG_LEVEL_DEBUG, fields, G_N_ELEMENTS (fields)); ]| Note also that, even if no other structured fields are specified, there -must always be a "MESSAGE" key before the format string. The "MESSAGE"-format -pair has to be the last of the key-value pairs, and "MESSAGE" is the only +must always be a `MESSAGE` key before the format string. The `MESSAGE`-format +pair has to be the last of the key-value pairs, and `MESSAGE` is the only field for which printf()-style formatting is supported. The default writer function for `stdout` and `stderr` will automatically @@ -24952,6 +25412,12 @@ Check whether the given @output_fd file descriptor is a connection to the systemd journal, or something else (like a log file or `stdout` or `stderr`). +Invalid file descriptors are accepted and return %FALSE, which allows for +the following construct without needing any additional error handling: +|[<!-- language="C" --> +is_journald = g_log_writer_is_journald (fileno (stderr)); +]| + Since: 2.50 @@ -25420,7 +25886,7 @@ Invokes a function in such a way that @context is owned during the invocation of @function. This function is the same as g_main_context_invoke() except that it -lets you specify the priority incase @function ends up being +lets you specify the priority in case @function ends up being scheduled as an idle and also lets you give a #GDestroyNotify for @data. @notify should not assume that it is called from any particular @@ -27589,7 +28055,8 @@ However, its use was incompatible with the use of global constructors in GLib and GIO, because those use the GLib allocators before main is reached. Therefore this function is now deprecated and is just a stub. -Deprecated: 2.46: Use other memory profiling tools instead +Deprecated: 2.46: This function now does nothing. Use other memory +profiling tools instead @@ -27731,12 +28198,16 @@ on most UNIX-like systems. The parameter is a string that should follow the rules for mkdtemp() templates, i.e. contain the string "XXXXXX". g_mkdtemp() is slightly more flexible than mkdtemp() in that the -sequence does not have to occur at the very end of the template -and you can pass a @mode and additional @flags. The X string will -be modified to form the name of a directory that didn't exist. +sequence does not have to occur at the very end of the template. +The X string will be modified to form the name of a directory that +didn't exist. The string should be in the GLib file name encoding. Most importantly, on Windows it should be in UTF-8. +If you are going to be creating a temporary directory inside the +directory returned by g_get_tmp_dir(), you might want to use +g_dir_make_tmp() instead. + Since: 2.30 @@ -27760,13 +28231,17 @@ on most UNIX-like systems. The parameter is a string that should follow the rules for mkdtemp() templates, i.e. contain the string "XXXXXX". -g_mkdtemp() is slightly more flexible than mkdtemp() in that the +g_mkdtemp_full() is slightly more flexible than mkdtemp() in that the sequence does not have to occur at the very end of the template and you can pass a @mode. The X string will be modified to form the name of a directory that didn't exist. The string should be in the GLib file name encoding. Most importantly, on Windows it should be in UTF-8. +If you are going to be creating a temporary directory inside the +directory returned by g_get_tmp_dir(), you might want to use +g_dir_make_tmp() instead. + Since: 2.30 @@ -28404,8 +28879,9 @@ the second 1, and so on. -Calls a function for each of the children of a #GNode. -Note that it doesn't descend beneath the child nodes. +Calls a function for each of the children of a #GNode. Note that it +doesn't descend beneath the child nodes. @func must not do anything +that would modify the structure of the tree. @@ -29006,6 +29482,7 @@ Reverses the order of the children of a #GNode. Traverses a tree starting at the given root #GNode. It calls the given function for each node visited. The traversal can be halted at any point by returning %TRUE from @func. +@func must not do anything that would modify the structure of the tree. @@ -29839,7 +30316,8 @@ Gets a named field from the objects table of associations (see g_object_set_data - the data if found, or %NULL if no such data exists. + the data if found, +or %NULL if no such data exists. @@ -29923,6 +30401,37 @@ name/return location pairs, followed by %NULL + + +Gets @n_properties properties for an @object. +Obtained properties will be set to @values. All properties must be valid. +Warnings will be emitted and undefined behaviour may result if invalid +properties are passed in. + +Since: 2.54 + + + + + a #GObject + + + + the number of properties + + + + the names of each property to get + + + + the values of each property to get + + + + + + Find the #GParamSpec with the given name for an @@ -30092,6 +30601,42 @@ name/value pairs, followed by %NULL + + +Creates a new instance of a #GObject subtype and sets its properties using +the provided arrays. Both arrays must have exactly @n_properties elements, +and the names and values correspond by index. + +Construction parameters (see %G_PARAM_CONSTRUCT, %G_PARAM_CONSTRUCT_ONLY) +which are not explicitly specified are set to their default values. + +Since: 2.54 + + + + + the object type to instantiate + + + + the number of properties + + + + the names of each property to be set + + + + the values of each property to be set + + + + a new instance of +@object_type + + + + Creates a new instance of a #GObject subtype and sets its properties. @@ -30099,6 +30644,8 @@ Creates a new instance of a #GObject subtype and sets its properties. Construction parameters (see #G_PARAM_CONSTRUCT, #G_PARAM_CONSTRUCT_ONLY) which are not explicitly specified are set to their default values. +Deprecated: 2.54: Use g_object_new_with_properties() instead. +deprecated. See #GParameter for more information. @@ -30117,6 +30664,7 @@ which are not explicitly specified are set to their default values. a new instance of @object_type + @@ -30208,6 +30756,11 @@ Since: 2.26 Increases the reference count of @object. +Since GLib 2.56, if `GLIB_VERSION_MAX_ALLOWED` is 2.56 or greater, the type +of @object will be propagated to the return type (using the GCC typeof() +extension), so any casting the caller needs to do on the return type must be +explicit. + @@ -30231,6 +30784,9 @@ reference by clearing the floating flag while leaving the reference count unchanged. If the object is not floating, then this call adds a new normal reference increasing the reference count by one. +Since GLib 2.56, the type of @object will be propagated to the return type +under the same conditions as for g_object_ref(). + Since: 2.10 @@ -30600,6 +31156,37 @@ name/value pairs, followed by %NULL + + +Sets @n_properties properties for an @object. +Properties to be set will be taken from @values. All properties must be +valid. Warnings will be emitted and undefined behaviour may result if invalid +properties are passed in. + +Since: 2.54 + + + + + a #GObject + + + + the number of properties + + + + the names of each property to be set + + + + the values of each property to be set + + + + + + Remove a specified datum from the object's data associations, @@ -30617,7 +31204,8 @@ without invoking the association's destroy handler. - the data if found, or %NULL if no such data exists. + the data if found, or %NULL +if no such data exists. @@ -31224,7 +31812,7 @@ Since: 2.44 - a #GoptionContext + a #GOptionContext @@ -31514,7 +32102,7 @@ Since: 2.44 - a #GoptionContext + a #GOptionContext @@ -32130,7 +32718,7 @@ Get the short description of a #GParamSpec. Gets the default value of @pspec as a pointer to a #GValue. -The #GValue will remain value for the life of @pspec. +The #GValue will remain valid for the life of @pspec. Since: 2.38 @@ -33430,7 +34018,7 @@ current directory introduce vagueness. This function interprets as an absolute file name one that either begins with a directory separator such as "\Users\tml" or begins with the root on a drive, for example "C:\Windows". The first case also includes UNC paths -such as "\\myserver\docs\foo". In all cases, either slashes or +such as "\\\\myserver\docs\foo". In all cases, either slashes or backslashes are accepted. Note that a file name relative to the current drive root does not @@ -33716,9 +34304,9 @@ directly if you need to block until a file descriptor is ready, but don't want to run the full main loop. Each element of @fds is a #GPollFD describing a single file -descriptor to poll. The %fd field indicates the file descriptor, -and the %events field indicates the events to poll for. On return, -the %revents fields will be filled with the events that actually +descriptor to poll. The @fd field indicates the file descriptor, +and the @events field indicates the events to poll for. On return, +the @revents fields will be filled with the events that actually occurred. On POSIX systems, the file descriptors in @fds can be any sort of @@ -33744,7 +34332,7 @@ Since: 2.20 - the number of entries in @fds whose %revents fields + the number of entries in @fds whose @revents fields were filled in, or 0 if the operation timed out, or -1 on error or if the call was interrupted. @@ -33842,6 +34430,8 @@ As with the standard printf(), this does not automatically append a trailing new-line character to the message, so typically @format should end with its own new-line character. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.2 @@ -34042,9 +34632,82 @@ in size automatically if necessary. + + +Checks whether @needle exists in @haystack. If the element is found, %TRUE is +returned and the element’s index is returned in @index_ (if non-%NULL). +Otherwise, %FALSE is returned and @index_ is undefined. If @needle exists +multiple times in @haystack, the index of the first instance is returned. + +This does pointer comparisons only. If you want to use more complex equality +checks, such as string comparisons, use g_ptr_array_find_with_equal_func(). + +Since: 2.54 + + + + + pointer array to be searched + + + + pointer to look for + + + + return location for the index of +the element, if found + + + + %TRUE if @needle is one of the elements of @haystack + + + + + +Checks whether @needle exists in @haystack, using the given @equal_func. +If the element is found, %TRUE is returned and the element’s index is +returned in @index_ (if non-%NULL). Otherwise, %FALSE is returned and @index_ +is undefined. If @needle exists multiple times in @haystack, the index of +the first instance is returned. + +@equal_func is called with the element from the array as its first parameter, +and @needle as its second parameter. If @equal_func is %NULL, pointer +equality is used. + +Since: 2.54 + + + + + pointer array to be searched + + + + pointer to look for + + + + the function to call for each element, which should +return %TRUE when the desired element is found; or %NULL to use pointer +equality + + + + return location for the index of +the element, if found + + + + %TRUE if @needle is one of the elements of @haystack + + + -Calls a function for each element of a #GPtrArray. +Calls a function for each element of a #GPtrArray. @func must not +add elements to or remove elements from the array. Since: 2.4 @@ -34079,6 +34742,10 @@ If array contents point to dynamically-allocated memory, they should be freed separately if @free_seg is %TRUE and no #GDestroyNotify function has been set for @array. +This function is not thread-safe. If using a #GPtrArray from multiple +threads, use only the atomic g_ptr_array_ref() and g_ptr_array_unref() +functions. + @@ -34480,7 +35147,7 @@ This is guaranteed to be a stable sort since version 2.32. Atomically decrements the reference count of @array by one. If the reference count drops to 0, the effect is the same as calling g_ptr_array_free() with @free_segment set to %TRUE. This function -is MT-safe and may be called from any thread. +is thread-safe and may be called from any thread. Since: 2.22 @@ -34726,6 +35393,9 @@ when the desired element is found Calls @func for each element in the queue passing @user_data to the function. +It is safe for @func to remove the element from @queue, but it must +not modify any part of the queue after that element. + Since: 2.4 @@ -34770,6 +35440,9 @@ either use g_queue_free_full() or free them manually first. Convenience method, which frees all the memory used by a #GQueue, and calls the specified destroy function on every element's data. +@free_func should not modify the queue (eg, by removing the freed +element from it). + Since: 2.32 @@ -36580,7 +37253,7 @@ number-th captured subexpression of the match, '\g<name>' refers to the captured subexpression with the given name. '\0' refers to the complete match, but '\0' followed by a number is the octal representation of a character. To include a literal '\' in the -replacement, write '\\'. +replacement, write '\\\\'. There are also escapes that changes the case of the following text: @@ -37294,9 +37967,20 @@ To make this undefined behaviour visible, if @expr evaluates to %FALSE, the result is usually that a critical message is logged and the current function returns. -If G_DISABLE_CHECKS is defined then the check is not performed. You +If `G_DISABLE_CHECKS` is defined then the check is not performed. You should therefore not depend on any side effects of @expr. +To debug failure of a g_return_if_fail() check, run the code under a debugger +with `G_DEBUG=fatal-criticals` or `G_DEBUG=fatal-warnings` defined in the +environment (see [Running GLib Applications](glib-running.html)): + +|[ +G_DEBUG=fatal-warnings gdb ./my-program +]| + +Any unrelated failures can be skipped over in +[gdb](https://www.gnu.org/software/gdb/) using the `continue` command. + @@ -37333,6 +38017,8 @@ should therefore not depend on any side effects of @expr. Logs a critical message and returns from the current function. This can only be used in functions which do not return a value. +See g_return_if_fail() for guidance on how to debug failure of this check. + @@ -37354,9 +38040,11 @@ To make this undefined behaviour visible, if @expr evaluates to %FALSE, the result is usually that a critical message is logged and @val is returned from the current function. -If G_DISABLE_CHECKS is defined then the check is not performed. You +If `G_DISABLE_CHECKS` is defined then the check is not performed. You should therefore not depend on any side effects of @expr. +See g_return_if_fail() for guidance on how to debug failure of this check. + @@ -37376,6 +38064,8 @@ if the expression is not true Logs a critical message and returns @val. +See g_return_if_fail() for guidance on how to debug failure of this check. + @@ -37478,7 +38168,8 @@ the write lock on @rw_lock or blocks waiting for it, the current thread will block. Read locks can be taken recursively. It is implementation-defined how many threads are allowed to -hold read locks on the same lock simultaneously. +hold read locks on the same lock simultaneously. If the limit is hit, +or if a deadlock is detected, a critical warning will be emitted. Since: 2.32 @@ -38182,7 +38873,7 @@ Since: 2.14 Calls @func for each item in the sequence passing @user_data -to the function. +to the function. @func must not modify the sequence itself. Since: 2.14 @@ -38207,7 +38898,8 @@ Since: 2.14 Calls @func for each item in the range (@begin, @end) passing -@user_data to the function. +@user_data to the function. @func must not modify the sequence +itself. Since: 2.14 @@ -39291,6 +39983,12 @@ assign to it, or %NULL to clear the pointer Sets the name of the program. This name should not be localized, in contrast to g_set_application_name(). +If you are using #GApplication the program name is set in +g_application_run(). In case of GDK or GTK+ it is set in +gdk_init(), which is called by gtk_init() and the +#GtkApplication::startup handler. The program name is found by +taking the last component of @argv[0]. + Note that for thread-safety reasons this function can only be called once. @@ -39374,7 +40072,8 @@ Since: 2.4 - the environment variable to set, must not contain '='. + the environment variable to set, must not +contain '='. @@ -39415,8 +40114,8 @@ domain. Free the returned vector with g_strfreev(). - return -location for array of args + +return location for array of args @@ -39676,7 +40375,7 @@ details on how to handle the return value and memory management of @data. - the handler id (always greater than 0 for successful connections) + the handler ID, of type #gulong (always greater than 0 for successful connections) @@ -39706,7 +40405,7 @@ The handler will be called after the default handler of the signal. - the handler id (always greater than 0 for successful connections) + the handler ID, of type #gulong (always greater than 0 for successful connections) @@ -39735,7 +40434,7 @@ default handler of the signal. - the handler id (always greater than 0 for successful connections) + the handler ID (always greater than 0 for successful connections) @@ -39768,7 +40467,7 @@ default handler of the signal. - the handler id (always greater than 0 for successful connections) + the handler ID (always greater than 0 for successful connections) @@ -39808,7 +40507,7 @@ used. Specify @connect_flags if you need `..._after()` or - the handler id (always greater than 0 for successful connections) + the handler ID (always greater than 0 for successful connections) @@ -39901,7 +40600,7 @@ g_signal_connect (button, "clicked", - the handler ID (always greater than 0 for successful connections) + the handler ID, of type #gulong (always greater than 0 for successful connections) @@ -40139,7 +40838,7 @@ and/or @data the handler has to match. -Returns whether @handler_id is the id of a handler connected to @instance. +Returns whether @handler_id is the ID of a handler connected to @instance. @@ -40149,7 +40848,7 @@ Returns whether @handler_id is the id of a handler connected to @instance. - the handler id. + the handler ID. @@ -41059,7 +41758,7 @@ structure which is to be invoked by the new closure - a new #GCClosure + a floating reference to a new #GCClosure @@ -41126,7 +41825,7 @@ Since: 2.48 Allocates a block of memory from the slice allocator. -The block adress handed out can be expected to be aligned +The block address handed out can be expected to be aligned to at least 1 * sizeof (void*), though in general slices are 2 * sizeof (void*) bytes aligned, if a malloc() fallback implementation is used instead, @@ -41639,6 +42338,9 @@ It should return 0 when the desired element is found Calls a function for each element of a #GSList. +It is safe for @func to remove the element from @list, but it must +not modify any part of the list after that element. + @@ -41708,6 +42410,9 @@ It is usually used after g_slist_remove_link(). Convenience method, which frees all the memory used by a #GSList, and calls the specified destroy function on every element's data. +@free_func must not modify the list (eg, by removing the freed +element from it). + Since: 2.28 @@ -41899,6 +42604,8 @@ check @list against %NULL. A convenience macro to get the next element in a #GSList. +Note that it is considered perfectly acceptable to access +@slist->next directly. @@ -42098,7 +42805,8 @@ Reverses a #GSList. -Sorts a #GSList using the given comparison function. +Sorts a #GSList using the given comparison function. The algorithm +used is a stable sort. @@ -42558,6 +43266,12 @@ return FALSE; } ]| +Calls to this function from a thread other than the one acquired by the +#GMainContext the #GSource is attached to are typically redundant, as the +source could be destroyed immediately after this function returns. However, +once a source is destroyed it cannot be un-destroyed, so this function can be +used for opportunistic checks from any thread. + Since: 2.12 @@ -42683,17 +43397,15 @@ Increases the reference count on a source by one. -Removes the source with the given id from the default main context. +Removes the source with the given ID from the default main context. You must +use g_source_destroy() for sources added to a non-default main context. -The id of a #GSource is given by g_source_get_id(), or will be +The ID of a #GSource is given by g_source_get_id(), or will be returned by the functions g_source_attach(), g_idle_add(), g_idle_add_full(), g_timeout_add(), g_timeout_add_full(), g_child_watch_add(), g_child_watch_add_full(), g_io_add_watch(), and g_io_add_watch_full(). -See also g_source_destroy(). You must use g_source_destroy() for sources -added to a non-default main context. - It is a programmer error to attempt to remove a non-existent source. More specifically: source IDs can be reissued after a source has been @@ -43095,9 +43807,12 @@ so yourself, from the source dispatch function. Note that if you have a pair of sources where the ready time of one suggests that it will be delivered first but the priority for the other suggests that it would be delivered first, and the ready time -for both sources is reached during the same main context iteration +for both sources is reached during the same main context iteration, then the order of dispatch is undefined. +It is a no-op to call this function on a #GSource which has already been +destroyed with g_source_destroy(). + This API is only intended to be used by implementations of #GSource. Do not call this API on a #GSource that you did not create. @@ -43164,10 +43879,10 @@ simply calls the g_spawn_async_with_pipes() without any pipes. You should call g_spawn_close_pid() on the returned child process reference when you don't need it any more. -If you are writing a GTK+ application, and the program you are -spawning is a graphical application, too, then you may want to -use gdk_spawn_on_screen() instead to ensure that the spawned program -opens its windows on the right screen. +If you are writing a GTK+ application, and the program you are spawning is a +graphical application too, then to ensure that the spawned program opens its +windows on the right screen, you may want to use #GdkAppLaunchContext, +#GAppLaunchContext, or set the %DISPLAY environment variable. Note that the returned @child_pid on Windows is a handle to the child process and not its identifier. Process handles and process identifiers @@ -43177,15 +43892,18 @@ are different concepts on Windows. - child's current working directory, or %NULL to inherit parent's + child's current working +directory, or %NULL to inherit parent's - child's argument vector + +child's argument vector - child's environment, or %NULL to inherit parent's + +child's environment, or %NULL to inherit parent's @@ -43273,10 +43991,11 @@ If @envp is %NULL, the child inherits its parent's environment. @flags should be the bitwise OR of any flags you want to affect the function's behaviour. The %G_SPAWN_DO_NOT_REAP_CHILD means that the -child will not automatically be reaped; you must use a child watch to -be notified about the death of the child process. Eventually you must -call g_spawn_close_pid() on the @child_pid, in order to free -resources which may be associated with the child process. (On Unix, +child will not automatically be reaped; you must use a child watch +(g_child_watch_add()) to be notified about the death of the child process, +otherwise it will stay around as a zombie process until this process exits. +Eventually you must call g_spawn_close_pid() on the @child_pid, in order to +free resources which may be associated with the child process. (On Unix, using a child watch is equivalent to calling waitpid() or handling the %SIGCHLD signal manually. On Windows, calling g_spawn_close_pid() is equivalent to calling CloseHandle() on the process handle returned @@ -43360,24 +44079,28 @@ and @standard_error will not be filled with valid values. If @child_pid is not %NULL and an error does not occur then the returned process reference must be closed using g_spawn_close_pid(). -If you are writing a GTK+ application, and the program you -are spawning is a graphical application, too, then you may -want to use gdk_spawn_on_screen_with_pipes() instead to ensure that -the spawned program opens its windows on the right screen. +If you are writing a GTK+ application, and the program you are spawning is a +graphical application too, then to ensure that the spawned program opens its +windows on the right screen, you may want to use #GdkAppLaunchContext, +#GAppLaunchContext, or set the %DISPLAY environment variable. - child's current working directory, or %NULL to inherit parent's, in the GLib file name encoding + child's current working +directory, or %NULL to inherit parent's, in the GLib file name encoding - child's argument vector, in the GLib file name encoding + child's argument +vector, in the GLib file name encoding - child's environment, or %NULL to inherit parent's, in the GLib file name encoding + +child's environment, or %NULL to inherit parent's, in the GLib file +name encoding @@ -43549,7 +44272,7 @@ separator. You need to enclose such paths with single quotes, like - a command line + a command line @@ -43585,7 +44308,8 @@ If @exit_status is non-%NULL, the platform-specific exit status of the child is stored there; see the documentation of g_spawn_check_exit_status() for how to use and interpret this. Note that it is invalid to pass %G_SPAWN_DO_NOT_REAP_CHILD in -@flags. +@flags, and on POSIX platforms, the same restrictions as for +g_child_watch_source_new() apply. If an error occurs, no data is returned in @standard_output, @standard_error, or @exit_status. @@ -43598,15 +44322,18 @@ how these functions work on Windows. - child's current working directory, or %NULL to inherit parent's + child's current working +directory, or %NULL to inherit parent's - child's argument vector + +child's argument vector - child's environment, or %NULL to inherit parent's + +child's environment, or %NULL to inherit parent's @@ -43650,6 +44377,8 @@ positional parameters, as specified in the Single Unix Specification. Note that it is usually better to use g_snprintf(), to avoid the risk of buffer overflow. +`glib/gprintf.h` must be explicitly included in order to use this function. + See also g_strdup_printf(). Since: 2.2 @@ -44456,11 +45185,11 @@ your corpus and build an index on the returned folded tokens, then call g_str_tokenize_and_fold() on the search term and perform lookups into that index. -As some examples, searching for "fred" would match the potential hit -"Smith, Fred" and also "Frédéric". Searching for "Fréd" would match -"Frédéric" but not "Frederic" (due to the one-directional nature of -accent matching). Searching "fo" would match "Foo" and "Bar Foo -Baz", but not "SFO" (because no word as "fo" as a prefix). +As some examples, searching for ‘fred’ would match the potential hit +‘Smith, Fred’ and also ‘Frédéric’. Searching for ‘Fréd’ would match +‘Frédéric’ but not ‘Frederic’ (due to the one-directional nature of +accent matching). Searching ‘fo’ would match ‘Foo’ and ‘Bar Foo +Baz’, but not ‘SFO’ (because no word has ‘fo’ as a prefix). Since: 2.40 @@ -44908,7 +45637,17 @@ the lifetime of the process. Note that the string may be translated according to the current locale. -The value of %errno will not be changed by this function. +The value of %errno will not be changed by this function. However, it may +be changed by intermediate function calls, so you should save its value +as soon as the call returns: +|[ +int saved_errno; + +ret = read (blah); +saved_errno = errno; + +g_strerror (saved_errno); +]| @@ -47072,6 +47811,7 @@ runs using random numbers. - `--verbose`: Run tests verbosely. - `-q`, `--quiet`: Run tests quietly. - `-p PATH`: Execute all tests matching the given path. +- `-s PATH`: Skip all tests matching the given path. This can also be used to force a test to run that would otherwise be skipped (ie, a test whose name contains "/subprocess"). - `-m {perf|slow|thorough|quick|undefined|no-undefined}`: Execute tests according to these test modes: @@ -47310,7 +48050,7 @@ Returns %TRUE if tests are run in performance mode. This function enqueus a callback @destroy_func to be executed during the next test case teardown phase. This is most useful -to auto destruct allocted test resources at the end of a test run. +to auto destruct allocated test resources at the end of a test run. Resources are released in reverse queue order, that means enqueueing callback A before callback B will cause B() to be called before A() during teardown. @@ -47495,8 +48235,9 @@ Since: 2.16 Runs all tests under the toplevel suite which can be retrieved with g_test_get_root(). Similar to g_test_run_suite(), the test cases to be run are filtered according to test path arguments -(`-p testpath`) as parsed by g_test_init(). g_test_run_suite() -or g_test_run() may only be called once in a program. +(`-p testpath` and `-s testpath`) as parsed by g_test_init(). +g_test_run_suite() or g_test_run() may only be called once in a +program. In general, the tests and sub-suites within each suite are run in the order in which they are defined. However, note that prior to @@ -47538,9 +48279,9 @@ Since: 2.16 Execute the tests within @suite and all nested #GTestSuites. The test suites to be executed are filtered according to -test path arguments (`-p testpath`) as parsed by g_test_init(). -See the g_test_run() documentation for more information on the -order that tests are run in. +test path arguments (`-p testpath` and `-s testpath`) as parsed by +g_test_init(). See the g_test_run() documentation for more +information on the order that tests are run in. g_test_run_suite() or g_test_run() may only be called once in a program. @@ -48895,6 +49636,12 @@ Both of these documents are profiles of ISO 8601. Use g_date_time_format() or g_strdup_printf() if a different variation of ISO 8601 format is required. +If @time_ represents a date which is too large to fit into a `struct tm`, +%NULL will be returned. This is platform dependent, but it is safe to assume +years up to 3000 are supported. The return value of g_time_val_to_iso8601() +has been nullable since GLib 2.54; before then, GLib would crash under the +same conditions. + Since: 2.12 @@ -48904,7 +49651,8 @@ Since: 2.12 - a newly allocated string containing an ISO 8601 date + a newly allocated string containing an ISO 8601 date, +or %NULL if @time_ was too large @@ -52945,7 +53693,7 @@ Since: 2.36 - a #GPollFDFunc + a #GUnixFDSourceFunc @@ -53157,7 +53905,7 @@ the range between #G_PRIORITY_DEFAULT and #G_PRIORITY_HIGH. Create a #GSource that will be dispatched upon delivery of the UNIX signal @signum. In GLib versions before 2.36, only `SIGHUP`, `SIGINT`, `SIGTERM` can be monitored. In GLib 2.36, `SIGUSR1` and `SIGUSR2` -were added. +were added. In GLib 2.54, `SIGWINCH` was added. Note that unlike the UNIX default, all sources which have created a watch will be dispatched, regardless of which underlying thread @@ -53244,7 +53992,8 @@ Since: 2.4 - the environment variable to remove, must not contain '=' + the environment variable to remove, must +not contain '=' @@ -53639,6 +54388,11 @@ Finds the start of the next UTF-8 character in the string after @p. is made to see if the character found is actually valid other than it starts with an appropriate byte. +If @end is %NULL, the return value will never be %NULL: if the end of the +string is reached, a pointer to the terminating nul byte is returned. If +@end is non-%NULL, the return value will be %NULL if the end of the string +is reached. + @@ -53652,7 +54406,8 @@ or %NULL to indicate that the string is nul-terminated - a pointer to the found character or %NULL + a pointer to the found character or %NULL if @end is +set and is reached @@ -53710,6 +54465,10 @@ This function checks for incomplete characters, for invalid characters such as characters that are out of the range of Unicode, and for overlong encodings of valid characters. +Note that g_utf8_get_char_validated() returns (gunichar)-2 if +@max_len is positive and any of the bytes in the first UTF-8 character +sequence are nul. + @@ -53718,8 +54477,7 @@ overlong encodings of valid characters. - the maximum number of bytes to read, or -1, for no maximum or -if @p is nul-terminated + the maximum number of bytes to read, or -1 if @p is nul-terminated @@ -53731,6 +54489,37 @@ Unicode character, returns (gunichar)-1. + + +If the provided string is valid UTF-8, return a copy of it. If not, +return a copy in which bytes that could not be interpreted as valid Unicode +are replaced with the Unicode replacement character (U+FFFD). + +For example, this is an appropriate function to use if you have received +a string that was incorrectly declared to be UTF-8, and you need a valid +UTF-8 version of it that can be logged or displayed to the user, with the +assumption that it is close enough to ASCII or UTF-8 to be mostly +readable as-is. + +Since: 2.52 + + + + + string to coerce into UTF-8 + + + + the maximum length of @str to use, in bytes. If @len < 0, +then the string is nul-terminated. + + + + a valid UTF-8 string whose content resembles @str + + + + Skips to the next character in a UTF-8 string. The string must be @@ -54278,6 +55067,43 @@ Since: 2.18 + + +Parses the string @str and verify if it is a UUID. + +The function accepts the following syntax: + +- simple forms (e.g. `f81d4fae-7dec-11d0-a765-00a0c91e6bf6`) + +Note that hyphens are required within the UUID string itself, +as per the aforementioned RFC. + +Since: 2.52 + + + + + a string representing a UUID + + + + %TRUE if @str is a valid UUID, %FALSE otherwise. + + + + + +Generates a random UUID (RFC 4122 version 4) as a string. + +Since: 2.52 + + + + + A string that should be freed with g_free(). + + + Insert a copy of @value as last element of @value_array. If @value is @@ -54600,7 +55426,8 @@ Get a copy the contents of a %G_TYPE_STRING #GValue. -Get the contents of a variant #GValue, increasing its refcount. +Get the contents of a variant #GValue, increasing its refcount. The returned +#GVariant is never floating. Since: 2.26 @@ -54611,8 +55438,8 @@ Since: 2.26 - variant contents of @value, should be unrefed using -g_variant_unref() when no longer needed + variant contents of @value (may be %NULL); +should be unreffed using g_variant_unref() when no longer needed @@ -54974,7 +55801,7 @@ Since: 2.26 - variant contents of @value + variant contents of @value (may be %NULL) @@ -55969,7 +56796,7 @@ It typically only makes sense to do this on a stack-allocated #GVariantBuilder if you want to abort building the value part-way through. This function need not be called if you call g_variant_builder_end() and it also doesn't need to be called on -builders allocated with g_variant_builder_new (see +builders allocated with g_variant_builder_new() (see g_variant_builder_unref() for that). This function leaves the #GVariantBuilder structure set to all-zeros. @@ -56121,12 +56948,42 @@ Since: 2.24 Opens a subcontainer inside the given @builder. When done adding -items to the subcontainer, g_variant_builder_close() must be called. +items to the subcontainer, g_variant_builder_close() must be called. @type +is the type of the container: so to build a tuple of several values, @type +must include the tuple itself. It is an error to call this function in any way that would cause an inconsistent value to be constructed (ie: adding too many values or a value of an incorrect type). +Example of building a nested variant: +|[<!-- language="C" --> +GVariantBuilder builder; +guint32 some_number = get_number (); +g_autoptr (GHashTable) some_dict = get_dict (); +GHashTableIter iter; +const gchar *key; +const GVariant *value; +g_autoptr (GVariant) output = NULL; + +g_variant_builder_init (&builder, G_VARIANT_TYPE ("(ua{sv})")); +g_variant_builder_add (&builder, "u", some_number); +g_variant_builder_open (&builder, G_VARIANT_TYPE ("a{sv}")); + +g_hash_table_iter_init (&iter, some_dict); +while (g_hash_table_iter_next (&iter, (gpointer *) &key, (gpointer *) &value)) +{ +g_variant_builder_open (&builder, G_VARIANT_TYPE ("{sv}")); +g_variant_builder_add (&builder, "s", key); +g_variant_builder_add (&builder, "v", value); +g_variant_builder_close (&builder); +} + +g_variant_builder_close (&builder); + +output = g_variant_builder_end (&builder); +]| + Since: 2.24 @@ -56136,7 +56993,7 @@ Since: 2.24 - a #GVariantType + the #GVariantType of the container @@ -57143,11 +58000,11 @@ the appropriate type: - %G_VARIANT_TYPE_DOUBLE: #gdouble For example, if calling this function for an array of 32-bit integers, -you might say sizeof(gint32). This value isn't used except for the purpose +you might say `sizeof(gint32)`. This value isn't used except for the purpose of a double-check that the form of the serialised data matches the caller's expectation. -@n_elements, which must be non-%NULL is set equal to the number of +@n_elements, which must be non-%NULL, is set equal to the number of items in the array. Since: 2.24 @@ -57299,6 +58156,13 @@ It makes sense to call this function if you've received #GVariant data from untrusted sources and you want to ensure your serialised output is definitely in normal form. +If @value is already in normal form, a new reference will be returned +(which will be floating if @value is floating). If it is not in normal form, +the newly created #GVariant will be returned with a single non-floating +reference. Typically, g_variant_take_ref() should be called on the return +value from this function to guarantee ownership of a single non-floating +reference to it. + Since: 2.24 @@ -58436,10 +59300,10 @@ Since: 2.24 -Provides access to the serialised data for an array of fixed-sized -items. +Constructs a new array #GVariant instance, where the elements are +of @element_type type. -@value must be an array with fixed-sized elements. Numeric types are +@elements must be an array with fixed-sized elements. Numeric types are fixed-size as are tuples containing only other fixed-sized types. @element_size must be the size of a single element in the array. @@ -58448,8 +59312,7 @@ you might say sizeof(gint32). This value isn't used except for the purpose of a double-check that the form of the serialised data matches the caller's expectation. -@n_elements, which must be non-%NULL is set equal to the number of -items in the array. +@n_elements must be the length of the @elements array. Since: 2.32 @@ -59040,7 +59903,7 @@ pointing to the argument following the last. Note that the arguments in @app must be of the correct width for their types specified in @format_string when collected into the #va_list. -See the [GVariant varargs documentation][gvariant-varargs. +See the [GVariant varargs documentation][gvariant-varargs]. These two generalisations allow mixing of multiple calls to g_variant_new_va() and g_variant_get_va() within a single actual @@ -60137,6 +61000,8 @@ This function is similar to g_vsprintf(), except that it allocates a string to hold the output, instead of putting the output in a buffer you allocate in advance. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.4 @@ -60165,6 +61030,8 @@ Since: 2.4 An implementation of the standard fprintf() function which supports positional parameters, as specified in the Single Unix Specification. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.2 @@ -60193,6 +61060,8 @@ Since: 2.2 An implementation of the standard vprintf() function which supports positional parameters, as specified in the Single Unix Specification. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.2 @@ -60264,6 +61133,8 @@ was large enough. An implementation of the standard vsprintf() function which supports positional parameters, as specified in the Single Unix Specification. +`glib/gprintf.h` must be explicitly included in order to use this function. + Since: 2.2 @@ -60446,7 +61317,8 @@ Since: 2.16 -A convenience function/macro to log a warning message. +A convenience function/macro to log a warning message. The message should +typically *not* be translated to the user's language. This is not intended for end user error reporting. Use of #GError is preferred for that instead, as it allows calling functions to perform actions @@ -60454,7 +61326,14 @@ conditional on the type of error. You can make warnings fatal at runtime by setting the `G_DEBUG` environment variable (see -[Running GLib Applications](glib-running.html)). +[Running GLib Applications](glib-running.html)): + +|[ +G_DEBUG=fatal-warnings gdb ./my-program +]| + +Any unrelated failures can be skipped over in +[gdb](https://www.gnu.org/software/gdb/) using the `continue` command. If g_log_default_handler() is used as the log handler function, a newline character will automatically be appended to @..., and diff --git a/glib/src/glib_docs_override.xml b/glib/src/glib_docs_override.xml index f9eba41..a64a435 100644 --- a/glib/src/glib_docs_override.xml +++ b/glib/src/glib_docs_override.xml @@ -10,6 +10,7 @@ + @@ -18,6 +19,9 @@ + + + diff --git a/glib/src/glib_enums.defs b/glib/src/glib_enums.defs index d9979c3..361fd9b 100644 --- a/glib/src/glib_enums.defs +++ b/glib/src/glib_enums.defs @@ -53,7 +53,8 @@ ;; G_CHECKSUM_MD5, ;; G_CHECKSUM_SHA1, ;; G_CHECKSUM_SHA256, -;; G_CHECKSUM_SHA512 +;; G_CHECKSUM_SHA512, +;; G_CHECKSUM_SHA384 ;; } GChecksumType; (define-enum-extended ChecksumType @@ -64,6 +65,7 @@ '("sha1" "G_CHECKSUM_SHA1" "1") '("sha256" "G_CHECKSUM_SHA256" "2") '("sha512" "G_CHECKSUM_SHA512" "3") + '("sha384" "G_CHECKSUM_SHA384" "4") ) ) @@ -911,7 +913,7 @@ '("newline-cr" "G_REGEX_NEWLINE_CR" "1 << 20") '("newline-lf" "G_REGEX_NEWLINE_LF" "1 << 21") '("newline-crlf" "G_REGEX_NEWLINE_CRLF" "0x300000") - '("newline-anycrlf" "G_REGEX_NEWLINE_ANYCRLF" "1048576 | 1 << 22") + '("newline-anycrlf" "G_REGEX_NEWLINE_ANYCRLF" "0x500000") '("bsr-anycrlf" "G_REGEX_BSR_ANYCRLF" "1 << 23") '("javascript-compat" "G_REGEX_JAVASCRIPT_COMPAT" "1 << 25") ) @@ -1233,6 +1235,22 @@ ) ) +;; Original typedef: +;; typedef enum +;; { +;; G_NUMBER_PARSER_ERROR_INVALID, +;; G_NUMBER_PARSER_ERROR_OUT_OF_BOUNDS, +;; } GNumberParserError; + +(define-enum-extended NumberParserError + (in-module "G") + (c-name "GNumberParserError") + (values + '("invalid" "G_NUMBER_PARSER_ERROR_INVALID" "0") + '("out-of-bounds" "G_NUMBER_PARSER_ERROR_OUT_OF_BOUNDS" "1") + ) +) + ;; From gtestutils.h ;; Original typedef: @@ -1271,6 +1289,25 @@ ;; Original typedef: ;; typedef enum { +;; G_TEST_RUN_SUCCESS, +;; G_TEST_RUN_SKIPPED, +;; G_TEST_RUN_FAILURE, +;; G_TEST_RUN_INCOMPLETE +;; } GTestResult; + +(define-enum-extended TestResult + (in-module "G") + (c-name "GTestResult") + (values + '("success" "G_TEST_RUN_SUCCESS" "0") + '("skipped" "G_TEST_RUN_SKIPPED" "1") + '("failure" "G_TEST_RUN_FAILURE" "2") + '("incomplete" "G_TEST_RUN_INCOMPLETE" "3") + ) +) + +;; Original typedef: +;; typedef enum { ;; G_TEST_LOG_NONE, ;; G_TEST_LOG_ERROR, /* s:msg */ ;; G_TEST_LOG_START_BINARY, /* s:binaryname s:seed */ @@ -1490,7 +1527,10 @@ ;; G_UNICODE_BREAK_CLOSE_PARANTHESIS, ;; G_UNICODE_BREAK_CONDITIONAL_JAPANESE_STARTER, ;; G_UNICODE_BREAK_HEBREW_LETTER, -;; G_UNICODE_BREAK_REGIONAL_INDICATOR +;; G_UNICODE_BREAK_REGIONAL_INDICATOR, +;; G_UNICODE_BREAK_EMOJI_BASE, +;; G_UNICODE_BREAK_EMOJI_MODIFIER, +;; G_UNICODE_BREAK_ZERO_WIDTH_JOINER ;; } GUnicodeBreakType; (define-enum-extended UnicodeBreakType @@ -1537,6 +1577,9 @@ '("conditional-japanese-starter" "G_UNICODE_BREAK_CONDITIONAL_JAPANESE_STARTER" "37") '("hebrew-letter" "G_UNICODE_BREAK_HEBREW_LETTER" "38") '("regional-indicator" "G_UNICODE_BREAK_REGIONAL_INDICATOR" "39") + '("emoji-base" "G_UNICODE_BREAK_EMOJI_BASE" "40") + '("emoji-modifier" "G_UNICODE_BREAK_EMOJI_MODIFIER" "41") + '("zero-width-joiner" "G_UNICODE_BREAK_ZERO_WIDTH_JOINER" "42") ) ) @@ -1693,7 +1736,21 @@ ;; G_UNICODE_SCRIPT_HATRAN, /* Hatr */ ;; G_UNICODE_SCRIPT_MULTANI, /* Mult */ ;; G_UNICODE_SCRIPT_OLD_HUNGARIAN, /* Hung */ -;; G_UNICODE_SCRIPT_SIGNWRITING /* Sgnw */ +;; G_UNICODE_SCRIPT_SIGNWRITING, /* Sgnw */ +;; +;; /* Unicode 9.0 additions */ +;; G_UNICODE_SCRIPT_ADLAM, /* Adlm */ +;; G_UNICODE_SCRIPT_BHAIKSUKI, /* Bhks */ +;; G_UNICODE_SCRIPT_MARCHEN, /* Marc */ +;; G_UNICODE_SCRIPT_NEWA, /* Newa */ +;; G_UNICODE_SCRIPT_OSAGE, /* Osge */ +;; G_UNICODE_SCRIPT_TANGUT, /* Tang */ +;; +;; /* Unicode 10.0 additions */ +;; G_UNICODE_SCRIPT_MASARAM_GONDI, /* Gonm */ +;; G_UNICODE_SCRIPT_NUSHU, /* Nshu */ +;; G_UNICODE_SCRIPT_SOYOMBO, /* Soyo */ +;; G_UNICODE_SCRIPT_ZANABAZAR_SQUARE /* Zanb */ ;; } GUnicodeScript; (define-enum-extended UnicodeScript @@ -1833,6 +1890,16 @@ '("multani" "G_UNICODE_SCRIPT_MULTANI" "129") '("old-hungarian" "G_UNICODE_SCRIPT_OLD_HUNGARIAN" "130") '("signwriting" "G_UNICODE_SCRIPT_SIGNWRITING" "131") + '("adlam" "G_UNICODE_SCRIPT_ADLAM" "132") + '("bhaiksuki" "G_UNICODE_SCRIPT_BHAIKSUKI" "133") + '("marchen" "G_UNICODE_SCRIPT_MARCHEN" "134") + '("newa" "G_UNICODE_SCRIPT_NEWA" "135") + '("osage" "G_UNICODE_SCRIPT_OSAGE" "136") + '("tangut" "G_UNICODE_SCRIPT_TANGUT" "137") + '("masaram-gondi" "G_UNICODE_SCRIPT_MASARAM_GONDI" "138") + '("nushu" "G_UNICODE_SCRIPT_NUSHU" "139") + '("soyombo" "G_UNICODE_SCRIPT_SOYOMBO" "140") + '("zanabazar-square" "G_UNICODE_SCRIPT_ZANABAZAR_SQUARE" "141") ) ) @@ -1900,7 +1967,8 @@ ;; { ;; G_FORMAT_SIZE_DEFAULT = 0, ;; G_FORMAT_SIZE_LONG_FORMAT = 1 << 0, -;; G_FORMAT_SIZE_IEC_UNITS = 1 << 1 +;; G_FORMAT_SIZE_IEC_UNITS = 1 << 1, +;; G_FORMAT_SIZE_BITS = 1 << 2 ;; } GFormatSizeFlags; (define-flags-extended FormatSizeFlags @@ -1910,6 +1978,7 @@ '("default" "G_FORMAT_SIZE_DEFAULT" "0x0") '("long-format" "G_FORMAT_SIZE_LONG_FORMAT" "1 << 0") '("iec-units" "G_FORMAT_SIZE_IEC_UNITS" "1 << 1") + '("bits" "G_FORMAT_SIZE_BITS" "1 << 2") ) ) @@ -1942,7 +2011,7 @@ (in-module "G") (c-name "GVariantClass") (values - '("boolean" "G_VARIANT_CLASS_BOOLEAN" "0") + '("boolean" "G_VARIANT_CLASS_BOOLEAN" "'b'") '("byte" "G_VARIANT_CLASS_BYTE" "'y'") '("int16" "G_VARIANT_CLASS_INT16" "'n'") '("uint16" "G_VARIANT_CLASS_UINT16" "'q'") @@ -1951,13 +2020,13 @@ '("int64" "G_VARIANT_CLASS_INT64" "'x'") '("uint64" "G_VARIANT_CLASS_UINT64" "'t'") '("handle" "G_VARIANT_CLASS_HANDLE" "'h'") - '("double" "G_VARIANT_CLASS_DOUBLE" "0") + '("double" "G_VARIANT_CLASS_DOUBLE" "'d'") '("string" "G_VARIANT_CLASS_STRING" "'s'") '("object-path" "G_VARIANT_CLASS_OBJECT_PATH" "'o'") '("signature" "G_VARIANT_CLASS_SIGNATURE" "'g'") '("variant" "G_VARIANT_CLASS_VARIANT" "'v'") '("maybe" "G_VARIANT_CLASS_MAYBE" "'m'") - '("array" "G_VARIANT_CLASS_ARRAY" "0") + '("array" "G_VARIANT_CLASS_ARRAY" "'a'") '("tuple" "G_VARIANT_CLASS_TUPLE" "'('") '("dict-entry" "G_VARIANT_CLASS_DICT_ENTRY" "'{'") ) diff --git a/glib/src/glib_functions.defs b/glib/src/glib_functions.defs index 0667836..219feea 100644 --- a/glib/src/glib_functions.defs +++ b/glib/src/glib_functions.defs @@ -37,6 +37,7 @@ '("sha1" "G_CHECKSUM_SHA1") '("sha256" "G_CHECKSUM_SHA256") '("sha512" "G_CHECKSUM_SHA512") + '("sha384" "G_CHECKSUM_SHA384") ) ) @@ -627,6 +628,16 @@ ) ) +(define-enum ParserError + (in-module "GNumber") + (c-name "GNumberParserError") + (gtype-id "G_TYPE_NUMBER_PARSER_ERROR") + (values + '("invalid" "G_NUMBER_PARSER_ERROR_INVALID") + '("out-of-bounds" "G_NUMBER_PARSER_ERROR_OUT_OF_BOUNDS") + ) +) + (define-flags TrapFlags (in-module "GTest") (c-name "GTestTrapFlags") @@ -649,6 +660,18 @@ ) ) +(define-enum Result + (in-module "GTest") + (c-name "GTestResult") + (gtype-id "G_TYPE_TEST_RESULT") + (values + '("success" "G_TEST_RUN_SUCCESS") + '("skipped" "G_TEST_RUN_SKIPPED") + '("failure" "G_TEST_RUN_FAILURE") + '("incomplete" "G_TEST_RUN_INCOMPLETE") + ) +) + (define-enum LogType (in-module "GTest") (c-name "GTestLogType") @@ -793,6 +816,9 @@ '("conditional-japanese-starter" "G_UNICODE_BREAK_CONDITIONAL_JAPANESE_STARTER") '("hebrew-letter" "G_UNICODE_BREAK_HEBREW_LETTER") '("regional-indicator" "G_UNICODE_BREAK_REGIONAL_INDICATOR") + '("emoji-base" "G_UNICODE_BREAK_EMOJI_BASE") + '("emoji-modifier" "G_UNICODE_BREAK_EMOJI_MODIFIER") + '("zero-width-joiner" "G_UNICODE_BREAK_ZERO_WIDTH_JOINER") ) ) @@ -934,6 +960,16 @@ '("multani" "G_UNICODE_SCRIPT_MULTANI") '("old-hungarian" "G_UNICODE_SCRIPT_OLD_HUNGARIAN") '("signwriting" "G_UNICODE_SCRIPT_SIGNWRITING") + '("adlam" "G_UNICODE_SCRIPT_ADLAM") + '("bhaiksuki" "G_UNICODE_SCRIPT_BHAIKSUKI") + '("marchen" "G_UNICODE_SCRIPT_MARCHEN") + '("newa" "G_UNICODE_SCRIPT_NEWA") + '("osage" "G_UNICODE_SCRIPT_OSAGE") + '("tangut" "G_UNICODE_SCRIPT_TANGUT") + '("masaram-gondi" "G_UNICODE_SCRIPT_MASARAM_GONDI") + '("nushu" "G_UNICODE_SCRIPT_NUSHU") + '("soyombo" "G_UNICODE_SCRIPT_SOYOMBO") + '("zanabazar-square" "G_UNICODE_SCRIPT_ZANABAZAR_SQUARE") ) ) @@ -978,6 +1014,7 @@ '("default" "G_FORMAT_SIZE_DEFAULT") '("long-format" "G_FORMAT_SIZE_LONG_FORMAT") '("iec-units" "G_FORMAT_SIZE_IEC_UNITS") + '("bits" "G_FORMAT_SIZE_BITS") ) ) @@ -1370,6 +1407,27 @@ ) ) +(define-method find + (of-object "GPtrArray") + (c-name "g_ptr_array_find") + (return-type "gboolean") + (parameters + '("gconstpointer" "needle") + '("guint*" "index_") + ) +) + +(define-method find_with_equal_func + (of-object "GPtrArray") + (c-name "g_ptr_array_find_with_equal_func") + (return-type "gboolean") + (parameters + '("gconstpointer" "needle") + '("GEqualFunc" "equal_func") + '("guint*" "index_") + ) +) + (define-function g_byte_array_new (c-name "g_byte_array_new") (is-constructor-of "GByteArray") @@ -2943,50 +3001,6 @@ ) ) -(define-function g_filename_to_utf8_utf8 - (c-name "g_filename_to_utf8_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "opsysstring") - '("gssize" "len") - '("gsize*" "bytes_read") - '("gsize*" "bytes_written") - '("GError**" "error") - ) -) - -(define-function g_filename_from_utf8_utf8 - (c-name "g_filename_from_utf8_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "utf8string") - '("gssize" "len") - '("gsize*" "bytes_read") - '("gsize*" "bytes_written") - '("GError**" "error") - ) -) - -(define-function g_filename_from_uri_utf8 - (c-name "g_filename_from_uri_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "uri") - '("gchar**" "hostname") - '("GError**" "error") - ) -) - -(define-function g_filename_to_uri_utf8 - (c-name "g_filename_to_uri_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "filename") - '("const-gchar*" "hostname") - '("GError**" "error") - ) -) - ;; From gdataset.h @@ -3186,6 +3200,12 @@ (return-type "none") ) +(define-method copy + (of-object "GDate") + (c-name "g_date_copy") + (return-type "GDate*") +) + (define-method valid (of-object "GDate") (c-name "g_date_valid") @@ -3610,6 +3630,15 @@ ) ) +(define-function g_date_time_new_from_iso8601 + (c-name "g_date_time_new_from_iso8601") + (return-type "GDateTime*") + (parameters + '("const-gchar*" "text") + '("GTimeZone*" "default_tz") + ) +) + (define-function g_date_time_new (c-name "g_date_time_new") (is-constructor-of "GDateTime") @@ -3950,22 +3979,6 @@ (return-type "none") ) -(define-function g_dir_open_utf8 - (c-name "g_dir_open_utf8") - (return-type "GDir*") - (parameters - '("const-gchar*" "path") - '("guint" "flags") - '("GError**" "error") - ) -) - -(define-method read_name_utf8 - (of-object "GDir") - (c-name "g_dir_read_name_utf8") - (return-type "const-gchar*") -) - ;; From genviron.h @@ -4035,32 +4048,6 @@ ) ) -(define-function g_getenv_utf8 - (c-name "g_getenv_utf8") - (return-type "const-gchar*") - (parameters - '("const-gchar*" "variable") - ) -) - -(define-function g_setenv_utf8 - (c-name "g_setenv_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "variable") - '("const-gchar*" "value") - '("gboolean" "overwrite") - ) -) - -(define-function g_unsetenv_utf8 - (c-name "g_unsetenv_utf8") - (return-type "none") - (parameters - '("const-gchar*" "variable") - ) -) - ;; From gerror.h @@ -4328,6 +4315,15 @@ ) ) +(define-function g_build_filename_valist + (c-name "g_build_filename_valist") + (return-type "gchar*") + (parameters + '("const-gchar*" "first_element") + '("va_list*" "args") + ) +) + (define-function g_mkdir_with_parents (c-name "g_mkdir_with_parents") (return-type "gint") @@ -4382,49 +4378,6 @@ ) ) -(define-function g_file_test_utf8 - (c-name "g_file_test_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "filename") - '("GFileTest" "test") - ) -) - -(define-function g_file_get_contents_utf8 - (c-name "g_file_get_contents_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "filename") - '("gchar**" "contents") - '("gsize*" "length") - '("GError**" "error") - ) -) - -(define-function g_mkstemp_utf8 - (c-name "g_mkstemp_utf8") - (return-type "gint") - (parameters - '("gchar*" "tmpl") - ) -) - -(define-function g_file_open_tmp_utf8 - (c-name "g_file_open_tmp_utf8") - (return-type "gint") - (parameters - '("const-gchar*" "tmpl") - '("gchar**" "name_used") - '("GError**" "error") - ) -) - -(define-function g_get_current_dir_utf8 - (c-name "g_get_current_dir_utf8") - (return-type "gchar*") -) - ;; From ggettext.h @@ -5590,16 +5543,6 @@ ) ) -(define-function g_io_channel_new_file_utf8 - (c-name "g_io_channel_new_file_utf8") - (return-type "GIOChannel*") - (parameters - '("const-gchar*" "filename") - '("const-gchar*" "mode") - '("GError**" "error") - ) -) - ;; From gkeyfile.h @@ -6211,10 +6154,6 @@ -;; From glib_probes.h - - - ;; From glib_trace.h @@ -6710,7 +6649,7 @@ (define-method check (of-object "GMainContext") (c-name "g_main_context_check") - (return-type "gint") + (return-type "gboolean") (parameters '("gint" "max_priority") '("GPollFD*" "fds") @@ -7154,6 +7093,15 @@ ) ) +(define-function g_clear_handle_id + (c-name "g_clear_handle_id") + (return-type "none") + (parameters + '("guint*" "tag_ptr") + '("GClearHandleFunc" "clear_func") + ) +) + (define-function g_timeout_add_full (c-name "g_timeout_add_full") (return-type "guint") @@ -10469,77 +10417,6 @@ ) ) -(define-function g_spawn_async_utf8 - (c-name "g_spawn_async_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "working_directory") - '("gchar**" "argv") - '("gchar**" "envp") - '("GSpawnFlags" "flags") - '("GSpawnChildSetupFunc" "child_setup") - '("gpointer" "user_data") - '("GPid*" "child_pid") - '("GError**" "error") - ) -) - -(define-function g_spawn_async_with_pipes_utf8 - (c-name "g_spawn_async_with_pipes_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "working_directory") - '("gchar**" "argv") - '("gchar**" "envp") - '("GSpawnFlags" "flags") - '("GSpawnChildSetupFunc" "child_setup") - '("gpointer" "user_data") - '("GPid*" "child_pid") - '("gint*" "standard_input") - '("gint*" "standard_output") - '("gint*" "standard_error") - '("GError**" "error") - ) -) - -(define-function g_spawn_sync_utf8 - (c-name "g_spawn_sync_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "working_directory") - '("gchar**" "argv") - '("gchar**" "envp") - '("GSpawnFlags" "flags") - '("GSpawnChildSetupFunc" "child_setup") - '("gpointer" "user_data") - '("gchar**" "standard_output") - '("gchar**" "standard_error") - '("gint*" "exit_status") - '("GError**" "error") - ) -) - -(define-function g_spawn_command_line_sync_utf8 - (c-name "g_spawn_command_line_sync_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "command_line") - '("gchar**" "standard_output") - '("gchar**" "standard_error") - '("gint*" "exit_status") - '("GError**" "error") - ) -) - -(define-function g_spawn_command_line_async_utf8 - (c-name "g_spawn_command_line_async_utf8") - (return-type "gboolean") - (parameters - '("const-gchar*" "command_line") - '("GError**" "error") - ) -) - ;; From gstdio.h @@ -11176,6 +11053,37 @@ ) ) +(define-function g_number_parser_error_quark + (c-name "g_number_parser_error_quark") + (return-type "GQuark") +) + +(define-function g_ascii_string_to_signed + (c-name "g_ascii_string_to_signed") + (return-type "gboolean") + (parameters + '("const-gchar*" "str") + '("guint" "base") + '("gint64" "min") + '("gint64" "max") + '("gint64*" "out_num") + '("GError**" "error") + ) +) + +(define-function g_ascii_string_to_unsigned + (c-name "g_ascii_string_to_unsigned") + (return-type "gboolean") + (parameters + '("const-gchar*" "str") + '("guint" "base") + '("guint64" "min") + '("guint64" "max") + '("guint64*" "out_num") + '("GError**" "error") + ) +) + ;; From gstringchunk.h @@ -13309,6 +13217,15 @@ ) ) +(define-function g_utf8_make_valid + (c-name "g_utf8_make_valid") + (return-type "gchar*") + (parameters + '("const-gchar*" "str") + '("gssize" "len") + ) +) + ;; From gunicomp.h @@ -13577,6 +13494,23 @@ +;; From guuid.h + +(define-function g_uuid_string_is_valid + (c-name "g_uuid_string_is_valid") + (return-type "gboolean") + (parameters + '("const-gchar*" "str") + ) +) + +(define-function g_uuid_string_random + (c-name "g_uuid_string_random") + (return-type "gchar*") +) + + + ;; From gvariant-core.h (define-function g_variant_new_from_children @@ -15081,25 +15015,6 @@ (return-type "gchar**") ) -(define-function g_win32_get_package_installation_directory_utf8 - (c-name "g_win32_get_package_installation_directory_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "package") - '("const-gchar*" "dll_name") - ) -) - -(define-function g_win32_get_package_installation_subdirectory_utf8 - (c-name "g_win32_get_package_installation_subdirectory_utf8") - (return-type "gchar*") - (parameters - '("const-gchar*" "package") - '("const-gchar*" "dll_name") - '("const-gchar*" "subdir") - ) -) - (define-function g_win32_check_windows_version (c-name "g_win32_check_windows_version") (return-type "gboolean") diff --git a/glib/src/glib_signals.defs b/glib/src/glib_signals.defs index d65d39e..2748e77 100644 --- a/glib/src/glib_signals.defs +++ b/glib/src/glib_signals.defs @@ -25,6 +25,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property target-property @@ -34,6 +35,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "") ) (define-property flags @@ -43,6 +45,7 @@ (readable #t) (writable #t) (construct-only #t) + (default-value "G_BINDING_DEFAULT") ) ;; GBytes is neither a GObject nor a GInterface. Not checked for signals and properties. diff --git a/glib/src/gmodule_functions.defs b/glib/src/gmodule_functions.defs index 9d92ebe..29b4835 100644 --- a/glib/src/gmodule_functions.defs +++ b/glib/src/gmodule_functions.defs @@ -76,19 +76,4 @@ ) ) -(define-function g_module_open_utf8 - (c-name "g_module_open_utf8") - (return-type "GModule*") - (parameters - '("const-gchar*" "file_name") - '("GModuleFlags" "flags") - ) -) - -(define-method name_utf8 - (of-object "GModule") - (c-name "g_module_name_utf8") - (return-type "const-gchar*") -) - diff --git a/glib/src/gobject_enums.defs b/glib/src/gobject_enums.defs index 7b64941..e3b157b 100644 --- a/glib/src/gobject_enums.defs +++ b/glib/src/gobject_enums.defs @@ -39,7 +39,8 @@ ;; G_PARAM_STATIC_BLURB = 1 << 7, ;; /* User defined flags go here */ ;; G_PARAM_EXPLICIT_NOTIFY = 1 << 30, -;; G_PARAM_DEPRECATED = 1 << 31 +;; /* Avoid warning with -Wpedantic for gcc6 */ +;; G_PARAM_DEPRECATED = (gint)(1u << 31) ;; } GParamFlags; (define-flags-extended ParamFlags @@ -57,7 +58,7 @@ '("static-nick" "G_PARAM_STATIC_NICK" "1 << 6") '("static-blurb" "G_PARAM_STATIC_BLURB" "1 << 7") '("explicit-notify" "G_PARAM_EXPLICIT_NOTIFY" "1 << 30") - '("deprecated" "G_PARAM_DEPRECATED" "1 << 31") + '("deprecated" "G_PARAM_DEPRECATED" "(gint)(1u << 31)") ) ) diff --git a/glib/src/gobject_functions.defs b/glib/src/gobject_functions.defs index f77738d..d03dd09 100644 --- a/glib/src/gobject_functions.defs +++ b/glib/src/gobject_functions.defs @@ -544,6 +544,24 @@ ) ) +(define-function g_enum_to_string + (c-name "g_enum_to_string") + (return-type "gchar*") + (parameters + '("GType" "g_enum_type") + '("gint" "value") + ) +) + +(define-function g_flags_to_string + (c-name "g_flags_to_string") + (return-type "gchar*") + (parameters + '("GType" "flags_type") + '("guint" "value") + ) +) + (define-method set_enum (of-object "GValue") (c-name "g_value_set_enum") @@ -1462,6 +1480,17 @@ (varargs #t) ) +(define-function g_object_new_with_properties + (c-name "g_object_new_with_properties") + (return-type "GObject*") + (parameters + '("GType" "object_type") + '("guint" "n_properties") + '("const-char*[]" "names") + '("const-GValue[]" "values") + ) +) + (define-function g_object_newv (c-name "g_object_newv") (return-type "gpointer") @@ -1522,6 +1551,17 @@ (varargs #t) ) +(define-method setv + (of-object "GObject") + (c-name "g_object_setv") + (return-type "none") + (parameters + '("guint" "n_properties") + '("const-gchar*[]" "names") + '("const-GValue[]" "values") + ) +) + (define-method set_valist (of-object "GObject") (c-name "g_object_set_valist") @@ -1532,6 +1572,17 @@ ) ) +(define-method getv + (of-object "GObject") + (c-name "g_object_getv") + (return-type "none") + (parameters + '("guint" "n_properties") + '("const-gchar*[]" "names") + '("GValue[]" "values") + ) +) + (define-method get_valist (of-object "GObject") (c-name "g_object_get_valist") @@ -1956,10 +2007,6 @@ -;; From gobject_probes.h - - - ;; From gobject_trace.h diff --git a/glib/src/iochannel.ccg b/glib/src/iochannel.ccg index 187db24..5e8113f 100644 --- a/glib/src/iochannel.ccg +++ b/glib/src/iochannel.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/iochannel.hg b/glib/src/iochannel.hg index 7a3ade1..2cc840f 100644 --- a/glib/src/iochannel.hg +++ b/glib/src/iochannel.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -40,6 +39,9 @@ _WRAP_ENUM(IOStatus, GIOStatus, NO_GTYPE, s#^EOF$#ENDOFFILE#) _WRAP_ENUM(IOFlags, GIOFlags, NO_GTYPE) +// Glib::IOCondition::IN and Glib::IOCondition::OUT would be problematic. +// IN and OUT can be preprocessor macros. +// See https://bugzilla.gnome.org/show_bug.cgi?id=786717 /** @enum IOCondition * A bitwise combination representing an I/O condition to watch for on an * event source. @@ -47,11 +49,17 @@ _WRAP_ENUM(IOFlags, GIOFlags, NO_GTYPE) * on UNIX (see man 2 poll). To test for individual flags, do * something like this: * @code - * if ((condition & Glib::IOCondition::OUT) == Glib::IOCondition::OUT) + * if ((condition & Glib::IOCondition::IO_OUT) == Glib::IOCondition::IO_OUT) * do_some_output(); * @endcode */ -_WRAP_ENUM(IOCondition, GIOCondition, NO_GTYPE) +_WRAP_ENUM(IOCondition, GIOCondition, NO_GTYPE, + s#^IN$#IO_IN#, + s#^OUT$#IO_OUT#, + s#^PRI$#IO_PRI#, + s#^ERR$#IO_ERR#, + s#^HUP$#IO_HUP#, + s#^NVAL$#IO_NVAL#) /** Exception class for IOChannel errors. */ diff --git a/glib/src/keyfile.ccg b/glib/src/keyfile.ccg index ce14bed..2f86b55 100644 --- a/glib/src/keyfile.ccg +++ b/glib/src/keyfile.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ namespace Glib diff --git a/glib/src/keyfile.hg b/glib/src/keyfile.hg index e33b1d8..584b9d3 100644 --- a/glib/src/keyfile.hg +++ b/glib/src/keyfile.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -143,7 +142,7 @@ public: _IGNORE(g_key_file_load_from_dirs) - _WRAP_METHOD_DOCS_ONLY(g_key_file_load_from_dirs) + _WRAP_METHOD_DOCS_ONLY(g_key_file_load_from_dirs, errthrow "Glib::KeyFileError, Glib::FileError") bool load_from_dirs(const std::string& file, const std::vector& search_dirs, std::string& full_path, Flags flags = Flags::NONE); /** Looks for a KeyFile named @a file in the paths returned from @@ -151,7 +150,7 @@ public: * into the keyfile object, placing the full path to the file in * @a full_path. * @param file The file to search for - * @param full_path Return location for a string containing the full path of the file + * @param[out] full_path Return location for a string containing the full path of the file * @param flags Bitwise combination of the flags to use for the KeyFile * @return true if the KeyFile was successfully loaded, false otherwise * @throw Glib::KeyFileError @@ -167,7 +166,7 @@ public: Glib::ustring to_data(); _IGNORE(g_key_file_to_data) - _WRAP_METHOD(bool save_to_file(const std::string& filename), g_key_file_save_to_file, errthrow) + _WRAP_METHOD(bool save_to_file(const std::string& filename), g_key_file_save_to_file, errthrow "Glib::FileError") _WRAP_METHOD(Glib::ustring get_start_group() const, g_key_file_get_start_group) @@ -234,7 +233,7 @@ public: */ gint64 get_int64(const Glib::ustring& key) const; - _WRAP_METHOD(gint64 get_int64(const Glib::ustring& group_name, const Glib::ustring& key) const, g_key_file_get_int64, errthrow) + _WRAP_METHOD(gint64 get_int64(const Glib::ustring& group_name, const Glib::ustring& key) const, g_key_file_get_int64, errthrow "Glib::KeyFileError") /** Gets the value in the first group, under @a key, interpreting it as * an unsigned 64-bit integer. This is similar to get_integer() but can @@ -247,7 +246,7 @@ public: */ guint64 get_uint64(const Glib::ustring& key) const; - _WRAP_METHOD(guint64 get_uint64(const Glib::ustring& group_name, const Glib::ustring& key) const, g_key_file_get_uint64, errthrow) + _WRAP_METHOD(guint64 get_uint64(const Glib::ustring& group_name, const Glib::ustring& key) const, g_key_file_get_uint64, errthrow "Glib::KeyFileError") /** Gets the value in the first group, under @a key, interpreting it as * a double. diff --git a/glib/src/markup.ccg b/glib/src/markup.ccg index 4e2bf54..408b168 100644 --- a/glib/src/markup.ccg +++ b/glib/src/markup.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/markup.hg b/glib/src/markup.hg index 6f745f5..8e014ba 100644 --- a/glib/src/markup.hg +++ b/glib/src/markup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/miscutils.ccg b/glib/src/miscutils.ccg index 579bcca..90043af 100644 --- a/glib/src/miscutils.ccg +++ b/glib/src/miscutils.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -78,13 +77,7 @@ unsetenv(const std::string& variable) std::vector listenv() { - char** value = g_listenv(); - char** end = value; - while (*end) - { - ++end; - } - return Glib::ArrayHandler::array_to_vector(value, end - value, Glib::OWNERSHIP_DEEP); + return Glib::ArrayHandler::array_to_vector(g_listenv(), Glib::OWNERSHIP_DEEP); } std::string @@ -138,35 +131,13 @@ get_user_config_dir() std::vector get_system_data_dirs() { - // TODO: Use a utility function: - std::vector result; - const char* const* cresult = g_get_system_data_dirs(); - if (!cresult) - return result; - - for (const gchar* const* iter = cresult; *iter != nullptr; ++iter) - { - result.emplace_back(convert_const_gchar_ptr_to_stdstring(*iter)); - } - - return result; + return Glib::ArrayHandler::array_to_vector(g_get_system_data_dirs(), Glib::OWNERSHIP_NONE); } std::vector get_system_config_dirs() { - // TODO: Use a utility function: - std::vector result; - const char* const* cresult = g_get_system_config_dirs(); - if (!cresult) - return result; - - for (const gchar* const* iter = cresult; *iter != nullptr; ++iter) - { - result.emplace_back(convert_const_gchar_ptr_to_stdstring(*iter)); - } - - return result; + return Glib::ArrayHandler::array_to_vector(g_get_system_config_dirs(), Glib::OWNERSHIP_NONE); } std::string diff --git a/glib/src/miscutils.hg b/glib/src/miscutils.hg index 336b13c..ffc87f3 100644 --- a/glib/src/miscutils.hg +++ b/glib/src/miscutils.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/module.ccg b/glib/src/module.ccg index 37ead86..6322cae 100644 --- a/glib/src/module.ccg +++ b/glib/src/module.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/module.hg b/glib/src/module.hg index bb6f428..89ddedf 100644 --- a/glib/src/module.hg +++ b/glib/src/module.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -39,7 +38,7 @@ namespace Glib class Module { _CLASS_GENERIC(Module, GModule) - _IGNORE(g_module_open, g_module_open_utf8, g_module_close) + _IGNORE(g_module_open, g_module_close) public: @@ -112,7 +111,6 @@ public: * @returns The name of the module */ _WRAP_METHOD(std::string get_name() const, g_module_name) - _IGNORE(g_module_name_utf8) /** A portable way to build the filename of a module. The * platform-specific prefix and suffix are added to the filename, if diff --git a/glib/src/nodetree.hg b/glib/src/nodetree.hg index 72cf86d..1db7f1a 100644 --- a/glib/src/nodetree.hg +++ b/glib/src/nodetree.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/optioncontext.ccg b/glib/src/optioncontext.ccg index a6132d0..b63434e 100644 --- a/glib/src/optioncontext.ccg +++ b/glib/src/optioncontext.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/optioncontext.hg b/glib/src/optioncontext.hg index 0f86e6e..9672650 100644 --- a/glib/src/optioncontext.hg +++ b/glib/src/optioncontext.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -99,9 +98,8 @@ public: //so it should be used carefully. For instance you could not access data in a derived class via this second instance. explicit OptionContext(GOptionContext* castitem, bool take_ownership = false); - //TODO?: - //OptionContext(const OptionContext& other) = delete; - //OptionContext& operator=(const OptionContext& other) = delete; + OptionContext(const OptionContext& other) = delete; + OptionContext& operator=(const OptionContext& other) = delete; OptionContext(OptionContext&& other) noexcept; OptionContext& operator=(OptionContext&& other) noexcept; @@ -117,7 +115,7 @@ public: _WRAP_METHOD(bool get_strict_posix() const, g_option_context_get_strict_posix) #m4 _CONVERSION(`char**&',`gchar***',`&($3)') - _WRAP_METHOD(bool parse(int& argc, char**& argv), g_option_context_parse, errthrow) + _WRAP_METHOD(bool parse(int& argc, char**& argv), g_option_context_parse, errthrow "Glib::OptionError, Glib::ConvertError") /** Parses the command line arguments. * @@ -143,6 +141,7 @@ public: * @return true if the parsing was successful, * false if an error occurred. * @throw Glib::OptionError + * @throw Glib::ConvertError */ _WRAP_METHOD(bool parse(char**& argv), g_option_context_parse_strv, errthrow) diff --git a/glib/src/optionentry.ccg b/glib/src/optionentry.ccg index 705e373..44a5dd3 100644 --- a/glib/src/optionentry.ccg +++ b/glib/src/optionentry.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/optionentry.hg b/glib/src/optionentry.hg index c64d13b..4e02700 100644 --- a/glib/src/optionentry.hg +++ b/glib/src/optionentry.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/optiongroup.ccg b/glib/src/optiongroup.ccg index 0bd922f..1045849 100644 --- a/glib/src/optiongroup.ccg +++ b/glib/src/optiongroup.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/optiongroup.hg b/glib/src/optiongroup.hg index 5fbdcbf..6ef64cd 100644 --- a/glib/src/optiongroup.hg +++ b/glib/src/optiongroup.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/regex.ccg b/glib/src/regex.ccg index 1014971..86272bc 100644 --- a/glib/src/regex.ccg +++ b/glib/src/regex.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/regex.hg b/glib/src/regex.hg index 73eedf3..68bca08 100644 --- a/glib/src/regex.hg +++ b/glib/src/regex.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -100,6 +99,7 @@ public: _WRAP_ENUM(CompileFlags, GRegexCompileFlags, NO_GTYPE) _WRAP_ENUM(MatchFlags, GRegexMatchFlags, NO_GTYPE) + /// @throws Glib::RegexError static Glib::RefPtr create(const Glib::ustring& pattern, CompileFlags compile_options = static_cast(0), MatchFlags match_options = static_cast(0)); _WRAP_METHOD(Glib::ustring get_pattern() const, g_regex_get_pattern) @@ -125,7 +125,9 @@ public: /// A match() method not requiring a Glib::MatchInfo. bool match(const Glib::ustring& string, MatchFlags match_options = static_cast(0)); - /// A match() method with a start position and a Glib::MatchInfo. + /** A match() method with a start position and a Glib::MatchInfo. + * @throws Glib::RegexError + */ bool match( const Glib::ustring& string, int start_position, @@ -133,7 +135,7 @@ public: MatchFlags match_options = static_cast(0) ); - _WRAP_METHOD_DOCS_ONLY(g_regex_match_full) + _WRAP_METHOD_DOCS_ONLY(g_regex_match_full, errthrow "Glib::RegexError") bool match( const Glib::ustring& string, gssize string_len, @@ -142,7 +144,9 @@ public: MatchFlags match_options = static_cast(0) ); - /// A match() method with a start position not requiring a Glib::MatchInfo. + /** A match() method with a start position not requiring a Glib::MatchInfo. + * @throws Glib::RegexError + */ bool match(const Glib::ustring& string, int start_position, MatchFlags match_options); /** A match() method with a string length and start position not requiring a @@ -160,7 +164,9 @@ public: /// A match_all() method not requiring a Glib::MatchInfo. bool match_all(const Glib::ustring& string, MatchFlags match_options = static_cast(0)); - /// A match_all() method with a start positon and a Glib::MatchInfo. + /** A match_all() method with a start positon and a Glib::MatchInfo. + * @throws Glib::RegexError + */ bool match_all( const Glib::ustring& string, int start_position, @@ -168,8 +174,7 @@ public: MatchFlags match_options = static_cast(0) ); - _WRAP_METHOD_DOCS_ONLY(g_regex_match_all_full, errthrow) - /// @throw Glib::Error. + _WRAP_METHOD_DOCS_ONLY(g_regex_match_all_full, errthrow "Glib::RegexError") bool match_all( const Glib::ustring& string, gssize string_len, @@ -178,13 +183,14 @@ public: MatchFlags match_options = static_cast(0) ); - /** A match_all() method with a start position not requiring a - * Glib::MatchInfo. + /** A match_all() method with a start position not requiring a Glib::MatchInfo. + * @throws Glib::RegexError */ bool match_all(const Glib::ustring& string, int start_position, MatchFlags match_options); /** A match_all() method with a start position and a string length not * requiring a Glib::MatchInfo. + * @throws Glib::RegexError */ bool match_all(const Glib::ustring& string, gssize string_len, int start_position, MatchFlags match_options); @@ -192,18 +198,21 @@ public: _WRAP_METHOD(static std::vector split_simple(const Glib::ustring& pattern, const Glib::ustring& string, CompileFlags compile_options = static_cast(0), MatchFlags match_options = static_cast(0)), g_regex_split_simple) _WRAP_METHOD(std::vector split(const Glib::ustring& string, MatchFlags match_options = static_cast(0)), g_regex_split) - _WRAP_METHOD(std::vector split(const gchar* string, gssize string_len, int start_position, MatchFlags match_options = static_cast(0), int max_tokens = 0) const, g_regex_split_full, errthrow) + _WRAP_METHOD(std::vector split(const gchar* string, gssize string_len, int start_position, MatchFlags match_options = static_cast(0), int max_tokens = 0) const, g_regex_split_full, errthrow "Glib::RegexError") + /// @throws Glib::RegexError std::vector split(const Glib::ustring& string, int start_position, MatchFlags match_options, int max_tokens) const; - _WRAP_METHOD(Glib::ustring replace(const gchar* string, gssize string_len, int start_position, const Glib::ustring& replacement, MatchFlags match_options = static_cast(0)), g_regex_replace, errthrow) + _WRAP_METHOD(Glib::ustring replace(const gchar* string, gssize string_len, int start_position, const Glib::ustring& replacement, MatchFlags match_options = static_cast(0)), g_regex_replace, errthrow "Glib::RegexError") + /// @throws Glib::RegexError Glib::ustring replace(const Glib::ustring& string, int start_position, const Glib::ustring& replacement, MatchFlags match_options); - _WRAP_METHOD(Glib::ustring replace_literal(const gchar *string, gssize string_len, int start_position, const Glib::ustring& replacement, MatchFlags match_options = static_cast(0)), g_regex_replace_literal, errthrow) + _WRAP_METHOD(Glib::ustring replace_literal(const gchar *string, gssize string_len, int start_position, const Glib::ustring& replacement, MatchFlags match_options = static_cast(0)), g_regex_replace_literal, errthrow "Glib::RegexError") + /// @throws Glib::RegexError Glib::ustring replace_literal(const Glib::ustring& string, int start_position, const Glib::ustring& replacement, MatchFlags match_options); - _WRAP_METHOD(Glib::ustring replace_eval(const Glib::ustring& string, gssize string_len, int start_position, MatchFlags match_options, GRegexEvalCallback eval, gpointer user_data), g_regex_replace_eval, errthrow) - _WRAP_METHOD(static bool check_replacement(const Glib::ustring& replacement, gboolean* has_references), g_regex_check_replacement, errthrow) + _WRAP_METHOD(Glib::ustring replace_eval(const Glib::ustring& string, gssize string_len, int start_position, MatchFlags match_options, GRegexEvalCallback eval, gpointer user_data), g_regex_replace_eval, errthrow "Glib::RegexError") + _WRAP_METHOD(static bool check_replacement(const Glib::ustring& replacement, gboolean* has_references), g_regex_check_replacement, errthrow "Glib::RegexError") }; //TODO: Add C++ iterator like functionality for this class. @@ -255,12 +264,12 @@ public: _WRAP_METHOD(Glib::ustring get_string() const, g_match_info_get_string) _WRAP_METHOD(bool matches() const, g_match_info_matches) - _WRAP_METHOD(bool next(), g_match_info_next, errthrow) + _WRAP_METHOD(bool next(), g_match_info_next, errthrow "Glib::RegexError") _WRAP_METHOD(int get_match_count() const, g_match_info_get_match_count) _WRAP_METHOD(bool is_partial_match() const, g_match_info_is_partial_match) - _WRAP_METHOD(Glib::ustring expand_references(const Glib::ustring& string_to_expand), g_match_info_expand_references, errthrow) + _WRAP_METHOD(Glib::ustring expand_references(const Glib::ustring& string_to_expand), g_match_info_expand_references, errthrow "Glib::RegexError") _WRAP_METHOD(Glib::ustring fetch(int match_num), g_match_info_fetch) diff --git a/glib/src/shell.ccg b/glib/src/shell.ccg index 10b4b4f..940a9a3 100644 --- a/glib/src/shell.ccg +++ b/glib/src/shell.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/shell.hg b/glib/src/shell.hg index 8b3b91e..50736ea 100644 --- a/glib/src/shell.hg +++ b/glib/src/shell.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/spawn.ccg b/glib/src/spawn.ccg index 74c8016..8475244 100644 --- a/glib/src/spawn.ccg +++ b/glib/src/spawn.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/spawn.hg b/glib/src/spawn.hg index 85d7ed2..b6a05d6 100644 --- a/glib/src/spawn.hg +++ b/glib/src/spawn.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/template.macros.m4 b/glib/src/template.macros.m4 index 1a24059..5679546 100644 --- a/glib/src/template.macros.m4 +++ b/glib/src/template.macros.m4 @@ -17,8 +17,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl Lesser General Public License for more details. dnl dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library; if not, write to the Free -dnl Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +dnl License along with this library. If not, see . dnl dnl----------------------------------------------------------------------- dnl Recursion prevention. (Don't attempt to understand why this works!) diff --git a/glib/src/timezone.ccg b/glib/src/timezone.ccg index ad11205..7faf86e 100644 --- a/glib/src/timezone.ccg +++ b/glib/src/timezone.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/timezone.hg b/glib/src/timezone.hg index 80e95d5..1a03376 100644 --- a/glib/src/timezone.hg +++ b/glib/src/timezone.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/unicode.ccg b/glib/src/unicode.ccg index be4c2b5..aac6cd6 100644 --- a/glib/src/unicode.ccg +++ b/glib/src/unicode.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/unicode.hg b/glib/src/unicode.hg index b3c50bb..b3d65f5 100644 --- a/glib/src/unicode.hg +++ b/glib/src/unicode.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/uriutils.ccg b/glib/src/uriutils.ccg index c34848b..4650c0c 100644 --- a/glib/src/uriutils.ccg +++ b/glib/src/uriutils.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/uriutils.hg b/glib/src/uriutils.hg index a1a6f89..05358a4 100644 --- a/glib/src/uriutils.hg +++ b/glib/src/uriutils.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) diff --git a/glib/src/value_basictypes.cc.m4 b/glib/src/value_basictypes.cc.m4 index 82b2233..5f52747 100644 --- a/glib/src/value_basictypes.cc.m4 +++ b/glib/src/value_basictypes.cc.m4 @@ -15,8 +15,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl Lesser General Public License for more details. dnl dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library; if not, write to the Free -dnl Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +dnl License along with this library. If not, see . include(template.macros.m4) diff --git a/glib/src/value_basictypes.h.m4 b/glib/src/value_basictypes.h.m4 index 56097ac..b6a3c83 100644 --- a/glib/src/value_basictypes.h.m4 +++ b/glib/src/value_basictypes.h.m4 @@ -15,8 +15,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl Lesser General Public License for more details. dnl dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library; if not, write to the Free -dnl Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +dnl License along with this library. If not, see . include(template.macros.m4) diff --git a/glib/src/variant.ccg b/glib/src/variant.ccg index fd0cb22..086c797 100644 --- a/glib/src/variant.ccg +++ b/glib/src/variant.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include @@ -23,6 +22,8 @@ namespace Glib { +/****************** VariantBase ***********************************/ + VariantBase::VariantBase(GVariant* castitem, bool make_a_copy /* = false */) { if (castitem) @@ -37,6 +38,32 @@ VariantBase::VariantBase(GVariant* castitem, bool make_a_copy /* = false */) gobject_ = castitem; } +VariantBase::operator bool() const +{ + return gobj(); +} + +void +VariantBase::init(const GVariant* cobject, bool take_a_reference) +{ + if (gobject_) + g_variant_unref(gobject_); + + gobject_ = const_cast(cobject); + if (take_a_reference) + g_variant_ref(gobject_); +} + +bool VariantBase::operator==(const VariantBase& other) const +{ + return equal(other); +} + +bool VariantBase::operator!=(const VariantBase& other) const +{ + return !equal(other); +} + void VariantBase::get_normal_form(VariantBase& result) const { @@ -109,6 +136,8 @@ VariantBase::is_castable_to(const VariantType& supertype) const return true; } +/****************** VariantStringBase ***********************************/ + VariantStringBase::VariantStringBase() : VariantBase() { } @@ -138,6 +167,8 @@ VariantStringBase::create_signature(VariantStringBase& output, const std::string output.init(result); } +/****************** VariantContainerBase ***********************************/ + VariantContainerBase::VariantContainerBase() : VariantBase() { } @@ -194,7 +225,7 @@ VariantContainerBase::get_child(VariantBase& child, gsize index) const // VariantContainerBase has no method variant_type() template <> VariantContainerBase -VariantBase::cast_dynamic(const VariantBase& v) noexcept(false) +VariantBase::cast_dynamic(const VariantBase& v) { if (!v.gobj()) return VariantContainerBase(); @@ -245,22 +276,6 @@ VariantContainerBase::get_iter(const VariantType& container_variant_type) const /****************** Specializations ***********************************/ -VariantBase::operator bool() const -{ - return gobj(); -} - -void -VariantBase::init(const GVariant* cobject, bool take_a_reference) -{ - if (gobject_) - g_variant_unref(gobject_); - - gobject_ = const_cast(cobject); - if (take_a_reference) - g_variant_ref(gobject_); -} - /*--------------------Variant---------------------*/ Variant::Variant() : VariantContainerBase() diff --git a/glib/src/variant.hg b/glib/src/variant.hg index 0824ce2..95633c7 100644 --- a/glib/src/variant.hg +++ b/glib/src/variant.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -144,6 +143,39 @@ public: */ _WRAP_METHOD(bool equal(const VariantBase& other) const, g_variant_equal) + /** Checks if @a *this and @a other have the same type and value. + * + * @newin{2,56} + * + * @param other The Variant to compare with. + * @return true if @a *this and @a other are equal. + */ + bool operator==(const VariantBase& other) const; + + /** Checks if @a *this and @a other have the same type and value. + * + * @newin{2,56} + * + * @param other The Variant to compare with. + * @return true if @a *this and @a other are not equal. + */ + bool operator!=(const VariantBase& other) const; + + /** Ordering relational operators. + * These are explicitly deleted to prevent the compiler from generating + * error messages containing long lists of operators that can't be used. + */ + bool operator<(const VariantBase& other) const = delete; + + /// See operator<(). + bool operator<=(const VariantBase& other) const = delete; + + /// See operator<(). + bool operator>(const VariantBase& other) const = delete; + + /// See operator<(). + bool operator>=(const VariantBase& other) const = delete; + /** Gets a VariantBase instance that has the same value as this variant and * is trusted to be in normal form. * @@ -203,7 +235,7 @@ public: * @throws std::bad_cast if the Variant was not of the expected type. */ template - static V_CastTo cast_dynamic(const VariantBase& v) noexcept(false); + static V_CastTo cast_dynamic(const VariantBase& v); _IGNORE(g_variant_dict_new) @@ -224,32 +256,10 @@ protected: */ bool is_castable_to(const VariantType& supertype) const; #endif //DOXYGEN_SHOULD_SKIP_THIS - -private: - /** Relational operators are deleted to prevent invalid conversion - * to const void*. - */ - bool operator<(const VariantBase& src) const; - - /// See operator<(). - bool operator<=(const VariantBase& src) const; - - /// See operator<(). - bool operator>(const VariantBase& src) const; - - /// See operator<(). - bool operator>=(const VariantBase& src) const; - - /// See operator<(). - bool operator==(const VariantBase& src) const; - - /// See operator<(). - bool operator!=(const VariantBase& src) const; }; template V_CastTo VariantBase::cast_dynamic(const VariantBase& v) -noexcept(false) { if(!(v.gobj())) { @@ -390,7 +400,7 @@ public: */ /** If this is a maybe-typed instance, try to extract its value. If there is - * no value (the value is nothing), return falsenothing), return false. Otherwise, * the value is copied to the supplied Variant and true is returned. * * @param maybe A place in which to return the value, if it isn’t @@ -410,8 +420,7 @@ protected: }; template<> -VariantContainerBase VariantBase::cast_dynamic(const VariantBase& v) -noexcept(false); +VariantContainerBase VariantBase::cast_dynamic(const VariantBase& v); /** Template class used for the specialization of the Variant<> classes. * @newin{2,28} @@ -428,7 +437,9 @@ public: /** Specialization of Variant containing a VariantBase. * Perhaps the main use of this is as a maybe-typed (i.e. nullable) Variant, as - * it inherits methods create_maybe() and get_maybe() from VariantContainerBase. + * it inherits the methods create_maybe() and get_maybe() from + * VariantContainerBase, plus get_n_children() to allow checking whether there + * is a contained value, i.e. the inner Variant is not nothing. * * @newin{2,28} * @ingroup Variant @@ -479,6 +490,11 @@ public: }; /** Specialization of Variant containing a Variant. + * Perhaps the main use of this is as a maybe-typed (i.e. nullable) Variant, as + * it inherits the methods create_maybe() and get_maybe() from + * VariantContainerBase, plus get_n_children() to allow checking whether there + * is a contained value, i.e. the inner Variant is not nothing. + * * @newin{2,36} * @ingroup Variant */ @@ -1469,6 +1485,7 @@ const VariantType& Variant>::variant_type() return type; } +#ifndef DOXYGEN_SHOULD_SKIP_THIS namespace detail { template @@ -1484,6 +1501,7 @@ void expand_tuple(std::vector &variants, const Tuple & t, (void)swallow {(expander(Variant::type>::create(std::get(t))))...}; } } // namespace detail +#endif // DOXYGEN_SHOULD_SKIP_THIS template Variant> @@ -1523,6 +1541,7 @@ Variant Variant>::get_child_variant(gsize index) const return entry; } +#ifndef DOXYGEN_SHOULD_SKIP_THIS namespace detail { // swallows any argument @@ -1541,6 +1560,7 @@ void assign_tuple(std::vector &variants, Tuple & t, std::index_sequ (void)swallow {(any_arg(std::get(t) = VariantBase::cast_dynamic::type > >(variants[i++]).get()))...}; } } // namespace detail +#endif // DOXYGEN_SHOULD_SKIP_THIS template std::tuple Variant>::get() const diff --git a/glib/src/variant_basictypes.cc.m4 b/glib/src/variant_basictypes.cc.m4 index 4247da8..ecdfc73 100644 --- a/glib/src/variant_basictypes.cc.m4 +++ b/glib/src/variant_basictypes.cc.m4 @@ -17,8 +17,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl Lesser General Public License for more details. dnl dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library; if not, write to the Free -dnl Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +dnl License along with this library. If not, see . include(template.macros.m4) diff --git a/glib/src/variant_basictypes.h.m4 b/glib/src/variant_basictypes.h.m4 index 959a8e5..5415177 100644 --- a/glib/src/variant_basictypes.h.m4 +++ b/glib/src/variant_basictypes.h.m4 @@ -17,8 +17,7 @@ dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU dnl Lesser General Public License for more details. dnl dnl You should have received a copy of the GNU Lesser General Public -dnl License along with this library; if not, write to the Free -dnl Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +dnl License along with this library. If not, see . include(template.macros.m4) diff --git a/glib/src/variantdict.ccg b/glib/src/variantdict.ccg index 6e069a3..18224f6 100644 --- a/glib/src/variantdict.ccg +++ b/glib/src/variantdict.ccg @@ -12,8 +12,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * License along with this library. If not, see . */ #include diff --git a/glib/src/variantdict.hg b/glib/src/variantdict.hg index 5974953..1f9a5a1 100644 --- a/glib/src/variantdict.hg +++ b/glib/src/variantdict.hg @@ -1,19 +1,18 @@ /* * Copyright (C) 2014 The glibmm Development Team * - * This library is free software, ) you can redistribute it and/or + * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation, ) either - * version 2.1 of the License, or(at your option) any later version. + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY, ) without even the implied warranty of + * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library, ) if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA + * License along with this library. If not, see . */ #include diff --git a/glib/src/variantiter.ccg b/glib/src/variantiter.ccg index cd06bac..7078951 100644 --- a/glib/src/variantiter.ccg +++ b/glib/src/variantiter.ccg @@ -1,18 +1,17 @@ /* Copyright(C) 2010 The glibmm Development Team * - * This library is free software, ) you can redistribute it and/or + * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation, ) either - * version 2.1 of the License, or(at your option) any later version. + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY, ) without even the implied warranty of + * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library, ) if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/variantiter.hg b/glib/src/variantiter.hg index 28f9517..c81dc29 100644 --- a/glib/src/variantiter.hg +++ b/glib/src/variantiter.hg @@ -1,18 +1,17 @@ /* Copyright(C) 2010 The glibmm Development Team * - * This library is free software, ) you can redistribute it and/or + * This library is free software; you can redistribute it and/or * modify it under the terms of the GNU Lesser General Public - * License as published by the Free Software Foundation, ) either - * version 2.1 of the License, or(at your option) any later version. + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. * * This library is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY, ) without even the implied warranty of + * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library, ) if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/varianttype.ccg b/glib/src/varianttype.ccg index 1bac94d..ff1784f 100644 --- a/glib/src/varianttype.ccg +++ b/glib/src/varianttype.ccg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/glib/src/varianttype.hg b/glib/src/varianttype.hg index de8b970..ba16db7 100644 --- a/glib/src/varianttype.hg +++ b/glib/src/varianttype.hg @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ _DEFS(glibmm,glib) @@ -126,9 +125,8 @@ public: _WRAP_METHOD(static VariantType create_dict_entry(const VariantType& key, const VariantType& value), g_variant_type_new_dict_entry) - //TODO: Use something instead of gsize? - _WRAP_METHOD(gsize _get_string_length() const, g_variant_type_get_string_length) - dnl wrapped by hand, because g_variant_type_peek_string does not return a C string. + _WRAP_METHOD(gsize get_string_length() const, g_variant_type_get_string_length) + dnl// wrapped by hand, because g_variant_type_peek_string does not return a nul-terminated C string. _WRAP_METHOD_DOCS_ONLY(g_variant_type_peek_string) std::string get_string() const; _IGNORE(g_variant_type_dup_string) diff --git a/tests/glibmm_bool_vector/main.cc b/tests/glibmm_bool_vector/main.cc index 79b286c..0752318 100644 --- a/tests/glibmm_bool_vector/main.cc +++ b/tests/glibmm_bool_vector/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include #include diff --git a/tests/glibmm_null_vectorutils/main.cc b/tests/glibmm_null_vectorutils/main.cc index b658b39..533451f 100644 --- a/tests/glibmm_null_vectorutils/main.cc +++ b/tests/glibmm_null_vectorutils/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/tests/glibmm_variant/main.cc b/tests/glibmm_variant/main.cc index 0836ec2..f3d4e26 100644 --- a/tests/glibmm_variant/main.cc +++ b/tests/glibmm_variant/main.cc @@ -120,6 +120,38 @@ bool test_object_path() return result_ok; } +bool test_comparison() +{ + bool result_ok = true; + + std::vector int_vector1 = { 1, 2, 3, 4, 5, 6, 7, 8 }; + std::vector int_vector2 = { 1, 2, 3, 4, 5, 6, 7 }; + + auto int_variant1 = Glib::Variant>::create(int_vector1); + auto int_variant2 = Glib::Variant>::create(int_vector2); + auto int_variant3 = Glib::Variant>::create(int_vector1); + + // Equality and inequality operators + ostr << "int_variant1 == int_variant2 (0): " << (int_variant1 == int_variant2) << std::endl; + result_ok &= !(int_variant1 == int_variant2); + ostr << "int_variant1 != int_variant2 (1): " << (int_variant1 != int_variant2) << std::endl; + result_ok &= (int_variant1 != int_variant2); + + ostr << "int_variant1 == int_variant3 (1): " << (int_variant1 == int_variant3) << std::endl; + result_ok &= (int_variant1 == int_variant3); + ostr << "int_variant1 != int_variant3 (0): " << (int_variant1 != int_variant3) << std::endl; + result_ok &= !(int_variant1 != int_variant3); + +#if 0 + // Less than (activate if operator<() exists) + ostr << "int_variant2 < int_variant1 (1): " << (int_variant2 < int_variant1) << std::endl; + result_ok &= (int_variant2 < int_variant1); + ostr << "int_variant1 < int_variant3 (0): " << (int_variant1 < int_variant3) << std::endl; + result_ok &= !(int_variant1 < int_variant3); +#endif + return result_ok; +} + } // anonymous namespace int @@ -276,6 +308,7 @@ main(int, char**) bool result_ok = test_tuple(); result_ok &= test_object_path(); + result_ok &= test_comparison(); return result_ok ? EXIT_SUCCESS : EXIT_FAILURE; } diff --git a/tests/glibmm_vector/main.cc b/tests/glibmm_vector/main.cc index e4e779c..31138cf 100644 --- a/tests/glibmm_vector/main.cc +++ b/tests/glibmm_vector/main.cc @@ -11,8 +11,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ // ugly code ahead. diff --git a/tools/defs_fixer.pl b/tools/defs_fixer.pl index e59c13c..bc0ace8 100644 --- a/tools/defs_fixer.pl +++ b/tools/defs_fixer.pl @@ -13,8 +13,7 @@ # Lesser General Public License for more details. # # You should have received a copy of the GNU Lesser General Public -# License along with this library; if not, write to the Free -# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. +# License along with this library. If not, see . # # # diff --git a/tools/defs_gen/docextract.py b/tools/defs_gen/docextract.py index 1b18f56..4428c80 100644 --- a/tools/defs_gen/docextract.py +++ b/tools/defs_gen/docextract.py @@ -457,21 +457,22 @@ def process_final_sections(fp, line, cur_doc): return line -def parse_dir(dir, doc_dict): +def parse_dir(dir, exclude_files, doc_dict): for file in os.listdir(dir): if file in ('.', '..'): continue path = os.path.join(dir, file) + if path in exclude_files: continue if os.path.isdir(path): if not no_recursion: - parse_dir(path, doc_dict) + parse_dir(path, exclude_files, doc_dict) elif len(file) > 2 and file[-2:] in ('.c', '.h'): sys.stderr.write("Processing " + path + '\n') parse_file(open(path, 'r'), doc_dict) -def extract(dirs, doc_dict=None): +def extract(dirs, exclude_files, doc_dict=None): if not doc_dict: doc_dict = {} for dir in dirs: - parse_dir(dir, doc_dict) + parse_dir(dir, exclude_files, doc_dict) return doc_dict tmpl_section_pattern = re.compile(r'^$') @@ -509,12 +510,13 @@ def parse_tmpl(fp, doc_dict): line = fp.readline() -def extract_tmpl(dirs, doc_dict=None): +def extract_tmpl(dirs, exclude_files, doc_dict=None): if not doc_dict: doc_dict = {} for dir in dirs: for file in os.listdir(dir): if file in ('.', '..'): continue path = os.path.join(dir, file) + if path in exclude_files: continue if os.path.isdir(path): continue if len(file) > 5 and file[-5:] == '.sgml': diff --git a/tools/defs_gen/docextract_to_xml.py b/tools/defs_gen/docextract_to_xml.py index a322135..7c73cc0 100755 --- a/tools/defs_gen/docextract_to_xml.py +++ b/tools/defs_gen/docextract_to_xml.py @@ -14,8 +14,10 @@ import docextract def usage(): sys.stderr.write('usage: docextract_to_xml.py ' + - '[-s /src/dir | --source-dir=/src/dir] [-a | --with-annotations] ' + - '[-p | --with-properties] [-c | --with-sections] [-r | --no-recursion] ' + + '[-s /src/dir | --source-dir=/src/dir] ' + + '[-x /src/dir/file-to-exclude | --exclude-file=/src/dir/file-to-exclude] ' + + '[-a | --with-annotations] [-p | --with-properties] ' + + '[-c | --with-sections] [-r | --no-recursion] ' + '[-n | --no-since] [-i | --no-signals ] [-e | --no-enums ]\n') sys.exit(1) @@ -61,15 +63,16 @@ def print_annotations(annotations): if __name__ == '__main__': try: - opts, args = getopt.getopt(sys.argv[1:], "d:s:o:apcrnie", - ["source-dir=", "with-annotations", - "with-properties", "with-sections", - "no-recursion", "no-since", + opts, args = getopt.getopt(sys.argv[1:], "s:x:apcrnie", + ["source-dir=", "exclude-file=", + "with-annotations", "with-properties", + "with-sections", "no-recursion", "no-since", "no-signals", "no-enums"]) except getopt.error as e: sys.stderr.write('docextract_to_xml.py: %s\n' % e) usage() source_dirs = [] + exclude_files = [] with_annotations = False with_signals = True with_properties = False @@ -78,25 +81,27 @@ if __name__ == '__main__': for opt, arg in opts: if opt in ('-s', '--source-dir'): source_dirs.append(arg) - if opt in ('-a', '--with-annotations'): + elif opt in ('-x', '--exclude-file'): + exclude_files.append(arg) + elif opt in ('-a', '--with-annotations'): with_annotations = True - if opt in ('-p', '--with-properties'): + elif opt in ('-p', '--with-properties'): with_properties = True - if opt in ('-c', '--with-sections'): + elif opt in ('-c', '--with-sections'): with_sections = True - if opt in ('-r', '--no-recursion'): + elif opt in ('-r', '--no-recursion'): docextract.no_recursion = True - if opt in ('-n', '--no-since'): + elif opt in ('-n', '--no-since'): docextract.no_since = True - if opt in ('-i', '--no-signals'): + elif opt in ('-i', '--no-signals'): with_signals = False - if opt in ('-e', '--no-enums'): + elif opt in ('-e', '--no-enums'): with_enums = False if len(args) != 0: usage() - docs = docextract.extract(source_dirs); - docextract.extract_tmpl(source_dirs, docs); #Try the tmpl sgml files too. + docs = docextract.extract(source_dirs, exclude_files); + docextract.extract_tmpl(source_dirs, exclude_files, docs); #Try the tmpl sgml files too. # print d.docs diff --git a/tools/extra_defs_gen/generate_defs_gio.cc b/tools/extra_defs_gen/generate_defs_gio.cc index 30c3939..229c155 100644 --- a/tools/extra_defs_gen/generate_defs_gio.cc +++ b/tools/extra_defs_gen/generate_defs_gio.cc @@ -13,8 +13,7 @@ * General Public License for more details. * * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "generate_extra_defs.h" @@ -39,6 +38,11 @@ main(int, char**) // g_type_init() is deprecated as of 2.36. // g_type_init(); + // Until the glib bug https://bugzilla.gnome.org/show_bug.cgi?id=465631 + // is fixed, get_defs() must be called for a GObject before it's + // called for a GInterface. + (void)get_defs(G_TYPE_APPLICATION); + std::cout << get_defs(G_TYPE_ASYNC_RESULT) << get_defs(G_TYPE_ACTION) << get_defs(G_TYPE_ACTION_GROUP) << get_defs(G_TYPE_APPLICATION) << get_defs(G_TYPE_APP_INFO_MONITOR) << get_defs(G_TYPE_CANCELLABLE) diff --git a/tools/extra_defs_gen/generate_defs_glib.cc b/tools/extra_defs_gen/generate_defs_glib.cc index 235bc39..f1e552f 100644 --- a/tools/extra_defs_gen/generate_defs_glib.cc +++ b/tools/extra_defs_gen/generate_defs_glib.cc @@ -13,8 +13,7 @@ * General Public License for more details. * * You should have received a copy of the GNU General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "generate_extra_defs.h" diff --git a/tools/extra_defs_gen/generate_extra_defs.cc b/tools/extra_defs_gen/generate_extra_defs.cc index 3b5028d..23300c8 100644 --- a/tools/extra_defs_gen/generate_extra_defs.cc +++ b/tools/extra_defs_gen/generate_extra_defs.cc @@ -13,12 +13,28 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include "generate_extra_defs.h" #include +#include +#include + +namespace +{ +void add_signal_flag_if(std::string& strFlags, const char* strFlag, + const GSignalQuery& signalQuery, GSignalFlags flag) +{ + if (signalQuery.signal_flags & flag) + { + if (!strFlags.empty()) + strFlags += ", "; + strFlags += strFlag; + } +} + +} // anonymous namespace std::string get_property_with_node_name( @@ -58,6 +74,55 @@ get_property_with_node_name( if (bDeprecated) strResult += " (deprecated #t)\n"; // Default: not deprecated + // Default value: + const GValue* defValue = g_param_spec_get_default_value(pParamSpec); + std::string defString; + bool defValueExists = false; + if (G_VALUE_HOLDS_STRING(defValue)) + { + defValueExists = true; + const char* defCString = g_value_get_string(defValue); + if (defCString) + { + // Replace newlines with \n. + // A string default value can contain newline characters. + // gmmproc removes all newlines when it reads .defs files. + defString = std::regex_replace(defCString, std::regex("\n"), "\\n"); + } + else + defString = ""; // A NULL string pointer becomes an empty string. + } + else if (G_VALUE_HOLDS_FLOAT(defValue) || G_VALUE_HOLDS_DOUBLE(defValue)) + { + // g_value_transform() can transform a floating point value to a terrible + // string, especially if the value is huge. + defValueExists = true; + const double defDouble = G_VALUE_HOLDS_FLOAT(defValue) ? + g_value_get_float(defValue) : g_value_get_double(defValue); + std::ostringstream defStringStream; + defStringStream << defDouble; + defString = defStringStream.str(); + } + else + { + GValue defStringValue = G_VALUE_INIT; + g_value_init(&defStringValue, G_TYPE_STRING); + + if (g_value_transform(defValue, &defStringValue)) + { + const char* defCString = g_value_get_string(&defStringValue); + if (defCString) + { + defValueExists = true; + defString = defCString; + } + } + g_value_unset(&defStringValue); + } + + if (defValueExists) + strResult += " (default-value \"" + defString + "\")\n"; + strResult += ")\n\n"; // close (strNodeName return strResult; @@ -210,24 +275,21 @@ get_signals(GType gtype, GTypeIsAPointerFunc is_a_pointer_func) // G_SIGNAL_TYPE_STATIC_SCOPE; strResult += " (return-type \"" + strReturnTypeName + "\")\n"; - // When: - { - bool bWhenFirst = (signalQuery.signal_flags & G_SIGNAL_RUN_FIRST) == G_SIGNAL_RUN_FIRST; - bool bWhenLast = (signalQuery.signal_flags & G_SIGNAL_RUN_LAST) == G_SIGNAL_RUN_LAST; - - std::string strWhen = "unknown"; - - if (bWhenFirst && bWhenLast) - strWhen = "both"; - else if (bWhenFirst) - strWhen = "first"; - else if (bWhenLast) - strWhen = "last"; - - strResult += " (when \"" + strWhen + "\")\n"; - } - bool bDeprecated = (signalQuery.signal_flags & G_SIGNAL_DEPRECATED) == G_SIGNAL_DEPRECATED; - if (bDeprecated) + // Flags: + std::string strFlags; + add_signal_flag_if(strFlags, "Run First", signalQuery, G_SIGNAL_RUN_FIRST); + add_signal_flag_if(strFlags, "Run Last", signalQuery, G_SIGNAL_RUN_LAST); + add_signal_flag_if(strFlags, "Run Cleanup", signalQuery, G_SIGNAL_RUN_CLEANUP); + add_signal_flag_if(strFlags, "No Recurse", signalQuery, G_SIGNAL_NO_RECURSE); + add_signal_flag_if(strFlags, "Action", signalQuery, G_SIGNAL_ACTION); + add_signal_flag_if(strFlags, "No Hooks", signalQuery, G_SIGNAL_NO_HOOKS); + add_signal_flag_if(strFlags, "Must Collect", signalQuery, G_SIGNAL_MUST_COLLECT); + strResult += " (flags \"" + strFlags + "\")\n"; + + if (signalQuery.signal_flags & G_SIGNAL_DETAILED) + strResult += " (detailed #t)\n"; // Default: not detailed + + if (signalQuery.signal_flags & G_SIGNAL_DEPRECATED) strResult += " (deprecated #t)\n"; // Default: not deprecated // Loop through the list of parameters: diff --git a/tools/extra_defs_gen/generate_extra_defs.h b/tools/extra_defs_gen/generate_extra_defs.h index 9d960e3..300df4c 100644 --- a/tools/extra_defs_gen/generate_extra_defs.h +++ b/tools/extra_defs_gen/generate_extra_defs.h @@ -1,5 +1,3 @@ -/* $Id$ */ - /* generate_extra_defs.h * * Copyright (C) 2001 The Free Software Foundation @@ -15,8 +13,7 @@ * Lesser General Public License for more details. * * You should have received a copy of the GNU Lesser General Public - * License along with this library; if not, write to the Free - * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + * License along with this library. If not, see . */ #include diff --git a/tools/gmmproc.in b/tools/gmmproc.in index e929503..56b44e6 100644 --- a/tools/gmmproc.in +++ b/tools/gmmproc.in @@ -21,8 +21,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # # # 'classes': diff --git a/tools/pm/DocsParser.pm b/tools/pm/DocsParser.pm index 93928be..20bcaf3 100644 --- a/tools/pm/DocsParser.pm +++ b/tools/pm/DocsParser.pm @@ -13,8 +13,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # # Based on XML::Parser tutorial found at http://www.devshed.com/Server_Side/Perl/PerlXML/PerlXML1/page1.html @@ -301,7 +300,7 @@ sub lookup_enum_documentation($$$$$$$) # Replace @newin in the enum description, but don't in the element descriptions. my $description = "\@enum $cpp_enum_name\n"; $description .= $$objFunction{description}; - DocsParser::convert_docs_to_cpp($objFunction, \$description); + DocsParser::convert_docs_to_cpp($c_enum_name, \$description); DocsParser::replace_or_add_newin(\$description, $newin); # Add note about deprecation if we have specified that in our _WRAP_ENUM(), @@ -312,7 +311,7 @@ sub lookup_enum_documentation($$$$$$$) } # Append the enum description docs. - DocsParser::convert_docs_to_cpp($objFunction, \$docs); + DocsParser::convert_docs_to_cpp($c_enum_name, \$docs); $docs .= "\n\n$description"; DocsParser::add_m4_quotes(\$docs); @@ -328,14 +327,17 @@ sub lookup_enum_documentation($$$$$$$) return $docs; } -# $strCommentBlock lookup_documentation($strFunctionName, $deprecation_docs, $newin, $objCppfunc) -# The final objCppfunc parameter is optional. If passed, it is used to -# decide if the final C parameter should be omitted if the C++ method -# has a slot parameter. It is also used for converting C parameter names to -# C++ parameter names in the documentation, if they differ. -sub lookup_documentation($$$;$) +# $strCommentBlock lookup_documentation($strFunctionName, $deprecation_docs, +# $newin, $objCppfunc, $errthrow, $voidreturn) +# The parameters from objCppfunc are optional. If objCppfunc is passed, it is used for +# - deciding if the final C parameter shall be omitted if the C++ method +# has a slot parameter, +# - converting C parameter names to C++ parameter names in the documentation, +# if they differ, +# - deciding if the @return section shall be omitted. +sub lookup_documentation($$$;$$$) { - my ($functionName, $deprecation_docs, $newin, $objCppfunc) = @_; + my ($functionName, $deprecation_docs, $newin, $objCppfunc, $errthrow, $voidreturn) = @_; my $objFunction = $DocsParser::hasharrayFunctions{$functionName}; if(!$objFunction) @@ -351,7 +353,7 @@ sub lookup_documentation($$$;$) print "DocsParser.pm: Warning: No C docs for: \"$functionName\"\n"; } - DocsParser::convert_docs_to_cpp($objFunction, \$text); + DocsParser::convert_docs_to_cpp($functionName, \$text); DocsParser::replace_or_add_newin(\$text, $newin); # A blank line, marking the end of a paragraph, is needed after @newin. # Most @newins are at the end of a function description. @@ -365,7 +367,11 @@ sub lookup_documentation($$$;$) } my %param_name_mappings = DocsParser::append_parameter_docs($objFunction, \$text, $objCppfunc); - DocsParser::append_return_docs($objFunction, \$text); + unless ((defined($objCppfunc) && $$objCppfunc{rettype} eq "void") || $voidreturn) + { + DocsParser::append_return_docs($objFunction, \$text); + } + DocsParser::add_throws(\$text, $errthrow); # Convert C parameter names to C++ parameter names where they differ. foreach my $key (keys %param_name_mappings) @@ -391,6 +397,20 @@ sub lookup_documentation($$$;$) return $text; } +# void convert_value_to_cpp(\$text) +# Converts e.g. a property's default value. +sub convert_value_to_cpp($) +{ + my ($text) = @_; + + $$text =~ s"\bFALSE\b"false"g; + $$text =~ s"\bTRUE\b"true"g; + $$text =~ s"\bNULL\b"nullptr"g; + + # Enumerator names + $$text =~ s/\b([A-Z]+)_([A-Z\d_]+)\b/&DocsParser::substitute_enumerator_name($1, $2)/eg; +} + # void remove_example_code($obj_name, \$text) # Removes example code from the text of docs (passed by reference). sub remove_example_code($$) @@ -452,6 +472,12 @@ sub append_parameter_docs($$;$) # due to imperfections in the C docs, and it's difficult to get the C docs # corrected, correct docs can be added to the docs_override.xml file. + if (scalar @docs_param_names != scalar @c_param_names) + { + print STDERR "DocsParser.pm: Warning, $$obj_function{name}\n" . + " Incompatible parameter lists in the docs.xml file and the methods.defs file.\n"; + } + # Skip first param if this is a signal. if ($$obj_function{name} =~ /\w+::/) { @@ -488,8 +514,14 @@ sub append_parameter_docs($$;$) # Skip the last param if it's an error output param. if (scalar @docs_param_names && $docs_param_names[-1] eq "error") { - pop(@docs_param_names); - pop(@c_param_names); + # If the number of parameters in @docs_param_names is not greater than + # the number of parameters in the _WRAP macro, the parameter called "error" + # is probably not an error output parameter. + if (!defined($objCppfunc) || scalar @docs_param_names > scalar @{$$objCppfunc{param_names}}) + { + pop(@docs_param_names); + pop(@c_param_names); + } } my $cpp_param_names; @@ -503,6 +535,11 @@ sub append_parameter_docs($$;$) { $out_param_index = $$param_mappings{OUT}; } + if (scalar @docs_param_names != scalar @$cpp_param_names) + { + print STDERR "DocsParser.pm: Warning, $$obj_function{name}\n" . + " Incompatible parameter lists in the docs.xml file and the _WRAP macro.\n"; + } } my %param_name_mappings; # C name -> C++ name @@ -556,7 +593,7 @@ sub append_parameter_docs($$;$) $param_name_mappings{$param} = "slot"; } - DocsParser::convert_docs_to_cpp($obj_function, \$desc); + DocsParser::convert_docs_to_cpp($$obj_function{name}, \$desc); if(length($desc) > 0) { $desc .= '.' unless($desc =~ /(?:^|\.)$/); @@ -572,7 +609,7 @@ sub append_return_docs($$) my ($obj_function, $text) = @_; my $desc = $$obj_function{return_description}; - DocsParser::convert_docs_to_cpp($obj_function, \$desc); + DocsParser::convert_docs_to_cpp($$obj_function{name}, \$desc); $desc =~ s/\.$//; $$text .= "\n\@return \u${desc}." unless($desc eq ""); @@ -581,7 +618,7 @@ sub append_return_docs($$) sub convert_docs_to_cpp($$) { - my ($obj_function, $text) = @_; + my ($doc_func, $text) = @_; # Chop off leading and trailing whitespace. $$text =~ s/^\s+//; @@ -590,7 +627,7 @@ sub convert_docs_to_cpp($$) # Convert C documentation to C++. DocsParser::remove_c_memory_handling_info($text); DocsParser::convert_tags_to_doxygen($text); - DocsParser::substitute_identifiers($$obj_function{name}, $text); + DocsParser::substitute_identifiers($doc_func, $text); $$text =~ s/\bX\s+Window\b/X \%Window/g; $$text =~ s/\bWindow\s+manager/\%Window manager/g; @@ -731,6 +768,24 @@ sub replace_or_add_newin($$) } } +# void add_throws(\$text, $errthrow) +# If $errthrow is defined and not empty, and $$text does not contain a @throw, +# @throws or @exception Doxygen command, add one or more @throws commands. +sub add_throws($$) +{ + my ($text, $errthrow) = @_; + + return if (!defined($errthrow) or $errthrow eq ""); + + if (!($$text =~ /[\@\\](throws?|exception)\b/)) + { + # Each comma, not preceded by backslash, creates a new @throws command. + $errthrow =~ s/([^\\]),\s*/$1\n\@throws /g; + $errthrow =~ s/\\,/,/g; # Delete backslash before comma + $$text .= "\n\n\@throws $errthrow"; + } +} + # Convert tags to a list of newline-separated elements. sub convert_simplelist($) { diff --git a/tools/pm/Function.pm b/tools/pm/Function.pm index e0f404c..37ffdd3 100644 --- a/tools/pm/Function.pm +++ b/tools/pm/Function.pm @@ -376,12 +376,12 @@ sub add_parameter($$$) return $self; } -# $string get_refdoc_comment($existing_signal_docs) +# $string get_refdoc_comment($existing_signal_docs, $signal_flags) # Generate a readable prototype for signals and merge the prototype into the # existing Doxygen comment block. -sub get_refdoc_comment($$) +sub get_refdoc_comment($$$) { - my ($self, $documentation) = @_; + my ($self, $documentation, $signal_flags) = @_; my $str = " /**\n"; @@ -402,6 +402,11 @@ sub get_refdoc_comment($$) $str .= ")\n"; $str .= " *\n"; + if ($signal_flags) + { + $str .= " * Flags: $signal_flags\n *\n"; + } + if($documentation ne "") { # Remove the initial '/** ' from the existing docs and merge it. diff --git a/tools/pm/GtkDefs.pm b/tools/pm/GtkDefs.pm index 03c1131..c50af4a 100644 --- a/tools/pm/GtkDefs.pm +++ b/tools/pm/GtkDefs.pm @@ -13,8 +13,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # package GtkDefs; use strict; @@ -714,8 +713,9 @@ BEGIN { @GtkDefs::Signal::ISA=qw(GtkDefs::Function); } # # string rettype; # -# string when. e.g. first, last, or both. +# string flags. e.g. Run Last, No Hooks # string entity_type. e.g. vfunc or signal +# bool detailed; # optional # bool deprecated; # optional # } @@ -742,7 +742,7 @@ sub new $$self{rettype} = "none"; $$self{param_types} = []; $$self{param_names} = []; - $$self{when} = ""; + $$self{flags} = ""; $$self{class} = ""; # snarf down lisp fields @@ -761,9 +761,26 @@ sub new $$self{rettype} =~ s/-/ /g; #e.g. replace const-gchar* with const gchar*. Otherwise it will be used in code. } - if($def =~ s/\(when "(\S+)"\)//) + if ($def =~ s/\(flags "(.*?)"\)//) { - $$self{when} = $1; + $$self{flags} = $1; + } + elsif ($def =~ s/\(when "(\S+)"\)//) + { + # "when" is a deprecated alternative to "flags". + # when eq "none", "first", "last", or "both". + if ($1 eq "first") + { + $$self{flags} = "Run First"; + } + elsif ($1 eq "last") + { + $$self{flags} = "Run Last"; + } + elsif ($1 eq "both") + { + $$self{flags} = "Run First, Run Last"; + } } if($$self{rettype} eq "none") @@ -771,6 +788,7 @@ sub new $$self{rettype} = "void" } + $$self{detailed} = ($1 eq "#t") if ($def =~ s/\(detailed (\S+)\)//); $$self{deprecated} = ($1 eq "#t") if ($def =~ s/\(deprecated (\S+)\)//); # signals always have a parameter @@ -791,6 +809,13 @@ sub new return $self; } +# bool get_detailed() +sub get_detailed($) +{ + my ($self) = @_; + return $$self{detailed}; # undef, 0 or 1 +} + # bool get_deprecated() sub get_deprecated($) { diff --git a/tools/pm/Output.pm b/tools/pm/Output.pm index f3c3bb3..c35cadf 100644 --- a/tools/pm/Output.pm +++ b/tools/pm/Output.pm @@ -13,8 +13,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # package Output; use strict; @@ -100,15 +99,11 @@ sub check_deprecation($$$$$$) print STDERR "Warning, $main::source: The $entity_name $entity_type" . " is deprecated in the .defs file, but not in _WRAP_$wrapper.\n"; } - # Uncomment the following lines some time in the future, when most - # signal.defs files have been updated with deprecation information. - # generate_extra_defs.cc was updated to generate this info soon after - # glibmm 2.47.6. - #elsif (!$defs_deprecated && $wrap_deprecated) - #{ - # print STDERR "Warning, $main::source: The $entity_name $entity_type" . - # " is deprecated in _WRAP_$wrapper, but not in the .defs file.\n"; - #} + elsif (!$defs_deprecated && $wrap_deprecated) + { + print STDERR "Warning, $main::source: The $entity_name $entity_type" . + " is deprecated in _WRAP_$wrapper, but not in the .defs file.\n"; + } } sub ifdef($$) @@ -635,7 +630,7 @@ sub output_wrap_sig_decl($$$$$$$$$$$$$$) # Create a merged Doxygen comment block for the signal from the looked up # docs (the block will also contain a prototype of the slot as an example). - my $doxycomment = $objCppfunc->get_refdoc_comment($documentation); + my $doxycomment = $objCppfunc->get_refdoc_comment($documentation, $$objCSignal{flags}); # If there was already a previous doxygen comment, we want to merge this # one with the previous so it is one big comment. If @@ -877,22 +872,22 @@ sub output_wrap_any_property($$$$$$$$$$) my $proxy_suffix = ""; # Read/Write: - if($objProperty->get_construct_only() eq 1) + if ($objProperty->get_construct_only()) { # construct-only functions can be read, but not written. $proxy_suffix = "_ReadOnly"; - if($objProperty->get_readable() ne 1) + if (!$objProperty->get_readable()) { $self->output_wrap_failed($name, "attempt to wrap write-only and construct-only property."); return; } } - elsif($objProperty->get_readable() ne 1) + elsif (!$objProperty->get_readable()) { $proxy_suffix = "_WriteOnly"; } - elsif($objProperty->get_writable() ne 1) + elsif (!$objProperty->get_writable()) { $proxy_suffix = "_ReadOnly"; } @@ -926,7 +921,6 @@ sub output_wrap_any_property($$$$$$$$$$) my $objdoc = $objProperty->get_docs("", ""); if ($objdoc ne "") { - add_m4_quotes(\$objdoc); $documentation = "$objdoc\n *\n * $documentation"; } } @@ -934,10 +928,26 @@ sub output_wrap_any_property($$$$$$$$$$) { # Try to get the (usually short) documentation from the Property object. $documentation = $objProperty->get_docs($deprecation_docs, $newin); + } + + # Default value, if available: + my $default_value = $objProperty->get_default_value(); + if (defined($default_value)) + { + DocsParser::convert_value_to_cpp(\$default_value); + + # Add double quotes around a string value. + if ($objProperty->get_type() eq "GParamString") + { + $default_value = "\"" . $default_value . "\""; + } + $default_value = "Default value: $default_value"; + add_m4_quotes(\$default_value); if ($documentation ne "") { - add_m4_quotes(\$documentation); + $documentation .= "\n *\n * "; } + $documentation .= $default_value; } #Declaration: diff --git a/tools/pm/Property.pm b/tools/pm/Property.pm index 265a3f7..5efca50 100644 --- a/tools/pm/Property.pm +++ b/tools/pm/Property.pm @@ -2,6 +2,7 @@ package Property; use strict; use warnings; +use DocsParser; BEGIN { use Exporter (); @@ -27,6 +28,7 @@ our @EXPORT_OK; # bool writable; # bool construct_only; # bool deprecated; # optional +# string default_value; # optional # string docs; # } @@ -48,10 +50,11 @@ sub new $$self{writable} = ($1 eq "#t") if ($def =~ s/\(writable (\S+)\)//); $$self{construct_only} = ($1 eq "#t") if ($def =~ s/\(construct-only (\S+)\)//); $$self{deprecated} = ($1 eq "#t") if ($def =~ s/\(deprecated (\S+)\)//); + $$self{default_value} = $1 if ($def =~ s/\(default-value "(.*?)"\)//); $$self{entity_type} = 'property'; # Property documentation: - my $propertydocs = $1 if ($def =~ s/\(docs "([^"]*)"\)//); + my $propertydocs = $1 if ($def =~ s/\(docs "([^"]*)"\)//); # Add a full-stop if there is not one already: if(defined($propertydocs)) { @@ -118,11 +121,19 @@ sub get_deprecated($) return $$self{deprecated}; # undef, 0 or 1 } +sub get_default_value($) +{ + my ($self) = @_; + return $$self{default_value}; # undef or a string (possibly empty) +} + sub get_docs($$) { my ($self, $deprecation_docs, $newin) = @_; my $text = $$self{docs}; + DocsParser::convert_docs_to_cpp("$$self{class}:$$self{name}", \$text); + #Add note about deprecation if we have specified that in our _WRAP_PROPERTY() #or_WRAP_CHILD_PROPERTY() call: if($deprecation_docs ne "") @@ -135,6 +146,11 @@ sub get_docs($$) $text .= "\n *\n * \@newin{$newin}"; } + if ($text ne "") + { + DocsParser::add_m4_quotes(\$text); + } + return $text; } diff --git a/tools/pm/Util.pm b/tools/pm/Util.pm index bf033c6..9b0dd66 100644 --- a/tools/pm/Util.pm +++ b/tools/pm/Util.pm @@ -13,8 +13,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # # # This file holds basic functions used throughout gtkmmproc modules. diff --git a/tools/pm/WrapParser.pm b/tools/pm/WrapParser.pm index 504e0c4..f8ce348 100644 --- a/tools/pm/WrapParser.pm +++ b/tools/pm/WrapParser.pm @@ -13,8 +13,7 @@ # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307, USA. +# along with this program. If not, see . # package WrapParser; use strict; @@ -942,6 +941,7 @@ sub on_wrap_method($) $$objCfunc{throw_any_errors} = 0; $$objCfunc{constversion} = 0; $$objCfunc{deprecated} = ""; + my $errthrow_docs = ""; my $deprecation_docs = ""; my $newin = ""; my $ifdef; @@ -953,9 +953,10 @@ sub on_wrap_method($) { $$objCfunc{rettype_needs_ref} = 1; } - elsif($argRef eq "errthrow") + elsif($argRef =~ /^errthrow(.*)/) #If errthrow is at the start. { $$objCfunc{throw_any_errors} = 1; + $errthrow_docs = ($1 ne "") ? string_unquote(string_trim($1)) : "Glib::Error"; } elsif($argRef eq "constversion") { @@ -1006,7 +1007,7 @@ sub on_wrap_method($) else { $commentblock = DocsParser::lookup_documentation($argCFunctionName, - $deprecation_docs, $newin, $objCppfunc); + $deprecation_docs, $newin, $objCppfunc, $errthrow_docs); } $objOutputter->output_wrap_meth($filename, $line_num, $objCppfunc, $objCfunc, $argCppMethodDecl, $commentblock, $ifdef); @@ -1056,22 +1057,30 @@ sub on_wrap_method_docs_only($) } $$objCfunc{throw_any_errors} = 0; + my $errthrow_docs = ""; my $newin = ""; + my $voidreturn = 0; while($#args >= 1) # If the optional ref/err arguments are there. { my $argRef = string_trim(pop @args); - if($argRef eq "errthrow") + if($argRef =~ /^errthrow(.*)/) #If errthrow is at the start. { $$objCfunc{throw_any_errors} = 1; + $errthrow_docs = ($1 ne "") ? string_unquote(string_trim($1)) : "Glib::Error"; } elsif($argRef =~ /^newin(.*)/) #If newin is at the start. { $newin = string_unquote(string_trim($1)); } + elsif($argRef eq "voidreturn") + { + $voidreturn = 1; + } } my $commentblock = ""; - $commentblock = DocsParser::lookup_documentation($argCFunctionName, "", $newin); + $commentblock = DocsParser::lookup_documentation($argCFunctionName, "", $newin, + undef, $errthrow_docs, $voidreturn); $objOutputter->output_wrap_meth_docs_only($filename, $line_num, $commentblock); } @@ -1677,7 +1686,7 @@ sub output_wrap_signal($$$$$$$$$$$$$$$$$) $objCSignal = GtkDefs::lookup_signal($$self{c_class}, $signal_name); # Check for failed lookup. - if($objCSignal eq 0) + if (!$objCSignal) { print STDERR "$signal_name\n"; $objOutputter->output_wrap_failed($signal_name, @@ -1686,6 +1695,19 @@ sub output_wrap_signal($$$$$$$$$$$$$$$$$) } } + # Check detailed. + my $defs_detailed = $objCSignal->get_detailed(); + if ($defs_detailed && !$detail_name) + { + print STDERR "Warning, $main::source: The $signal_name signal" . + " is marked 'detailed' in the .defs file, but not in _WRAP_SIGNAL.\n"; + } + elsif (!$defs_detailed && $detail_name) + { + print STDERR "Warning, $main::source: The $signal_name signal" . + " is marked 'detailed' in _WRAP_SIGNAL, but not in the .defs file.\n"; + } + Output::check_deprecation($$self{deprecated}, $objCSignal->get_deprecated(), $deprecated, $signal_name, "signal", "SIGNAL"); @@ -1694,7 +1716,7 @@ sub output_wrap_signal($$$$$$$$$$$$$$$$$) $deprecated, $deprecation_docs, $newin, $exceptionHandler, $detail_name, $bTwoSignalMethods); - if($bNoDefaultHandler eq 0) + if (!$bNoDefaultHandler) { $objOutputter->output_wrap_default_signal_handler_h($filename, $line_num, $objCppSignal, $objCSignal, $ifdef, $deprecated, $exceptionHandler); -- 2.7.4