Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Wed 17 Sep 2014, 13:52
All times are UTC - 4
 Forum index » Off-Topic Area » Programming
How to change settings of different window mangers?
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [7 Posts]  
Author Message
8-bit


Joined: 03 Apr 2007
Posts: 3368
Location: Oregon

PostPosted: Sun 25 Apr 2010, 03:03    Post subject:  How to change settings of different window mangers?  

With puppy versions offering a variety of desktop managers,
JWM, Stardust, ICEWM, etc, how does one write their program if it makes changes to JWM as far as Class with options.
I tried a suggestion to make a file of the additions and write code to put an Include [Path to addition file] in the JWM template file.
But I tried that and it did not seem to take.
It had a nolist option that just did not work unless the code was written directly to .jwmrc.
Also, it seems that some puppy versions have more than one window manager and a modification to the configuration of one does not carry to the others.
Does this mean that for a program to work with all, one has to write window manager specific code for each?

And some people think programming is easy.
I have spent many a sleepless night debugging and testing programs as have others here.
But when you get it to a point of "always works", you get a feeling of accomplishment.
Back to top
View user's profile Send private message 
Pizzasgood


Joined: 04 May 2005
Posts: 6270
Location: Knoxville, TN, USA

PostPosted: Sun 25 Apr 2010, 18:26    Post subject:  

Yeah. If you want to alter the settings of a WM, you have to do it on a per-WM basis. There isn't any kind of standardized means of configuring them.

Generally it is considered bad form for a program to modify a person's WM settings. Instead, they usually ship with instructions for the user on how to modify it, maybe including a sample configuration file that they can just drop in or copy and paste from. Some programs also have an option where it asks the user which WM they use and whether they want it to update their settings.

What is it that you need to do?

_________________
Between depriving a man of one hour from his life and depriving him of his life there exists only a difference of degree. --Muad'Dib

Back to top
View user's profile Send private message Visit poster's website 
8-bit


Joined: 03 Apr 2007
Posts: 3368
Location: Oregon

PostPosted: Sun 25 Apr 2010, 21:05    Post subject:  

I brought this up after experimenting with a NOT RELEASED program that made direct changes to .jwmrc.
It had an uninstall script that would undo the changes if one uninstalled the program.
But I found that although it would work on some versions of Puppy with the JWM window manager, Puppy 4.5 CE using Stardust or Dude, would mess up with all window borders becoming bright red after a first run of the program.
A reboot would restore things until the program was run again.
I did not go very far into it and since it was not my program, I just chalked it up as not being compatable with any Puppy that did not use the JWM window manager.
I spent many a sleepless night bug searching, trying code modifications and making suggestions to the program's creator.
I have a working version now that works for me, but I will not offer it to anyone but the creator and another tester that has already helped out the creator of the program.
If I upset the creator of said program with these comments, I am sorry!
I have not at any time tried to take over the program, and only submitted modified programs to him for his interest.
Back to top
View user's profile Send private message 
disciple

Joined: 20 May 2006
Posts: 6433
Location: Auckland, New Zealand

PostPosted: Mon 26 Apr 2010, 02:50    Post subject:  

BTW normally programs shouldn't make direct changes to .jwmrc as it is automatically regenerated from a template whenever you install or uninstall a .pet, and the changes will be lost.
_________________
DEATH TO SPREADSHEETS
- - -
Classic Puppy quotes
- - -
Beware the demented serfers!
Back to top
View user's profile Send private message 
technosaurus


Joined: 18 May 2008
Posts: 4351

PostPosted: Mon 26 Apr 2010, 03:28    Post subject:  

I wouldn't say its 100% to not change "window manager" settings when referring to jwm - Ptray is the perfect example

include for jwm should look like
<Include>/root/.jwm/jwmrc-theme</Include>
right before the </JWM> at the end

most scripts I have seen remove the jwm tag and echo >> whatever lines they need to add

it can be a pain to add with a sed script via pinstall - looks like a tornado hit a picket fence

_________________
Web Programming - Pet Packaging 100 & 101
Back to top
View user's profile Send private message 
8-bit


Joined: 03 Apr 2007
Posts: 3368
Location: Oregon

PostPosted: Mon 26 Apr 2010, 03:40    Post subject:  

technosaurus,

With exactly the type of modification as to doing it, I found that the file I had made for the include was not used even though I had the program add an include to the jwmrc template file. That same include line was also written by the template file to .jwmrc by the template file.
But the include file never seemed to be picked up and used.
Also, I double and triple checked the path to the file the include statement referenced.
When .jwmrc was modified directly, the modification was used.
I also noticed a comment that changes to the jwmrc template file would stay.
could it be that the include file has to be placed in the hidden /root/.jwm directory?
Back to top
View user's profile Send private message 
technosaurus


Joined: 18 May 2008
Posts: 4351

PostPosted: Mon 26 Apr 2010, 12:38    Post subject:  

Did you begin the include file with <JWM> and end it with </JWM> ????
I'm not really sure why that is necessary, but it is something I ran into when I was playing with using trays & traybuttons as icons and using jwm to set the background image for each virtual desktop (to eliminate the need for ROX for low resource machines)

If you post up the code I can take a look.

_________________
Web Programming - Pet Packaging 100 & 101
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [7 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Off-Topic Area » Programming
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0546s ][ Queries: 11 (0.0036s) ][ GZIP on ]