SEARCH

Enter your search query in the box above ^, or use the forum search tool.

You are not logged in.

#1 2012-05-01 02:26:23

KF7EEL
New Member
From: Washington State, USA
Registered: 2012-04-29
Posts: 6

Simple "Start" menu button for tint2

sudo apt-get install xdotool

Last edited by KF7EEL (2012-05-14 03:16:16)


#!
and there goes Windoze.

Offline

Help fund CrunchBang, donate to the project!

#2 2012-05-01 04:07:45

VastOne
#! Ranger
From: V-Ger
Registered: 2011-04-26
Posts: 10,165
Website

Re: Simple "Start" menu button for tint2

Nice How To KF7EEL...

I have added it to Quick References as  Simple "Start" menu button with Tint2

You may want to consider renaming the title of this as the same so that anyone seeing it from that perspective will know it is for tint2..

Thanks!

Offline

#3 2012-05-11 08:25:47

fog
#! CrunchBanger
From: Athens, Greece
Registered: 2012-05-11
Posts: 179
Website

Re: Simple "Start" menu button for tint2

Nice howto.
My arch-openbox-netbook thanks you smile

Offline

#4 2012-05-11 10:27:15

Stanie
#! CrunchBanger
Registered: 2011-12-20
Posts: 225

Re: Simple "Start" menu button for tint2

Offline

#5 2012-05-14 22:17:13

KF7EEL
New Member
From: Washington State, USA
Registered: 2012-04-29
Posts: 6

Re: Simple "Start" menu button for tint2

Well, to start with, I found a few pieces of this on the arch forums.


#!
and there goes Windoze.

Offline

#6 2012-05-14 23:52:35

VastOne
#! Ranger
From: V-Ger
Registered: 2011-04-26
Posts: 10,165
Website

Re: Simple "Start" menu button for tint2

Offline

#7 2012-05-15 00:27:56

pvsage
Internal Affairs
From: North Carolina
Registered: 2009-10-18
Posts: 13,970

Re: Simple "Start" menu button for tint2

Well, just `sudo {appname}` from gmrun will get you bubkes; gotta use gksu/gksudo in that case.  I think there are some security issues when using sudo to open a GUI application from the terminal, but frankly I never paid much attention to that discussion.

Where's my nickel? tongue

Offline

#8 2012-05-15 00:35:21

VastOne
#! Ranger
From: V-Ger
Registered: 2011-04-26
Posts: 10,165
Website

Re: Simple "Start" menu button for tint2

Offline

#9 2012-05-15 00:37:24

pvsage
Internal Affairs
From: North Carolina
Registered: 2009-10-18
Posts: 13,970

Re: Simple "Start" menu button for tint2

^ lol  Was fully expecting a plug nickel, FWIW...

Offline

#10 2012-10-24 14:51:08

hehsusss
Member
Registered: 2012-10-20
Posts: 11

Re: Simple "Start" menu button for tint2


Well this looks nice.

Offline

#11 2012-10-25 06:40:46

AlanD
#! CrunchBanger
Registered: 2011-05-12
Posts: 156

Re: Simple "Start" menu button for tint2

Nicely done. I find it hilarious that you use a mouse click to cause a simulated key press, to emulate a mouse click.

hehsusss, I never thought of having two tint2 bars side by side. Neat!


Nerds that build or deploy tongue

Offline

#12 2012-10-25 07:18:43

brontosaurusrex
#! Red Menace
Registered: 2012-06-15
Posts: 1,643

Re: Simple "Start" menu button for tint2

@hehsusss; screenshot? (or it didn't happen)

Offline

#13 2012-10-26 10:09:16

hehsusss
Member
Registered: 2012-10-20
Posts: 11

Re: Simple "Start" menu button for tint2


Well this looks nice.

Offline

#14 2012-12-04 11:50:54

sevensage
#! CrunchBanger
Registered: 2012-11-10
Posts: 134

Re: Simple "Start" menu button for tint2

thanks for this KF7EEL, I followed the instructions however xdotool refused to open the popup menu. I reconfigured xfce keyboard shortcuts and even went so far as to install openbox in case the rc.xml file was required, both xfce and rx.xml pointing to the same keyboard shortcut.

long story short ...

xfce has its own command for a popup menu which doesn't require xdotool "xfce4-popup-applicationsmenu"

therefore, I uninstalled xdotool which was buggy on my system for some reason and my .desktop file looks as such:

[Desktop Entry]
Encoding=UTF-8
Name=menu
Comment=menu launcher
Exec=xfce4-popup-applicationsmenu
Icon=/usr/share/icons/LinuxLex/places/start-here-poseidon.png
Terminal=false
X-MultipleArgs=false
Type=Application
Categories=Menu;
StartupNotify=true

Aside: the app menu button is for my wife tongue ... because a right click is "just sooo annoying"


dig +short txt crunchbang.wp.dg.cx

Offline

#15 2013-02-03 21:32:05

thebonvoyage
New Member
Registered: 2013-02-01
Posts: 7

Re: Simple "Start" menu button for tint2

Offline

#16 2013-02-10 15:53:53

tekhertz
New Member
Registered: 2013-02-10
Posts: 1

Re: Simple "Start" menu button for tint2

Just wanted to add my little menu. It opens on click and closes on a second click. the only problems i have with it ar that it opens directly under the mouse(normal menu would be offset by the panel) and that if you close it by clicking elsewhere it will take two clicks to reopen it the next time.

#! /bin/bash
DISPLAYH=`xdpyinfo  | sed 's/^ *dimensions: *[0-9]*x\([0-9]*\).*/\1/;t;d'`
PANELH=`sed -e 's/^panel_size = [0-9]* \([0-9]*\).*/\1/;t;d' ~/.config/tint2/tint2rc`
MOUSEX="0"
MOUSEY=$(($DISPLAYH-$PANELH))
RESTORE=`xdotool getmouselocation 2> /dev/null | sed -e 's/x://' -e 's/y://' -e 's/ screen:.*$//'`
POSITION=`sed -e 's/^panel_position = \([a-z]*\).*/\1/;t;d' ~/.config/tint2/tint2rc`
if [ $POSITION = top ] ; then
MOUSEY=$PANELH
else
MOUSEY=$(($DISPLAYH-$PANELH))
fi
xdotool mousemove $MOUSEX $MOUSEY
xdotool key super+space
xdotool mousemove $RESTORE
[Desktop Entry]
Name=Start-here
Exec=$HOME/.config/tint2/start_menu.sh
Icon=/usr/share/icons/Faenza-Dark-CrunchBang/places/24/start-here-debian.png
Type=Application
GenericName=

*edit = I was using ~ in the quoted exec path, for some reason this was breaking.
*edit2 = ok even $HOME is inconsistent if it doesnt work just change it to the full path.
*edit3 = I added offsets pulled from tintrc and xdpyinfo

Last edited by tekhertz (2013-02-15 16:26:57)

Offline

#17 2013-07-01 07:53:24

GekkoP
#! Junkie
From: Vicenza (Italy)
Registered: 2013-06-17
Posts: 297
Website

Re: Simple "Start" menu button for tint2

Thank for this, useful to ease a couple of friend into #! world.

Offline

#18 2014-06-07 09:45:07

koz
New Member
Registered: 2014-06-07
Posts: 7

Re: Simple "Start" menu button for tint2

Sorry for post necro - I found this very useful, and I'd like to ask how I can change the icon for the resulting 'start menu' (as mine looks like a rather hideous bunch of black and white pixels at the moment).

Offline

#19 2014-06-07 13:44:29

PackRat
#! Die Hard
From: USA
Registered: 2011-03-03
Posts: 1,572

Re: Simple "Start" menu button for tint2

In the menu.desktop file change -

Icon=mousepad

to the icon of your choice. For example -

Icon=menu_icon.png

if the icon is not located in the usual place - like /usr/share/pixmaps - you'll need to use the full path.

Last edited by PackRat (2014-06-07 13:47:42)


"It does not require many words to speak the truth." - Chief Joseph, Nez Perce tribe

Offline

#20 2014-06-07 22:16:12

koz
New Member
Registered: 2014-06-07
Posts: 7

Re: Simple "Start" menu button for tint2

Icon=mousepad

Last edited by koz (2014-06-07 22:18:13)

Offline

#21 2014-06-22 04:39:36

pressanykey
Member
Registered: 2013-08-28
Posts: 33

Re: Simple "Start" menu button for tint2

In the past, I've created a 16x16 transparent .png using gimp and named it do-nothing.png and I move it to /usr/share/pixmaps. Then, I create a do-nothing.desktop file in /usr/share/applications that sets its Icon=/usr/share/pixmaps/do-nothing.png. And, I set its Exec=/bin/true. Then, using tint2's config file, I call /usr/share/applications/do-nothing.desktop to create a space between the menu button this post describes and the rest of my app icons on the tint2 panel bar. Then, you don't need two instances of the tint2 panel running just to separate the menu button from the other icons in the panel. And, if you click the transparent do-nothing.png icon, all that executes is /bin/true, which does nothing in this context.

^@tekhertz has a good .desktop example to use.

Offline

#22 2014-06-22 08:45:24

Joe90
#! Junkie
Registered: 2013-10-10
Posts: 337

Re: Simple "Start" menu button for tint2

I took a slightly different approach to this:

1. Create/find your preferred menu icon
2. Create a new application .desktop file in /user/share/applications with the exec being: "Exec=xdotool key Super+space" and pointing it at your icon.
3. Add launcher to tint2

No fancy on/off function

Offline

#23 2014-06-22 08:58:16

pressanykey
Member
Registered: 2013-08-28
Posts: 33

Re: Simple "Start" menu button for tint2

I like ^ idea!

Offline

#24 2014-10-04 02:43:06

YellowPudding
New Member
Registered: 2014-10-04
Posts: 3

Re: Simple "Start" menu button for tint2

Last edited by YellowPudding (2014-10-04 03:03:26)

Offline

Be excellent to each other!

#25 2014-10-04 05:24:13

damo
#! gimpbanger
From: N51.5 W002.8 (mostly)
Registered: 2011-11-24
Posts: 5,434

Re: Simple "Start" menu button for tint2

Last edited by damo (2014-10-04 05:51:13)

Offline

Board footer

Powered by FluxBB

Copyright © 2012 CrunchBang Linux.
Proudly powered by Debian. Hosted by Linode.
Debian is a registered trademark of Software in the Public Interest, Inc.
Server: bleh

Debian Logo