HdyStringUtf8: Handy Reference Manual

## HdyStringUtf8 HdyStringUtf8 — GString utf-8 helpers |

## Functions

GString * | hdy_string_utf8_truncate ()
glong | hdy_string_utf8_len ()

## Description

Helpers to ease utf-8 handling based on GString

## Functions

### hdy_string_utf8_truncate ()

    GString *
    hdy_string_utf8_truncate (GString *string,
                              gsize len);

Cut of the end of the string `string` so that `len` utf8 characters remain

#### Parameters

string | a GString |
len | the new size of the string |

#### Returns

`string` .

[transfer none]

### hdy_string_utf8_len ()

    glong
    hdy_string_utf8_len (GString *string);

Computes the length of the string in utf-8 characters. See g_utf8_strlen.

#### Parameters

string | a GString |

#### Returns

the length of `string` in characters