xlunch

Window managers, icon programs, widgets, etc.
Message
Author
User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

xlunch

#1 Post by sc0ttman »

http://xlunch.org/
This is xlunch, the coolest graphical app launcher for Xorg/X11. It requires only pure Xlib and Imlib2. It allows you to run programs, commands, or simply select something out of a list using your mouse, keyboard, or both! UTF8 is fully supported meaning you can have text of all kinds. The prompt allows you to run arbitrary commands, and it works to filter your entries as well. xlunch is also highly configurable, both in functionality and style, it can even be used as a desktop! See below for more
Image

Features:
Available Modes

One time launcher mode - this is default mode. There is no need to specify any command line parameter for this mode. In this mode, xlunch opens as a fullscreen application, and offers a screen with icons to select applications to run, plus command line which serves as a filter for the icons at the same time. Running any app or command ends the launcher. You can also cancel the launcher (by default) with the Esc key, or click with right mouse button.

Desktop mode - this mode is activated with -d. In this mode, xlunch sends itself to the lowest position in the window stack, so all other windows are above it. Your window manager will not have any control over it, so xlunch does not receive any input or focus and it cannot be raised to front. This emulates desktop with icons. In Desktop mode, applications start using fork (as another process) and don't terminate the launcher. xlunch in this mode cannot be terminated (except by killing it with SIGTERM).

By Tomas Matejicek - tomas [at] slax [dot] org
Last edited by sc0ttman on Sat 01 Sep 2018, 02:14, edited 1 time in total.
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#2 Post by musher0 »

Hi scotman.

Does it come with a Coke or a Ginger Ale? :lol:

I tried it, and nah... it can't replace your WM. I can't find any use for it.
(That's just my opinion, of course.)

Although the author Tomaz Something, of Slax fame, is a top developer, he
must've woken up on the wrong side of the bed that day!!!

BFN.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

#3 Post by sc0ttman »

Xlunch could be customised to be a simple, lightweight, searchable frontend for not only Linux apps, but for anything..

I am thinking of making xlunch into a fancy ROM loader for Puppy Arcade.
.. Just do 'for each ROM, make a .desktop file or text entry', put them/it in
a single dir, update xlunch to look in that dir, and viola.

In this way, xlunch could probably also be used as a very fast alternative to Kodi ..
Get a load of local media, videos, music etc, make .desktop files of them,
make xlunch look for those files (not only in /usr/share/applicatins) and ur done..

OR you *could* even write a script to put online streams/torrents into .desktop files,
each one loading the stream through vlc, mpv, (even PeerFlix) etc ...
Then xlunch can list the movies, streams, torrents etc...
You click it, it and the Exec= from te desktop file would play the stream..

Any of these uses would make xlunch the lightest, fastest Kodi alternative,
or Emulation ROM loading frontend there is!

Also, xlunch could serve as a really lightweight alternative to Spotlight,
with the right settings, scripts, hacks and stuff..

Just some ideas on what *could* be done with xlunch..
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#4 Post by musher0 »

Hi sc0ttman.

Maybe you can use this for a few things. But generalized? No.

For practical reasons, this concept is absurd if anyone is suggesting XLunch
can replace a window manager -- or a windows manager menu. (hehe)

You have about 250 items as *desktop entries,
plus
How many Internet TV channels?
How many Internet radio stations?
How many executables in /usr/bin?
and in the other "bin" directories.

Where will you put all the little squares on your screen? It just isn't practical.
Which is why I don't see XLunch as a general solution for managing your
box. You'll still need something more fine-tuned.

BFN.
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

Fork of Xlunch, for Puppy Linux

#5 Post by sc0ttman »

Fork of Xlunch, for Puppy Linux
(a work-in-progress)

https://gitlab.com/sc0ttj/xlunch

Install (requires devx installed):

Code: Select all

mkdir -p ~/Gitlab/xlunch
cd ~/Gitlab/xlunch
git clone https://gitlab.com/sc0ttj/xlunch .
make
make install
Run it (with nice defaults):

Code: Select all

xlunch --columns 4
Or use the custom loader script called xlunchr:

Code: Select all

xlunchr --config   # setup all icons as needed (automatic)


Run as desktop background (runs under all windows, never exits):

Code: Select all

xlunchr --desktop
(note, if ROX Pinboard running, click it to show the xlunchr desktop)

Image

Run as a popup menu (runs on top of all windows, runs chosen cmd and exits):

Code: Select all

xlunchr --menu

Run a nice logout menu:

Code: Select all

xlunchr --logout
....

Note: I only tested it on Dpup Stretch 7.5 RC1

STILL TO DO:

Prevent need to click ROX desktop to show 'xlunchr --desktop': .. Fix it to auto disable ROX Pinboard while running, and reload it again once it has exited.

Fix and improve the --menu and --logout features of xlunchr.
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

musher0
Posts: 14629
Joined: Mon 05 Jan 2009, 00:54
Location: Gatineau (Qc), Canada

#6 Post by musher0 »

Speaking for myself: it's still an awful concept for anyone who likes to look
at inspiring photographs -- and a clean desktop!
musher0
~~~~~~~~~~
"You want it darker? We kill the flame." (L. Cohen)

User avatar
rockedge
Posts: 1864
Joined: Wed 11 Apr 2012, 13:32
Location: Connecticut, United States
Contact:

#7 Post by rockedge »

I have been using the xlunch fork with relatively good success...but not to replace the Rox pin board or menu system...but more of a layer on top using the same background as the jwm background and the use of all the available .desktop apps in one menu that can be sorted or isolated quickly via some text input. I am still experimenting with xlunch and looking for it's true nitch..at the moment it gets started via a desktop link/icon and gets used occasionally......xlunch is not handling the .svg icons very well

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

#8 Post by sc0ttman »

Yeah I think, aside from a custom frontend for Media Player, Emulation Menus (etc), the best use for xlunch is as a 'spotlight' clone ... A popup menu that is loaded by a hotkey like Ctrl+SPACE, pops up, lets you run 1 command, and disappears again... That is the `xlunchr --menu` option ...

rockedge, If you use `xlunchr --config`, then `xlunchr --menu` (or `xlunchr --desktop`) do you not get ALL icons working? (Like in my screenshot?)
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

Xlunch .pet packages

#9 Post by fredx181 »

Decided to move Xlunch .pet packages topic to it's own thread because it doesn't really fit with sc0ttman's project.
http://www.murga-linux.com/puppy/viewtopic.php?t=114208

Fred
Last edited by fredx181 on Sun 02 Sep 2018, 08:05, edited 4 times in total.

User avatar
rockedge
Posts: 1864
Joined: Wed 11 Apr 2012, 13:32
Location: Connecticut, United States
Contact:

#10 Post by rockedge »

sc0ttman Thanks for the tips.
I pulled the latest xlunch-master and built it. Running on Bionic 18.05 with a kernel 4.17.9

Screenshot(2)-600px shows the desktop with xlunch being launched from the icon on the top left of the screen.

Screenshot-600px
Now I have all the icons displaying. This following screen is using the genentries from the latest version and xlunch-3.2.10. This displays nicely.

Code: Select all

/root/my-applications/xlunch-3.2.10/xlunch -g /usr/share/backgrounds/BionicZM-A-logo.png --input /root/.config/xlunch/entries.dsv
Screenshot(1)-600px
now with the latest version of xlunch-master because the text is handled differently the text now bunches up and overlaps

Code: Select all

 xlunchr --menu
Attachments
Screenshot(2)-600px.png
(29.42 KiB) Downloaded 587 times
Screenshot(1)-600px.png
(119.24 KiB) Downloaded 595 times
Screenshot-600px.png
(104.01 KiB) Downloaded 600 times

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

#11 Post by sc0ttman »

rockedge wrote:sc0ttman Thanks for the tips.

Screenshot(1)-600px
now with the latest version of xlunch-master because the text is handled differently the text now bunches up and overlaps

Code: Select all

 xlunchr --menu
Add the --columns option to your xlunch command to reduce overlapping ...

That is a stop-gap, until I learn enough C (or the fix appears on GitHub) to choose whether or not to truncate the app names, and if so, at what length...

For now, my fork simply does not truncate app names... Which is ugly unless you set the --columns option ...
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

User avatar
rockedge
Posts: 1864
Joined: Wed 11 Apr 2012, 13:32
Location: Connecticut, United States
Contact:

#12 Post by rockedge »

I have fixed most of it by reducing the font size --font and adjusting the descriptions in entries.dsv.

I like the --columns option and below is a view of it's use. I think a parser that runs a filter after the entries.dsv creation. The filter then shortens the description entry like this:

Code: Select all

ISOMaster iso file editor;/usr/share/xlunch/svgicons/cdrom.png;isomaster
to

Code: Select all

ISOMaster;/usr/share/xlunch/svgicons/cdrom.png;isomaster
but I am experimenting to see what happens all around.

Code: Select all

xlunch -g /usr/share/backgrounds/BionicZM-A-logo.png --font /usr/share/fonts/default/TTF/FreeSans.ttf/9  --column 8 --input /root/.config/xlunch/entries.dsv
Attachments
Screenshot(3).png
(69.36 KiB) Downloaded 540 times

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#13 Post by fredx181 »

sc0ttman wrote:For now, my fork simply does not truncate app names... Which is ugly unless you set the --columns option ...
I tried by compiling your new xlunch.c, must say, not an improvement IMHO, but unfortunately don't have suggestion for how to truncate "at what length" (I'm really not a C programmer)
EDIT: Btw, isn't it better making changes maybe to co-operate with the author(s) of xlunch ?

Fred
Last edited by fredx181 on Sat 01 Sep 2018, 21:01, edited 2 times in total.

User avatar
rockedge
Posts: 1864
Joined: Wed 11 Apr 2012, 13:32
Location: Connecticut, United States
Contact:

#14 Post by rockedge »

how does one page or scroll through the different pages of the icons/text? with the --columns set is there a way to reach the other apps page up or down don't do it only if I begin to add text at the prompt like an "x"

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#15 Post by fredx181 »

rockedge wrote:how does one page or scroll through the different pages of the icons/text? with the --columns set is there a way to reach the other apps page up or down don't do it only if I begin to add text at the prompt like an "x"
If you mean how it could be possible to scroll, add option:

Code: Select all

--scroll
Fred

User avatar
rockedge
Posts: 1864
Joined: Wed 11 Apr 2012, 13:32
Location: Connecticut, United States
Contact:

#16 Post by rockedge »

Yes! thank you Fred ...I borrowed one of your examples so I have 2 nice options of using xlunch....

one with

Code: Select all

xlunch -g /usr/share/backgrounds/BionicZM-A-logo.png --font /usr/share/fonts/default/TTF/FreeSans.ttf/9  --column 8 --input /root/.config/xlunch/entries.dsv --scroll
and the one I used from the example in the PET package from Fred running zoneminder - zmNinja alongside
Attachments
Screenshot(7).png
(101.03 KiB) Downloaded 548 times
Screenshot(5).png
(68.25 KiB) Downloaded 551 times

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

#17 Post by sc0ttman »

fredx181 wrote:
sc0ttman wrote:For now, my fork simply does not truncate app names... Which is ugly unless you set the --columns option ...
I tried by compiling your new xlunch.c, must say, not an improvement IMHO, but unfortunately don't have suggestion for how to truncate "at what length" (I'm really not a C programmer)
EDIT: Btw, isn't it better making changes maybe to co-operate with the author(s) of xlunch ?

Fred
It's a BIG improvement on my system, all I get is about 5 chars per title otherwise ("Tran..." instead of "Transmission") ... I can't even tell what half the apps are with normal xlunch....

And yes, eventually, when I finally work out how to do a proper fix, I will do a Pull Request.

One of the problems is that linux progs have such crappy names - without the description that follows it's hard to know what they do ... If all descriptions were prefixed with a dash (-) we could truncate form the dash onwards .....

So "VLC - media player" (instead of "VLC media player") would allow us to choose to show names + description or names only .... or even name + descr on new line (convert dash to \n)..

But the desktop files are a mess (no systematic division between prog name and description) and dejaVuSans looks crap in xlunch...

A smaller, more condensed, narrower font, with dashes after prog name, would do wonders on my system .... YMMV.


EDIT:

The easiest fix is to update /usr/bin/genentries ... Give it a new option, like --maxtitlelength or --maxtitlewords, and truncate the names in entries.dsv from there... But then it may conflict with (ignore) some xlunch options...
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#18 Post by fredx181 »

sc0ttman wrote:all I get is about 5 chars per title otherwise ("Tran..." instead of "Transmission") ... I can't even tell what half the apps are with normal xlunch....
Some options may help, like setting --iconpadding, I'm not sure what's the proper use of --textpadding, I experimented with negative value -4 in below example, seems to work :roll:

Code: Select all

xlunch --scroll --border 5% --sideborder 5% --borderratio 50 --sideborderratio 50 --columns 10 --rows 5 --iconpadding 30 --textpadding -4 --paddingswap --iconsize 48 --leastmargin 12
See pic below.
This is with the standard xlunch.

Fred
Attachments
2018-09-02-150707_1280x800_scrot_780x488.png
(117.24 KiB) Downloaded 478 times

User avatar
sc0ttman
Posts: 2812
Joined: Wed 16 Sep 2009, 05:44
Location: UK

#19 Post by sc0ttman »

Will play with those settings, but couldn't get anything I liked... Will have another go..

In the mean time....

I've literally just completed a feature branch in my fork, which adds an all-new --maxtextlength option (updated C code in xlunch.c)

See here: https://gitlab.com/sc0ttj/xlunch/tree/f ... textlength

(diffs here: https://gitlab.com/sc0ttj/xlunch/merge_requests/1/diffs)

You can now do:

xlunch --maxtextlength 0 # disables truncation
xlunch --maxtextlength 10 # limits titles to 10 chars

..if ommitted, you get the default behaviour back

From xlunch --help:

Code: Select all

--maxtextlength [i]                The maximum character length of the icon text.
                                              If set to 0, text truncation is disabled.
[b][url=https://bit.ly/2KjtxoD]Pkg[/url], [url=https://bit.ly/2U6dzxV]mdsh[/url], [url=https://bit.ly/2G49OE8]Woofy[/url], [url=http://goo.gl/bzBU1]Akita[/url], [url=http://goo.gl/SO5ug]VLC-GTK[/url], [url=https://tiny.cc/c2hnfz]Search[/url][/b]

User avatar
fredx181
Posts: 4448
Joined: Wed 11 Dec 2013, 12:37
Location: holland

#20 Post by fredx181 »

sc0ttman wrote:--maxtextlength The maximum character length of the icon text.
If set to 0, text truncation is disabled.


I tested this and works well, great improvement, thanks !
I'm using it in combination with --columns, this works nicely for me:

Code: Select all

--maxtextlength 18 --columns 8
EDIT: One possible "problem": with a smaller resolution the text may overlap.
(in case of sharing a script, it's unpredictable how it will look)

Fred

Post Reply