mirror of
https://gitlab.com/eql/EQL5.git
synced 2025-12-08 11:31:07 -08:00
add trivial "qml-lisp" example (call Lisp from QML); tiny revisions;
This commit is contained in:
parent
75c2b80e4e
commit
0e82b0a517
10 changed files with 123 additions and 3 deletions
15
examples/M-modules/quick/qml-lisp/qml-lisp.lisp
Normal file
15
examples/M-modules/quick/qml-lisp/qml-lisp.lisp
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
;;; enable QML to call Lisp functions
|
||||
;;; (requires a C++ plugin, see "lib/")
|
||||
|
||||
(provide :qml-lisp)
|
||||
|
||||
(in-package :eql)
|
||||
|
||||
(defvar *qml-lisp* (qload-c++ "lib/qml_lisp"))
|
||||
|
||||
(defun qml-apply (function arguments)
|
||||
(let ((value (apply (intern (string-upcase function)) arguments)))
|
||||
(if (stringp value)
|
||||
value
|
||||
(princ-to-string value))))
|
||||
|
||||
Loading…
Add table
Add a link
Reference in a new issue