[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [m17n-list] Can I define a function in a .mim input method file?
From: |
K. Handa |
Subject: |
Re: [m17n-list] Can I define a function in a .mim input method file? |
Date: |
Tue, 26 Jun 2018 21:32:30 +0900 |
In article <address@hidden>, "Chen, Chien-ting" <address@hidden> writes:
> I tried to write a input method with m17n. After I looked the tutorial
> https://www.nongnu.org/m17n/manual-en/m17nDBTutorial.html , I've found
> that it's under lisp-like language. But can I define a function in .mim
> file?
> for example:
> (define (add1 x)
> (+ 1 x)
> )
> and I can use (insert (add1 one-set-value)) to insert the number in the
> text box.
MIM file uses S-expression syntax like Lisp, but the semantics is very
different, and lisp-like function is not supported.
But, you can use MACRO directive will help you.
For example, si-wijesekera.mim heavily uses macros.
---
K. Handa
address@hidden