[liblouis-liblouisxml] Re: Very preliminary documentation of scripting language

  • From: Mesar Hameed <mesar.hameed@xxxxxxxxx>
  • To: liblouis-liblouisxml@xxxxxxxxxxxxx
  • Date: Tue, 24 Jul 2012 09:41:02 +0100

Hi John,

Would it be possible to expand on this documentation.
examples with a small amount of commentary would also be useful.
I am happy to go through and put things in doc/liblouis.texi if I have 
something to go on.

Thanks.
-- Mesar
On Thu 29/03/12,11:37, John J. Boyer wrote:
> Below is a very preliminary documentation of the liblouis scripting 
> language. It is little more than a description and a list of keywords 
> and symbols. Future revisions of the scripting language will introduce 
> features that perform functions that cannot be handled by present 
> liblouis algorithms, such as placing capitalization and emphasis 
> indicators after the last word of a phrase.
> 
> In the process of implementing the scripting language the older 
> multipass opcodes were also reimplemented. This introduced some bugs. 
> Hopefully they are all fixed by now.
> 
> -------------------
> 
> LIBLOUIS SCRIPT SPECIFICATION 
> 
> This scripting language provides advanced functionality for the 
> multipass opcodes. 
> The original multipass language can still be used. Translation tables 
> in which it is used should function as expected. The multipass opcodes 
> are:
> 
> correct, change the input before translation;
> context, use the multipass feature during translation;
> pass2, perform additional processing after translation;
> pass3 pass4, still more processing passes.
> 
> To use the scripting loanguage place the word "script" after the opcode, 
> proceeded and followed by whitespace. A single script statement may be 
> up to 500 characters in length. If it is too long to fit on a single 
> line it may be continued on additional lines by placing a backslash (\) 
> at the end of a line.
> 
> A script statement consists of three parts: a declarative part that can 
> be used to give names to variables; an if part; and a then part.
> 
> There are 50 integer variables that can be used to record the results 
> of one script statement for use in another. They can be given names and 
> operated on with the plus (+) and minus symbols. They can be compared to 
> numbers using = != <= and >=
> 
> Keywords and Symbols 
> 
> Below are the keywords and symbols used in the scripting language, with 
> a brief explanation of each.
> 
> "attr",
> "back",
> "def",
> "emph",
> "find",
> "first",
> "group",
> "last",
> "mark",
> "rep",
> "repcopy",
> "repgroup",
> "repomit",
> "script",
> "swap",
> "\"",
> "@",
> "(",
> ")",
> ",",
> "#",
> "+",
> "-",
> "=",
> "<",
> ">",
> "!="
> "<=",
> ">=",
> "!",
> 
> -- 
> John J. Boyer; President, Chief Software Developer
> Abilitiessoft, Inc.
> http://www.abilitiessoft.com
> Madison, Wisconsin USA
> Developing software for people with disabilities
> 
> For a description of the software, to download it and links to
> project pages go to http://www.abilitiessoft.com
For a description of the software, to download it and links to
project pages go to http://www.abilitiessoft.com

Other related posts: