[liblouis-liblouisxml] Re: Spaces being erroneously stripped when typeforms specified

  • From: "John J. Boyer" <john@xxxxxxxxxxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Mon, 30 Jul 2012 10:33:27 -0500

How important is this bug? How many people cre what happens to extra 
spaces at the end of a translation? The case in which there is typeform 
information in the source but the table does not contain typeform 
information can be handled. It will require an additional field in the 
header of the compiled table.

John

On Mon, Jul 30, 2012 at 11:38:55AM +1000, James Teh wrote:
> Hi all,
> 
> A user reported a bug in NVDA which I've tracked down to a bug in 
> lou_translate when translating a string with spaces at the end including 
> typeforms. In this case, the spaces at the end are stripped. This occurs 
> even if the table being used doesn't handle typeforms. In Python:
> >>> louis.translate(["louis/tables/en-us-comp8.ctb"], u"ab  ", 
> typeform=(0, 0, 0, 0), mode=louis.dotsIO, cursorPos=0)
> (u'\u8001\u8003\u8000\u8000', [0, 1, 2, 3], [0, 1, 2, 3], 0)
> >>> louis.translate(["louis/tables/en-us-comp8.ctb"], u"ab  ", 
> typeform=(0, 4, 4, 0), mode=louis.dotsIO, cursorPos=0)
> (u'\u8001\u8003', [0, 1], [0, 1, 2, 3], 0)
> (Typeform 4 is bold.)
> Unless I'm missing something, the result of these two commands should 
> have been the same. Can anyone give me some idea of what might be 
> happening here? I'm not even sure where to start. :)
> 
> Jamie
> 
> -- 
> James Teh
> Director, NV Access Limited
> Email: jamie@xxxxxxxxxxxx
> Web site: http://www.nvaccess.org/
> Phone: +61 7 5667 8372
> For a description of the software, to download it and links to
> project pages go to http://www.abilitiessoft.com

-- 
John J. Boyer, Executive Director
GodTouches Digital Ministry, Inc.
http://www.godtouches.org
Madison, Wisconsin, USA
Peace, Love, Service

For a description of the software, to download it and links to
project pages go to http://www.abilitiessoft.com

Other related posts: