Commit Graph

1751 Commits

Author SHA1 Message Date
Dan Winship
f9c2362e43 glib-mkenums: add --identifier-prefix and --symbol-prefix args
Allow passing --identifier-prefix and --symbol-prefix to glib-mkenums,
with the same meanings as in g-ir-scanner, to allow fixing up the enum
name parsing globally rather than needing to add a /<* *>/ override to
each enum.

https://bugzilla.gnome.org/show_bug.cgi?id=661797
2011-10-28 18:04:28 -04:00
Dan Winship
78a0dbd853 docs: don't refer to a deprecated glib-mkenums flag
Refer to the new flag instead

https://bugzilla.gnome.org/show_bug.cgi?id=661797
2011-10-28 18:04:28 -04:00
Sjoerd Simons
6a81ced72d Fix document generation in out of tree builds
https://bugzilla.gnome.org/show_bug.cgi?id=662390
2011-10-24 20:40:35 -04:00
Ryan Lortie
3d13ee1b5f GVariant format string docs: fix maybe types
The documentation for maybe types failed to mention 'a' as one of the
types that was handled with a single pointer for which NULL means
"nothing".  Correct that omission.

Problem caught by Shaun McCance.
2011-10-21 15:04:37 -04:00
Ryan Lortie
2a98cc635e The usual docs unbreaking... 2011-10-19 15:07:22 -04:00
Ryan Lortie
aba0f0c38b gatomic: introduce G_ATOMIC_LOCK_FREE
We clean up the detection of if we should do 'real' atomic operations or
mutex-emulated ones with the introduction of a new (public) macro:
G_ATOMIC_LOCK_FREE.  If defined, our atomic operations are guaranteed to
be done in hardware.

We need to use __GCC_HAVE_SYNC_COMPARE_AND_SWAP_4 to determine if our
compiler supports GCC-style atomic operations from the gatomic.h header
because we might be building a program against GLib using a different
set of compiler options (or a different compiler) than was used to build
GLib itself.

Unfortunately, this macro is not available on clang, so it has currently
regressed to using the mutex emulation.  A bug about that has been
opened here:

  http://llvm.org/bugs/show_bug.cgi?id=11174
2011-10-18 16:45:28 -04:00
David Zeuthen
915e2238c4 gio: Introduce get_sort_key() methods on GDrive, GVolume and GMount
This is needed to implement efficient and predictable proxy volume
monitors, see

 https://bugzilla.gnome.org/show_bug.cgi?id=661711

for details.

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-10-18 14:29:18 -04:00
Matthias Clasen
45f221c32f Move GTrashStack out of gutils.[hc]
Reducing the mess in gutils, and moving docs inline
at the same time. Double win.
2011-10-16 16:52:24 -04:00
Matthias Clasen
d0bb1e0b0a Move g_get_codeset next to g_get_charset
g_get_codeset is a close relatove to g_get_charset, and up to now
it lived a shadowy existence without any header presence.
2011-10-15 23:27:28 -04:00
Giovanni Campagna
96817746d9 Turn GKeyFile into a boxed for introspection
Using the new refcounting API, introduce a boxed type wrapping
GKeyFile and expose it introspection bindings in glib-types.h.
2011-10-15 17:51:25 -04:00
Christian Persch
a57c9148cf GKeyFile: Add refcounting API
Adds g_key_file_ref and g_key_file_unref, to be used by a future
GKeyFile boxed type for language bindings.

Based on the patch by Christian Persch and Emmanuele Bassi.

Author: Christian Persch
Signed-off-by: Johan Dahlin
Signed-off-by: Giovanni Campagna

https://bugzilla.gnome.org/show_bug.cgi?id=590808
2011-10-15 17:44:45 -04:00
Matthias Clasen
dfd75d2ead Add 'Since 2.32' indexes to gio and gobject docs 2011-10-15 17:31:47 -04:00
Dan Winship
de834bed30 GAppLaunchContext: add environment-manipulating functions
Add functions for manipulating the environment under which a
GAppLaunchContext will launch its children, to avoid thread-related
bugs with using setenv() directly.

FIXME: win32 side isn't implemented yet

https://bugzilla.gnome.org/show_bug.cgi?id=659326
2011-10-15 17:30:55 -04:00
Matthias Clasen
117e534091 Misc doc formatting fixes 2011-10-15 17:00:56 -04:00
Dan Winship
409d93148f gutils: Add functions for working with environment arrays
When spawning a child process, it is not safe to call setenv() before
the fork() (because setenv() isn't thread-safe), but it's also not
safe to call it after the fork() (because it's not async-signal-safe).
So the only safe way to alter the environment for a child process from
a threaded program is to pass a fully-formed envp array to
exec*/g_spawn*/etc.

So, add g_environ_getenv(), g_environ_setenv(), and
g_environ_unsetenv(), which act like their namesakes, but work on
arbitrary arrays rather than working directly on the environment.

http://bugzilla.gnome.org/show_bug.cgi?id=659326
2011-10-15 15:54:45 -04:00
Ryan Lortie
e75e9c3044 Rename g_thread_try to g_thread_try_new 2011-10-15 09:48:10 -04:00
Matthias Clasen
81431fa5b8 Add g_thread_try to the docs 2011-10-14 23:12:06 -04:00
Matthias Clasen
d000bf67f7 Update doc lists 2011-10-14 23:01:05 -04:00
Ryan Lortie
51773c6c64 Mask all signals in GLib worker thread
Some code using GLib (gnome-keyring-daemon, for example) assumes that
they can catch signals by masking them out in the main thread and
calling sigwait() from a worker.

The problem is that our new worker thread catches the signals before
sigwait() has a chance and the default action occurs (typically
resulting in program termination).

If we mask all the signals in our worker, then this can't happen.
2011-10-14 20:01:22 -04:00
Florian Müllner
1ed88f0615 desktop-app-info: Add support for X-GNOME-Keywords
With search gaining traction as being the preferred way to locate
applications, the existing .desktop file fields meant for browsing
often produce insufficient results.
gnome-control-center introduced a custom X-GNOME-Keywords field for
that purpose, which we plan to support in gnome-shell as well.

https://bugzilla.gnome.org/show_bug.cgi?id=661763
2011-10-14 23:30:21 +02:00
Ryan Lortie
4033c616ff GCond: use monotonic time for timed waits
Switch GCond to using monotonic time for timed waits by introducing a
new API based on monotonic time in a gint64: g_cond_wait_until().

Deprecate the old API based on wallclock time in a GTimeVal.

Fix up the gtk-doc for GCond while we're at it: update the examples to
use static-allocated GCond and GMutex and clarify some things a bit.
Also explain the rationale behind using an absolute time instead of a
relative time.
2011-10-13 23:44:17 -04:00
Matthias Clasen
6613b2f8fd Move more docs inline 2011-10-12 22:29:53 -04:00
Matthias Clasen
75ea14e885 Move GScanner docs inline 2011-10-12 21:49:44 -04:00
Matthias Clasen
2da83bbd36 Deprecate GCache
Ryan said it would be 'deprecated soon in GLib', when he removed
the use of this in GTK+. That was a year ago, so its about time
we act on it.
2011-10-12 19:55:02 -04:00
Matthias Clasen
7455dd370e Make single includes mandatory
This has been the official line since 2.17, which seems plenty
long enough for a transition phase.
2011-10-12 00:25:38 -04:00
Matthias Clasen
c6016458ba Update deprecation docs 2011-10-11 23:50:34 -04:00
Matthias Clasen
a1acf35653 Add our own deprecation macros
This will allow to suppress deprecation warnings on a per-module
basis, if needed. They are on by default now, though.
2011-10-11 13:42:58 -04:00
Matthias Clasen
0da0411a4a Add better deprecation macros
Unlike G_GNUC_... macros, the new G_DEPRECATED[_FOR] are
meant as abstractions that work with different compilers.
Using a new name also lets us restrict it to 'must be placed
before the declaration', which works with more compilers.

https://bugzilla.gnome.org/show_bug.cgi?id=661438
2011-10-11 13:13:27 -04:00
Dan Winship
59f1f54655 Add g_main_context_ref_thread_default()
Add g_main_context_ref_thread_default(), which always returns a
reffed GMainContext, rather than sometimes returning a (non-reffed)
GMainContext, and sometimes returning NULL. This simplifies the
bookkeeping in any code that needs to keep a reference to the
thread-default context for a while.

https://bugzilla.gnome.org/show_bug.cgi?id=660994
2011-10-07 10:14:34 -04:00
Ryan Lortie
e76927006a Move G_LOCK below GMutex in the docs
The flow is currently a bit wrong since G_LOCK makes reference to GMutex
which was not yet defined, so switch things around.
2011-10-06 12:24:21 -04:00
Ryan Lortie
761e75f849 .gitignore 2011-10-06 12:21:33 -04:00
Ryan Lortie
083812f854 Several docs cleanups 2011-10-06 12:19:58 -04:00
Ryan Lortie
94b7d2ee6c Cleanup thread documentation 2011-10-06 12:01:53 -04:00
Matthias Clasen
47c7fa2ccd Remove mention of gthread-2.0.pc from 'Compiling' section
At the same time, add one or two other corrections.
2011-10-05 22:31:17 -04:00
David Zeuthen
3f982cb9ab GUnixMountPoint: expose options
Make the options from an /etc/fstab entry available as public API -
this can be used to support options such as

 comment=gvfs.name=Foo\040Bar

to e.g. set the name of an fstab mount in the UI to "Foo Bar".

https://bugzilla.gnome.org/show_bug.cgi?id=660536

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-10-03 14:06:47 -04:00
Matthias Clasen
fa6710ab6f Documentation fixes 2011-10-02 23:43:45 -04:00
Ryan Lortie
2a677d1370 locks: drop _INIT macros
All locks are now zero-initialised, so we can drop the G_*_INIT macros
for them.

Adjust various users around GLib accordingly and change the docs.

https://bugzilla.gnome.org/show_bug.cgi?id=659866
2011-10-02 22:33:10 -04:00
Ryan Lortie
8e43470c38 Stop dithering over GPrivate
Take out the half-private g_private_init() stuff and replace it with a
G_PRIVATE_INIT macro that allows specifying a GDestroyNotify.

Expose the GPrivate structure in a public header.

Add a g_private_replace() to (sort of) match the functionality of
g_static_mutex_set().

Improve the documentation.

Deprecate g_private_new().
2011-10-02 20:04:03 -04:00
Javier Jardón
91713e950f docs: Use G_VALUE_INIT 2011-10-02 17:22:18 +01:00
Matthias Clasen
0e8bcc3ed7 Move GString docs inline 2011-10-01 23:27:45 -04:00
Matthias Clasen
7154d44c5c Move file utility docs inline 2011-10-01 23:03:09 -04:00
Matthias Clasen
ca77b0e252 Move string utility docs inline 2011-10-01 22:48:27 -04:00
Matthias Clasen
793ff83527 Move test docs inline 2011-10-01 22:00:41 -04:00
Matthias Clasen
9d3b37ac3f Move keyfile docs inline 2011-10-01 21:03:14 -04:00
Matthias Clasen
1af5ac0179 Add an index for 2.32 api additions 2011-10-01 13:47:54 -04:00
Stef Walter
5a95e19a46 gvariant: Add g_variant_get_fixed_array()
Using g_variant_new_from_data() for creating new byte arrays is non-obvious.
This patch adds a g_variant_new_fixed_array() function.

https://bugzilla.gnome.org/show_bug.cgi?id=659923
2011-09-25 07:57:26 +02:00
Matthias Clasen
81e395b00b More GThread docs tweaks 2011-09-25 01:32:41 -04:00
Matthias Clasen
4e44e23517 Drop G_THREADS_IMPL_NONE from the docs
GLib can no longer be built without thread support.
2011-09-25 01:00:59 -04:00
Matthias Clasen
a485a0e565 Document G_THREADS_IMPL_WIN32 2011-09-24 19:04:46 -04:00
Matthias Clasen
d6b0af99d7 GThread doc additions 2011-09-24 19:01:02 -04:00
Ryan Lortie
14e6377a60 Deprecate g_thread_create_full()
Replace it with g_thread_create_with_stack_size() and a real function
implementation of g_thread_create().

Modify a testcase that was calling g_thread_create_full()
inappropriately (it was using the default values anyway).
2011-09-21 16:06:55 -04:00
David Zeuthen
933ad70c32 gdbus-codegen: Clarify how naming and Ugly_Case handling works
Basically, move some paragraphs around.

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-09-21 07:14:28 -04:00
David Zeuthen
30537b84de gdbus-codegen: Update man page to reflect how --annotate actually works
Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-09-21 07:14:28 -04:00
Ryan Lortie
a2ea02d01e Move GAllocator/GMemChunk to separate file
Create a deprecated/ directory that we can start moving ancient chunks
of code to.  Start with GAllocator, GMemChunk and related APIs.

Also drop all mention of them from the docs.

https://bugzilla.gnome.org/show_bug.cgi?id=659427
2011-09-18 22:00:58 -04:00
Matthias Clasen
f18eab2ac7 GMappedFile: return an error when trying to map a device
Previously, we were returning an empty buffer for all filenames
where fstat() gives a size of 0. But this is only appropriate
for regular files.

Also improve the documentation around this issue. Based on a
patch by Ryan Lortie.

Conflicts:

	glib/tests/mappedfile.c

https://bugzilla.gnome.org/show_bug.cgi?id=659212
2011-09-17 20:03:00 -04:00
Ryan Lortie
cab5b8abd3 GType tutorial: clarify class struct initialisation
Make the information on how the class structure is initialised less
confusing to first-time readers.
2011-09-11 15:48:47 -04:00
Emmanuele Bassi
e15d5313af Add macros for GSourceFunc return values
The boolean values to be returned by a GSourceFunc are always ambiguous,
and even in case of experienced developers then can lead to confusion.

The Perl bindings for GLib have two simple constants, mapping to TRUE
and FALSE, that make the return values less confusing: G_SOURCE_CONTINUE
and G_SOURCE_REMOVE respectively.

https://bugzilla.gnome.org/show_bug.cgi?id=631413
2011-09-09 22:08:58 -04:00
Ryan Lortie
715f94e951 Remove support for DCE threads 2011-09-09 12:47:40 -04:00
Ryan Lortie
3534ff418c Update building docs to mention mandatory threads
The docs used to say thread support was optional -- it's mandatory now.
2011-09-09 12:47:39 -04:00
Ryan Lortie
8060a7a207 'master' is now glib 2.31.0 2011-09-06 10:55:09 -04:00
Ryan Lortie
8a7d33024a gio docs: lots more fixes 2011-09-06 00:31:49 -04:00
Ryan Lortie
e88d735787 gio docs: only include GTlsInteraction once
It was included twice in the gio-docs.xml file.
2011-09-06 00:01:29 -04:00
Ryan Lortie
f333aeb297 gio docs: drop GTimeZoneMonitor from docs 2011-09-05 23:56:33 -04:00
Ryan Lortie
a44b225ae7 Remove enums from gio.types
Only objects and interfaces should go in here.  If enums are in here
then gtk-doc responds by outputting two anchors for the same name (which
results in many warnings being printed).
2011-09-05 23:54:42 -04:00
Ryan Lortie
fb700d7ea3 GDBus object manager example: update -sections.txt 2011-09-05 19:41:16 -04:00
Ryan Lortie
c2e7ef17ac gio docs: ignore private .h files 2011-09-05 19:35:16 -04:00
Ryan Lortie
1f9c189e20 gio docs: don't scan subdirectories
This clears up >50% of the huge warning spew from building GIO docs.
2011-09-05 19:10:04 -04:00
Ryan Lortie
c14a971f32 docs fixups for glib/ 2011-09-05 19:00:11 -04:00
Ryan Lortie
9829d04be8 GObject docs: resolve broken links
Some links were broken due to typos, because functionality was removed
in GLib 2.0 or for various other reasons.  Fix up as many of them as is
reasonable.
2011-09-05 18:46:59 -04:00
Ryan Lortie
b402c3f014 gobject docs: add symbols from GMainLoop boxing 2011-09-05 18:05:05 -04:00
Ryan Lortie
b407086b38 Back out some changes to docs Makefiles
Commit ab0e9dbfa7 introduced some changes
to the documentation Makefiles designed to clean-up the process of
deciding which headers get scanned for the docs.

Unfortunately, the gtk-doc Makefile doesn't use HFILE_GLOB for actually
generating the docs -- only for knowing when it needs to redo the
generation.  Because of this, we need to use IGNORE_HFILES or otherwise
we get hundreds of symbols in the *-unused.txt files.

Revert the changes that that commit made to the docs Makefiles (but
leave the generation of the *-public-headers.txt files in place).
2011-09-05 18:01:39 -04:00
Ryan Lortie
ba6d70a99e include 'hmac' in the docs
It wasn't added to glib-docs.sgml, so it wasn't being included in the html.
2011-09-05 11:36:48 -04:00
Ryan Lortie
3b25e975b3 gtk-doc fixups for glib/ 2011-09-05 11:30:58 -04:00
Alexandre Franke
c32c9526ad Fix missing semi-colon after struct definition 2011-09-05 13:22:37 +02:00
Ryan Lortie
ab8938c64d Revert "gdatetime: Add g_date_time_source_new()"
This reverts three commits:

 - 1feb752996
 - 5763c63147
 - 21a5389340

https://bugzilla.gnome.org/show_bug.cgi?id=655129
2011-08-31 12:56:28 -04:00
Ryan Lortie
c0eb77bfc8 unix signal watch: make API match other sources
Change the unix signal watch API to match other sources in both
available functions, names of those functions and order of the
parameters to the _full function.

https://bugzilla.gnome.org/show_bug.cgi?id=657705
2011-08-30 19:22:54 -04:00
Matthias Clasen
d156492c83 Add a forgotten section 2011-08-30 00:09:51 -04:00
Matthias Clasen
258ecdfbe6 More doc additions 2011-08-30 00:09:51 -04:00
Matthias Clasen
b57f2e9327 Clean up gobject docs 2011-08-30 00:09:51 -04:00
Matthias Clasen
a8b128a01c Remove no-longer existing api 2011-08-30 00:09:51 -04:00
Matthias Clasen
c938250c33 Add a 'since 2.30' index to gobject docs 2011-08-29 21:43:50 -04:00
Colin Walters
1feb752996 gdatetime: Add g_date_time_source_new()
Several different codebases in GNOME want to implement wall clocks.
While we could pretty easily share a private library, it's not a
substantial amount of code, and GLib already has a lot of the
necessary system-specific detection and handling infrastructure.

Note this initial implementation just wakes up once a second in the
cancel_on_set case; we'll add the Linux-specific handling in a
subsequent commit.

https://bugzilla.gnome.org/show_bug.cgi?id=655129
2011-08-29 10:24:08 -04:00
Stef Walter
d789e78dff giomodule: When loading GIO_EXTRA_MODULES skip duplicates
* Load modules from paths listed in GIO_EXTRA_MODULES environment
   variable first.
 * Ignore duplicate modules based on module basename.
 * Add the concept of GIOModuleScope which allows other callers to
   skip duplicate loaded modules, or block specific modules based on
   basename.
 * Document behavior.

https://bugzilla.gnome.org/show_bug.cgi?id=656914
2011-08-26 15:27:19 +02:00
David Zeuthen
05448a6bef gdbus-codegen: Rework C property getters
Rework property getters to use a vfunc so we can take the fast path
and avoid allocating memory for both the skeleton and the proxy
cases. This requires some special case because of how GVariant expects
you to free memory in some cases, see #657100. Add test cases for
this.

Document the _get_ functions as not being thread-safe and also
generate _dup_ C getters (which are thread-safe).

Mark all the generated _get_, _dup_ and _set_ as (skip) as non-C
languages should just use GObject properties and not the (socalled)
"C binding".

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-08-23 12:54:27 -04:00
Colin Walters
5b68b49b20 GTimeZoneMonitor: Revert addition of this class
The main rationale for adding it was to avoid having gnome-shell
mmap'ing /etc/localtime once a second.  However, we can just as easily
run inotify there, and given no one else was clamoring for a way to
detect when the time zone changes, I don't see a need for public API
here - at least not yet.

In the bigger picture, I just don't believe that the vast majority of
applications are going to go out of their way to instantiate and keep
around a random GTimeZoneMonitor class.  And if they do, it's has the
side effect that for other bits of code in the process, local GDateTime
instances may start varying again!

So, if code can't rely on local GDateTime instances being in a
consistent state anyways, let's just do that always.  The
documentation now says that this is the case.  Applications have
always been able to work in a consistent local time zone by
instantiating a zone and then using it for GDateTime constructors.

We fix the "gnome-shell stats /etc/localtime once a second" issue by
using timerfd (in glib) and inotify (in gnome-shell).

https://bugzilla.gnome.org/show_bug.cgi?id=655129
2011-08-22 11:12:37 -04:00
Matthias Clasen
b76bb6713b Add g_mkdtemp in the spirit of g_mkstemp
At the same time, also add g_mkdtemp_full and g_dir_make_tmp
variants. The patch also unifies the unique-name-generating
code for all variants of mkstemp and mkdtemp and adds tests
for the new functions.

Based on patches by Paolo Bonzini,
http://bugzilla.gnome.org/show_bug.cgi?id=118563
2011-08-14 14:09:58 -04:00
Stef Walter
acbcb8f7e3 hmac: Implementation of HMAC in glib
This implements g_hmac_xxx() functionality using the standard checksum
functions supported by glib.

HMAC is a secure way to hash a key and a password. Many other
approaches fraught with append and prepend issues.

Includes test cases defined in relevant RFCs

https://bugzilla.gnome.org/show_bug.cgi?id=652480
2011-08-14 09:27:45 +02:00
Marc-André Lureau
d2ca14c270 Add G_VALUE_INIT
The implementation of GValue is not public or documented.  When
allocated on the stack, initializing a GValue is usually done as
documented with:

GValue value = { 0, };

There is lot code around (including WebKit) that added all the missing
fields, resulting in this ugly and non-obvious:

GValue value = { 0, { { 0 } } };

However, this doesn't play nice with -Wmissing-field-initializers for
example. Thus, G_VALUE_INIT.

http://bugzilla.gnome.org/show_bug.cgi?id=654793
http://bugzilla.gnome.org/show_bug.cgi?id=577231
2011-08-13 18:16:44 -04:00
Stef Walter
0f99cfa882 GTlsDatabase and related objects
The database is an abstract object implemented by the various TLS
backends, which is used by GTlsConnection to lookup certificates
and keys, as well as verify certificate chains.

Also add GTlsInteraction, which can be used to prompt the user
for a password or PIN (used with the database).

https://bugzilla.gnome.org/show_bug.cgi?id=636572
2011-08-04 08:54:55 +02:00
Ryan Lortie
c81eb121a1 GWakeup: make it private API
Colin requests that we keep this one private for now.

Include it at each point of use (libglib, libgio, tests).
2011-07-25 18:51:03 +02:00
Ryan Lortie
3c25f9f609 GWakeup .gitignore fixes 2011-07-25 15:30:36 +02:00
Ryan Lortie
452b6277d4 gtk-doc GWakeup 2011-07-25 15:30:35 +02:00
Vincent Untz
ae7c48b955 GDesktopAppInfo: Add g_desktop_app_info_get_show_in()
Necessary for rebasing gnome-menus on top of GDesktopAppInfo.

https://bugzilla.gnome.org/show_bug.cgi?id=655044
2011-07-23 10:05:12 +02:00
Ryan Lortie
804e3ba4dd gitignore tweaks 2011-07-22 15:47:24 +02:00
Xavier Claessens
eec69a75ee Add g_ptr_array_new_full
Fixes bug #654450
2011-07-22 10:19:48 +02:00
David Zeuthen
c404dbed11 gdbus-codegen: Add support for new org.gtk.GDBus.C.UnixFD annotation
Also add convenience _with_unix_fd_list variants to GDBusConnection,
GDBusProxy and GDBusMethodInvocation types to easily support this.

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-07-21 16:06:18 -04:00
David Zeuthen
419bfe325c gdbus-codegen: Use G_TYPE_STRV/gchar** for GVariant type 'ao'
This is possible now that we have better support for object path
arrays, see

 http://git.gnome.org/browse/glib/commit/?id=19878998bc386db78614f1c92ff8524a81479c7b

Note that this breaks the ABI of generated code but since
gdbus-codegen(1) has never yet been in a stable GLib release, this is
fine.

Signed-off-by: David Zeuthen <davidz@redhat.com>
2011-07-21 09:32:38 -04:00
Behdad Esfahbod
9bcb3d7457 Add g_unicode_script_from_iso15924()
And adjust g_unicode_script_to_iso1592().
2011-07-20 22:12:03 -04:00
Behdad Esfahbod
7e03b28870 Bug 648271 - Add g_unicode_script_to_iso15924()
Add g_unicode_script_to_iso15924() and tests.
2011-07-20 19:13:19 -04:00
Ryan Lortie
afd1e36970 Change GLib size units policy
This commit changes GLib size units policy.  We now prefer SI units and
allow for use of proper IEC units where desired.

g_format_size_for_display() which incorrectly mixed IEC units with SI
suffixes is left unmodified, but has been deprecated.

g_format_size() has been introduced which uses SI units and suffixes.

g_format_size_full() has also been added which takes a flags argument to
allow for use of IEC units (with correct suffixes).  It also allows for
a "long format" output which includes the total number of bytes.  For
example: "238.5 MB (238,472,938 bytes)".
2011-07-20 20:06:35 +02:00