[liblouis-liblouisxml] Re: lou_trace and the new emphasis opcodes

  • From: Christian Egli <christian.egli@xxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Wed, 15 Jun 2016 13:50:20 +0200

On 06/15/2016 01:28 PM, Paul Wood (Torch) wrote:

Sorry should be clearer: See answer about using printf or sprintf
functions with the %lc conversion specification

If I understand this correctly then this is talking about wchar_t which is not the same as widechar as it is used in liblouis.

If my understanding is correct (and the code I have seems to support this hypothesis :-) then liblouis is using either 2 bytes for a widechar which more or less corresponds to UTF16 with the exception that UTF16 is a variable-length encoding and the liblouis widechar isn't. There are characters that liblouis when compiled without ucs4 cannot handle. When compiled with ucs4 then the liblouis widechar type corresponds to UTF-32.

So with that in mind we can use all the facilities of libunistring that come with gnulib. No more hand crafted output routines, string comparisons, etc.

Hope that helps. I will push my code into a branch shortly.

Thanks
Christian

--
Christian Egli
Swiss Library for the Blind, Visually Impaired and Print Disabled
Grubenstrasse 12, CH-8045 Zürich, Switzerland


-----
Tag der offenen Tuer: Es war einmal...
Die SBS laedt Sie herzlich ein: 25. Juni 2016 von 9 bis 16 Uhr. Mehr Informationen erhalten Sie unter www.sbs.ch/offenetuer
For a description of the software, to download it and links to
project pages go to http://liblouis.org

Other related posts: