Editing the new whisker menu

Forum rules
Before you post read how to get help. Topics in this forum are automatically closed 6 months after creation.
Locked
Bauwle

Editing the new whisker menu

Post by Bauwle »

I just tried mint xfce today and it came with a great menu launcher, the new whisker menu and i really like it, the only problem that I want to edit the lock screen button here
[url=http://imgbox.com/adhQ2X1C][img]http://t.imgbox.com/adhQ2X1C.jpg[/img][/url]
to execute the command "i3lock --color 2e2e2e" to use i3lock because the xscreensaver looks really ugly. So how do i do it?. Thanks in advance.
I searched the forums so i think it is safe to make a new thread, but if by some chance this was answered before, please feel free to remove this thread.
Last edited by LockBot on Wed Dec 28, 2022 7:16 am, edited 1 time in total.
Reason: Topic automatically closed 6 months after creation. New replies are no longer allowed.
User avatar
xenopeek
Level 25
Level 25
Posts: 29509
Joined: Wed Jul 06, 2011 3:58 am

Re: Editing the new whisker menu

Post by xenopeek »

A short search in the source code shows the lock_screen function in the file menu.cpp uses the command "xflock4" to lock the screen, see here: https://github.com/gottcode/xfce4-whisk ... u.cpp#L755. As it is C++ source code, you'll have to compile it from source to change this.

Compiling from source is easy-peasy (I peaked at the PKGBUILD from AUR to get the steps). First, get the development tools and libraries:

Code: Select all

apt install build-essential checkinstall cmake libexo-1-dev libgarcon-1-0-dev libxfce4ui-1-dev libxfce4util-dev xfce4-panel-dev
Download the source code and unpack it (replace 1.1.1 with 1.0.3 if you don't want the latest version, but the exact same version as you currently have on Linux Mint):

Code: Select all

wget http://gottcode.org/xfce4-whiskermenu-plugin/xfce4-whiskermenu-plugin-1.1.1-src.tar.bz2
tar xvf xfce4-whiskermenu-plugin-1.1.1-src.tar.bz2
Make the changes you need to the file xfce4-whiskermenu-plugin-1.1.1/src/menu.cpp and then get back to your terminal to compile the program:

Code: Select all

cd xfce4-whiskermenu-plugin-1.1.1
cmake -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
make
sudo checkinstall
The last step will ask you a series of yes/no questions, and ask you for a description of the program (just enter "whisker menu"). You can accept the default answer for all questions, except the question "Should I exclude them from the package? (Saying yes is a good idea) [n]". Answer "y" instead on this question.

Finally, restart the xfce4-panel to load the new menu:

Code: Select all

xfce4-panel --restart
An alternative hack that will work is to override the default xflock4 program. This will affect all programs that use xflock4 without its full path, but you won't change xflock4 and you won't need to compile from source the Whisker menu. To do so create a file /usr/local/bin/xflock4 (as root) and put this in it:

Code: Select all

#/bin/sh
i3lock --color 2e2e2e
Then make the file executable and next time you lock the screen this command will be run instead.
Image
Bauwle

Re: Editing the new whisker menu

Post by Bauwle »

Thanks! I successfully compiled it and it worked fine after installation. again thanks because you made it so easy to do.
bobafetthotmail

Re: Editing the new whisker menu

Post by bobafetthotmail »

If you just want to get rid of the ugly xscreensaver, you should just remove the xscreensaver package with apt-get. It would then "fall back" to the gnome-like looks it had in 14, with a simple black screen and a thunar-like popup window for the password when moving the mouse.

All credit goes to the guy in [url=http://forums.linuxmint.com/viewtopic.php?f=57&t=139825]this thread[/url]. Where you find a better explanation and everything. :mrgreen:
Locked

Return to “Xfce”