diff --git a/src/xdgmenumaker b/src/xdgmenumaker index 9ac99b6..1d4366a 100755 --- a/src/xdgmenumaker +++ b/src/xdgmenumaker @@ -188,6 +188,8 @@ def main(argv): pekwmmenu() elif desktop == "jwm": jwmmenu() + elif desktop == "compizboxmenu": + compizboxmenu() else: usage() sys.exit(2) @@ -235,7 +237,7 @@ def icon_full_path(icon): return icon -def get_entry_info(desktopfile): +def get_entry_info(desktopfile, ico_paths=True): de = dentry.DesktopEntry(filename=desktopfile) # skip processing the rest of the desktop entry if the item is to not be @@ -257,7 +259,8 @@ def get_entry_info(desktopfile): if seticon: # strip the directory and extension from the icon name icon = de.getIcon() - icon = icon_full_path(icon) + if ico_paths: + icon = icon_full_path(icon) else: icon = None @@ -349,11 +352,11 @@ def desktopfilelist(): return filelist -def menu(): +def menu(ico_paths=True): applist = [] for desktopfile in desktopfilelist(): try: - entry = get_entry_info(desktopfile) + entry = get_entry_info(desktopfile, ico_paths=ico_paths) if entry is not None: applist.append(entry) except exc.ParsingError: @@ -593,5 +596,47 @@ def jwmmenu(): print('') print('') +def compizboxmenu(): + if submenu: + spacing = '\t' + if seticon: + app_icon = icon_full_path(applications_icon) + if app_icon is None: + print('