---
name: "mtext_coll"
section: "3m17n"
platform: "linux"
package: "m17n-docs"
version: "1.8.4-1"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/mtext_coll"
---

# mtext\_coll(3m17n)

## NAME

mtext\_coll -

## SYNOPSIS

int **mtext\_coll** (**MText** \* *mt1*, **MText** \* *mt2*)

## DESCRIPTION

Compare two M-texts using the current locale. The **mtext\_coll()** function compares the two M-texts **mt1** and **mt2**. It returns an integer less than, equal to, or greater than zero if **mt1** is found, respectively, to be less than, to match, or to be greater than **mt2**. The comparison is based on texts as appropriate for the current locale (LC\_COLLATE).

This function makes use of information that is automatically cached in the M-texts as a text property. So, the second call of this function with **mt1** or **mt2** finishes faster than the first call. \

## COPYRIGHT

Copyright (C) 2001 Information-technology Promotion Agency (IPA)\
 Copyright (C) 2001-2011 National Institute of Advanced Industrial Science and Technology (AIST)\
 Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License  \<http://www.gnu.org/licenses/fdl.html\>.
