GOffice.String

Fields

Name

Type

Access

Description

str

str

r/w

the embeded UTF-8 string

Methods

class

ERROR ()

class

append_c_n (target, c, n)

class

append_gstring (target, src)

class

cmp (gstr_a, gstr_b)

class

cmp_ignorecase (gstr_a, gstr_b)

class

equal (gstr_a, gstr_b)

class

equal_ignorecase (gstr_a, gstr_b)

class

equal_rich (gstr_a, gstr_b)

class

foreach_base (callback, *data)

class

hash (gstr)

class

new (str)

class

new_len (str, len)

class

new_nocopy (str)

class

new_nocopy_len (str, len)

class

new_rich (str, byte_len, markup, phonetic)

class

new_rich_nocopy (str, byte_len, markup, phonetic)

class

replace (target, pos, oldlen, txt, newlen)

get_casefold ()

get_casefolded_collate ()

get_collation ()

get_len ()

get_markup ()

get_ref_count ()

ref ()

trim (internal)

unref ()

Details

class GOffice.String

GOffice.String is a structure containing a string.

classmethod ERROR()
Returns:

A string saying ‘ERROR’

Return type:

GOffice.String

A convenience for g_return_val to share one error string without adding a reference to functions that do not add references to the result

classmethod append_c_n(target, c, n)
Parameters:
classmethod append_gstring(target, src)
Parameters:
classmethod cmp(gstr_a, gstr_b)
Parameters:
Return type:

int

classmethod cmp_ignorecase(gstr_a, gstr_b)
Parameters:
Return type:

int

classmethod equal(gstr_a, gstr_b)
Parameters:
Return type:

bool

classmethod equal_ignorecase(gstr_a, gstr_b)
Parameters:
Returns:

True if the two strings are equal when ignoring letter case.

Return type:

bool

classmethod equal_rich(gstr_a, gstr_b)
Parameters:
Return type:

bool

classmethod foreach_base(callback, *data)
Parameters:

Iterates through the strings data base and apply callback to each.

classmethod hash(gstr)
Parameters:

gstr (object or None) –

Return type:

int

classmethod new(str)
Parameters:

str (str) –

Returns:

a GOffice.String containing str, or None if str is None

Return type:

GOffice.String or None

str (nullable): string GOffice.String duplicates str if no string already exists.

classmethod new_len(str, len)
Parameters:
  • str (str or None) – string

  • len (int) – guint32

Returns:

a GOffice.String containing str, or None if str is None

Return type:

GOffice.String or None

GOffice.String duplicates str if no string already exists.

classmethod new_nocopy(str)
Parameters:

str (str or None) – string

Returns:

a GOffice.String containing str, or None if str is None

Return type:

GOffice.String or None

GOffice.String takes ownership of str

classmethod new_nocopy_len(str, len)
Parameters:
  • str (str or None) – string

  • len (int) – guint32

Returns:

a GOffice.String containing str

Return type:

GOffice.String or None

GOffice.String takes ownership of str

classmethod new_rich(str, byte_len, markup, phonetic)
Parameters:
Returns:

a string.

Return type:

GOffice.String

str (nullable): string.

classmethod new_rich_nocopy(str, byte_len, markup, phonetic)
Parameters:
Returns:

a string.

Return type:

GOffice.String

str (transfer full) (nullable): string

classmethod replace(target, pos, oldlen, txt, newlen)
Parameters:
get_casefold()
Return type:

str

get_casefolded_collate()
Return type:

str

get_collation()
Return type:

str

get_len()
Return type:

int

get_markup()
Returns:

markup from self.

Return type:

Pango.AttrList or None

get_ref_count()
Return type:

int

ref()
Return type:

GOffice.String

trim(internal)
Parameters:

internal (bool) – Trim multiple consequtive internal spaces.

Returns:

self

Return type:

GOffice.String

unref()