Difference between revisions of "Package:Ltk"

From Funtoo
Jump to navigation Jump to search
(Created page with "{{Ebuild |Summary=LTK is a Common Lisp binding for the Tk graphics toolkit |CatPkg=dev-lisp/ltk |Homepage=http://www.peter-herth.de/ltk/ }} {{EbuildFooter}}")
 
 
Line 4: Line 4:
|Homepage=http://www.peter-herth.de/ltk/
|Homepage=http://www.peter-herth.de/ltk/
}}
}}
== About LTK ==
<blockquote>
LTK is a Common Lisp binding for the Tk graphics toolkit. It does not require any Tk knowledge for its usage. As it is written in pure Lisp, it is highly portable.
The LTK documentation can be read [http://www.peter-herth.de/ltk/ltkdoc online] or is available as a [http://www.peter-herth.de/ltk/ltkdoc.pdf PDF] here.
Visit the Ltk user mailinglist at http://common-lisp.net/cgi-bin/mailman/listinfo/ltk-user Comments and suggestions for further development are very welcome.
</blockquote>
===Installation===
To install ltk:
{{console|body=
###i## emerge -av dev-lisp/ltk
}}
It is necessary to have a common lisp interpreter. There are many available in the repository but for purposes of this document we will use SBCL:
{{console|body=
###i## emerge -av dev-lisp/sbcl
}}
The LTK library will be installed in {{c| /usr/share/common-lisp/source/ltk}}
=== A Simple Example ===
Here is a simple test program to see that it is working properly:
{{file|name=test.lisp|lang=lisp|desc=A simple test of LTK |body=
#! /usr/bin/sbcl --script
(load "/usr/share/common-lisp/source/ltk/ltk")
(in-package :ltk)
(ltktest)
}}
Save the file and set it's permissions so that it can be executed:
{{console|body=
$ ##i##chmod +x ./test.lisp
}}
Execute the file:
{{console|body=
$ ##i##./test.lisp
}}
You should see this test program if everything is working properly:
[[File:LtkDemo.jpeg]]


{{EbuildFooter}}
{{EbuildFooter}}

Latest revision as of 05:53, January 14, 2017

Ltk

   Tip

We welcome improvements to this page. To edit this page, Create a Funtoo account. Then log in and then click here to edit this page. See our editing guidelines to becoming a wiki-editing pro.

About LTK

LTK is a Common Lisp binding for the Tk graphics toolkit. It does not require any Tk knowledge for its usage. As it is written in pure Lisp, it is highly portable.

The LTK documentation can be read online or is available as a PDF here.

Visit the Ltk user mailinglist at http://common-lisp.net/cgi-bin/mailman/listinfo/ltk-user Comments and suggestions for further development are very welcome.

Installation

To install ltk:

root # emerge -av dev-lisp/ltk

It is necessary to have a common lisp interpreter. There are many available in the repository but for purposes of this document we will use SBCL:

root # emerge -av dev-lisp/sbcl

The LTK library will be installed in /usr/share/common-lisp/source/ltk

A Simple Example

Here is a simple test program to see that it is working properly:

   test.lisp (lisp source code) - A simple test of LTK
#! /usr/bin/sbcl --script
(load "/usr/share/common-lisp/source/ltk/ltk")
(in-package :ltk)
(ltktest)

Save the file and set it's permissions so that it can be executed:

user $ chmod +x ./test.lisp

Execute the file:

user $ ./test.lisp

You should see this test program if everything is working properly:

LtkDemo.jpeg