You are not logged in.

#551 2014-02-26 08:18:10

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

Hi windowsrefund, glad you like the wm.

What you'd like has been possible in snapwm for ages now, via a combination of ~/.xinitrc and the apps.conf file.
I'll give an example using my apps file and .xinitrc slightly modded:

DESKTOP Xfe;2;0;
DESKTOP Firefox;3;0;
DESKTOP Dwb;3;0;
DESKTOP SNOOZER;3;1;
DESKTOP SNOOZER-MARK;3;0;
DESKTOP Thunderbird;5;1;
DESKTOP MPlayer;4;0;
DESKTOP mpv;4;0;
DESKTOP Pysol;6;0;
DESKTOP Leafpad;2;0;

POSITION Dwb;100;60;1150;650;
POSITION Xfe;100;100;800;400;
POSITION Leafpad;500;60;550;600;
POSITION URxvt;100;320;820;400;

Notice the entry for leafpad to open and be focused on desktop 2.

starter="exec dbus-launch --sh-syntax --exit-with-session "

numlockx &
xsetroot -cursor_name left_ptr &
#turn of the caps lock key !!
xmodmap -e 'keycode 66 ='
[ "`ps -C power2_mon -o pid=`" != "" ] || \
~/build/power2_mon/power2_mon &
rm ~/.weechat/logs/* 2> /dev/null
urxvtd -q -f -o
# mycompositing &
$(fbsetbg -l && sleep 1 && (wallclock &) &&\
 (for i in {1..3}; do (urxvtc &); done) && (leafpad &)) &
~/progs/c.files/status_output/snap_output &

$starter ~/build/snapwm-0.8.0/snapwm

exit 0

In ~/.xinitrc after I start the urxvt daemon I set the wallpaper, wait a sec then open my analogue clock and three urxvtc's on desktop 1, then open leafpad which will be opened on desktop 2 and focused because of the line in the apps.conf file.
Hopefully you are aware that most terminals have the -name switch available to make a particular terminal uniquely identifiable which you can use in the apps.conf file.

I hope that helps and if you have any more questions that aren't about doing this with a desktop manager I would be happy to try and help. tongue

Cheers


You're just jealous because the voices only talk to me.

Offline

#552 2014-02-26 08:33:27

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

Would there be a way to bring in (toggle) a view of an app on another tag(desktop) and move it back again as you can do in DWM with the key strokes W_C  then number of the tag.

It's described in this article "Tags are not workspaces"

Tags are not workspaces

Last edited by chickenPie4tea (2014-02-26 08:41:41)


You can like linux without becoming a fanatic!

Offline

#553 2014-02-26 18:26:02

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

chickenPie4tea wrote:

Would there be a way to bring in (toggle) a view of an app on another tag(desktop) and move it back again as you can do in DWM with the key strokes W_C  then number of the tag.

It's described in this article "Tags are not workspaces"

Tags are not workspaces

Heh, no.
snapwm has the client_to_desktop() and follow_client_to_desktop() functions for moving windows between desktops which work well.

Cheers


You're just jealous because the voices only talk to me.

Offline

#554 2014-02-26 23:35:46

windowsrefund
Member
Registered: 2010-11-13
Posts: 16

Re: dminiwm snapwm & bipolarbar

Hi moetunes,

Thanks for the reply. Wouldn't your approach limit your usage of leafpad though? Also, not sure how this solution would drop me into desktop #2

FYI, I've pretty much settled on a workflow involving 3 desktops with #2 as my main hangout (running termite+tmux). #3 always runs a brower and #1 tends to get put to use by zathura. So basically, I'd like to find a way to start things off from #2 rather than having to accept the default #1, and be forced to switch manually.

Take care

Offline

#555 2014-02-27 09:05:31

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

hmm yes your right windowsrefund!  I cant see an option in the rc file on starting snapwm in a certain desktop.
If I wanted to have it start in desktop 2 I would use one of those keyboard control apps to send the keyboard keys needed to switch to desktop 2 and make a separate script for it  -  you could point to the script in your .xinitrc
I have a startup script that starts certain apps etc here is my .xinitrc

[[ -f ~/.Xresources ]] && xrdb -merge ~/.Xresources
xsetroot -cursor_name left_ptr &
case $1 in
bspwm)
    exec bspwm
    ;;
i3)
	exec /home/dk/bin/startup-apps &
	exec i3
	;;
dwm)
	exec /home/dk/bin/startup-apps &
	exec startDWM.sh
	;;	
snapwm)
	exec /home/dk/bin/startup-apps &
	exec snapwm
	;;	
echinus)
	exec /home/dk/bin/startup-apps &
	exec echinus
	;;	
musca)
    exec /home/dk/bin/startup-apps &
	exec /home/dk/musca/musca
	;;
xfwm4)
	exec /home/dk/bin/startup-apps &
	exec xfwm4
	;;		
openbox|*)
    exec openbox-session
    ;;
esac

of course having an option in the snapwm rc file would be simpler - maybe there is an undocumented one?
if you use a tool like xdotool, a one line command to change to desktop 2 would be
xdotool key super+2      asuming you use the windows key as your command in snapwm

Last edited by chickenPie4tea (2014-02-27 09:33:30)


You can like linux without becoming a fanatic!

Offline

#556 2014-02-27 13:06:46

stlarch
Member
From: hell
Registered: 2010-12-25
Posts: 1,265

Re: dminiwm snapwm & bipolarbar

Guys, re-read his last couple of responses again and take another look at the apps.conf file, it can do what you want along with .xinitrc.
hint: focus on the 'focused' part..(follow in apps.conf)

Last edited by stlarch (2014-02-27 13:51:52)

Offline

#557 2014-02-27 13:57:17

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

oh yes your right as long as he sets his startup apps to open on desktop 2 and has the set to follow switch, and just make sure not to have other apps that startup from the begining (and set to open on another desktop) also set with the follow switch


You can like linux without becoming a fanatic!

Offline

#558 2014-02-28 06:29:19

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

@windowsrefund, how do you think the above example would limit my use of leafpad? The point of the DESKTOP entries in apps.conf is to have apps always open on a specific desktop.
You've changed what you are asking for I think.

windowsrefund wrote:

I'd like to find a way to start things off from #2 rather than having to accept the default #1, and be forced to switch manually.

Originally you asked for a way to have apps open when snapwm starts and to open them on a specific desktop.

windowsrefund wrote:

I'd love to have a way to execute a few things when snapwm starts. More specifically, switch to a particular desktop (rather than accept the default value of 1) and then fire up a terminal

If you just need need to select the desktop the wm starts on that should just be 3 or 4 lines of code so check for an update in about twelve hours.

Cheers


You're just jealous because the voices only talk to me.

Offline

#559 2014-02-28 21:07:28

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

I've added a new option in rc.conf for setting the desktop to start on. It defaults to the first desktop so if it's not needed nothing needs to be done.

DEFAULT_DESK 1

The desktop count starts from 0(zero) so the second desktop will be 1(one).

Cheers


You're just jealous because the voices only talk to me.

Offline

#560 2014-03-02 08:14:00

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

just an idea but say I have a text editor open on desktop 1 and I am currently on desktop 2 with firefox open
being able to rightclick on the desktop 1 tab and have it's apps brought into my current desktop to view them and do the same to toggle them out would be handy. Maybe I am the only one that thinks so though smile


You can like linux without becoming a fanatic!

Offline

#561 2014-03-02 09:29:00

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: dminiwm snapwm & bipolarbar

You are confusing tags with workspaces, again.


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#562 2014-03-02 09:41:36

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

erm maybe your right but I was just asking if there would there be a way to bring open apps from Desktop 1 onto desktop 2 by rightclicking on the Desktop 1 tab - I guess the toggle part would involve a tag system.


You can like linux without becoming a fanatic!

Offline

#563 2014-03-02 18:58:29

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

chickenPie4tea wrote:

just an idea but say I have a text editor open on desktop 1 and I am currently on desktop 2 with firefox open
being able to rightclick on the desktop 1 tab and have it's apps brought into my current desktop to view them and do the same to toggle them out would be handy. Maybe I am the only one that thinks so though smile

If there was 6 open windows on each desktop your idea would have 12 open windows on desktop 2 and a very crowded screen.
With snapwm it is only 2 keyboard shortcuts to move an app from a desktop to the one that you are working on and one to move it back.


You're just jealous because the voices only talk to me.

Offline

#564 2014-03-03 11:51:39

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

erm yes although if i knew there was more than 2 apps on another deskop I wouldn't use the rightclick then.
Although I know nothing abt coding so don't even know if it is possible. I just found it very handy when I used DWM but that uses a tagging system. I had thought Snapwm was very similar to DWM but I am probably very wrong.

Last edited by chickenPie4tea (2014-03-03 12:15:28)


You can like linux without becoming a fanatic!

Offline

#565 2014-03-04 08:19:52

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

@chickenPie4tea, as a bloke that has several windows open on desktops a lot of the time the idea of combining desktops seems silly to me, so I won't do that.
But I think I have come up with something that might fit in with your above scenario. If you right click an unfocused desktop in the switcher the window on the current desktop that is focused will be moved to the desktop that was clicked and that desktop will be focused.
Hope that helps.

Cheers


You're just jealous because the voices only talk to me.

Offline

#566 2014-03-04 08:25:23

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

Well it's not exactly the same but it is a useful feature to have - I will definately use it, thanks.


You can like linux without becoming a fanatic!

Offline

#567 2014-03-04 11:57:58

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

Well, to be a bit blunt, if you want something exactly the same as dwm use dwm... tongue

Cheers


You're just jealous because the voices only talk to me.

Offline

#568 2014-03-04 12:23:10

chickenPie4tea
Member
Registered: 2012-08-21
Posts: 309

Re: dminiwm snapwm & bipolarbar

oops I didn't mean to sound ungrateful, I am glad about this feature, smile


You can like linux without becoming a fanatic!

Offline

#569 2014-03-05 03:25:00

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

@chickenPie4tea, it's all good. I was being cheeky tongue

I've updated snapwm-stable to current.
There are a few changes, see the Changelog

Cheers


You're just jealous because the voices only talk to me.

Offline

#570 2014-03-26 21:01:03

frash23
Member
From: Denmark
Registered: 2014-03-26
Posts: 49
Website

Re: dminiwm snapwm & bipolarbar

Hey!

I've been using snapwm for a week now, and I absolutely love it smile

I have one slight problem, though.
When I use my terminals, they leave space because they are locked in a grid so the font fits to the terminal.

How much would it take to i.e. add a "force size" option to the apps.conf settings? So if you enabled that, it would force the application into the tiled size no matter what.


Cheers,
frash


Amateur web developer & Linux enthusiast

Offline

#571 2014-03-27 15:30:19

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

Hi frash23, I'm glad you like the window manager.

What terminal are you using? Can you show a screenshot of the issue?


You're just jealous because the voices only talk to me.

Offline

#572 2014-03-27 20:04:44

frash23
Member
From: Denmark
Registered: 2014-03-26
Posts: 49
Website

Re: dminiwm snapwm & bipolarbar

moetunes wrote:

Hi frash23, I'm glad you like the window manager.

What terminal are you using? Can you show a screenshot of the issue?

nZyIYJQ.png

I get that with most terminals (only sakura does not do this, which removed pseudo-transparency in 3.0+).

Tested with gnome-terminal, roxterm, lxterminal, and a few others.

Last edited by frash23 (2014-03-27 20:05:56)


Amateur web developer & Linux enthusiast

Offline

#573 2014-03-27 23:33:32

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

I've known gvim behaves like that for a while but didn't know there were terminals that did that.
Providing a fix for gvim was pretty straightforward but the terminals won't redraw themselves until focus is taken away and reapplied.
Here's a pic of roxterm being unfriendly:
http://postimg.org/image/tcwbia1zn/
It fits the window size ok and can be typed into but it won't show properly until unfocused/focused...
Tried lots of things but haven't found a solution for that yet...
lxterminal is the same.
Both lxterminal and roxterm use the vte package which is developed by gnome for gnome so it only cares about stacking window managers not tilers so I'd suggest using a better terminal that works ok in a tiler like urxvt or xterm until I can stumble across a fix.

Cheers


You're just jealous because the voices only talk to me.

Offline

#574 2014-03-28 00:02:49

frash23
Member
From: Denmark
Registered: 2014-03-26
Posts: 49
Website

Re: dminiwm snapwm & bipolarbar

moetunes wrote:

I've known gvim behaves like that for a while but didn't know there were terminals that did that.
Providing a fix for gvim was pretty straightforward but the terminals won't redraw themselves until focus is taken away and reapplied.
Here's a pic of roxterm being unfriendly:
http://postimg.org/image/tcwbia1zn/
It fits the window size ok and can be typed into but it won't show properly until unfocused/focused...
Tried lots of things but haven't found a solution for that yet...
lxterminal is the same.
Both lxterminal and roxterm use the vte package which is developed by gnome for gnome so it only cares about stacking window managers not tilers so I'd suggest using a better terminal that works ok in a tiler like urxvt or xterm until I can stumble across a fix.

Cheers

Hmm, ok then.

I found EvilVTE to be absolutely perfect, but it must be configured during compilation, which dependencies I could not get to work (deprecated methods).

I guess I'll give urxvt a shot.

Last edited by frash23 (2014-03-28 00:10:30)


Amateur web developer & Linux enthusiast

Offline

#575 2014-04-09 23:12:41

moetunes
Member
From: A comfortable couch
Registered: 2010-10-09
Posts: 1,033

Re: dminiwm snapwm & bipolarbar

Fonts in firefox in dminiwm were missing/bad so i had to add Locale to have them readable.

Cheers


You're just jealous because the voices only talk to me.

Offline

Board footer

Powered by FluxBB