George Vlahavas
be98a02e04
Merge pull request #23 from pinotree/drop-python2
Drop support for Python 2
3 years ago
Pino Toscano
e86d98c8c6
Drop Python 2 support
Python 2 went EOL almost 1 year and half ago, and Python 2 bits are
tested less and less. Even more, Python 3 has been available for years
before that.
Hence, drop the support for Python 2, and assume Python 3 instead.
3 years ago
Pino Toscano
103914b7e7
Switch to Python 3 as default
Discourage the usage of Python 2 by using Python 3 as default Python
everywhere.
3 years ago
George Vlahavas
1931ee4079
Merge pull request #22 from pinotree/qwindowtitle
Ignore also -qwindowtitle %c in Exec
3 years ago
Pino Toscano
e63c8f63d0
Ignore also -qwindowtitle %c in Exec
Qt 5 supports a -qwindowtitle for the main window title, so ignore it
in the same way of -caption %c.
3 years ago
George Vlahavas
bc99abf2af
Replace SafeConfigParser with ConfigParser
SafeConfigParser seems to be deprecated now.
Closes #20
3 years ago
George Vlahavas
2552e06343
Merge pull request #19 from bgstack15/onlyshowin
handle OnlyShowIn and NotShowIn better
4 years ago
B Stack
62fb13e154
handle OnlyShowIn and NotShowIn better
While the target WMs are not registered with freedesktop, some
users do use these fields for these WMs.
https://github.com/search?l=&q=onlyshowin%3D.%2Afluxbox+extension%3Adesktop&type=Code
returns 367 code results.
4 years ago
George Vlahavas
08554c83f5
Remove redundant word
6 years ago
George Vlahavas
ebfcea7459
Add generated manpage to gitignore
6 years ago
George Vlahavas
ee8d421782
Add info about amiwm in manpage
6 years ago
George Vlahavas
da7f1debe6
Add info about amiwm in README.md
6 years ago
George Vlahavas
65255ffcc7
Add menus_test in .gitignore
6 years ago
George Vlahavas
f35861ff70
Add test for amiwm
6 years ago
George Vlahavas
ae2952675a
Mention amiwm in the --help message
6 years ago
George Vlahavas
2d52840859
Add support for amiwm
6 years ago
George Vlahavas
eabec4527d
Update tests
7 years ago
George Vlahavas
f2944fee0d
Add description for --no-svg option
7 years ago
George Vlahavas
7bde503afc
Use SVG icons for JWM menus
Apparently JWM supports SVG icons, so use them when they are available.
Also provide a --no-svg command line option to disable their use.
Fixes #13
7 years ago
George Vlahavas
dcc48c6611
Merge pull request #12 from quatauta/dict-has-key-in
Python 3 removed dict.has_key(), use in operator
7 years ago
Daniel Schömer
40363599d0
Python 3 removed dict.has_key(), use in operator
Should solve #11
7 years ago
George Vlahavas
21a399042f
Exit if no X session is found
Catch the exception that is raised when an icon lookup is performed
without an active X session and bail out.
8 years ago
George Vlahavas
b50ac52703
Merge pull request #9 from roarde/category-selection-order
Use first valid category listed in Desktop Entry
8 years ago
roarde
0f6b825298
Use first valid category listed in Desktop Entry
8 years ago
George Vlahavas
f5e3564845
Extract clean_up_categories from get_entry_info
Just to make the get_entry_info function smaller and more readable.
8 years ago
George Vlahavas
907f2a119d
Extract remove_command_keys from get_entry_info
The get_entry_info function was getting too long. It's cleaner if we
extract the part that removes the command keys from it.
8 years ago
George Vlahavas
3c923b7e63
Change replacement order for %c
Quoted keys should be replaced first, otherwise they will never be
replaced.
8 years ago
George Vlahavas
db833f265d
Replace the %k key in Exec
This is what freedektop says about it:
"The location of the desktop file as either a URI (if for example
gotten from the vfolder system) or a local filename or empty if no
location is known."
I have never seen this in the wild, but still it might exist somewhere.
8 years ago
George Vlahavas
ca8c0c957b
Replace the icon key (%i) in Exec
This is what freedesktop says about it:
"The Icon key of the desktop entry expanded as two arguments, first
--icon and then the value of the Icon key. Should not expand to any
arguments if the Icon key is empty or missing. "
8 years ago
George Vlahavas
a2ea68873a
Remove caption option for KDE .desktop files
some KDE apps have this "-caption %c" in a few variations. %c is "The
translated name of the application as listed in the appropriate Name key
in the desktop entry" according to freedesktop. All apps launch without a
problem without it as far as I can tell, so it's better to remove it than
have to deal with extra sets of nested quotes which behave differently in
each WM. This is not 100% failure-proof. There might be other variations
of this out there, but we can't account for every single one. If someone
finds one another one, I can always add it later.
8 years ago
George Vlahavas
85dffdd9a5
Improve icon extension handling
In addition to other icon file types, also detect svgz icons. Do not
use them in any case, since none of the supported WMs can use them.
Also, make the extension detection case-insensitive. I've never seen an
icon extension with capitals in the wild, but who knows...
Finally, clean up the code a bit, so it reads easier.
8 years ago
George Vlahavas
a5f8ab0ff2
Add tests for twm
8 years ago
George Vlahavas
5ec2443ab1
Add more test menus for TWM
Add a TWM menu with titles as well as the same menu with titles in
Greek.
8 years ago
George Vlahavas
a93e20af64
Add --twm-titles option
Add a --twm-titles option that adds a header title to each menu
category. Naturally, only works for TWM.
8 years ago
George Vlahavas
0fe22cf196
Add twm to the list of avaliable WMs in manpage
8 years ago
George Vlahavas
50dafc7ee4
Remove redundant assignemnt
No need to read the command name twice. This is also assigned a few
lines down.
8 years ago
George Vlahavas
9ebfcfb8ee
Add test for twm
8 years ago
George Vlahavas
ca4ad660bc
Remove redundant branching
No reason to use an else statement and branch the code since the
previous if always returns and exits the function call anyway.
8 years ago
George Vlahavas
7a90065a1b
Look up svg icons with direct path anyway
When an svg icon is provided with a full path in the .desktop file,
strip the extension and path and look it up just as if only the icon
name was given.
8 years ago
George Vlahavas
f54a55b4f4
Return the actual full path to the icon
When no max icon size is requested, always return the full path to the
icon, instead of returning None.
8 years ago
George Vlahavas
96b962902c
Update README.md for twm
8 years ago
George Vlahavas
337a66e60f
Update manpage for twm
8 years ago
George Vlahavas
d9c93fe068
Add support for twm
Using "-f twm". Includes support for twm derivatives, such as ctwm and
vtwm.
8 years ago
George Vlahavas
6e3e2284bb
Do not run sed in place
Since it creates issues with GNU/BSD sed compatibility, don't replace in
place, just redirect the output to the destination.
8 years ago
George Vlahavas
c6f36ab908
Remove space between sed -i and empty prefix
Otherwise it would fail with GNU sed.
8 years ago
George Vlahavas
a26db27e84
Merge pull request #6 from cbettinger/master
Add support for BSD in Makefile
8 years ago
Christian Bettinger
904a21537f
Add support for BSD in Makefile
Suffix to option -i is optional in GNU sed but mandatory in BSD sed. Adding an empty suffix allows proper installation on Linux and BSD.
8 years ago
George Vlahavas
caaa47189d
Add fvwm test
8 years ago
George Vlahavas
9732fec737
Update README.md for fvwm and --max-icon-size
8 years ago
George Vlahavas
80c4320400
Update manpage for Fvwm and --max-icon-size
8 years ago