標準/拡張機能 | C/C++ | 依存項目 |
---|---|---|
Language Environment | 両方 |
#include <collate.h>
int ismccollel(collel_t c);
文字が複数文字照合エレメントであるかどうかを 判別します。照合エレメントは通常は 1 文字の glyph で、照合シーケンス内での 順番を定義する値を持っています。複数文字照合エレメントは 2 つ以上の文字のシーケンスで、1 つのエンティティーとして 照合されるものです。
⁄* CELEBI05
This example prints all of the collating elements in the
collating sequence, by using the &ismc. function to determine
if the collating element is a multi-character collating
element.
*⁄
#include <collate.h>
#include <locale.h>
#include <stdio.h>
#include <wchar.h>
#include <wctype.h>
main(int argc, char *argv[]) {
collel_t e, *rp;
int i;
setlocale(LC_ALL, "");
i = collorder(&rp);
for (; i-- > 0; rp++) {
if (ismccollel(*rp))
printf("'%s' ", colltostr(*rp));
else if (iswprint(*rp))
printf("'%lc' ", *rp);
else
printf("'%x' ", *rp);
}
}