Re: Obsolete fribidi_log2vis
Shachar Shemesh <[email protected]> Tue, 23 Jun 2009 17:40:03 +0300
| Newsgroups | gmane.comp.internationalization.fribidi |
|---|---|
| Message-ID | <[email protected]> |
أحمد المحمودي wrote: > Hello, > > On Mon, Jun 22, 2009 at 03:34:41PM -0400, Behdad Esfahbod wrote: > >> You are not allocating enough for outstr which is UTF8. Try >> allocating 4 bytes per character. That is, (size * 4). >> > > Thanks, but please notice that instr is also UTF8, and although it > consists of 13 characters, yet its size, as returned by sizeof(instr), > is 26 ! > > Anyways I tried your method, yet I still get the problem I mentioned > with: > > base = FRIBIDI_PAR_RTL; > > That is printf(outstr); shows nothing ! > > >> Also, "sizeof(us)" doesn't return what you meant. >> > > Yes, I noticed that it returns the size of pointer type. Well, what I > need is to know the size of the string after log2vis, because for > example if I got the 2 characters ل & ا after each other, they get > translated to a single character, hence the string size decreases. So > how do I get the resulting string size ? > > Are you looking for the string size in characters or in bytes? Shachar -- Shachar Shemesh Lingnu Open Source Consulting Ltd. http://www.lingnu.com _______________________________________________ fribidi mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/fribidi