Scott Starker wrote:
> 
> I'm trying to do an xxe that one can entry in an interlinear text (the
> language text, the gloss text and the free translation). I have it all
> working except the part were one would press F12 (I would eventually have
> the key be a SPACE | TAB keys though) where it would generates another

Tab, Shift-Tab are ``reserved by the system''.

Ctrl-Tab is bound to "insert a Tab character".

Space is bound to "insert a space character".

Ctrl-Space is bound to "insert a non breaking space character".

I suggest using Shift-Space.

> langData and gloss.
> 
> I have:
> 
> <cfg:binding>
> <cfg:keyPressed code="F12"/>
> <cfg:command name="newWords"/>
> </cfg:binding>
> 
> <cfg:command name="newWords">
> <cfg:macro>
> <cfg:sequence>
> <cfg:command name="alert" parameter="before insert try 1"/>
> <cfg:pass>
> <cfg:match context="$implicitElement" pattern="Int:langData |
> Int:gloss"></cfg:match>
> </cfg:pass>
> <cfg:command name="alert" parameter="before insert try 2"/>
> <cfg:command name="insert" parameter="after[implicitElement]
> #template(Int:words,interlinearization_1_g_free)"/>
> </cfg:sequence>
> </cfg:macro>
> </cfg:command>
> 
> 
> <cfg:elementTemplate name="interlinearization_1_g_free">
> <Int:words>
> <Int:word>
>    <Int:langData lang="l"/>
> </Int:word>
> <Int:word>
>    <Int:gloss lang="l"/>
> </Int:word>
> </Int:words>
> </cfg:elementTemplate>
> 

[1] Make sure that you have properly declared the "Int" prefix in the
configuration files which contain the "newWords" command and the
"interlinearization_1_g_free" element template.

[2] Are you 100% sure of the pattern of your match element? (I cannot
help you with that because I don't know your schema.)

[3] The parameter of a command is a plain string where namespace
prefixes have no special significance. Therefore, please replace:
---
<cfg:command name="insert" parameter="after[implicitElement]
#template(Int:words,interlinearization_1_g_free)"/>
---
by:
---
<cfg:command name="insert" parameter="after[implicitElement]
#template({namespace_associated_to_Int}words,interlinearization_1_g_free)"/>
---

This pitfall is documented here:
http://www.xmlmind.com/xmleditor/_distrib/doc/commands/commandref.html


Reply via email to