Difference between revisions of "Talk:Emacs"

From Apertium
Jump to navigation Jump to search
Line 42: Line 42:
</pre>
</pre>


(basically, the "." switches between adding pardefs and adding i's, a "=" turns an <code><i></code> into <code><p><l></l><r></r></p></code>, a "+" adds s'es and an initial &lt; or &gt; adds restrictions to e)
(basically, the "." switches between adding pardefs and adding i's, a "=" turns an &lt;i&gt; into &lt;p&gt;&lt;l&gt;&lt;/l&gt;&lt;r&gt;&lt;/r&gt;&lt;/p&gt;, a "+" adds s'es and an initial &lt; or &gt; adds restrictions to e)

Revision as of 07:49, 3 May 2010

Zen Coding for dix?

I think the Zen Coding syntax is more useful for XML types where you can have nesting, and where the structure changes more than the content; in eg. a bidix you'd probably find more use for a simple YASnippet that let you tab through these places:

<e><p><l>$1<s n="$2"/></l><r>$3<s n="$4"/></r></p></e>


Alternatively, it'd be fun to make a very compact dix expansion syntax…

i dag+adv=today+adv

<e>       <p><l>i<b/>dag<s n="adv"/></l><r>today<s n="adv"/></r></p></e>
 
driv.op/en__adj

<e lm="driven">          <i>driv</i><par n="op/en__adj"/></e>
 
irsk=Irish.__n_adj

<e>       <p><l>irsk</l><r>Irish</r></p><par n="__n_adj"/></e>

.iI.rsk=rish.__n_adj

<e>       <par n="iI"/><p><l>irsk</l><r>Irish</r></p><par n="__n_adj"/></e>
 
>ombudskvinne+n+f=ombudsman+n

<e r="LR"><p><l>ombudskvinne<s n="n"/><s n="f"/></l><r>ombudsman<s
n="n"/></r></p></e>

<skulde( på)+vblex=blame+vblex

<e r="RL"><p><l>skulde<g><b/>på</g><s
n="vblex"/></l><r>blame</g><s n="vblex"/></r></p></e>

\.

<e>       <i>.</i></e>

(basically, the "." switches between adding pardefs and adding i's, a "=" turns an <i> into <p><l></l><r></r></p>, a "+" adds s'es and an initial < or > adds restrictions to e)