[liblouis-liblouisxml] Re: Difficulty with the context opcode.

  • From: "John J. Boyer" <john.boyer@xxxxxxxxxxxxxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Mon, 2 Jan 2017 06:26:51 -0600

Yes, * or ? should be the only thing in the action columkn. the documentation 
probably needs improvement.

John

On Mon, Jan 02, 2017 at 08:28:03AM +0000, Michael Whapples wrote:

I have a feeling that if * or ? is used in the action column then it should
be the only thing. However the documentation is not clear on this and it
might be otherwise.


I think that for the first of the context rules you gave it would need to be
specified as:

context `[]%englishLetter @56


The third column is specifying what to replace the content of the brackets
with, so moving the %englishLetter outside those brackets means it does not
need specifying in the third column. If the second column has no brackets
then I think it is assumed the brackets surround the whole of the second
column.


Similar can be done for the other context rule you gave:

context _!$l[]%englishLetter @56


Does this work for you?


Michael Whapples


On 02/01/2017 01:45, Dave Mielke wrote:
I must be missing something regarding my understanding of the context opcode.
My goal is to prefix the first English letter of a sequence with dots 56. To
that end, I've written:

   class englishLetter ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz
   context `[%englishLetter] @56*
   context _!$l[%englishLetter] @56*

What happens is that the dots 56 is generated but that the letter itself is
missing. What's the right way to have the original text copied from the test 
to
the action?


For a description of the software, to download it and links to
project pages go to http://liblouis.org

-- 
John J. Boyer, President
AbilitiesSoft, Inc.
Email: john.boyer@xxxxxxxxxxxxxxxxx
website: http://www.abilitiessoft.org
Status: 501(C)(3) NONPROFIT
Location: Madison, Wisconsin, USA
Mission: developing assistive technology software and providing STEM services 
        that are available at no cost


For a description of the software, to download it and links to
project pages go to http://liblouis.org

Other related posts: