has no matching language, this function returns FcLangDifferentLang.
@@
+@RET@ FcStrSet *
+@FUNC@ FcLangSetGetLangs
+@TYPE1@ const FcLangSet * @ARG1@ ls
+@PURPOSE@ get the list of languages in the langset
+@DESC@
+Returns a string set of all languages in <parameter>langset</parameter>.
+@@
+
@RET@ FcStrSet *
@FUNC@ FcGetLangs
@TYPE1@ void
*l_serialize = *l;
return l_serialize;
}
+
+FcStrSet *
+FcLangSetGetLangs (const FcLangSet *ls)
+{
+ FcStrSet *langs;
+ int i;
+
+ langs = FcStrSetCreate();
+ if (!langs)
+ return 0;
+
+ for (i = 0; i < NUM_LANG_CHAR_SET; i++)
+ if (FcLangSetBitGet (ls, i))
+ FcStrSetAdd (langs, fcLangCharSets[i].lang);
+
+ if (ls->extra)
+ {
+ FcStrList *list = FcStrListCreate (ls->extra);
+ FcChar8 *extra;
+
+ if (list)
+ {
+ while ((extra = FcStrListNext (list)))
+ FcStrSetAdd (langs, extra);
+
+ FcStrListDone (list);
+ }
+ }
+
+ return langs;
+}
+
#define __fclang__
#include "fcaliastail.h"
#include "fcftaliastail.h"