<refentry id="thunar-vfs-Utility-Functions">
<refmeta>
<refentrytitle>Utility Functions</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>THUNAR-VFS Library</refmiscinfo>
</refmeta>

<refnamediv>
<refname>Utility Functions</refname><refpurpose></refpurpose>
</refnamediv>

<refsynopsisdiv><title>Synopsis</title>

<synopsis>

#include &lt;thunar-vfs/thunar-vfs.h&gt;


<link linkend="gchar">gchar</link>*      <link linkend="thunar-vfs-humanize-size">thunar_vfs_humanize_size</link>        (<link linkend="ThunarVfsFileSize">ThunarVfsFileSize</link> size,
                                             <link linkend="gchar">gchar</link> *buffer,
                                             <link linkend="gsize">gsize</link> buflen);
</synopsis>
</refsynopsisdiv>









<refsect1>
<title>Description</title>
<para>

</para>
</refsect1>

<refsect1>
<title>Details</title>
<refsect2>
<title><anchor id="thunar-vfs-humanize-size"/>thunar_vfs_humanize_size ()</title>
<indexterm><primary>thunar_vfs_humanize_size</primary></indexterm><programlisting><link linkend="gchar">gchar</link>*      thunar_vfs_humanize_size        (<link linkend="ThunarVfsFileSize">ThunarVfsFileSize</link> size,
                                             <link linkend="gchar">gchar</link> *buffer,
                                             <link linkend="gsize">gsize</link> buflen);</programlisting>
<para>
The caller is responsible to free the returned string using <link linkend="g-free"><function>g_free()</function></link>
if you pass <literal>NULL</literal> for <parameter>buffer</parameter>. Else the returned string will be a
pointer to <parameter>buffer</parameter>.</para>
<para>

</para><variablelist role="params">
<varlistentry><term><parameter>size</parameter>&nbsp;:</term>
<listitem><simpara> size in bytes.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>buffer</parameter>&nbsp;:</term>
<listitem><simpara> destination buffer or <literal>NULL</literal> to dynamically allocate a buffer.
</simpara></listitem></varlistentry>
<varlistentry><term><parameter>buflen</parameter>&nbsp;:</term>
<listitem><simpara> length of <parameter>buffer</parameter> in bytes.
</simpara></listitem></varlistentry>
<varlistentry><term><emphasis>Returns</emphasis>&nbsp;:</term><listitem><simpara> a string containing a human readable description of <parameter>size</parameter>.
</simpara></listitem></varlistentry>
</variablelist></refsect2>

</refsect1>




</refentry>
