Function

GLibstr_is_ascii

since: 2.40

Declaration

gboolean
g_str_is_ascii (
  const gchar* str
)

Description

Determines if a string is pure ASCII. A string is pure ASCII if it contains no bytes with the high bit set.

Available since: 2.40

Parameters

str

Type: const gchar*

A string.

The data is owned by the caller of the function.
The value is a NUL terminated UTF-8 string.

Return value

Type: gboolean

True if str is ASCII.