unicoderange.cpp revision fa3db23a1c336c813b1f9da7fa7cad6e81dffc36
#include "unicoderange.h"
#include <malloc.h>
#include <string.h>
static unsigned int hex2int(char* s){
int res=0;
int i=0, mul=1;
while(s[i+1]!='\0') i++;
while(i>=0){
i--;
mul*=16;
}
return res;
}
while(val[0] != '\0'){
} else {
// g_warning("adding unichar. unichar=%c", g_utf8_get_char(&val[0]));
val++;
}
//skip spaces or commas
}
}
int
Urange r;
//U+
val+=2;
int i=0, count=2;
r.start[i] = '\0';
val+=i;
count+=i;
i=0;
if (val[0]=='-'){
val++;
r.end[i] = '\0';
val+=i;
count+=i;
} else {
}
// g_warning("adding range. from %s to %s", r.start, r.end);
return count+1;
}
}
unsigned int unival;
unsigned char val;
for (unsigned int i=7; unival>0; i--){
}
// g_warning("uni=%s", uni);
bool found;
if (r.end){
// g_warning("hex2int: start=%d", hex2int(r.start));
// g_warning("hex2int: end=%d", hex2int(r.end));
} else {
found = true;
}
if (found) return true;
}
}
return false;
}