Author Topic: (solved) Numlock on boot  (Read 4331 times)

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 375
(solved) Numlock on boot
« on: June 23, 2011, 10:31:50 AM »

Just wanted to share this tip with anyone wanting LXDE to boot with numlock enabled.

edit:

 /home/<user_name>/.config/lxautostart/lxautostart.sh

and add this to the end of the file:

/usr/bin/enable_X11_numlock &

save and close the file. Next time you reboot--tada-- numlock will be enabled.

It took me way too long to figure out how to fix this minor annoyance! I hope this helps anyone as annoyed as I was...

 8)
 

Offline jeffreybruton

  • Jr. Member
  • **
  • Posts: 16
Re: (solved) Numlock on boot
« Reply #1 on: August 04, 2011, 01:25:07 PM »
Zerocool:

Thanks for the post as this is really great!  Also thanks to parnote (for the idea) and leiche (for the coding)!

I didn't initially have /home/username/.config/lxautostart/lxautostart.sh but running /usr/bin/lxautostart.sh (which fires up a cool GUI) gave me the option of creating it and then also adding apps.

Thanks again to all.
Jeffrey Bruton

Offline daniel

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 3752
  • God knows, i'm not an Angel!
    • Tipps und Tricks
Re: (solved) Numlock on boot
« Reply #2 on: August 04, 2011, 01:48:59 PM »
Hi Jeffrey Bruton,

enjoy LXDE...

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 375
Re: (solved) Numlock on boot
« Reply #3 on: August 04, 2011, 04:07:44 PM »
Wow, great. I'm happy I could help ya.

I'm actually a diehard KDE guy myself, but I have an older Dell at work that LXDE runs
really great on. It really is quite good DE in its own right.

The only issue I've run into with it is every once in a blue moon, lxpanel peeks 100% cpu
usage and locks up the panel. So I have to <Ctrl>, <Alt>, <Del> "Kill lxpanel" and then
rerun lxpanel (I created a desktop icon to lxpanel). Not very graceful solution but better
than rebooting with open apps.

If anyone knows a better solution please post it...


Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15847
  • LXDE! Coffee, Bacon and Cheesecake!
Re: (solved) Numlock on boot
« Reply #4 on: August 04, 2011, 05:38:36 PM »
zerocool,
Try this instead --- open lxdecc and click the Refresh Panel icon. The icon for lxdecc is on the panel a couple over from the menu - looks like a monitor.

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 375
Re: (solved) Numlock on boot
« Reply #5 on: August 04, 2011, 06:54:59 PM »
Thanks for the tip Neal. The problem is when lxpanel peeks 100% cpu it locks up everything
on the panel. But I guess I could change the lxpanel icon on my desktop to point to lxdecc
(refresh panel). Then whenever it locks run lxdecc from the desktop.

BTW, you have done a superb job with LXDE. I'm sure you make Texstar proud to have ya.

Thanks for all you do.

 8) 

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15847
  • LXDE! Coffee, Bacon and Cheesecake!
Re: (solved) Numlock on boot
« Reply #6 on: August 05, 2011, 01:53:56 AM »
Thanks for the tip Neal. The problem is when lxpanel peeks 100% cpu it locks up everything
on the panel. But I guess I could change the lxpanel icon on my desktop to point to lxdecc
(refresh panel). Then whenever it locks run lxdecc from the desktop.

BTW, you have done a superb job with LXDE. I'm sure you make Texstar proud to have ya.

Thanks for all you do.

 8) 

As an alternative, try this --- 
Create a file named panel-refresh (or whatever name you're comfortable with) dot desktop on your desktop. Add this content to it --   
Code: [Select]
[Desktop Entry]
Name=Panel Refresh
Comment=refresh the panel
Exec=/home/zerocool/.bin/panel-refresh
Icon=boot_init_section.png
Terminal=false
Type=Application
StartupNotify=true

Save and exit.

Now create a new hidden folder named .bin in your /home/zerocool. Add this content --
Code: [Select]
#!/bin/sh
#
lxpanelctl restart &

Save and exit.
Make the file executable - right click > Properties > Permissions tab > tick the Make the file executable entry.

Now click the icon on your and your panel will be refreshed.

Offline sling-shot

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 1730
  • Satyameva Jayate | Truth Alone Triumphs.
Re: (solved) Numlock on boot
« Reply #7 on: August 05, 2011, 08:11:26 AM »
Does LXDE have PCC?
I think NumLock is among the services. If you tick the option it sets the NumLock on.
I run KDE so can not say about LXDE.
-SS.
Packaging well will cure headaches of many :) But learning to package will cause headaches in many :(

AMD AthlonX2 3600+/ASUS M2NPV-VM/ATi HD4670/Onboard sound/3.5GB DDR2-533 RAM/SEAGATE 160+320GB HDD/DELL S2240L FullHD/Creative SBS370 2.1/PCLinuxOS2013/KDE4
Samsung NP305U1-A06IN | Nokia E6

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15847
  • LXDE! Coffee, Bacon and Cheesecake!
Re: (solved) Numlock on boot
« Reply #8 on: August 05, 2011, 10:15:58 AM »
LXDE is a desktop environment, just as KDE is a desktop environment. PCLinuxOS with LXDE is PCLinuxOS, just as PCLinuxOS with KDE is PCLinuxOS. The PCLinuxOS Control Center (PCC) is part of PCLinuxOS.

Offline sling-shot

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 1730
  • Satyameva Jayate | Truth Alone Triumphs.
Re: (solved) Numlock on boot
« Reply #9 on: August 05, 2011, 11:02:21 AM »
Then wonder why there is any need to edit all these configuration files while a simple step in PCC might fix it. Or did I not get something here?
-SS.
Packaging well will cure headaches of many :) But learning to package will cause headaches in many :(

AMD AthlonX2 3600+/ASUS M2NPV-VM/ATi HD4670/Onboard sound/3.5GB DDR2-533 RAM/SEAGATE 160+320GB HDD/DELL S2240L FullHD/Creative SBS370 2.1/PCLinuxOS2013/KDE4
Samsung NP305U1-A06IN | Nokia E6

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15847
  • LXDE! Coffee, Bacon and Cheesecake!
Re: (solved) Numlock on boot
« Reply #10 on: August 05, 2011, 11:05:58 AM »
It's an alternate way of accomplishing the same thing, sling-shot.   

Offline sling-shot

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 1730
  • Satyameva Jayate | Truth Alone Triumphs.
Re: (solved) Numlock on boot
« Reply #11 on: August 05, 2011, 11:12:42 AM »
:)
That is the beauty of Linux. There are many ways of getting to the same destination. Any of them will work the same and one select what one wants.
Looks like this might be a good topic to write a page on the wiki.
-SS.
Packaging well will cure headaches of many :) But learning to package will cause headaches in many :(

AMD AthlonX2 3600+/ASUS M2NPV-VM/ATi HD4670/Onboard sound/3.5GB DDR2-533 RAM/SEAGATE 160+320GB HDD/DELL S2240L FullHD/Creative SBS370 2.1/PCLinuxOS2013/KDE4
Samsung NP305U1-A06IN | Nokia E6

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 375
Re: (solved) Numlock on boot
« Reply #12 on: August 05, 2011, 02:00:08 PM »
Hi sling-shot:

That I know of, there is no way to set numlock on boot in PCC.

In KDE it might be under <configure your desktop> (which is a KDE thing)
but as I have said, that I know of, it's not in PCC <configure your computer>
which is a PCLinuxOS thing.

If I'm wrong please feel free to correct me. No shame in being wrong ever.

Thanks ZC 8)
« Last Edit: August 05, 2011, 02:04:40 PM by zerocool »

Offline Neal ManBear

  • Administrator
  • Super Villain
  • *****
  • Posts: 15847
  • LXDE! Coffee, Bacon and Cheesecake!
Re: (solved) Numlock on boot
« Reply #13 on: August 05, 2011, 02:16:13 PM »
zerocool,
PCC is the same across all DEs in PCLinuxOS. In PCLinuxOS-LXDE as in all versions, open PCC > System > Manage system services by enabling or disabling them, scroll down to Numlock and check or uncheck its tickbox, according to what you want to do.

Offline zerocool

  • Sr. Member
  • ****
  • Posts: 375
Re: (solved) Numlock on boot
« Reply #14 on: August 05, 2011, 02:25:28 PM »
Quote
zerocool,
PCC is the same across all DEs in PCLinuxOS.

That I knew...

Quote
In PCLinuxOS-LXDE as in all versions, open PCC > System > Manage system services by enabling or disabling them, scroll down to Numlock and check or uncheck its tickbox, according to what you want to do.

That I didn't know. Never thought to look there for it... Live and learn.

Thanks