Home | Blog | Software | Reviews and Features | Forum | Help | Donate | About us
topbanner_forum
  *

avatar image

Welcome, Guest. Please login or register.
Did you miss your activation email?

Login with username, password and session length
  • September 02, 2015, 07:52:16 AM
  • Proudly celebrating 10 years online.
  • Donate now to become a lifetime supporting member of the site and get a non-expiring license key for all of our programs.
  • donate

Author Topic: idea: make scroll lock <say> remap arrow key functions to page,home, end etc.  (Read 5945 times)

brotman

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 51
  • Chuck
    • View Profile
    • Donate to Member
'Situation:  I am able to type only using my right hand.  I recently "inherited" a very nice SONY viao laptop,  I love using it when I'm away from my desktop.

Problem: This laptop has separate (inverted T") cursor keys. Unfortunately it does not have separate keys for  numbers, page-up,down pg-dn home, and end.  To get those functions one must press a "Fn" key located between the left ctrl and windows keys. I cannot do this with one hand.  (If it were on the right side ofg the space bar it would be no problem!)... I  spoke with the Folks at Sony and the told me that the "Fn" key is intercepted before it gets to windows, so standard key remapping won't work.  I've had limited only success using AHK to remap alt or ctrl with the cursor keys to the required functions (it appears that odd thins happen where ctrl or alt lead to ctrl + alt being received. 

What might help??:  I'd like to be able to choose an otherwise unused key, like scroll lock, to act as a modal switch to turn on the alternate meanings for the cursor. It seems like AHK could allow me to do this, but I'm not sure exactly how to accomplish this. 

Any help in this regard will be appreciated.

Thanks,
Chuck
Chuck Brotman

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 2,535
    • View Profile
    • Donate to Member
I think the essence is in what Sony told you already. The Fn key isn't handled by Windows but by the BIOS, not modifiable by any software intervention.

Would connecting a more you-friendly keyboard be a solution? One that has all the normal keys in a configuration that you can use it with one hand only? I assume you had something usable before you got the laptop.

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 2,535
    • View Profile
    • Donate to Member
Another rigorous option could be to pull out the keyboard, grab a soldering iron and some wire, and re-wire the Scroll-Lock key to be connected parallel to the Fn key (and no longer be the Scroll-lock key). Then pop the keyboard back in. Voila 8).

mouser

  • First Author
  • Administrator
  • Joined in 2005
  • *****
  • Posts: 34,977
    • View Profile
    • Mouser's Software Zone on DonationCoder.com
    • Donate to Member
Quote
I'd like to be able to choose an otherwise unused key, like scroll lock, to act as a modal switch to turn on the alternate meanings for the cursor. It seems like AHK could allow me to do this, but I'm not sure exactly how to accomplish this.


Your request seems reasonable and indeed a clever idea, and ahk should be able to handle this easily I think.

Ath: There is no need to manipulate the fn key, the idea would be to simply check the ScrollLock state and trigger the alternative keys if it is engaged.  The only tricky part is preventing the original keypress from going through.
« Last Edit: June 15, 2011, 10:43:05 AM by mouser »

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,393
    • View Profile
    • Donate to Member
I can do this.  Please provide me a list of which new keystroke you would like to assign to each arrow key when the ScrollLock is engaged.  Thanks.

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,393
    • View Profile
    • Donate to Member
If you're able to write some AHK yourself, here's the basic idea.  The following code will turn the Up arrow into an Insert key if the ScrollLock key is toggled on:

Code: Autohotkey
  1. Up::
  2. {
  3.     If GetKeyState( "ScrollLock", "T" )
  4.     {
  5.         SendInput, {Insert}
  6.     }
  7.     Else
  8.     {
  9.         SendInput, {Up}
  10.     }
  11. }
  12. Return
  13.  



brotman

  • Charter Member
  • Joined in 2005
  • ***
  • Posts: 51
  • Chuck
    • View Profile
    • Donate to Member
Skwire:
 :Thmbsup:
That's the ticket!!!  I don't, necessarily want a way to press the "Fn" Key.  I just want to make the arrow keys act AS THOUGH I had pressed it!!!   I can and will try this myself,  as soon as I can figure out what is required on this very nice but peculiar laptop's keyboard to get Scroll lock activated (ie do I need to press the Fn key to do that?)! thank you for your Offer though,  I'll let you know what key I choose, in case it might be usefull for someone else with this Silly Sony Setup! Your tip definitely got me looking in the right direction --- Thanks!!!

Others,
 :)
Thanks for all your Ideas.
  - I had considered hooking up another keyboard, but didn't think of it until after my first post. Problem there is that it makes things much less portable.  Worth A try though, pending an AHK solution.
 - I have to admit rewiring the keys had not occurred to me,  I guess I was thinking more of a software solution.  Good idea, but not one I'm likely to try, plus I was looking for a togle action not a modifier key type action.
  
Thanks all for your time and consideration,
Chuck
PS. Ironically named key, don't you think?  "Fn" as in "how can I reach that "effin" key?!" !!!!!!    :D
Chuck Brotman
« Last Edit: June 15, 2011, 01:39:42 PM by brotman »

ewemoa

  • Honorary Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 2,704
    • View Profile
    • Donate to Member
PS. Ironically named key, don't you think?  "Fn" as in "how can I reach that "effin" key?!" !!!!!!    :D
Ha ha ha ha ha  ;D

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,393
    • View Profile
    • Donate to Member
as soon as I can figure out what is required on this very nice but peculiar laptop's keyboard to get Scroll lock activated

If that proves to be an unusable option, we can easily dedicate another key to act as the toggle.  Say, F12, for instance or possibly one of the custom keys on your laptop (if it has any).

ewemoa

  • Honorary Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 2,704
    • View Profile
    • Donate to Member
I hope a digression regarding F12 will be tolerated :)

I've been curious about F12, especially what's mentioned at:

  http://msdn.microsoft.com/en-us/library/ms646309%28v=vs.85%29.aspx

Quote
The F12 key is reserved for use by the debugger at all times, so it should not be registered as a hot key. Even when you are not debugging an application, F12 is reserved in case a kernel-mode debugger or a just-in-time debugger is resident.

Any reflections regarding this?

I've seen it used elsewhere (e.g. Irfanview)...

skwire

  • Global Moderator
  • Joined in 2005
  • *****
  • Posts: 4,393
    • View Profile
    • Donate to Member
I use it all the time for various things across several apps.  To me, it's just another function key. *shrug*

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 2,535
    • View Profile
    • Donate to Member
Even the official Microsoft Visual Studio uses F12 (by default) for another purpose: "Go To Definition", so I wouldn't worry too much about using it for your special hotkey, unless ofcourse it's used by an application you use a lot ;)

ewemoa

  • Honorary Member
  • Joined in 2008
  • **
  • default avatar
  • Posts: 2,704
    • View Profile
    • Donate to Member
Thank you both for the feedback :)

I was intrigued that the AutoIt3 docs for HotKeySet list F12 under "The following hotkeys cannot be set":

  http://www.autoitscript.com/autoit3/docs/functions/HotKeySet.htm

My opinion on this so far has been that it makes sense to be able to configure things to make it possible to use F12, but that I'd tend to shy away from making something F12 by default.

Really, I wish there were some comprehensive and consistent guidelines for this sort of thing :(

Ath

  • Supporting Member
  • Joined in 2006
  • **
  • Posts: 2,535
    • View Profile
    • Donate to Member
Really, I wish there were some comprehensive and consistent guidelines for this sort of thing :(
There are a lot of guidelines, it's just quite hard to get hold of all of them. If you only follow guidelines you most likely will get stuck in good intentions :(, so if you need a particular feature (or hotkey) then use it unless you can't or it breaks something else :tellme: