View Single Post
Old 02-14-2013, 09:50 PM   #124
twobob
( ͡° ͜ʖ ͡°){ʇlnɐɟ ƃǝs}Týr
twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.twobob ought to be getting tired of karma fortunes by now.
 
twobob's Avatar
 
Posts: 6,586
Karma: 6299991
Join Date: Jun 2012
Location: uti gratia usura (Yao ying da ying; Mo ying da yieng)
Device: PW-WIFI|K5-3G+WIFI| K4|K3-3G|DXG|K2| Rooted Nook Touch
Quote:
Originally Posted by Fvek View Post
Here's a proof-of-concept example of using kterm's -e and -l options to launch a terminal program from KUAL with a custom interface using matchbox-keyboard's layout config, in this case a media player with basic controls (play/pause, forward, back, next, previous, volume +/-, off).

This is just an example and not of much practical use since it just plays *.mp3 in a folder, but the concept can be adapted to other things (or a media player with a better frontend, at least). Hopefully it'll give someone an idea to play with.

No screenshots since I apparently can't do that when kterm's running a program. Just imagine an ugly text-based media player with hastily drawn media buttons under it.

Install:

Put the attached mplayer_test folder in your extensions folder.

You will need mplayer provided by baf from the bottom of the page here: http://www.fabiszewski.net/kindle-xterm/

Put mplayer in any of the following folders (or edit mplayer_test.sh):
/mnt/us/bin
/mnt/us/opt/bin
/mnt/us/extensions/mplayer_test/bin

Put some MP3s in /mnt/us/music (you can change this location in mplayer_test.sh)

Launch it from KUAL.

Notes:

Matchbox-keyboard's README with layout info:
https://github.com/Xlab/matchbox-key...xlab/README.md

There's a bug of sorts with kterm (and xterm before it) where some programs won't execute right if just run with the -e command (e.g. "kterm -e foo" will open kterm but then immediately exit without running foo). I don't know why this is but you can get around this by putting the command in a shell script and using -e on that instead (e.g. "kterm -e foo.sh" where foo.sh contains only "#!/bin/sh [linefeed] foo" -- see attached example for example).

I am so testing this.

(I attached the mplayer I will be testing with for future reference )
Attached Files
File Type: zip mplayer.zip (3.81 MB, 303 views)

Last edited by twobob; 02-14-2013 at 09:52 PM.
twobob is offline   Reply With Quote