diff options
author | Mark Vender <markv743@yahoo.co.uk> | 2012-10-29 13:06:09 +0100 |
---|---|---|
committer | Kjell Ahlstedt <kjell.ahlstedt@bredband.net> | 2012-10-29 13:06:09 +0100 |
commit | e980da407d311e82a1286b1b480ba15d658f4826 (patch) | |
tree | 6f8a8e9e735a93fc542a2bd399b8be98c07281d9 /glib | |
parent | 70d82352b34ec18634c99c61a174655b178bcd08 (diff) | |
download | glibmm-e980da407d311e82a1286b1b480ba15d658f4826.tar.gz |
Strip trailing whitespace.
* gio/giomm/*.[h|cc]:
* gio/src/*.[hg|ccg]:
* glib/glibmm/*.[h|cc]:
* glib/src/*.[hg|ccg]: Strip trailing whitespace. Bug #681072.
Diffstat (limited to 'glib')
49 files changed, 302 insertions, 302 deletions
diff --git a/glib/glibmm/class.cc b/glib/glibmm/class.cc index 5f96ec4a..913b17da 100644 --- a/glib/glibmm/class.cc +++ b/glib/glibmm/class.cc @@ -53,7 +53,7 @@ void Class::register_derived_type(GType base_type, GTypeModule* module) //GTypeQuery::instance_size is guint but GTypeInfo::instance_size is guint16. const guint16 instance_size = (guint16)base_query.instance_size; - + const GTypeInfo derived_info = { class_size, @@ -75,7 +75,7 @@ void Class::register_derived_type(GType base_type, GTypeModule* module) } gchar* derived_name = g_strconcat("gtkmm__", base_query.type_name, (void*)0); - + if(module) gtype_ = g_type_module_register_type(module, base_type, derived_name, &derived_info, GTypeFlags(0)); else diff --git a/glib/glibmm/containerhandle_shared.h b/glib/glibmm/containerhandle_shared.h index cd338677..eb7e508b 100644 --- a/glib/glibmm/containerhandle_shared.h +++ b/glib/glibmm/containerhandle_shared.h @@ -42,10 +42,10 @@ namespace Glib /** * @ingroup ContHandles */ - + //! Ownership of the container -/*! Defines how and if the container will release the list and - * its elemens when it is destroyed +/*! Defines how and if the container will release the list and + * its elemens when it is destroyed */ enum OwnershipType { @@ -145,7 +145,7 @@ struct TypeTraits<T*> GObject* cobj = (GObject*)ptr; return dynamic_cast<CppType>(Glib::wrap_auto(cobj, false /* take_copy */)); } - + static void release_c_type (CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); @@ -154,7 +154,7 @@ struct TypeTraits<T*> }; //This confuse the SUN Forte compiler, so we ifdef it out: -#ifdef GLIBMM_HAVE_DISAMBIGUOUS_CONST_TEMPLATE_SPECIALIZATIONS +#ifdef GLIBMM_HAVE_DISAMBIGUOUS_CONST_TEMPLATE_SPECIALIZATIONS /** Partial specialization for pointers to const GtkObject instances. * @ingroup ContHelpers @@ -177,7 +177,7 @@ struct TypeTraits<const T*> GObject* cobj = (GObject*)const_cast<CTypeNonConst>(ptr); return dynamic_cast<CppType>(Glib::wrap_auto(cobj, false /* take_copy */)); } - + static void release_c_type (CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); @@ -211,7 +211,7 @@ struct TypeTraits< Glib::RefPtr<T> > return Glib::RefPtr<T>( dynamic_cast<T*>(Glib::wrap_auto(cobj, true /* take_copy */)) ); //We use dynamic_cast<> in case of multiple inheritance. } - + static void release_c_type (CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); @@ -247,7 +247,7 @@ struct TypeTraits< Glib::RefPtr<const T> > return Glib::RefPtr<const T>( dynamic_cast<const T*>(Glib::wrap_auto(cobj, true /* take_copy */)) ); //We use dynamic_cast<> in case of multiple inheritance. } - + static void release_c_type (CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); diff --git a/glib/glibmm/containers.h b/glib/glibmm/containers.h index 390879a2..7d78854b 100644 --- a/glib/glibmm/containers.h +++ b/glib/glibmm/containers.h @@ -61,7 +61,7 @@ public: typedef std::bidirectional_iterator_tag iterator_category; typedef std::size_t size_type; typedef std::ptrdiff_t difference_type; - + typedef typename List_Iterator_Base<T>::pointer pointer; typedef typename List_Iterator_Base<T>::reference reference; diff --git a/glib/glibmm/init.cc b/glib/glibmm/init.cc index 4bc5eacb..0710f3f4 100644 --- a/glib/glibmm/init.cc +++ b/glib/glibmm/init.cc @@ -27,7 +27,7 @@ namespace Glib void init() { Glib::wrap_register_init(); - Glib::Error::register_init(); //also calls Glib::wrap_init(); + Glib::Error::register_init(); //also calls Glib::wrap_init(); } } // namespace Glib diff --git a/glib/glibmm/interface.h b/glib/glibmm/interface.h index 43e529fc..2eec856c 100644 --- a/glib/glibmm/interface.h +++ b/glib/glibmm/interface.h @@ -41,18 +41,18 @@ public: typedef GTypeInterface BaseClassType; #endif /* DOXYGEN_SHOULD_SKIP_THIS */ - /** Called by constructors of derived classes. Provide the result of - * the Class object's init() function to ensure that it is properly + /** Called by constructors of derived classes. Provide the result of + * the Class object's init() function to ensure that it is properly * initialized. - * + * * @param interface_class The Class object for the derived type. */ explicit Interface(const Glib::Interface_Class& interface_class); /** Called by constructors of derived classes. - * - * @param cast_item A C instance that will be wrapped by the new - * C++ instance. This does not take a reference, so call reference() + * + * @param cast_item A C instance that will be wrapped by the new + * C++ instance. This does not take a reference, so call reference() * if necessary. */ explicit Interface(GObject* castitem); diff --git a/glib/glibmm/listhandle.h b/glib/glibmm/listhandle.h index 84c71b6c..e63bb0b0 100644 --- a/glib/glibmm/listhandle.h +++ b/glib/glibmm/listhandle.h @@ -150,10 +150,10 @@ private: //TODO: Remove this when we can break glibmm API. /** This is an intermediate type. When a method takes this, or returns this, you - * should use a standard C++ container of your choice, such as std::list or + * should use a standard C++ container of your choice, such as std::list or * std::vector. * - * However, this is not used in new API. We now prefer to just use std::vector, + * However, this is not used in new API. We now prefer to just use std::vector, * which is less flexibile, but makes the API clearer. * * @ingroup ContHandles diff --git a/glib/glibmm/object.h b/glib/glibmm/object.h index 9d48d933..4ac56a11 100644 --- a/glib/glibmm/object.h +++ b/glib/glibmm/object.h @@ -189,7 +189,7 @@ struct TypeTraits< Glib::RefPtr<T> > return Glib::RefPtr<T>( dynamic_cast<T*>(Glib::wrap_auto(cobj, true /* take_copy */)) ); //We use dynamic_cast<> in case of multiple inheritance. } - + static void release_c_type(CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); @@ -225,7 +225,7 @@ struct TypeTraits< Glib::RefPtr<const T> > return Glib::RefPtr<const T>( dynamic_cast<const T*>(Glib::wrap_auto(cobj, true /* take_copy */)) ); //We use dynamic_cast<> in case of multiple inheritance. } - + static void release_c_type (CType ptr) { GLIBMM_DEBUG_UNREFERENCE(0, ptr); @@ -261,7 +261,7 @@ public: CppType get() const { return Glib::RefPtr<T>::cast_dynamic(get_object_copy()); } }; -//The SUN Forte Compiler has a problem with this: +//The SUN Forte Compiler has a problem with this: # ifdef GLIBMM_HAVE_DISAMBIGUOUS_CONST_TEMPLATE_SPECIALIZATIONS /** Partial specialization for RefPtr<> to const Glib::Object. diff --git a/glib/glibmm/objectbase.cc b/glib/glibmm/objectbase.cc index 4798c1fc..7a2c377c 100644 --- a/glib/glibmm/objectbase.cc +++ b/glib/glibmm/objectbase.cc @@ -271,7 +271,7 @@ sigc::connection ObjectBase::connect_property_changed_with_return(const Glib::us // which will contain a switch/case statement which will examine the property name. const Glib::ustring notify_signal_name = "notify::" + property_name; pConnectionNode->connection_id_ = g_signal_connect_data(gobj(), - notify_signal_name.c_str(), (GCallback)(&PropertyProxyConnectionNode::callback), pConnectionNode, + notify_signal_name.c_str(), (GCallback)(&PropertyProxyConnectionNode::callback), pConnectionNode, &PropertyProxyConnectionNode::destroy_notify_handler, G_CONNECT_AFTER); diff --git a/glib/glibmm/objectbase.h b/glib/glibmm/objectbase.h index 69b77224..97f78f3f 100644 --- a/glib/glibmm/objectbase.h +++ b/glib/glibmm/objectbase.h @@ -55,7 +55,7 @@ protected: /** This default constructor is called implicitly from the constructor of user-derived * classes, even if, for instance, Gtk::Button calls a different ObjectBase constructor. * This is normal behaviour for C++ virtual inheritance. - * + * * The GType name will be gtkmm__anonymous_custom_type. */ ObjectBase(); @@ -63,7 +63,7 @@ protected: /** A derived constructor always overrides this choice. * The C++ language itself ensures that the constructor * is only invoked once. - * + * * All classes generated by gtkmmproc use this constructor, with custom_type_name = 0, * which essentially means it's not a custom type. This is used to optimize * vfunc and signal handler callbacks -- since the C++ virtual methods are @@ -104,17 +104,17 @@ public: template <class PropertyType> void get_property(const Glib::ustring& property_name, PropertyType& value) const; - /** You can use the signal_changed() signal of the property proxy instead, + /** You can use the signal_changed() signal of the property proxy instead, * but this is necessary when using the reduced API. * * See also connect_property_changed_with_return(). */ void connect_property_changed(const Glib::ustring& property_name, const sigc::slot<void>& slot); - /** You can use the signal_changed() signal of the property proxy instead, + /** You can use the signal_changed() signal of the property proxy instead, * but this is necessary when using the reduced API. * - * This method was added because connect_property_changed() does not return a sigc::connection, + * This method was added because connect_property_changed() does not return a sigc::connection, * and we could not break the ABI by changing that function. */ sigc::connection connect_property_changed_with_return(const Glib::ustring& property_name, const sigc::slot<void>& slot); @@ -128,7 +128,7 @@ public: */ void freeze_notify(); - /** + /** * Reverts the effect of a previous call to freeze_notify(). The freeze count * is decreased on object and when it reaches zero, all queued "notify" * signals are emitted. diff --git a/glib/glibmm/property.h b/glib/glibmm/property.h index 5878a941..3b2b422d 100644 --- a/glib/glibmm/property.h +++ b/glib/glibmm/property.h @@ -49,9 +49,9 @@ void custom_set_property_callback(GObject* object, unsigned int property_id, #endif /* DOXYGEN_SHOULD_SKIP_THIS */ /** This is the base class for Glib::Object properties. - * + * * This class manages the generic parts of the object properties. - * Derived (templated) classes handle the specific value types. + * Derived (templated) classes handle the specific value types. */ class PropertyBase { @@ -60,7 +60,7 @@ public: /** Returns the name of the property. */ Glib::ustring get_name() const; - + /** Notifies the object containing the property that the property has changed. * This emits the "notify" signal, passing the property name. */ @@ -72,7 +72,7 @@ protected: GParamSpec* param_spec_; /** This constructs a property of type @a value_type for the @a object. - * The property is not registered in the GObject object system + * The property is not registered in the GObject object system * until install_property() has been called. Derived classes do this in * their constructors. * @@ -86,7 +86,7 @@ protected: * Checks if the property has already been installed. */ bool lookup_property(const Glib::ustring& name); - + /** * Installs the property specified by the given @a param_spec. */ @@ -114,7 +114,7 @@ private: }; /** A Glib::Object property. - * + * * This class wraps a GObject property, providing a C++ API to the GObject property * system, for use with classes derived from Glib::Object or Glib::Interface. * @@ -125,15 +125,15 @@ private: * * A short description. * * The default value and the minimum and maximum bounds (depending on the type of the property). * * Flags, defining, among other things, whether the property can be read or written. - * + * * This Property class currently supports only the name and default value. The * minimum and maximum bounds are set to the full range of the value. The nick * and the explanation are set to empty. The flags are set to indicate that the * property can be both read from and written to. - * - * The class information must be installed into the GObject system once per + * + * The class information must be installed into the GObject system once per * property, but this is handled automatically. - * + * * A property can be used only as direct data member of a type, inheriting from * Glib::Object. A reference to the object must be passed to the constructor of * the property. @@ -149,7 +149,7 @@ public: * For each instance of the object, the same property must be constructed with the same name */ Property(Glib::Object& object, const Glib::ustring& name); - + /** Constructs a property of the @a object with the specified @a name and @a default_value. * For each instance of the object, the same property must be constructed with the same name. */ @@ -159,7 +159,7 @@ public: * The object containing the property will be notified about the change. */ inline void set_value(const PropertyType& data); - + /** Returns the value of the property. */ inline PropertyType get_value() const; @@ -168,7 +168,7 @@ public: * The object containing the property will be notified about the change. */ inline Property<T>& operator=(const PropertyType& data); - + /** Returns the value of the property. */ inline operator PropertyType() const; diff --git a/glib/glibmm/propertyproxy.h b/glib/glibmm/propertyproxy.h index 98093bec..a41f549a 100644 --- a/glib/glibmm/propertyproxy.h +++ b/glib/glibmm/propertyproxy.h @@ -39,9 +39,9 @@ namespace Glib * * You may also receive notification when a property's value changes, by connecting to signal_changed(). * - * You may register new properties for your class (actually for the underlying GType) + * You may register new properties for your class (actually for the underlying GType) * simply by adding a PropertyProxy instance as a class member. - * However, your constructor must call the Glib::ObjectBase constructor with a new GType name, + * However, your constructor must call the Glib::ObjectBase constructor with a new GType name, * in order to register a new GType. */ template <class T> @@ -149,7 +149,7 @@ T PropertyProxy<T>::get_value() const return value.get(); } -//We previously just static_cast<> PropertyProxy_WriteOnly<> to PropertyProxy<> to call its set_value(), +//We previously just static_cast<> PropertyProxy_WriteOnly<> to PropertyProxy<> to call its set_value(), //to avoid code duplication. //But the AIX compiler does not like that hack. template <class T> @@ -162,7 +162,7 @@ void PropertyProxy_WriteOnly<T>::set_value(const T& data) set_property_(value); } -//We previously just static_cast<> PropertyProxy_WriteOnly<> to PropertyProxy<> to call its set_value(), +//We previously just static_cast<> PropertyProxy_WriteOnly<> to PropertyProxy<> to call its set_value(), //to avoid code duplication. //But the AIX compiler does not like that hack. template <class T> diff --git a/glib/glibmm/quark.cc b/glib/glibmm/quark.cc index 73a4baaf..810ec344 100644 --- a/glib/glibmm/quark.cc +++ b/glib/glibmm/quark.cc @@ -25,7 +25,7 @@ namespace Glib { QueryQuark::QueryQuark(const GQuark& q) - : quark_(q) + : quark_(q) {} QueryQuark::QueryQuark(const ustring& s) diff --git a/glib/glibmm/quark.h b/glib/glibmm/quark.h index c0bdc814..472589f5 100644 --- a/glib/glibmm/quark.h +++ b/glib/glibmm/quark.h @@ -28,11 +28,11 @@ namespace Glib { -/** Quarks are unique IDs in Glib for strings for use in +/** Quarks are unique IDs in Glib for strings for use in * hash table lookups. Each Quark is unique but may change * between runs. * - * QueryQuark is a converter class for looking up but not + * QueryQuark is a converter class for looking up but not * allocating an ID. An id means the quark lookup failed. * * Quark is used for actions for which the id should live on diff --git a/glib/glibmm/refptr.h b/glib/glibmm/refptr.h index bd27b165..541a1bcf 100644 --- a/glib/glibmm/refptr.h +++ b/glib/glibmm/refptr.h @@ -55,7 +55,7 @@ public: * Afterwards it will be null and use of -> will cause a segmentation fault. */ inline RefPtr(); - + /// Destructor - decrements reference count. inline ~RefPtr(); @@ -94,7 +94,7 @@ public: /// Tests whether the RefPtr<> point to the same underlying instance. inline bool operator==(const RefPtr<T_CppObject>& src) const; - + /// See operator==(). inline bool operator!=(const RefPtr<T_CppObject>& src) const; @@ -137,7 +137,7 @@ public: /** Static cast to derived class. * - * Like the dynamic cast; the notation is + * Like the dynamic cast; the notation is * @code * ptr_derived = RefPtr<Derived>::cast_static(ptr_base); * @endcode @@ -155,7 +155,7 @@ public: template <class T_CastFrom> static inline RefPtr<T_CppObject> cast_const(const RefPtr<T_CastFrom>& src); - //TODO: Maybe remove these if we replace operator bool() with operator const void* after + //TODO: Maybe remove these if we replace operator bool() with operator const void* after //an API/ABI break, as suggested by Daniel Elstner? murrayc. //See bug https://bugzilla.gnome.org/show_bug.cgi?id=626858 diff --git a/glib/glibmm/signalproxy_connectionnode.cc b/glib/glibmm/signalproxy_connectionnode.cc index c0f64c9c..cc6f7079 100644 --- a/glib/glibmm/signalproxy_connectionnode.cc +++ b/glib/glibmm/signalproxy_connectionnode.cc @@ -52,7 +52,7 @@ void* SignalProxyConnectionNode::notify(void* data) { GObject* o = conn->object_; conn->object_ = 0; - + if(g_signal_handler_is_connected(o, conn->connection_id_)) //We check first, because during destruction, GTK+ sometimes seems to disconnect them for us, before we expect it to. See bug #87912 { // Disconnecting triggers execution of destroy_notify_handler(), eiter immediately or later: @@ -60,11 +60,11 @@ void* SignalProxyConnectionNode::notify(void* data) // In that case, destroy_notify_handler() will be called after this whole function has returned. // Anyway. destroy_notify_handler() will always be called, so we leave that to do the deletion. - + //Forget the connection: gulong connection_id = conn->connection_id_; conn->connection_id_ = 0; - + g_signal_handler_disconnect(o, connection_id); } } @@ -77,7 +77,7 @@ void SignalProxyConnectionNode::destroy_notify_handler(gpointer data, GClosure*) { //glib calls this when it has finished with a glib signal connection, //either when the emitting object dies, or when the connection has been disconnected. - + // notification from gtk+. SignalProxyConnectionNode* conn = static_cast<SignalProxyConnectionNode*>(data); diff --git a/glib/glibmm/slisthandle.h b/glib/glibmm/slisthandle.h index 67728f50..a83cc85e 100644 --- a/glib/glibmm/slisthandle.h +++ b/glib/glibmm/slisthandle.h @@ -151,10 +151,10 @@ private: //TODO: Remove this when we can break glibmm API. /** This is an intermediate type. When a method takes this, or returns this, you - * should use a standard C++ container of your choice, such as std::list or + * should use a standard C++ container of your choice, such as std::list or * std::vector. * - * However, this is not used in new API. We now prefer to just use std::vector, + * However, this is not used in new API. We now prefer to just use std::vector, * which is less flexibile, but makes the API clearer. * @ingroup ContHandles */ diff --git a/glib/glibmm/timeval.cc b/glib/glibmm/timeval.cc index f99083bb..99b65977 100644 --- a/glib/glibmm/timeval.cc +++ b/glib/glibmm/timeval.cc @@ -30,7 +30,7 @@ void TimeVal::assign_current_time() { g_get_current_time(this); } - + bool TimeVal::assign_from_iso8601(const Glib::ustring& iso_date) { return g_time_val_from_iso8601(iso_date.c_str(), this); @@ -108,7 +108,7 @@ void TimeVal::subtract_milliseconds(long milliseconds) } void TimeVal::add_microseconds(long microseconds) -{ +{ g_time_val_add(this, microseconds); } diff --git a/glib/glibmm/timeval.h b/glib/glibmm/timeval.h index 8897ee1c..0e49dba4 100644 --- a/glib/glibmm/timeval.h +++ b/glib/glibmm/timeval.h @@ -43,11 +43,11 @@ struct TimeVal : public GTimeVal inline TimeVal& operator=(const GTimeVal& gtimeval); /** Assigns the current time to the TimeVal instance. - * Equivalent to the UNIX gettimeofday() function, but is portable and - * works also on Win32. + * Equivalent to the UNIX gettimeofday() function, but is portable and + * works also on Win32. */ void assign_current_time(); - + /** Converts a string containing an ISO 8601 encoded date and time * to a Glib::TimeVal and puts it in TimeVal instance. * @param iso_date ISO 8601 encoded string. @@ -178,17 +178,17 @@ TimeVal operator+(const TimeVal& lhs, const TimeVal& rhs) { return TimeVal(lhs) += rhs; } /** @relates Glib::TimeVal */ -inline +inline TimeVal operator+(const TimeVal& lhs, long seconds) { return TimeVal(lhs) += seconds; } /** @relates Glib::TimeVal */ -inline +inline TimeVal operator-(const TimeVal& lhs, const TimeVal& rhs) { return TimeVal(lhs) -= rhs; } /** @relates Glib::TimeVal */ -inline +inline TimeVal operator-(const TimeVal& lhs, long seconds) { return TimeVal(lhs) -= seconds; } diff --git a/glib/glibmm/ustring.cc b/glib/glibmm/ustring.cc index 62b79d7d..0d31d48f 100644 --- a/glib/glibmm/ustring.cc +++ b/glib/glibmm/ustring.cc @@ -219,7 +219,7 @@ namespace Glib { #ifndef GLIBMM_HAVE_ALLOWS_STATIC_INLINE_NPOS -// Initialize static member here, +// Initialize static member here, // because the compiler did not allow us do it inline. const ustring::size_type ustring::npos = std::string::npos; #endif diff --git a/glib/glibmm/value.h b/glib/glibmm/value.h index c0890154..4873d684 100644 --- a/glib/glibmm/value.h +++ b/glib/glibmm/value.h @@ -108,7 +108,7 @@ public: protected: void set_boxed(const void* data); - void* get_boxed() const; // doesn't copy + void* get_boxed() const; // doesn't copy }; @@ -235,7 +235,7 @@ public: CppType get() const { return Glib::RefPtr<T>::cast_dynamic(get_object_copy()); } }; -//The SUN Forte Compiler has a problem with this: +//The SUN Forte Compiler has a problem with this: #ifdef GLIBMM_HAVE_DISAMBIGUOUS_CONST_TEMPLATE_SPECIALIZATIONS /** Partial specialization for RefPtr<> to const Glib::Object. diff --git a/glib/glibmm/value_custom.h b/glib/glibmm/value_custom.h index 17db8791..a63fc420 100644 --- a/glib/glibmm/value_custom.h +++ b/glib/glibmm/value_custom.h @@ -88,7 +88,7 @@ private: inline CppType get_(void*) const; }; - + /** Generic value implementation for custom types. * @ingroup glibmmValue * Any type to be used with this template must implement: diff --git a/glib/glibmm/wrap.cc b/glib/glibmm/wrap.cc index 38e75716..4d9c71cf 100644 --- a/glib/glibmm/wrap.cc +++ b/glib/glibmm/wrap.cc @@ -132,7 +132,7 @@ static gboolean gtype_wraps_interface(GType implementer_type, GType interface_ty { found = (ifaces[n_ifaces] == interface_type); } - + g_free (ifaces); return found; @@ -156,7 +156,7 @@ Glib::ObjectBase* wrap_create_new_wrapper_for_interface(GObject* object, GType i { // Look up the wrap table index stored in the type's static data. // If a wrap_new() has been registered for the type then call it. - // But only if the type implements the interface, + // But only if the type implements the interface, // so that the C++ instance is likely to inherit from the appropriate class too. // const gpointer idx = g_type_get_qdata(type, Glib::quark_); diff --git a/glib/glibmm/wrap.h b/glib/glibmm/wrap.h index a65bcf6a..5b07395b 100644 --- a/glib/glibmm/wrap.h +++ b/glib/glibmm/wrap.h @@ -73,8 +73,8 @@ TInterface* wrap_auto_interface(GObject* object, bool take_copy = false) pCppObject = wrap_create_new_wrapper_for_interface(object, TInterface::get_base_type()); } - //If no exact wrapper was created, - //create an instance of the interface, + //If no exact wrapper was created, + //create an instance of the interface, //so we at least get the expected type: TInterface* result = 0; if(pCppObject) diff --git a/glib/src/bytes.hg b/glib/src/bytes.hg index 424347af..1c81e61b 100644 --- a/glib/src/bytes.hg +++ b/glib/src/bytes.hg @@ -60,7 +60,7 @@ class Bytes public: static Glib::RefPtr<Glib::Bytes> create(gconstpointer data, gsize size); - + _WRAP_METHOD(gconstpointer get_data(gsize& size) const, g_bytes_get_data) _WRAP_METHOD(gsize get_size() const, g_bytes_get_size) diff --git a/glib/src/checksum.ccg b/glib/src/checksum.ccg index 6a0a7871..19cdc280 100644 --- a/glib/src/checksum.ccg +++ b/glib/src/checksum.ccg @@ -43,7 +43,7 @@ std::string Checksum::compute_checksum(ChecksumType type, const std::string& dat void Checksum::update(const std::string& data) { - g_checksum_update(gobj(), (const guchar*)data.c_str(), data.size()); + g_checksum_update(gobj(), (const guchar*)data.c_str(), data.size()); } } // Glib namespace diff --git a/glib/src/checksum.hg b/glib/src/checksum.hg index 934c70a4..528251ec 100644 --- a/glib/src/checksum.hg +++ b/glib/src/checksum.hg @@ -28,11 +28,11 @@ namespace Glib { /** Computes the checksum for data. - * This is a generic API for computing checksums (or "digests") for a sequence of arbitrary bytes, + * This is a generic API for computing checksums (or "digests") for a sequence of arbitrary bytes, * using various hashing algorithms like MD5, SHA-1 and SHA-256. Checksums are commonly used in various environments and specifications. * - * glibmm supports incremental checksums by calling update() as long as there's data available and then using get_string() - * or get_digest() to compute the checksum and return it either as a string in hexadecimal form, or as a raw sequence of bytes. + * glibmm supports incremental checksums by calling update() as long as there's data available and then using get_string() + * or get_digest() to compute the checksum and return it either as a string in hexadecimal form, or as a raw sequence of bytes. * To compute the checksum for binary blobs and NULL-terminated strings in one go, use the static compute_checksum() convenience functions(). * * @newin{2,16} @@ -52,8 +52,8 @@ public: * The hashing algorithm to be used by Checksum when performing the * digest of some data. * - * Note that the ChecksumType enumeration may be extended at a later - * date to include new hashing algorithm types. + * Note that the ChecksumType enumeration may be extended at a later + * date to include new hashing algorithm types. * * @newin{2,16} */ @@ -61,7 +61,7 @@ public: #m4 _CONVERSION(`ChecksumType', `GChecksumType', `(($2)$3)') - /** Creates a new Checksum, using the checksum algorithm @a checksum_type. + /** Creates a new Checksum, using the checksum algorithm @a checksum_type. * If the checksum_type is not known, then operator bool() will return false. * * @param type checksum type, one of defined above. @@ -74,14 +74,14 @@ public: operator bool() const; _WRAP_METHOD(void reset(), g_checksum_reset) - + //TODO: length should really be gssize, not gsize, when we can break ABI: #m4 _CONVERSION(`gsize',`gssize',`(gssize)($3)') _WRAP_METHOD(void update(const guchar* data, gsize length), g_checksum_update) /** Feeds data into an existing Checksum. * The checksum must still be open, that is get_string() or get_digest() must not have been called on the checksum. - * + * * @param data Buffer used to compute the checksum */ void update(const std::string& data); @@ -90,11 +90,11 @@ public: _WRAP_METHOD(std::string get_string() const, g_checksum_get_string) - + _WRAP_METHOD(static std::string compute_checksum(ChecksumType type, const guchar* data, gsize length), g_compute_checksum_for_data) /** Computes the checksum of a string. - * + * * @param checksum_type A ChecksumType * @param str The string to compute the checksum of. * @result The checksum as a hexadecimal string. diff --git a/glib/src/convert.ccg b/glib/src/convert.ccg index 33ae8287..b216f932 100644 --- a/glib/src/convert.ccg +++ b/glib/src/convert.ccg @@ -274,7 +274,7 @@ Glib::ustring filename_to_uri(const std::string& filename) Glib::ustring filename_display_basename(const std::string& filename) { char *const buf = g_filename_display_basename(filename.c_str()); - + return Glib::ustring(ScopedPtr<char>(buf).get()); } @@ -282,7 +282,7 @@ Glib::ustring filename_display_basename(const std::string& filename) Glib::ustring filename_display_name(const std::string& filename) { char *const buf = g_filename_display_name(filename.c_str()); - + return Glib::ustring(ScopedPtr<char>(buf).get()); } diff --git a/glib/src/convert.hg b/glib/src/convert.hg index 194b5d94..de5e12ab 100644 --- a/glib/src/convert.hg +++ b/glib/src/convert.hg @@ -247,11 +247,11 @@ Glib::ustring filename_to_uri(const std::string& filename); */ Glib::ustring filename_display_basename(const std::string& filename); -/** Converts a filename into a valid UTF-8 string. The - * conversion is not necessarily reversible, so you +/** Converts a filename into a valid UTF-8 string. The + * conversion is not necessarily reversible, so you * should keep the original around and use the return * value of this function only for display purposes. - * Unlike g_filename_to_utf8(), the result is guaranteed + * Unlike g_filename_to_utf8(), the result is guaranteed * to be non-empty even if the filename actually isn't in the GLib * file name encoding. * diff --git a/glib/src/iochannel.hg b/glib/src/iochannel.hg index f04a14b9..2c89419a 100644 --- a/glib/src/iochannel.hg +++ b/glib/src/iochannel.hg @@ -428,7 +428,7 @@ protected: /** Constructor that should be used by derived classes. * Use this constructor if you want to inherit from IOChannel. - * It will set up a GIOChannel that will call the vfuncs of your + * It will set up a GIOChannel that will call the vfuncs of your * class even if it is being used from C code, and it will keep * a reference to the C++ code while the GIOChannel exists. */ diff --git a/glib/src/keyfile.ccg b/glib/src/keyfile.ccg index 5a6c65e5..366b4980 100644 --- a/glib/src/keyfile.ccg +++ b/glib/src/keyfile.ccg @@ -155,7 +155,7 @@ bool KeyFile::get_boolean(const Glib::ustring& key) const { GError* gerror = 0; const bool value = - static_cast<bool>(g_key_file_get_boolean(const_cast<GKeyFile*>(gobj()), + static_cast<bool>(g_key_file_get_boolean(const_cast<GKeyFile*>(gobj()), 0, key.c_str(), &gerror)); if(gerror) Glib::Error::throw_exception(gerror); @@ -213,7 +213,7 @@ double KeyFile::get_double(const Glib::ustring& key) const void KeyFile::set_double(const Glib::ustring& key, double value) { - g_key_file_set_double(gobj(), 0, key.c_str(), value); + g_key_file_set_double(gobj(), 0, key.c_str(), value); } # define GLIBMM_ERROR_ARG diff --git a/glib/src/keyfile.hg b/glib/src/keyfile.hg index 415dd496..db176396 100644 --- a/glib/src/keyfile.hg +++ b/glib/src/keyfile.hg @@ -37,12 +37,12 @@ namespace Glib */ _WRAP_GERROR(KeyFileError, GKeyFileError, G_KEY_FILE_ERROR, NO_GTYPE) -/** This class lets you parse, edit or create files containing groups of key-value pairs, which we call key files - * for lack of a better name. Several freedesktop.org specifications use key files now, e.g the Desktop Entry +/** This class lets you parse, edit or create files containing groups of key-value pairs, which we call key files + * for lack of a better name. Several freedesktop.org specifications use key files now, e.g the Desktop Entry * Specification and the Icon Theme Specification. * - * The syntax of key files is described in detail in the Desktop Entry Specification, here is a quick summary: Key - * files consists of groups of key-value pairs, interspersed with comments. + * The syntax of key files is described in detail in the Desktop Entry Specification, here is a quick summary: Key + * files consists of groups of key-value pairs, interspersed with comments. * * @code * # this is just an example @@ -67,28 +67,28 @@ _WRAP_GERROR(KeyFileError, GKeyFileError, G_KEY_FILE_ERROR, NO_GTYPE) * * Lines beginning with a '#' and blank lines are considered comments. * - * Groups are started by a header line containing the group name enclosed in '[' and ']', and ended implicitly by + * Groups are started by a header line containing the group name enclosed in '[' and ']', and ended implicitly by * the start of the next group or the end of the file. Each key-value pair must be contained in a group. - * - * Key-value pairs generally have the form key=value, with the exception of localized strings, which have the form - * key[locale]=value. Space before and after the '=' character are ignored. Newline, tab, carriage return and - * backslash characters in value are escaped as \\n, \\t, \\r, and \\\\, respectively. To preserve leading spaces in + * + * Key-value pairs generally have the form key=value, with the exception of localized strings, which have the form + * key[locale]=value. Space before and after the '=' character are ignored. Newline, tab, carriage return and + * backslash characters in value are escaped as \\n, \\t, \\r, and \\\\, respectively. To preserve leading spaces in * values, these can also be escaped as \\s. - * - * Key files can store strings (possibly with localized variants), integers, booleans and lists of these. Lists are - * separated by a separator character, typically ';' or ','. To use the list separator character in a value in a + * + * Key files can store strings (possibly with localized variants), integers, booleans and lists of these. Lists are + * separated by a separator character, typically ';' or ','. To use the list separator character in a value in a * list, it has to be escaped by prefixing it with a backslash. - * - * This syntax is obviously inspired by the .ini files commonly met on Windows, but there are some important + * + * This syntax is obviously inspired by the .ini files commonly met on Windows, but there are some important * differences: * - .ini files use the ';' character to begin comments, key files use the '#' character. * - Key files allow only comments before the first group. * - Key files are always encoded in UTF-8. * - Key and Group names are case-sensitive, for example a group called [GROUP] is a different group from [group]. - * - * Note that in contrast to the Desktop Entry Specification, groups in key files may contain the same key multiple - * times; the last entry wins. Key files may also contain multiple groups with the same name; they are merged - * together. Another difference is that keys and group names in key files are not restricted to ASCII characters. + * + * Note that in contrast to the Desktop Entry Specification, groups in key files may contain the same key multiple + * times; the last entry wins. Key files may also contain multiple groups with the same name; they are merged + * together. Another difference is that keys and group names in key files are not restricted to ASCII characters. * * @newin{2,14} */ @@ -112,7 +112,7 @@ public: _IGNORE(g_key_file_free) /** Creates a glibmm KeyFile wrapper for a GKeyFile object. - * Note, when using this that when the wrapper is deleted, + * Note, when using this that when the wrapper is deleted, * it will not automatically deleted the GKeyFile unless you * set the delete_c_instance boolean to true. * @param castitem The C instance to wrap @@ -262,7 +262,7 @@ _DEPRECATE_IFDEF_END /** Associates a new double value with @a key under the start group. * If @a key cannot be found then it is created. - * + * * @newin{2,12} * @param key A key. * @param value An double value. @@ -349,7 +349,7 @@ _DEPRECATE_IFDEF_END _WRAP_METHOD(void set_int64(const Glib::ustring& group_name, const Glib::ustring& key, gint64 value), g_key_file_set_int64) _WRAP_METHOD(void set_uint64(const Glib::ustring& group_name, const Glib::ustring& key, guint64 value), g_key_file_set_uint64) - /** Sets a list of string values for @a key under @a group_name. If + /** Sets a list of string values for @a key under @a group_name. If * key cannot be found it is created. If @a group_name cannot be found * it is created. * @param group_name The name of a group diff --git a/glib/src/markup.ccg b/glib/src/markup.ccg index 3d52d81e..ae3d4d2f 100644 --- a/glib/src/markup.ccg +++ b/glib/src/markup.ccg @@ -63,13 +63,13 @@ public: static void text(GMarkupParseContext* context, const char* text, - gsize text_len, + gsize text_len, void* user_data, GError** error); static void passthrough(GMarkupParseContext* context, const char* passthrough_text, - gsize text_len, + gsize text_len, void* user_data, GError** error); @@ -149,7 +149,7 @@ void ParserCallbacks::end_element(GMarkupParseContext* context, void ParserCallbacks::text(GMarkupParseContext* context, const char* text, - gsize text_len, + gsize text_len, void* user_data, GError** error) { @@ -172,7 +172,7 @@ void ParserCallbacks::text(GMarkupParseContext* context, void ParserCallbacks::passthrough(GMarkupParseContext* context, const char* passthrough_text, - gsize text_len, + gsize text_len, void* user_data, GError** error) { diff --git a/glib/src/module.hg b/glib/src/module.hg index a1bdb7e5..afa2bcd9 100644 --- a/glib/src/module.hg +++ b/glib/src/module.hg @@ -44,7 +44,7 @@ class Module _IGNORE(g_module_open, g_module_close) public: - + /** Opens a module. * * First of all it tries to open file_name as a module. If that diff --git a/glib/src/nodetree.hg b/glib/src/nodetree.hg index c8f89fb0..ad99555b 100644 --- a/glib/src/nodetree.hg +++ b/glib/src/nodetree.hg @@ -30,11 +30,11 @@ _DEFS(glibmm,glib) namespace Glib { -//Hand-written, instead of using _WRAP_ENUM, +//Hand-written, instead of using _WRAP_ENUM, //because the C enum values don't have a prefix. /** Specifies the type of traveral performed by methods such as NodeTree::_traverse() and NodeTree::find(). - * + * * @ingroup glibmmEnums */ enum TraverseType @@ -47,24 +47,24 @@ enum TraverseType /** N-ary Trees - trees of data with any number of branches * The NodeTree class and its associated functions provide an N-ary tree data structure, in which nodes in the tree can contain arbitrary data. - * + * * To insert a node into a tree use insert(), insert_before(), append() or prepend(). - * + * * To create a new node and insert it into a tree use insert_data(), insert_data_before(), append_data() and prepend_data(). - * + * * To reverse the children of a node use reverse_children(). - * + * * To find a node use root(), find(), find_child(), index_of(), child_index(), first_child(), last_child(), nth_child(), first_sibling(), prev_sibling(), next_sibling() or last_sibling(). - * + * * To get information about a node or tree use is_leaf(), is_root(), depth(), node_count(), child_count(), is_ancestor() or max_height(). - * + * * To traverse a tree, calling a function for each node visited in the traversal, use traverse() or foreach(). - * + * * To remove a node or subtree from a tree use unlink(). * * @newin{2,18} */ -template <typename T> +template <typename T> class NodeTree { _CLASS_GENERIC(NodeTree, GNode) @@ -136,7 +136,7 @@ public: /** Inserts a NodeTree beneath the parent at the given position. * - * @param position the position to place node at, with respect to its siblings + * @param position the position to place node at, with respect to its siblings * If position is -1, node is inserted as the last child of parent * @param node the NodeTree to insert * @return the inserted NodeTree @@ -201,7 +201,7 @@ public: /** Inserts a new NodeTree at the given position. * - * @param position the position to place the new NodeTree at. + * @param position the position to place the new NodeTree at. * If position is -1, the new NodeTree is inserted as the last child of parent * @param data the data for the new NodeTree * @return the new NodeTree @@ -216,7 +216,7 @@ public: /** Inserts a new NodeTree before the given sibling. * - * @param sibling the sibling NodeTree to place node before. + * @param sibling the sibling NodeTree to place node before. * @param data the data for the new NodeTree * @return the new NodeTree */ @@ -292,13 +292,13 @@ public: }; /** Traverses a tree starting at the current node. - * It calls the given function for each node visited. + * It calls the given function for each node visited. * The traversal can be halted at any point by returning true from @a func. * * @param order The order in which nodes are visited. * @param flags Which types of children are to be visited. - * @param max_depth The maximum depth of the traversal. - * Nodes below this depth will not be visited. + * @param max_depth The maximum depth of the traversal. + * Nodes below this depth will not be visited. * If max_depth is -1 all nodes in the tree are visited. * If max_depth is 1, only the root is visited. * If max_depth is 2, the root and its children are visited. And so on. @@ -339,7 +339,7 @@ public: type_foreach_gnode_slot bound_slot = sigc::bind(real_slot, the_data, &child); g_node_children_foreach(gobj(), (GTraverseFlags)flags, c_callback_foreach_compare_child, reinterpret_cast<gpointer>(&bound_slot)); - + return wrap(child); } @@ -411,7 +411,7 @@ public: } _IGNORE(g_node_child_index) - /** Gets the position with respect to its siblings. + /** Gets the position with respect to its siblings. * child must be a child of node. * The first child is numbered 0, the second 1, and so on. * @@ -426,7 +426,7 @@ public: /** Gets the first child. * - * @return The first child, or 0 if the node has no children. + * @return The first child, or 0 if the node has no children. */ NodeTree<T>* first_child() { @@ -435,7 +435,7 @@ public: /** Gets the first child. * - * @return The first child, or 0 if the node has no children. + * @return The first child, or 0 if the node has no children. */ const NodeTree<T>* first_child() const { @@ -466,7 +466,7 @@ public: * * @return The nth child, or 0 if n is too large. */ - NodeTree<T>* nth_child(int n) + NodeTree<T>* nth_child(int n) { return wrap(g_node_nth_child(gobj(), n)); } @@ -480,7 +480,7 @@ public: return const_cast<NodeTree<T>*>(this)->nth_child(n); } _IGNORE(g_node_nth_child) - + /** Gets the first sibling * @return The first sibling, or 0 if the node has no siblings. */ diff --git a/glib/src/optioncontext.ccg b/glib/src/optioncontext.ccg index fec4329d..601b928c 100644 --- a/glib/src/optioncontext.ccg +++ b/glib/src/optioncontext.ccg @@ -64,7 +64,7 @@ OptionContext::~OptionContext() { if(has_ownership_) g_option_context_free(gobj()); - + gobject_ = 0; } diff --git a/glib/src/optioncontext.hg b/glib/src/optioncontext.hg index 770d8899..bc31f15d 100644 --- a/glib/src/optioncontext.hg +++ b/glib/src/optioncontext.hg @@ -46,12 +46,12 @@ public: * @param parameter_string A string which is displayed in the first line of --help output, after programname [OPTION...] */ explicit OptionContext(const Glib::ustring& parameter_string = Glib::ustring()); - + //Note that, unlike Glib::Wrap(), this would create a second C++ instance for the same C instance, //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); virtual ~OptionContext(); - + _WRAP_METHOD(void set_help_enabled(bool help_enabled = true), g_option_context_set_help_enabled) _WRAP_METHOD(bool get_help_enabled() const, g_option_context_get_help_enabled) _WRAP_METHOD(void set_ignore_unknown_options(bool ignore_unknown = true), g_option_context_set_ignore_unknown_options) @@ -63,16 +63,16 @@ public: //g_option_context_add_main_entries(), just creates a group internally, adds them to it, and does a set_main_group() //- a group without callbacks seems to do some simple default parsing. _IGNORE(g_option_context_add_main_entries) - - /** Adds an OptionGroup to the context, so that parsing with context will recognize the options in the group. + + /** Adds an OptionGroup to the context, so that parsing with context will recognize the options in the group. * Note that the group will not be copied, so it should exist for as long as the context exists. * * @param group The group to add. */ void add_group(OptionGroup& group); _IGNORE(g_option_context_add_group) - - /** Sets an OptionGroup as the main group of the context. This has the same effect as calling add_group(), the only + + /** Sets an OptionGroup as the main group of the context. This has the same effect as calling add_group(), the only * difference is that the options in the main group are treated differently when generating --help output. * Note that the group will not be copied, so it should exist for as long as the context exists. * @@ -80,7 +80,7 @@ public: */ void set_main_group(OptionGroup& group); _IGNORE(g_option_context_set_main_group) - + //We don't need this (hopefully), and the memory management would be really awkward. //OptionGroup& get_main_group(); //const OptionGroup& get_main_group() const; @@ -88,9 +88,9 @@ public: #m4 _CONVERSION(`const OptionGroup&',`GOptionGroup*',`const_cast<GOptionGroup*>(($3).gobj())') _WRAP_METHOD(Glib::ustring get_help(bool main_help, const OptionGroup& group) const, g_option_context_get_help) - - /** Returns a formatted, translated help text for the given context. - * To obtain the text produced by --help, call get_help (true). + + /** Returns a formatted, translated help text for the given context. + * To obtain the text produced by --help, call get_help (true). * To obtain the text produced by --help-all, call get_help(false). * To obtain the help text for an option group, call get_help(false, group). * diff --git a/glib/src/optionentry.ccg b/glib/src/optionentry.ccg index 2febf45c..9a64f102 100644 --- a/glib/src/optionentry.ccg +++ b/glib/src/optionentry.ccg @@ -28,10 +28,10 @@ OptionEntry::OptionEntry() OptionEntry::~OptionEntry() { - g_free(const_cast<char*>(gobject_->long_name)); + g_free(const_cast<char*>(gobject_->long_name)); g_free(const_cast<char*>(gobject_->description)); g_free(const_cast<char*>(gobject_->arg_description)); - g_free(gobject_); + g_free(gobject_); } OptionEntry::OptionEntry(const OptionEntry& src) @@ -57,7 +57,7 @@ OptionEntry& OptionEntry::operator=(const OptionEntry& src) gobject_->arg_data = src.gobject_->arg_data; //Shared, because it's not owned by any instance of this class anyway. if(gobject_->description) - g_free(const_cast<char*>(gobject_->description)); + g_free(const_cast<char*>(gobject_->description)); gobject_->description = g_strdup(src.gobject_->description); @@ -78,9 +78,9 @@ void OptionEntry::set_long_name(const Glib::ustring& value) gobject_->long_name = 0; } - //Note that we do not use NULL for an empty string, + //Note that we do not use NULL for an empty string, //because G_OPTION_REMAINING is actually a "", so it actually has a distinct meaning: - //TODO: Wrap G_OPTION_REMAINING in C++ somehow, maybe as an explicit set_long_name(void) or set_is_remaining()? murrayc. + //TODO: Wrap G_OPTION_REMAINING in C++ somehow, maybe as an explicit set_long_name(void) or set_is_remaining()? murrayc. gobj()->long_name = (value).c_str() ? g_strdup((value).c_str()) : 0; } @@ -105,7 +105,7 @@ void OptionEntry::set_arg_description(const Glib::ustring& value) gobj()->arg_description = (value).empty() ? 0 : g_strdup((value).c_str()); } - + } // namespace Glib diff --git a/glib/src/optionentry.hg b/glib/src/optionentry.hg index 70b8d658..852dff20 100644 --- a/glib/src/optionentry.hg +++ b/glib/src/optionentry.hg @@ -27,18 +27,18 @@ extern "C" { typedef struct _GOptionEntry GOptionEntry; } namespace Glib { -/** An OptionEntry defines a single option. To have an effect, it must be added to an OptionGroup with +/** An OptionEntry defines a single option. To have an effect, it must be added to an OptionGroup with * OptionGroup::add_entry(). - * - * The long name of an option can be used to specify it in a commandline as --long_name. - * Every option must have a long name. To resolve conflicts if multiple option groups contain the same long name, it is also + * + * The long name of an option can be used to specify it in a commandline as --long_name. + * Every option must have a long name. To resolve conflicts if multiple option groups contain the same long name, it is also * possible to specify the option as --groupname-long_name. * * If an option has a short name, it can be specified as -short_name in a commandline. * * The description for the option is shown in the --help output. * - * The arg_descripton is the placeholder to use for the extra argument parsed by the option in --help output. + * The arg_descripton is the placeholder to use for the extra argument parsed by the option in --help output. */ class OptionEntry { @@ -60,36 +60,36 @@ public: OptionEntry(); OptionEntry(const OptionEntry& src); virtual ~OptionEntry(); - + OptionEntry& operator=(const OptionEntry& src); //#m4 _CONVERSION(`Glib::ustring',`const gchar*',`($3).empty() ? NULL : g_strdup(($3).c_str())') - + _MEMBER_GET(long_name, long_name, Glib::ustring, const char*) void set_long_name(const Glib::ustring& value); - + _MEMBER_GET(short_name, short_name, gchar, gchar) _MEMBER_SET(short_name, short_name, gchar, gchar) - + _MEMBER_GET(flags, flags, int, int) /** Set one or more OptionEntry::Flags. * Do not set FLAG_FILENAME. Character encoding is chosen when the OptionEntry * is added to an OptionGroup. */ _MEMBER_SET(flags, flags, int, int) - + _MEMBER_GET(description, description, Glib::ustring, const char*) void set_description(const Glib::ustring& value); - + _MEMBER_GET(arg_description, arg_description, Glib::ustring, const char*) void set_arg_description(const Glib::ustring& value); - + GOptionEntry* gobj() { return gobject_; } const GOptionEntry* gobj() const { return gobject_; } - + protected: GOptionEntry* gobject_; diff --git a/glib/src/optiongroup.ccg b/glib/src/optiongroup.ccg index 1d6697ae..baa1331c 100644 --- a/glib/src/optiongroup.ccg +++ b/glib/src/optiongroup.ccg @@ -43,10 +43,10 @@ public: bool is_filename_option() const { return slot_filename_ != 0; } - + const OptionGroup::SlotOptionArgString* get_slot_string() const { return slot_string_; } - + const OptionGroup::SlotOptionArgFilename* get_slot_filename() const { return slot_filename_; } @@ -743,8 +743,8 @@ void OptionGroup::CppOptionEntry::convert_c_to_cpp() //Glib::StringArrayHandle array_handle(*typed_arg, Glib::OWNERSHIP_NONE); //The SUN Forte compiler complains about this: - // "optiongroup.cc", line 354: Error: Cannot assign Glib::ArrayHandle<Glib::ustring, - // Glib::Container_Helpers::TypeTraits<Glib::ustring>> to std::vector<Glib::ustring> without + // "optiongroup.cc", line 354: Error: Cannot assign Glib::ArrayHandle<Glib::ustring, + // Glib::Container_Helpers::TypeTraits<Glib::ustring>> to std::vector<Glib::ustring> without // "std::vector<Glib::ustring>::operator=(const std::vector<Glib::ustring>&)";. // //(*typed_cpp_arg) = array_handle; @@ -777,7 +777,7 @@ void OptionGroup::CppOptionEntry::convert_c_to_cpp() char*** typed_arg = static_cast<char***>(carg_); vecustrings* typed_cpp_arg = static_cast<vecustrings*>(cpparg_); if(typed_arg && typed_cpp_arg) - { + { typed_cpp_arg->clear(); //See comments above about the SUN Forte and Tru64 compilers. @@ -808,7 +808,7 @@ void OptionGroup::CppOptionEntry::convert_c_to_cpp() break; } } -} +} GOptionGroup* OptionGroup::gobj_give_ownership() { diff --git a/glib/src/optiongroup.hg b/glib/src/optiongroup.hg index 59fd1171..7d330eb6 100644 --- a/glib/src/optiongroup.hg +++ b/glib/src/optiongroup.hg @@ -37,7 +37,7 @@ class OptionEntry; class OptionContext; #endif //DOXYGEN_SHOULD_SKIP_THIS -/** An OptionGroup defines the options in a single group. +/** An OptionGroup defines the options in a single group. * Libraries which need to parse commandline options are expected to provide a function that allows their OptionGroups to * be added to the application's OptionContext. */ @@ -53,7 +53,7 @@ public: * const Glib::ustring& value, bool has_value);. */ typedef sigc::slot<bool, const Glib::ustring&, const Glib::ustring&, bool> SlotOptionArgString; - + /** For example bool on_option_arg_filename(const Glib::ustring& option_name, * const std::string& value, bool has_value);. */ @@ -61,10 +61,10 @@ public: OptionGroup(const Glib::ustring& name, const Glib::ustring& description, const Glib::ustring& help_description = Glib::ustring()); - /** This always takes ownership of the underlying GOptionGroup, - * so it is only useful with C functions that return newly-allocated GOptionGroups. + /** This always takes ownership of the underlying GOptionGroup, + * so it is only useful with C functions that return newly-allocated GOptionGroups. */ - explicit OptionGroup(GOptionGroup* castitem); + explicit OptionGroup(GOptionGroup* castitem); _IGNORE(g_option_group_new) virtual ~OptionGroup(); @@ -87,7 +87,7 @@ public: void add_entry(const OptionEntry& entry, int& arg); void add_entry(const OptionEntry& entry, double& arg); void add_entry(const OptionEntry& entry, Glib::ustring& arg); - void add_entry_filename(const OptionEntry& entry, std::string& arg); + void add_entry_filename(const OptionEntry& entry, std::string& arg); void add_entry(const OptionEntry& entry, vecustrings& arg); void add_entry_filename(const OptionEntry& entry, vecstrings& arg); void add_entry(const OptionEntry& entry, const SlotOptionArgString& slot); diff --git a/glib/src/regex.hg b/glib/src/regex.hg index 63f0dff1..33b1701b 100644 --- a/glib/src/regex.hg +++ b/glib/src/regex.hg @@ -43,53 +43,53 @@ class MatchInfo; /** Perl-compatible regular expressions - matches strings against regular expressions. * - * The Glib::Regex functions implement regular expression pattern matching using + * The Glib::Regex functions implement regular expression pattern matching using * syntax and semantics similar to Perl regular expression. * - * Some functions accept a start_position argument, setting it differs from just - * passing over a shortened string and setting REGEX_MATCH_NOTBOL in the case - * of a pattern that begins with any kind of lookbehind assertion. For example, - * consider the pattern "\Biss\B" which finds occurrences of "iss" in the middle - * of words. ("\B" matches only if the current position in the subject is not a - * word boundary.) When applied to the string "Mississipi" from the fourth byte, - * namely "issipi", it does not match, because "\B" is always false at the - * start of the subject, which is deemed to be a word boundary. However, if - * the entire string is passed , but with start_position set to 4, it finds the + * Some functions accept a start_position argument, setting it differs from just + * passing over a shortened string and setting REGEX_MATCH_NOTBOL in the case + * of a pattern that begins with any kind of lookbehind assertion. For example, + * consider the pattern "\Biss\B" which finds occurrences of "iss" in the middle + * of words. ("\B" matches only if the current position in the subject is not a + * word boundary.) When applied to the string "Mississipi" from the fourth byte, + * namely "issipi", it does not match, because "\B" is always false at the + * start of the subject, which is deemed to be a word boundary. However, if + * the entire string is passed , but with start_position set to 4, it finds the * second occurrence of "iss" because it is able to look behind the starting point * to discover that it is preceded by a letter. * - * Note that, unless you set the REGEX_RAW flag, all the strings passed to these + * Note that, unless you set the REGEX_RAW flag, all the strings passed to these * functions must be encoded in UTF-8. The lengths and the positions inside the - * strings are in bytes and not in characters, so, for instance, - * "\xc3\xa0" (i.e. "à") is two bytes long but it is treated as a single + * strings are in bytes and not in characters, so, for instance, + * "\xc3\xa0" (i.e. "à") is two bytes long but it is treated as a single * character. If you set REGEX_RAW the strings can be non-valid UTF-8 strings - * and a byte is treated as a character, so "\xc3\xa0" is two bytes and + * and a byte is treated as a character, so "\xc3\xa0" is two bytes and * two characters long. * - * When matching a pattern, "\n" matches only against a "\n" character in the - * string, and "\r" matches only a "\r" character. To match any newline sequence - * use "\R". This particular group matches either the two-character sequence + * When matching a pattern, "\n" matches only against a "\n" character in the + * string, and "\r" matches only a "\r" character. To match any newline sequence + * use "\R". This particular group matches either the two-character sequence * CR + LF ("\r\n"), or one of the single characters LF (linefeed, U+000A, "\n"), - * VT (vertical tab, U+000B, "\v"), FF (formfeed, U+000C, "\f"), CR (carriage - * return, U+000D, "\r"), NEL (next line, U+0085), LS (line separator, U+2028), + * VT (vertical tab, U+000B, "\v"), FF (formfeed, U+000C, "\f"), CR (carriage + * return, U+000D, "\r"), NEL (next line, U+0085), LS (line separator, U+2028), * or PS (paragraph separator, U+2029). * - * The behaviour of the dot, circumflex, and dollar metacharacters are affected + * The behaviour of the dot, circumflex, and dollar metacharacters are affected * by newline characters, the default is to recognize any newline character (the * same characters recognized by "\R"). This can be changed with REGEX_NEWLINE_CR, - * REGEX_NEWLINE_LF and REGEX_NEWLINE_CRLF compile options, and with - * REGEX_MATCH_NEWLINE_ANY, REGEX_MATCH_NEWLINE_CR, REGEX_MATCH_NEWLINE_LF - * and REGEX_MATCH_NEWLINE_CRLF match options. These settings are also + * REGEX_NEWLINE_LF and REGEX_NEWLINE_CRLF compile options, and with + * REGEX_MATCH_NEWLINE_ANY, REGEX_MATCH_NEWLINE_CR, REGEX_MATCH_NEWLINE_LF + * and REGEX_MATCH_NEWLINE_CRLF match options. These settings are also * relevant when compiling a pattern if REGEX_EXTENDED is set, and an unescaped - * "#" outside a character class is encountered. This indicates a comment that + * "#" outside a character class is encountered. This indicates a comment that * lasts until after the next newline. * - * Creating and manipulating the same Glib::Regex class from different threads is - * not a problem as Glib::Regex does not modify its internal state between creation and + * Creating and manipulating the same Glib::Regex class from different threads is + * not a problem as Glib::Regex does not modify its internal state between creation and * destruction, on the other hand Glib::MatchInfo is not threadsafe. * - * The regular expressions low level functionalities are obtained through the - * excellent PCRE library written by Philip Hazel. + * The regular expressions low level functionalities are obtained through the + * excellent PCRE library written by Philip Hazel. * * @newin{2,14} */ @@ -100,12 +100,12 @@ class Regex public: static Glib::RefPtr<Glib::Regex> create(const Glib::ustring& pattern, RegexCompileFlags compile_options = static_cast<RegexCompileFlags>(0), RegexMatchFlags match_options = static_cast<RegexMatchFlags>(0)); - + _WRAP_METHOD(Glib::ustring get_pattern() const, g_regex_get_pattern) _WRAP_METHOD(int get_max_backref() const, g_regex_get_max_backref) _WRAP_METHOD(int get_capture_count() const, g_regex_get_capture_count) _WRAP_METHOD(bool get_has_cr_or_lf() const, g_regex_get_has_cr_or_lf) - + _WRAP_METHOD(int get_string_number(const Glib::ustring& name) const, g_regex_get_string_number) _WRAP_METHOD(RegexCompileFlags get_compile_flags() const, g_regex_get_compile_flags) _WRAP_METHOD(RegexMatchFlags get_match_flags() const, g_regex_get_match_flags) diff --git a/glib/src/spawn.hg b/glib/src/spawn.hg index d1778339..889a38d8 100644 --- a/glib/src/spawn.hg +++ b/glib/src/spawn.hg @@ -44,7 +44,7 @@ _WRAP_GERROR(SpawnError, GSpawnError, G_SPAWN_ERROR, NO_GTYPE, s#^2BIG$#TOOBIG#) * specified by the only argument that must be provided, @a argv. * The first string in @a argv is of * course the name of the program to execute. By default, the name of - * the program must be a full path; the PATH shell variable + * the program must be a full path; the PATH shell variable * will only be searched if you pass the SPAWN_SEARCH_PATH flag. * * On Windows, note that all the string or string vector arguments to @@ -87,25 +87,25 @@ _WRAP_GERROR(SpawnError, GSpawnError, G_SPAWN_ERROR, NO_GTYPE, s#^2BIG$#TOOBIG#) * the child's environment. * * @a flags should be the bitwise OR of any flags you want to affect the - * function's behaviour. The SPAWN_DO_NOT_REAP_CHILD flags means that + * function's behaviour. The SPAWN_DO_NOT_REAP_CHILD flags means that * the child will not automatically be reaped; you must use a - * ChildWatch source to be notified about the death of the child + * ChildWatch source to be notified about the death of the child * process. Eventually you must call spawn_close_pid() on the * @a child_pid, in order to free resources which may be associated * with the child process. (On Unix, using a ChildWatch source is - * equivalent to calling waitpid() or handling the SIGCHLD signal + * equivalent to calling waitpid() or handling the SIGCHLD signal * manually. On Windows, calling spawn_close_pid() is equivalent - * to calling CloseHandle() on the process handle returned in + * to calling CloseHandle() on the process handle returned in * @a child_pid). * * PAWN_LEAVE_DESCRIPTORS_OPEN means that the parent's open file * descriptors will be inherited by the child; otherwise all * descriptors except stdin/stdout/stderr will be closed before - * calling exec() in the child. SPAWN_SEARCH_PATH + * calling exec() in the child. SPAWN_SEARCH_PATH * means that argv[0] need not be an absolute path, it - * will be looked for in the user's PATH. - * SPAWN_STDOUT_TO_DEV_NULL means that the child's standard output will - * be discarded, instead of going to the same location as the parent's + * will be looked for in the user's PATH. + * SPAWN_STDOUT_TO_DEV_NULL means that the child's standard output will + * be discarded, instead of going to the same location as the parent's * standard output. If you use this flag, @a standard_output must be NULL. * SPAWN_STDERR_TO_DEV_NULL means that the child's standard error * will be discarded, instead of going to the same location as the parent's @@ -141,7 +141,7 @@ _WRAP_GERROR(SpawnError, GSpawnError, G_SPAWN_ERROR, NO_GTYPE, s#^2BIG$#TOOBIG#) * SPAWN_DO_NOT_REAP_CHILD flag. You can then access the child * process using the Win32 API, for example wait for its termination * with the WaitFor*() functions, or examine its - * exit code with GetExitCodeProcess(). You should close the handle + * exit code with GetExitCodeProcess(). You should close the handle * with CloseHandle() or spawn_close_pid() when you no longer need it. * * If non-NULL, the @a standard_input, @a standard_output, @a standard_error @@ -151,24 +151,24 @@ _WRAP_GERROR(SpawnError, GSpawnError, G_SPAWN_ERROR, NO_GTYPE, s#^2BIG$#TOOBIG#) * when they are no longer in use. If these parameters are NULL, the corresponding * pipe won't be created. * - * If @a standard_input is NULL, the child's standard input is attached to + * If @a standard_input is NULL, the child's standard input is attached to * /dev/null unless SPAWN_CHILD_INHERITS_STDIN is set. * - * If @a standard_error is NULL, the child's standard error goes to the same - * location as the parent's standard error unless SPAWN_STDERR_TO_DEV_NULL + * If @a standard_error is NULL, the child's standard error goes to the same + * location as the parent's standard error unless SPAWN_STDERR_TO_DEV_NULL * is set. * - * If @a standard_output is NULL, the child's standard output goes to the same - * location as the parent's standard output unless SPAWN_STDOUT_TO_DEV_NULL + * If @a standard_output is NULL, the child's standard output goes to the same + * location as the parent's standard output unless SPAWN_STDOUT_TO_DEV_NULL * is set. * * If @a child_pid is not NULL and an error does not occur then the returned * pid must be closed using spawn_close_pid(). * * @note - * If you are writing a gtkmm application, and the program you + * If you are writing a gtkmm application, and the program you * are spawning is a graphical application, too, then you may - * want to use spawn_on_screen_with_pipes() instead to ensure that + * want to use spawn_on_screen_with_pipes() instead to ensure that * the spawned program opens its windows on the right screen. * * @param working_directory Child's current working directory, or an empty string to inherit the parent's, in the GLib file name encoding. @@ -225,11 +225,11 @@ void spawn_async_with_pipes(const std::string& working_directory, /** See pawn_async_with_pipes() for a full description. This function * simply calls the spawn_async_with_pipes() without any pipes. - * + * * @note - * If you are writing a GTK+ application, and the program you + * 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 + * want to use gdk_spawn_on_screen() instead to ensure that * the spawned program opens its windows on the right screen. * * @param working_directory Child's current working directory, or an empty string to inherit parent's. @@ -273,21 +273,21 @@ void spawn_async(const std::string& working_directory, /** Executes a child synchronously (waits for the child to exit before returning). * All output from the child is stored in @a standard_output and @a standard_error, - * if those parameters are non-NULL. Note that you must set the + * if those parameters are non-NULL. Note that you must set the * SPAWN_STDOUT_TO_DEV_NULL and SPAWN_STDERR_TO_DEV_NULL flags when * passing NULL for @a standard_output and @a standard_error. * If @a exit_status is non-NULL, the exit status of the child is stored - * there as it would be returned by waitpid(); standard UNIX macros such + * there as it would be returned by waitpid(); standard UNIX macros such * as WIFEXITED() and WEXITSTATUS() must be used to evaluate the exit status. * Note that this function calls waitpid() even if @a exit_status is NULL, and * does not accept the SPAWN_DO_NOT_REAP_CHILD flag. - * If an error occurs, no data is returned in @a standard_output, - * @a standard_error, or @a exit_status. + * If an error occurs, no data is returned in @a standard_output, + * @a standard_error, or @a exit_status. * * This function calls spawn_async_with_pipes() internally; see that * function for full details on the other parameters and details on * how these functions work on Windows. - * + * * @param working_directory Child's current working directory, or an empty string to inherit the parent's, in the GLib file name encoding. * @param argv Child's argument vector. * @param envp Child's environment. @@ -313,7 +313,7 @@ void spawn_sync(const std::string& working_directory, int* exit_status = 0); /** Like the main spawn_sync() method, but inheriting the parent's environment. - * + * * @param working_directory Child's current working directory, or an empty string to inherit the parent's, in the GLib file name encoding. * @param argv Child's argument vector. * @param flags Flags from SpawnFlags @@ -341,8 +341,8 @@ void spawn_sync(const std::string& working_directory, * command line in the background. Unlike spawn_async(), the * SPAWN_SEARCH_PATH flag is enabled, other flags are not. Note * that SPAWN_SEARCH_PATH can have security implications, so - * consider using spawn_async() directly if appropriate. - * + * consider using spawn_async() directly if appropriate. + * * The same concerns on Windows apply as for spawn_command_line_sync(). * * @param command_line A command line. @@ -366,9 +366,9 @@ void spawn_command_line_async(const std::string& command_line); * If @a exit_status is non-NULL, the exit status of the child is stored there as * it would be returned by waitpid(); standard UNIX macros such as WIFEXITED() * and WEXITSTATUS() must be used to evaluate the exit status. - * + * * On Windows, please note the implications of shell_parse_argv() - * parsing @a command_line. Parsing is done according to Unix shell rules, not + * parsing @a command_line. Parsing is done according to Unix shell rules, not * Windows command interpreter rules. * Space is a separator, and backslashes are * special. Thus you cannot simply pass a @a command_line containing @@ -377,7 +377,7 @@ void spawn_command_line_async(const std::string& command_line); * separator. You need to enclose such paths with single quotes, like * "'c:\\program files\\app\\app.exe' 'e:\\folder\\argument.txt'". * - * @param command_line A command line. + * @param command_line A command line. * @param standard_output Return location for child output. * @param standard_error Return location for child errors. * @param exit_status Return location for child exit status, as returned by waitpid(). @@ -400,7 +400,7 @@ void spawn_command_line_sync(const std::string& command_line, * * @param pid The process identifier to close. */ -void spawn_close_pid(Pid pid); +void spawn_close_pid(Pid pid); /** @} group Spawn */ diff --git a/glib/src/thread.ccg b/glib/src/thread.ccg index a6f346a6..cfc38952 100644 --- a/glib/src/thread.ccg +++ b/glib/src/thread.ccg @@ -56,7 +56,7 @@ namespace Glib { // This was always meant as an internal method. It is no longer called, -// and no longer needs to be called. We are keeping it just to avoid +// and no longer needs to be called. We are keeping it just to avoid // breaking ABI, though hopefully nobody is using it anyway. // TODO: Remove this when we can break ABI. void thread_init_impl() @@ -148,10 +148,10 @@ ThreadPriority Thread::get_priority() const void thread_init(GThreadFunctions* /* vtable */) { //g_thread_init() is deprecated and now does nothing, - //so we do not even call it. That avoids a need to link to gthread-2.0, + //so we do not even call it. That avoids a need to link to gthread-2.0, //which contains the empty g_thread_init() implementation. //g_thread_init(vtable); - + Glib::thread_init_impl(); } diff --git a/glib/src/thread.hg b/glib/src/thread.hg index 1bc10dce..fb6f19b7 100644 --- a/glib/src/thread.hg +++ b/glib/src/thread.hg @@ -33,7 +33,7 @@ _IS_DEPRECATED // This whole file is deprecated. //Stop the deprecation ifdef guards around the API declarations: #undef G_DISABLE_DEPRECATED -//Stop the compiler warnings about using the deprecated API; +//Stop the compiler warnings about using the deprecated API; #define GLIB_DISABLE_DEPRECATION_WARNINGS 1 #define GLIBMM_G_DISABLE_DEPRECATED_UNDEFED 1 @@ -71,7 +71,7 @@ enum { THREAD_PRIORITY_NORMAL = GLIBMM_MACRO_DEFINITION_THREAD_PRIORITY_NORMAL } * @relates Glib::StaticRecMutex * @hideinitializer * - * @deprecated Glib::StaticRecMutex is deprecated in favour of Glib::Threads::RecMutex, which can be used statically. + * @deprecated Glib::StaticRecMutex is deprecated in favour of Glib::Threads::RecMutex, which can be used statically. */ #define GLIBMM_STATIC_REC_MUTEX_INIT { G_STATIC_REC_MUTEX_INIT } @@ -79,7 +79,7 @@ enum { THREAD_PRIORITY_NORMAL = GLIBMM_MACRO_DEFINITION_THREAD_PRIORITY_NORMAL } * @relates Glib::StaticRWLock * @hideinitializer * - * @deprecated Glib::StaticRWLock is deprecated in favour of Glib::Threads::RWLock, which can be used statically. + * @deprecated Glib::StaticRWLock is deprecated in favour of Glib::Threads::RWLock, which can be used statically. */ #define GLIBMM_STATIC_RW_LOCK_INIT { G_STATIC_RW_LOCK_INIT } @@ -87,7 +87,7 @@ enum { THREAD_PRIORITY_NORMAL = GLIBMM_MACRO_DEFINITION_THREAD_PRIORITY_NORMAL } * @relates Glib::StaticPrivate * @hideinitializer * - * @deprecated Glib::StaticPrivate is deprecated in favour of Glib::Threads::Private, which can be used statically. + * @deprecated Glib::StaticPrivate is deprecated in favour of Glib::Threads::Private, which can be used statically. */ #define GLIBMM_STATIC_PRIVATE_INIT { G_STATIC_PRIVATE_INIT } @@ -247,7 +247,7 @@ public: * @return The new Thread* on success. * @throw Glib::ThreadError * - * @deprecated Use the simpler create() method instead, because all Threads + * @deprecated Use the simpler create() method instead, because all Threads * are now joinable, and bounds and priority parameters now have no effect. */ static Thread* create(const sigc::slot<void>& slot, unsigned long stack_size, @@ -259,7 +259,7 @@ public: * @deprecated All threads are now joinable. */ bool joinable() const; - + /** Changes the priority of the thread to @a priority. * @note It is not guaranteed, that threads with different priorities really * behave accordingly. On some systems (e.g. Linux) only @c root can @@ -336,7 +336,7 @@ struct StaticMutex; * conversion to Mutex&, thus you can safely use Mutex::Lock with a * StaticMutex. * - * @deprecated Use Glib::Threads::Mutex instead, which can be used statically. + * @deprecated Use Glib::Threads::Mutex instead, which can be used statically. */ struct StaticMutex { @@ -358,7 +358,7 @@ struct StaticMutex * @relates Glib::StaticMutex * @hideinitializer * - * @deprecated Glib::StaticMutex is deprecated in favour of Glib::Threads::Mutex, which can be used statically. + * @deprecated Glib::StaticMutex is deprecated in favour of Glib::Threads::Mutex, which can be used statically. */ #define GLIBMM_STATIC_MUTEX_INIT { G_STATIC_MUTEX_INIT } @@ -630,9 +630,9 @@ private: RWLock::WriterLock& operator=(const RWLock::WriterLock&); }; -/** An opaque data structure to represent a condition. - * A @a Cond is an object that threads can block on, if they find a certain - * condition to be false. If other threads change the state of this condition +/** An opaque data structure to represent a condition. + * A @a Cond is an object that threads can block on, if they find a certain + * condition to be false. If other threads change the state of this condition * they can signal the @a Cond, such that the waiting thread is woken up. * @par Usage example: * @code @@ -670,15 +670,15 @@ public: Cond(); ~Cond(); - /** If threads are waiting for this @a Cond, exactly one of them is woken up. - * It is good practice to hold the same lock as the waiting thread, while calling + /** If threads are waiting for this @a Cond, exactly one of them is woken up. + * It is good practice to hold the same lock as the waiting thread, while calling * this method, though not required. * */ void signal(); /** If threads are waiting for this @a Cond, all of them are woken up. - * It is good practice to hold the same lock as the waiting thread, while calling + * It is good practice to hold the same lock as the waiting thread, while calling * this method, though not required. */ void broadcast(); @@ -687,12 +687,12 @@ public: * The mutex is unlocked before falling asleep and locked again before resuming. * * @param mutex a @a Mutex that is currently locked. - * + * * @note It is important to use the @a wait() and @a timed_wait() methods - * only inside a loop, which checks for the condition to be true as it is not - * guaranteed that the waiting thread will find it fulfilled, even if the signaling - * thread left the condition in that state. This is because another thread can have - * altered the condition, before the waiting thread got the chance to be woken up, + * only inside a loop, which checks for the condition to be true as it is not + * guaranteed that the waiting thread will find it fulfilled, even if the signaling + * thread left the condition in that state. This is because another thread can have + * altered the condition, before the waiting thread got the chance to be woken up, * even if the condition itself is protected by a @a Mutex. */ void wait(Mutex& mutex); @@ -702,12 +702,12 @@ public: * * @param mutex a @a Mutex that is currently locked. * @param abs_time a max time to wait. - * + * * @note It is important to use the @a wait() and @a timed_wait() methods - * only inside a loop, which checks for the condition to be true as it is not - * guaranteed that the waiting thread will find it fulfilled, even if the signaling - * thread left the condition in that state. This is because another thread can have - * altered the condition, before the waiting thread got the chance to be woken up, + * only inside a loop, which checks for the condition to be true as it is not + * guaranteed that the waiting thread will find it fulfilled, even if the signaling + * thread left the condition in that state. This is because another thread can have + * altered the condition, before the waiting thread got the chance to be woken up, * even if the condition itself is protected by a @a Mutex. */ bool timed_wait(Mutex& mutex, const Glib::TimeVal& abs_time); diff --git a/glib/src/threads.hg b/glib/src/threads.hg index 10ef5ddf..01de9689 100644 --- a/glib/src/threads.hg +++ b/glib/src/threads.hg @@ -390,9 +390,9 @@ private: RWLock::WriterLock& operator=(const RWLock::WriterLock&); }; -/** An opaque data structure to represent a condition. - * A @a Cond is an object that threads can block on, if they find a certain - * condition to be false. If other threads change the state of this condition +/** An opaque data structure to represent a condition. + * A @a Cond is an object that threads can block on, if they find a certain + * condition to be false. If other threads change the state of this condition * they can signal the @a Cond, such that the waiting thread is woken up. * @par Usage example: * @code @@ -428,15 +428,15 @@ public: Cond(); ~Cond(); - /** If threads are waiting for this @a Cond, exactly one of them is woken up. - * It is good practice to hold the same lock as the waiting thread, while calling + /** If threads are waiting for this @a Cond, exactly one of them is woken up. + * It is good practice to hold the same lock as the waiting thread, while calling * this method, though not required. * */ void signal(); /** If threads are waiting for this @a Cond, all of them are woken up. - * It is good practice to hold the same lock as the waiting thread, while calling + * It is good practice to hold the same lock as the waiting thread, while calling * this method, though not required. */ void broadcast(); @@ -445,12 +445,12 @@ public: * The mutex is unlocked before falling asleep and locked again before resuming. * * @param mutex a @a Mutex that is currently locked. - * + * * @note It is important to use the @a wait() and @a wait_until() methods - * only inside a loop, which checks for the condition to be true as it is not - * guaranteed that the waiting thread will find it fulfilled, even if the signaling - * thread left the condition in that state. This is because another thread can have - * altered the condition, before the waiting thread got the chance to be woken up, + * only inside a loop, which checks for the condition to be true as it is not + * guaranteed that the waiting thread will find it fulfilled, even if the signaling + * thread left the condition in that state. This is because another thread can have + * altered the condition, before the waiting thread got the chance to be woken up, * even if the condition itself is protected by a @a Mutex. */ void wait(Mutex& mutex); @@ -460,12 +460,12 @@ public: * * @param mutex a @a Mutex that is currently locked. * @param abs_time a max time to wait. - * + * * @note It is important to use the @a wait() and @a wait_until() methods - * only inside a loop, which checks for the condition to be true as it is not - * guaranteed that the waiting thread will find it fulfilled, even if the signaling - * thread left the condition in that state. This is because another thread can have - * altered the condition, before the waiting thread got the chance to be woken up, + * only inside a loop, which checks for the condition to be true as it is not + * guaranteed that the waiting thread will find it fulfilled, even if the signaling + * thread left the condition in that state. This is because another thread can have + * altered the condition, before the waiting thread got the chance to be woken up, * even if the condition itself is protected by a @a Mutex. */ bool wait_until(Mutex& mutex, gint64 end_time); diff --git a/glib/src/uriutils.hg b/glib/src/uriutils.hg index 6ef99d96..a1a6f890 100644 --- a/glib/src/uriutils.hg +++ b/glib/src/uriutils.hg @@ -26,12 +26,12 @@ namespace Glib * Various uri-related functions. */ -//Note that the illegal_characters and reserved_chars_allowed parameters are bytes and may not be UTF-8 +//Note that the illegal_characters and reserved_chars_allowed parameters are bytes and may not be UTF-8 //so they are not Glib::ustring. See http://bugzilla.gnome.org/show_bug.cgi?id=508773 /** Unescapes a whole escaped string. * If any of the characters in @a illegal_characters or the character zero appears - * as an escaped character in @a escaped_string then that is an error and an empty string + * as an escaped character in @a escaped_string then that is an error and an empty string * will be returned. This is useful it you want to avoid, for instance, having a * slash being expanded in an escaped path element, which might confuse pathname * handling. @@ -39,26 +39,26 @@ namespace Glib * @param escaped_string An escaped string to be unescaped. * @param illegal_characters An optional string of illegal characters not to be allowed. * @result An unescaped version of @a escaped_string. - * + * * @ingroup UriUtils * @newin{2,16} */ std::string uri_unescape_string(const std::string& escaped_string, const std::string& illegal_characters = std::string()); -//TODO: Use iterator? +//TODO: Use iterator? //char * g_uri_unescape_segment (const char *escaped_string, // const char *escaped_string_end, // const char *illegal_characters); /** Gets the scheme portion of a URI. RFC 3986 decodes the scheme as: * @code - * URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ] + * URI = scheme ":" hier-part [ "?" query ] [ "#" fragment ] * @endcode * Common schemes include "file", "http", "svn+ssh", etc. * * @param uri - * @result The "Scheme" component of the URI, or an empty string on error. - * + * @result The "Scheme" component of the URI, or an empty string on error. + * * @ingroup UriUtils * @newin{2,16} */ diff --git a/glib/src/variant.ccg b/glib/src/variant.ccg index 8dc5ad80..ded44d5d 100644 --- a/glib/src/variant.ccg +++ b/glib/src/variant.ccg @@ -131,7 +131,7 @@ VariantContainerBase::create_tuple(const VariantBase& child) //static VariantContainerBase -VariantContainerBase::create_maybe(const VariantType& child_type, +VariantContainerBase::create_maybe(const VariantType& child_type, const VariantBase& child) { GVariant* g_variant = g_variant_new_maybe(child_type.gobj(), diff --git a/glib/src/variantiter.hg b/glib/src/variantiter.hg index 9ecf193e..8382ab4e 100644 --- a/glib/src/variantiter.hg +++ b/glib/src/variantiter.hg @@ -49,7 +49,7 @@ public: bool next_value(VariantBase& value); _IGNORE(g_variant_iter_next_value) - + // Ignore varargs function _IGNORE(g_variant_iter_next) }; diff --git a/glib/src/varianttype.ccg b/glib/src/varianttype.ccg index c60031e2..6cd317ec 100644 --- a/glib/src/varianttype.ccg +++ b/glib/src/varianttype.ccg @@ -41,12 +41,12 @@ VariantType& VariantType::operator=(const GVariantType* castitem) { g_variant_type_free (gobject_); } - + if(castitem) gobject_ = g_variant_type_copy(castitem); else gobject_ = 0; - + return *this; } |