Light-Debian-Core-Live-CD-Wheezy + Porteus-Wheezy

For talk and support relating specifically to Puppy derivatives
Message
Author
wjaguar
Posts: 359
Joined: Wed 21 Jun 2006, 14:16

#1581 Post by wjaguar »

sunburnt wrote:Dmitry; I tried that: /opt/apps/h3v/hv3-linux-nightly-08_0203 in Browser box.
And http://mtpaint.sourceforge.net/handbook/index.html in Location box.

I seem to recall I did this in the past and it worked, but it doesn`t work now...
No, this never worked. Maybe it should be made to work... but presently, mtPaint checks if the Location is an existing file, and doesn't accept URLs in its place.
And the workaround which I've meant, is to make a wrapper script:

Code: Select all

#!/bin/sh
/opt/apps/h3v/hv3-linux-nightly-08_0203 http://mtpaint.sourceforge.net/handbook/index.html
And put its name into "Browser" box, and any existing file (even the same script) into "Location". That works.

BTW, it seems I've broken the file-selecting part of pathboxes somewhere between 3.44.40 and 3.44.50. That will be fixed tomorrow in 3.44.57.

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#1582 Post by sunburnt »

Dmitry; Thanks for your reply.
Our intent was how to avoid having it take space in DebianDog.
And downloading it is only slightly better, but it does solve the problem.

Having MtPaint be able to directly connect to the web site seems best.
Look for a local copy first, and go to the web page if there is none.
An option to download a local copy is a good idea too.
This keeps the docs from having to be part of the package.
.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

Re: mtPaint help

#1583 Post by mcewanw »

wjaguar wrote:
mcewanw wrote:I think you can just open mtpaint and edit Image -> Preferences to point the entry box 'Location of Handbook Index' to a shell script which loads the browser with address: (...)
EDIT: As Terry points out, the above doesn't work. So I think you need to create an extra small shell script (e.g. /opt/bin/mtpaint_help), and have an icon/menu item for that, as Terry suggests. Mtpaint itself won't open it unfortunately:
saintless wrote:Added Mtpaint help file menu entry.
And all this because no one noticed the very next box on the Preferences->Paths page: "HTML browser program". :-)
There is the proper place to put the name of your shell script; mtPaint doesn't use a browser for anything else but displaying its docs, so it won't break anything.

-= With best regards, Dmitry Groshev, maintainer of mtPaint =-
Well, I don't think anyone overlooked that entry box Dmitry, but I think a script isn't intuitively an "HTML browser program", which I at least presumed your program wanted/needed there for some other purpose. Good that that's not the case and thanks for letting us know that calling a script there is acceptable rather than naming a browser per se. An other minor issue solved! Please don't imagine I have anything against your program (just because my daughter has!). Mtpaint is a work of art really - an amazing example of resource efficiency and minimalism.

I'm also very impressed with the way JWM has been put together, having now looked quite closely at some of its source code. Very well organised and well written and again an impressive piece of work in terms of efficiency, functionality, and low resource usage.
github mcewanw

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1584 Post by saintless »

Hi, all.

Removing IceWM - I think it is too early for this yet. Lets work with both WM and try to make JWM easy configurable.
What we gain is saving 3,3 Mb compressed space after removing IceWM-Control-Center as well. Removing XFE will save more but we keep it with Rox.
What we loose? JWM does not have any configuration programs. All has to be done with text editor and much reading and testing first. Puppy JWM structure is different. It has separate files for theme, toolbar etc. JWM doesn't have even Reboot and Shutdown menu buttons as default (at least the debian package doesn't have them).
DebianDog jwm has only system.jwmrc with all included there. None of the puppy JWM configuration programs will work out of the box in DebianDog.
It is hard to imagine how long it will take to have something for JWM that we already have in IceWM. For Example IceWM control center has working: Menu, Winoptions, Toolbar, Keys, Themes editor. We have Themes changer from Start menu by default for IceWM.
IceWM has more understandable configurations files format even if we edit them with text editor. It has only one format for programs menu and toolbar buttons for example:

Code: Select all

program path-toicon path-to-program
This is not the case with Jwm.
Lets not forget the first day JWM trials brought this strange behavior:
I just found that one of the "side-effects" I assumed were caused by my experimenting but I was wrong.
Booting with empty savefile I noticed the following:
Clicking on an empty space on the desktop and directly click on xterm icon results in unresponsive xterm (cannot type anything)
Same goes for me when clicking geany on desktop.
Opening xterm or geany from the menu is OK.
Yes, we have a fix, but in IceWM we do not have this problem to be fixed.
Now the other side effect (I think only when starting jwm from icewm):
When you do from Menu>Programs>Window Managers>Jwm
It will start Jwm but: when opening xterm it can't be closed, need to type "exit"
Then switch to icewm again, run start-jwm from /opt/bin in xfe.
Everything seems fine then... very strange Shocked
I added in ~/.icewm/menu a new entry for start-jwm under utilities and... works without problems also, even more strange!
It happens every time in JWM and seldom in IceWM.

I suggest we test and improve JWM.
I will make DebianDog to boot by default in JWM but it is too early for decision to remove IceWM. Even if we do not need it and all seems good or better with JWM does it worth for 3,3 Mb to loose second WM? Many puppies use both as an option or even IceWM by Default (Fluppy for example).

Also note we still have two kernel modules in 01-v5.squashfs. Removing 686-pae kernel will save 21Mb compressed data. We can afford to keep 3,3 Mb for second WM.

Toni

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1585 Post by saintless »

wjaguar wrote:And the workaround which I've meant, is to make a wrapper script:

Code: Select all

#!/bin/sh
/opt/apps/h3v/hv3-linux-nightly-08_0203 http://mtpaint.sourceforge.net/handbook/index.html
Thank you, Dmitry :)
I will change it this way.

Toni

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1586 Post by saintless »

Hi, Terry.
See if you can stop desktop buttons from popping-up "hints/tool-text".
I think this is easy in IceWM preferences but not sure how to do it in JWM. I will search for an option.
# Can we reduce the text size in Xterm.? ( Isn`t rxvt better then Xterm.? )
# And Xterm in the new Squash file has no scroll bar. ( Maybe always.? )
I do not see any difference in Xterm in 01-v5.squashfs.
Text size is easy to change from this line in /etc/X11/app-default/xterm

Code: Select all

*faceSize:  14
Rxvt is smaller but I don't see it as better. For example hold Ctrl and Left or Right click in Xterm to see what menu will appear. I can't see this in Rxvt.
BTW Rxvt is only 400 Kb so no problem to add it as second option if you think it is better. Maybe it is possible to configure Rxvt to be more useful than Xterm? Then we can remove Xterm.
I noticed menu has 2 System categories. ( Debian generated of course...)
Yes, the first System category can be easy removed or Changed to other name - Config Tools for example?
# Where is the .jwmrc file at.? It needs some editing to fix some stuff.
/etc/jwm/system.jwmrc
Use update-menus after the change and check for errors with:

Code: Select all

jwm -p
And Restart X from Start menu button to make changes visible.
### New menu scripts work. The desktop files are a mess of course.
They will need to be handled better, most Categories are "Development".
Thank you, I will test it today.

Toni

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1587 Post by saintless »

sunburnt wrote:### New menu scripts work. The desktop files are a mess of course.
They will need to be handled better, most Categories are "Development".
Hi, Terry.
Still can't make the new menu appear. I get only this output from terminal but no change in Start menu. Do I have to edit system.jwmrc some way befor using mk-menus? What is the right place for menu folder or shall I move the files in /opt/bin for example?

Code: Select all

<JWM>

<RootMenu label="JWM" labeled="false" height="24" onroot="3">

<Menu label="Desktop" icon="Desktop" height="16">
</Menu>
<Menu label="System" icon="System" height="16">
 
..............................

Many programs here - too long for posting.

....................................................

<!-- <Include>/root/.jwm/themes/jwm-default</Include> -->
<Include>/root/.jwm/jwmrc-theme</Include>
<Include>/root/.jwm/jwmrc-personal</Include>

</JWM>
root@debian:~# 
When I copy the content in /etc/jwm/system.jwmrc I get this errors and I can see the new menu clicking on the desktop but not the taskbar.

Code: Select all

root@debian:~# jwm -p
JWM: warning: /etc/jwm/system.jwmrc[95]: close tag "RootMenu" does not match open tag "Group"
JWM: warning: /etc/jwm/system.jwmrc[98]: close tag "Group" does not match open tag "JWM"
JWM: warning: /etc/jwm/system.jwmrc[246]: close tag "JWM" without open tag
JWM: warning: /etc/jwm/system.jwmrc[97]: invalid tag in JWM: Option
root@debian:~# 
Also almost all folders are empty except System, Utility and Multimedia have few programs. It does not translate the catgories from .desktop files in the new menu Categories yet I guess?
And I loose the theme and shutdown, exit menu. I gues I have to edit system.jwmrc to keep this menu and the theme.

I created /root/.jwmrc file from /etc/jwm/system.jwmrc copy and it works to save changes with update-menus, but it does not get changed from mk-menus command.
We also do not have separate files jwm-default, jwm-theme, jwm-personal etc. All in Debian is included in /etc/jwm/system.jwmrc file (or $HOME/.jwmrc).
I think we have a lot lot lot of work to configure JWM the way puppy does it.

Edit:
OK, changing (uncomment) this line in mk-menus and creating /root/.jwmrc does the update but with the errors I posted above from jwm -p + allmost no programs in the menu folders and no taskbar:

Code: Select all

echo -e "$jwmH\n\n$JWM$jwmT"
to

Code: Select all

echo -e "$jwmH\n\n$JWM$jwmT" > $HOME/.jwmrc
Toni

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#1588 Post by mcewanw »

I haven't tried this, but read:

http://www.murga-linux.com/puppy/viewto ... 252#719252

If you want to completely disable popups, you can set:
Code:

<PopupStyle enabled="false">
</PopupStyle>
github mcewanw

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1589 Post by saintless »

mcewanw wrote:<PopupStyle enabled="false">
</PopupStyle>
Thank you, William :)

Terry, it works but... we loose the date view popup when the cursor is over the clock also. Better not to disable popups.

Toni

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1590 Post by saintless »

If we disable menu.h hints we can get this menu on the picture for JWM. Empty Applications and System are removed. The only empty folder is Debian but it will include any installed program with missing section like Others folder in xdg-menu.

Toni
Attachments
jwm-mwnu.jpg
(46.23 KiB) Downloaded 178 times

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#1591 Post by sunburnt »

Toni; Puppy`s Desktop view on the desktop buttons does no popup, and is nicer.

Keeping IceWM is the best idea, it`s a very good one and it`s working very well.
I do think JWM as default is good ( Puppy clone ), once it`s fixed and working.

Yes, the menu app is just for experiment, I didn`t know where the jwmrc file went.
Strange... I looked for /etc/jwm but I didn`t see it...
I`ll compare Debian and JWM`s jwmrc files to see where things are going wrong.
The echo in Xterm looked good with no errors, but that doesn`t mean it will work.


Got Xterm`s font set at 10. And it`s Rox desktop shortcut set to position.
In "Edit Item" set "Arguments to pass" like "-geometry 80x24+200+396"
-geometry (Text Width)x(Text Height)+(Text X)+(Text Y)
Size and Position is character size based, not pixel based.

# Thanks Toni.!
.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

quick and reliable way to switch window managers

#1592 Post by mcewanw »

EDIT: Hi guys, see my following post for a better and faster method that doesn't need Ctrl-D, and which can also be used to quickly change autologged in user from root to puppy

If you don't mind doing a Ctrl-D to complete the switch wm procedure, the following provides a quick and probably reliable way to switch window managers:

In /opt/bin/start-icewm put:

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-icewm .xsession
ln -f -s startup-icewm startup
telinit 1
In /opt/bin/start-jwm put:

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-jwm .xsession
ln -f -s startup-jwm startup
telinit 1
Then just use the menu entry you already have to run these. If you press Ctrl-D when asked to continue, init will not drop into runlevel 1 but instead restart per Debian normal in runlevel 2 but with the alternative wm.

The same idea of using telinit 1 (or telinit s) would also work with changing login user without asking for password (by first editing /etc/inittab via command 'sed' and then calling telinit 1 to restart init). I have tried kill -HUP 1 to restart init, but that wouldn't work.

telinit needs to be run as root of course (telinit is really just a link to init but its use clarifies what you are doing).
Last edited by mcewanw on Sun 02 Mar 2014, 22:24, edited 2 times in total.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#1593 Post by mcewanw »

EDIT: Drat! I thought the following was fine but now I note I'm getting 100% CPU in Lxtask! I've seen that occurring occasionally anyway (has anyone else?) but it is all the time with this pkill method it seems... Pity if true (and why???). Please test.

EDIT2: I've just rebooted with clean live-rw and this pkill login method seems to be working fine now afterall (no 100% CPU problem anymore).

As I say, at other times (nothing to do with this change wm routine), I have occasionally found CPU going up to 100%; Has anyone else experienced that??
It seems to occur sometimes after making major system script change - but I'm not sure about that.

Even better than my above post, the following seems to work immediately. The only problem I see with this method would be that it probably needs changed should multiple users want to log in at once. However, for that usage the system admin would probably change the login mechanism anyway, so this simple method might be useful for the general iso release:

The following provides a very quick and probably reliable way to switch window managers:

In /opt/bin/start-icewm put:

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-icewm .xsession
ln -f -s startup-icewm startup
pkill login
In /opt/bin/start-jwm put:

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-jwm .xsession
ln -f -s startup-jwm startup
pkill login
Then just use the menu entry you already have to run these.

The same idea might work for automatically changing logged-in user by first using something like sed to alter inittab line (I haven't tried this second idea yet):

Code: Select all

1:2345:respawn:/bin/login -f root </dev/tty1 >/dev/tty1 2>&1
to the user you want autologged in. EDIT: I've now tested changing autologged in user with pkill login method too, and yes, it works, you just need to first issue the command 'telinit q' to get init to re-read inittab before running command 'pkill login' so you just need to put these commands into a script and call from the menu.

After backing up original /etc/inittab, I tried following quick sed command, which worked but could no doubt be improved:

Code: Select all

sed -i -e "/^1\:/ s/login -f root/login -f puppy/" /etc/inittab
A swap user from root to puppy script would at its simplest just therefore need something like:

Code: Select all

sed -i -e "/^1\:/ s/login -f root/login -f puppy/" /etc/inittab
telinit q
pkill login
A more complicated version of that could also do puppy back to root (via sudo)
Last edited by mcewanw on Sun 02 Mar 2014, 23:55, edited 9 times in total.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

unnecessary bash processes still running

#1594 Post by mcewanw »

As far as ${HOME}/startup-icewm and startup-jwm are concerned, looks like you need to put any sleep as follows afterall. Otherwise, as things stand in what was released, bash processes are left hanging around taking up some RAM (haven't had time to think why...). With these changes should only be the bash process started by login immediately after booting into X:

startup-icewm maybe should be:

Code: Select all

icewmtray &
/usr/bin/rox -p ${HOME}/.config/rox.sourceforge.net/ROX-Filer/pinbd &
sleep 4
/opt/bin/start-up &
desktop_drive_icons &
frisbee-tray &
volumeicon &
startup-jwm maybe should be (didn't need any sleep at least on my computer):

Code: Select all

/usr/bin/rox -p ${HOME}/.config/rox.sourceforge.net/ROX-Filer/pinbd &
/opt/bin/start-up &
desktop_drive_icons &
frisbee-tray &
volumeicon &

User avatar
sunburnt
Posts: 5090
Joined: Wed 08 Jun 2005, 23:11
Location: Arizona, U.S.A.

#1595 Post by sunburnt »

That`s great William. I`m needing JWM to reread it`s menu with Bash after update-menus is run.
Or restart X in Bash.? It makes the screen flash, JWM should refresh itself without restarting X.

Menu setup now makes a working menu. Can`t get icons to show on the root menu.
Some of the program icons show, but not all. I think it has to do with JWM icon path.
I set a few <IconPath> so it should work, but doesn`t...

Many empty categories in the root menu, I think leaving them there is the best and easiest.
They will be filled in as apps are installed, unless no "Games, etc." are added of course.

# Getting the icons to show is the main problem needing a fix. And testing with apt-get installs.

Toni; Add "menu" folder to /opt/apps when it works, it`s one of our custom apps for DebianDog.
Add the icons in the Zip file`s /menu/icons to /usr/share/pixmaps
.
Attachments
menus.zip
(40.88 KiB) Downloaded 188 times

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#1596 Post by mcewanw »

