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 Mon 20 Oct 2014, 19:02
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
Numlock switcher for X
Moderators: deshlab, Flash, GuestToo, Ian, JohnMurga, Lobster
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [5 Posts]  
Author Message
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Fri 23 Oct 2009, 12:03    Post subject:  Numlock switcher for X  

Dear Puppians,

I had a weird experience today installing Puppy Jaunty on a Packard-Bell EasyNote laptop. A friend was willing to let me trash his pre-installed Vista for Puppy, an opportunity for which I am grateful, coming as it did on the launch day of M$ Win7. He would be an influential Puppy convert/advocate since he is a rector of a university in Germany. Everything went fine except for the Xorg language settings. I have four languages on my three computers and did the same for him. Oddly, whenever I tried typing anything in the three additional languages, I would get crap on the right side of the keyboard, starting with the letter "k". I could not for the life of me figure out what was wrong. Eventually, to our mutual embarrassment, I figured it out: numlock was on by default and there was no indicator lamp to tell us. I looked in the bios for a way to turn it off by default, but the Packard-Bell implementation is a very abbreviated affair with no numlock setting that I could see.

So, I compiled a little program called numlockx, which can toggle the state of that key. It can be placed in root/.xinitrc or in the /root/Startup dir. It knows only two arguments:
Code:

numlockx on
numlockx off

Now, everything is all sweetness and light in EasyNote-land. Long live Puppy!

Here is the tiny binary (4k), which I tested in 3.x and 4.x.

With kind regards,
vovchik
fixnumlock.tar.gz
Description 
gz

 Download 
Filename  fixnumlock.tar.gz 
Filesize  3.17 KB 
Downloaded  462 Time(s) 
Back to top
View user's profile Send private message 
jemimah


Joined: 26 Aug 2009
Posts: 4309
Location: Tampa, FL

PostPosted: Fri 23 Oct 2009, 17:50    Post subject:  

There's also a more generalized version of this called xte that can be used to press any button you want from a script.

http://linux.die.net/man/1/xte

You can get it here: http://hoopajoo.net/projects/xautomation.html
Back to top
View user's profile Send private message Visit poster's website 
01micko


Joined: 11 Oct 2008
Posts: 7831
Location: qld

PostPosted: Sat 24 Oct 2009, 19:25    Post subject:  

Hello vovchik

Very nice little app. I put the binary in my path (/usr/bin if I recall) and made a simple script and put it in /root/Startup such that my numlock is on at boot and X restart.
Code:
#!/bin/sh
numlockx on &


Thank you and Cheers

Mick

_________________
Woof Mailing List | keep the faith Cool |
Back to top
View user's profile Send private message Visit poster's website 
Vyse


Joined: 15 Aug 2009
Posts: 30

PostPosted: Sun 25 Oct 2009, 07:23    Post subject:  

@vovchik
Thanks a lot!! This is exactly what I was looking for..no more turning the numlock manually after each start!

Long live Puppy!
Back to top
View user's profile Send private message Yahoo Messenger 
Fingers


Joined: 25 May 2013
Posts: 14
Location: London, UK

PostPosted: Wed 19 Jun 2013, 09:45    Post subject:  

fatdog64 users: search for numlockx in the Package Manager (in Control Panel > System) and install it there. Option to have numlock on at startup is provided Smile
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 1 [5 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Unsorted
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.0527s ][ Queries: 13 (0.0043s) ][ GZIP on ]