multimud / clojure-lanterna Goto Github PK
View Code? Open in Web Editor NEWA Clojurey wrapper around the Lanterna terminal output library.
Home Page: http://multimud.github.io/clojure-lanterna
A Clojurey wrapper around the Lanterna terminal output library.
Home Page: http://multimud.github.io/clojure-lanterna
Using clojure-lanterna 0.9.2 I am getting a swing window that is too narrow and the characters are corrupted. After a bit of digging, it looks like the cause is with the default constructor in the Lanterna library, which defaults to using a "Courier New" typeface, which is not a default GNU/Linux/Ubuntu typeface.
To workaround the problem, I downloaded and installed a "Courier New" truetype font.
The Lanterna issue is here https://code.google.com/p/lanterna/issues/detail?id=8&can=1
Hi, sorry but in the documentation I can't found if clojure lanterna support panels and GUIGuideComponents
https://code.google.com/p/lanterna/wiki/GUIGuideComponents
are they supported?..thank you...
This is an awesome function that I would love to start using. For now i'm forced to copy and paste it into my project. Let's make a new release and put it in!
I'm super new to this. Trying to follow your Caves of Clojure series is the first Clojure I've written outside the repl. I've gotten Leiningen and Clojure working fine, but I can't get clojure-lanterna to work.
It looks like Leiningen did resolve the lanterna dep since there are lanterna folders in ~\.m2
.
Here is the error:
user=> (require 'lanterna.screen)
FileNotFoundException Could not locate lanterna/screen__init.class or lanterna/screen.clj on classpath: clojure.lang.RT.load (RT.java:443)
Here is lein classpath
(yes I'm on Windows):
C:\Users\kitsu\Dropbox\projects\clj-caves\test;C:\Users\kitsu\Dropbox\projects\clj-caves\src;C:\Users\kitsu\Dropbox\projects\clj-caves\dev-resources;C:\Users\kitsu\Dropbox\projects\clj-caves\resources;C:\Users\kitsu\Dropbox\projects\clj-caves\target\classes;C:\Users\kitsu\.m2\repository\clojure-complete\clojure-complete\0.2.3\clojure-complete-0.2.3.jar;C:\Users\kitsu\.m2\repository\org\clojure\tools.nrepl\0.2.3\tools.nrepl-0.2.3.jar;C:\Users\kitsu\.m2\repository\clojure-lanterna\clojure-lanterna\0.9.4\clojure-lanterna-0.9.4.jar;C:\Users\kitsu\.m2\repository\com\googlecode\lanterna\lanterna\2.1.5\lanterna-2.1.5.jar;C:\Users\kitsu\.m2\repository\org\clojure\clojure\1.5.1\clojure-1.5.1.jar
The functions get-key
and get-key-blocking
are giving you all keys pressed. But they don't seem to recognise the Control, Alt & super (and on Mac Command) keys.
For instance, get-key
returns 'å' when I hit Alt-a on my mac keyboard. Ctrl and any character just returns the character. It would be nice to let the program get {:mod :ctrl :key "a"}
or something like that.
According to the Java lanterna if you set the cursor to null it will hide the cursor: https://github.com/mabe02/lanterna/blob/release/2.1/src/main/java/com/googlecode/lanterna/screen/Screen.java#L121.
However, This doesn't work Clojure lanterna because you hit a null pointer exception because x and y are undefined: https://github.com/MultiMUD/clojure-lanterna/blob/master/src/lanterna/screen.clj#L132.
Do you have any plans on adding this feature to clojure-lanterna? I'd love to add it through a pull request but I'm pretty new to Clojure and I'm pretty sure my code would be ugly and nonidiomatic.
Hi. There are plenty of functions to set text at given coordinates, but it would also be possible to retrieve rows or columns from the screen or terminal.
Hello I enjoy using this library, but do you plan on doing more development on thie library?
I have created a little snake game using this library.
cheers!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.