sunburnt wrote:That`s great William. I`m needing JWM to reread it`s menu with Bash after update-menus is run.
Hi Terry:

Code: Select all

jwm -restart
I'm enjoying jwm - low on resources and fast loading. Love its Pager, which can have tons of virtual desktops in double of triple row if required whilst still taking up only a little space.

catsezmoo
Posts: 26
Joined: Sun 09 Feb 2014, 04:59

#1597 Post by catsezmoo »

JWM does not have any configuration programs. All has to be done with text editor and much reading and testing first.
I turned over some rocks. Here ya go:

JWM Configuration Manager GUI
http://bkhome.org/blog/?viewDetailed=01775
^---v
HowTo use JWM configuration manager(4 minutes)
http://www.youtube.com/watch?v=SEyJSvwoV5g

http://puppylinux.org/wikka/JWMElements

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1598 Post by saintless »

Hi, all.

William, thank you for the login and wm change solutions. I will test and include for the next testing module.
BTW I haven't noticed any 100% CPU load from time to time, but I noticed after switching WM I have start-icewm and start-jwm both processes left in Lxtask.

Terry, thanks, I will test the menus.

I think it is important to decide something now.
Puppy uses separate .jwmrc, jwmrc-tray, jwmrc-theme, jwmrc-personal etc files with <include>pathts to the files in main .jwmrc
Should we keep all in system.jwmrc file or we should accept the puppy structure in order to make puppy configuration programs to work easier in DebianDog?

Catsezmoo, thank you for the links.

Toni

User avatar
saintless
Posts: 3862
Joined: Sat 11 Jun 2011, 13:43
Location: Bulgaria

#1599 Post by saintless »

mcewanw wrote:

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-icewm .xsession
ln -f -s startup-icewm startup
pkill login

Code: Select all

#!/bin/sh

cd $HOME/
ln -f -s .xsession-jwm .xsession
ln -f -s startup-jwm startup
pkill login
Seems to work perfect, William. I will leave it this way for the next version.
The same idea might work for automatically changing logged-in user by first using something like sed to alter inittab line (I haven't tried this second idea yet):

Code: Select all

1:2345:respawn:/bin/login -f root </dev/tty1 >/dev/tty1 2>&1
I'm not sure we should include this as option. Multiuser distro should not allow user to autologin as root such quick and easy way. At least I see logout and typing the password from command prompt as a security matter. We even didn't allow user to shutdown and reboot without using sudo. Even for root such option should be decided by system administrator. Any other thoughts on this?

Toni
Last edited by saintless on Mon 03 Mar 2014, 06:56, edited 2 times in total.

mcewanw
Posts: 3169
Joined: Thu 16 Aug 2007, 10:48
Contact:

#1600 Post by mcewanw »

saintless wrote:

Code: Select all

1:2345:respawn:/bin/login -f root </dev/tty1 >/dev/tty1 2>&1
[
I'm not sure we should include this as option. Multiuser distro should not allow user to autologin as root such quick and easy way. At least I see logout and typing the password from command prompt as a security matter. We even didn't allow user to shutdown and reboot without using sudo. Even for root such option should be decided by system administrator. Any other thoughts on this?

Toni
Valid point to prevent user easily becoming root user, However, since root user has full power anyway, the described mechanism is very useful the other way round: That is, to quickly allow default root user to become normal (puppy user) after which they need to use sudo. And puppy user should in any case have only limited sudo rights - not 'all' - at present they can use sudo to become root as I describe simply via the console anyway. As you know, it is traditional for root user to have a second account in which they log in as a 'normal' users - that's what I will be using Puppy user for. Other users can be added at any time to the system of course and be given the same (or different sudo permissions as Puppy user); the appropriate permissions can be worked upon.

Anyway, the point is that there is no harm (and many advantages) including this option for root user to become puppy user, but we shouldn't set it up to allow the other way round. At the moment, the fact I can use this method from puppy demonstrates a security hole, but as I say we just need to fix the sudo rights to prevent that (sudo rights could be restricted to specified apps only).
Last edited by mcewanw on Mon 03 Mar 2014, 07:08, edited 1 time in total.

Post Reply