Slashdot Mirror


What's A 'Scroll Lock' And Why Is It On My Keyboard?

Jeff Bauer writes "Today's article in The Straight Dope explains all the weird keys that come with standard PC keyboards. Now if someone could just explain what the 'Alt Graph' key does on my Sun keyboard, enlightement would be at hand ..."

65 of 866 comments (clear)

  1. Scroll lock is useful in Linux terminals by gotr00t · · Score: 5, Informative
    When using a TTY terminal in Linux, the scroll lock is an extremely useful key so that you can pause the output in order to read it. In most BIOS's, you can also press it to pause the info that it is giving you as well.

    Many people think that scroll lock is now useless, except in Microsoft Excel, but it does have a much more useful purpose, at least in Linux and perhaps BSD.

    1. Re:Scroll lock is useful in Linux terminals by voisine · · Score: 2, Informative

      In BSD, using the arrow keys with scroll lock on is the equivilant of shift+PgUp,PgDn in Linux.

    2. Re:Scroll lock is useful in Linux terminals by drinkypoo · · Score: 3, Informative
      I have news for you, and its name is ^S and ^Q! Sing it loudly from the mountaintops!

      P.S. this works places other than Unix also.

      --
      "You're right," Fisheye says. "I should have set it on 'whip' or 'chop.'"
    3. Re:Scroll lock is useful in Linux terminals by Ded+Bob · · Score: 2, Informative

      From syscons(4) in FreeBSD:

      Back Scrolling
      The syscons driver allows the user to browse the output which has
      ``scrolled off'' the top of the screen.

      Press the ``slock'' key (usually ScrllLock / Scroll Lock or Pause on many
      keyboards) and the terminal is in the ``scrollback'' mode. It is indi-
      cated by the Scroll Lock LED. Use the arrow keys, the Page Up/Down keys
      and the Home/End keys to scroll buffered terminal output. Press the
      ``slock'' key again to get back to the normal terminal mode.

      The size of the scrollback buffer can be set by the SC_HISTORY_SIZE
      option described below.

    4. Re:Scroll lock is useful in Linux terminals by evilviper · · Score: 2, Informative
      In BSD

      NO! Not in "BSD", ONLY in FreeBSD... FreeBSD is not the end-all, be-all BSD, thank you very much.
      --
      Slashdot gets worse every day... Pipedot: News for nerds, without the corporate slant
  2. Fark by Anonymous Coward · · Score: 1, Informative

    Yet another link that Fark ran first, and Slashdot copied...

  3. Alt Graph on Sun-boxen ... by Hektor_Troy · · Score: 5, Informative

    The Danish keymap is the same on all PC's (and Sun Boxen as well), and we need Alt Graph to access the following characters:
    \@${[]}|~?

    Not sure about the US keymap, but I sure as hell wouldn't want to go without Alt Graph.

    --
    We do not live in the 21st century. We live in the 20 second century.
    1. Re:Alt Graph on Sun-boxen ... by NaturePhotog · · Score: 4, Informative

      On keyboards in general, most keys generates two characters. This is fine for English, not using any letters besides A-Z or any accents as far as ASCII is concerned.

      However, for many European languages, there are additional characters, like a+ring (U+0035) in Swedish, and accented characters, like e+acute (U+00E9) in French. Since back in the days of XTs, there were only 83/84 keys to go around, they made some keys produce a third and sometimes fourth character. These were accessed by pressing Ctrl and Alt for the third char and Ctrl, Alt and Shift for the fourth char and then the key.

      At some point, it was (rightfully) decided this was unnecessarily clunky. Keyboard BIOSes/drivers were changed to support the Mac-style input of accent + character to generate that character accented. That still left the 'standard' for older keyboards to be backward compatible with, and other chars that didn't fit that pattern.

      So when the 101/102 key keyboards came out, for European languages that changed the right Alt key to Alt Gr, or alternate graphic. (For some languages it had a different abbreviation, like Alt Car). This allowed typing Alt Gr plus one of the 3- or 4-character keys to access the 3rd (and with Shift, the 4th) character. Still a pain, but less so than a 3 or 4 finger salute to get a single character.

  4. The ` key by vanza · · Score: 2, Informative

    You know, it's not just a LISP or Python operator... some of us use it to write in our languages. Tres frequemment, sometimes. (I'm not French, but, similarly to French, my native language uses the grave accent - just not as often.)

    --
    Marcelo Vanzin
  5. Use for the tilde key by uvsc_wolverine · · Score: 3, Informative

    The tilde still has some limited use in C++ (don't know about other C-based programming languages since I don't know any of the others...yet). It's how you indicate to the compiler that this is the destructor function for programmer-defined class. That way the instructions in the destructor are automatically executed when an object of the class goes out of scope (usually used for returning dynamically allocated memory). Example: MyClass(); //CONstructor ~MyClass(); //DEstructor

    --
    This space for rent...
    1. Re:Use for the tilde key by larry+bagina · · Score: 2, Informative
      ~ is also used in C for binary negation.

      0xbeefbabe & (~0x04) == 0xbeefbabe & 0xfffffff8

      --
      Do you even lift?

      These aren't the 'roids you're looking for.

    2. Re:Use for the tilde key by proj_2501 · · Score: 2, Informative

      it's also the bitwise-NOT operator.

      say char boing = 0x55; // 01010101
      char gniob = ~boing; // 10101010

  6. Re:real application! by dark-br · · Score: 2, Informative

    It's always hard to sort through 22,000 lesbian porn pics.

    Try "| sort | more" instead :)

  7. Re:Windows Key by Anonymous Coward · · Score: 1, Informative

    Ditto. Fuck IBM. Whenever you finally learned:
    Win+F - Search files
    Win+E - File manager
    Win+M - Minimize pr0n, the boss is around

    the corp. buys me that Thinkpad that doesn't have it.

  8. Re:Losing the Insert key by EvanED · · Score: 2, Informative

    And ~ is essential in many URLs.

  9. Alt Graph.... by jdreed1024 · · Score: 3, Informative
    Alt Graph is a modifier key, like Shift, Control, Meta, etc. It existed on the PC platform too. If you look at non-US keyboard maps in the old IBM DOS manuals (like version 3.30), you'll see the that one of the "Alt" keys was labelled "AltGr" (guess what the "Gr" is an abbreviation for). You had to use the AltGr key to get things like accents and stuff if you used a non-US code page in DOS.

    ISTR that AltGraph+Help did something on older Sun machines, but I can't recall what.

    --
    There is no sig, there is only Zuul.
  10. Re:real application! by realdpk · · Score: 2, Informative

    # mkfifo booda
    # cat text > booda

    in another window:

    # cat booda > somefile

    voila

  11. Re:Wrong! by Trogre · · Score: 4, Informative

    For example, una says the Macintosh extended keyboards have a scroll lock key. It does not.

    Yes it does. It shares the same keycap as F14.

    --
    "Nine times out of ten, starting a fire is not the best way to solve the problem." - my wife
  12. Re:real application! by shird · · Score: 5, Informative

    'clip' is not a program which comes default installed with WinXP. Try it and see.

    You must have it installed from somewhere else, or as part of the admin pack or whatever. Its obvioulsy just a program which puts the stdin input into the clipboard, pretty useful, but not included by default.

    --
    I.O.U One Sig.
  13. Re:real application! by WatertonMan · · Score: 4, Informative

    In OSX it is ls | pbcopy

  14. ADB Apple Extended Keyboard II by Anonymous Coward · · Score: 1, Informative

    I have one of these laying around. Those three keys are labelled F13-F15, but in smaller letters say "print screen" "scroll lock" and "pause" respectively

    Now, it might be that some of the newer mac keyboards don't have scroll lock, but the original ADB extended keyboards did. For example, I have a USB spanish mac keyboard that doesn't have those extra labels.

  15. Re:real application! by Anonymous Coward · · Score: 1, Informative

    in X xsel, its not part of X, but clip is not part of default win install either

  16. Re:real application! by Anonymous Coward · · Score: 1, Informative
    the windows example was piping output from a command line application into the system clipboard (as in copy/paste). Your example is quite different.

  17. Re:real application! by rwuest · · Score: 5, Informative

    get xclip http://people.debian.org/~kims/xclip/, install, then

    $ ls | xclip -i

    does what you'd expect.

  18. Re:MS Office scroll lock peeve by Malc · · Score: 2, Informative

    Use Ctrl+Arrow keys to scroll in this situation. The insertion point will probably be moved to the edge of the visible area.

  19. Xon/Xoff history lesson: blame microsoft by goombah99 · · Score: 5, Informative
    Since everyone hear has totally missed the boat I'll chime in. The concept of a Scoll lock is indeed alive and well today. Try the following on your Unix computer: run some command that spews text to the screen in a terminal window (e.g. fs_usage or du /) now while its scrolling type control-S. it scroll locks. Now type control-Q to resume the text output.

    this dates back to the teletype and is enshrined in the ascii alphabet as Xon and Xoff. Originally it was intended not as a scroll lock but as a way for a teletype or printer to not overflow its fixed hardware buffer. The communication baud rate could easily out pace the tele type printers print speed. when the hardware buffer was nearly full it would send an X-off (contol-s) to the sender to pause its communications. When the buffer was printed the teletype would send a X-on back to the sender to resume spewing.

    There was no need for scoll locking functionality on a teletype printer since you could just hold up the paper and look at it back as many lines as you wanted.

    but when dumb video terminals came along the terminals could print as fast as the data came in the X-on and X-off functions had little use as a communications protocol, but Now they were useful to humans as a scroll lock. they had at most 40 lines of text and once you scrolled off the top of the screen, you lost that line forever. There were no "windows" or "scroll bars". So you had your fingers poised over the contrl-s key to halt the text from flowing off the screen.

    finally along came the PC and Microsoft messed with all the unix converions in their VMS/CPM ripoff called dos: so you could not be sure that control-S would actually work. In part this was because DOS was not really multitasking. programs could take over the OS and capture all the interupts and put hooks directly into the keyboard handler. Since there were no Menus and the "alt" key had not come into its standard defintion yet, the control keys were premium realestate for programs to hook functions into.

    thus there was a need for another semaphore. So things like scroll lock and sysRequest, and print screen got added. So yes virgina you can blame MS for these keys as valuable male breasts or an appendix.

    --
    Some drink at the fountain of knowledge. Others just gargle.
  20. Re:real application! by SEE · · Score: 5, Informative

    Correct. clip isn't built in.

    Clip is one of the utilities from http://www.cmdtools.com/ .

  21. Yes: Screen by marnanel · · Score: 4, Informative

    Well, the clipboard is a property of the environment, rather than the OS. But there's certainly at least one environment that allows this: GNU screen.

    Screen has a concept of a buffer file that can be used to store or load the clipboard. The name of this file is defined in your screenrc, so it can vary from system to system, but it's often called /tmp/screen-xchg or (better for multi-user systems) ~/.screen_exchange. The keystroke ^A< reads this file and ^A> writes it; ^A> will also flash up a message telling you what the name of the file is (for example, Copybuffer written to "/tmp/screen-xchg" ).

    So what you do is:

    $ some-command > ~/.screen_exchange
    ^A< (copybuf)
    screen responds "Slurped 2323 characters into buffer"
    ^A] (paste)

    And there you have it.

    --
    GROGGS: alive and well and living in
  22. Re:Here's an idea by akedia · · Score: 2, Informative

    In every version of Windows since 3.1 pressing Print Screen will copy a screenshot of the entire screen to the clipboard. Pressing Alt + Print Screen will copy an image of the current active window.

  23. Fan of Michael Moorcock I presume? by quinkin · · Score: 3, Informative
    Una Persson??

    Well call me Catherine Cornelius and break out the psychotropic lesbian porn fiction...

    Well it is true to the spirit of Moorcock. Just look at the cover art.

    Ok, so it is a touch off-topic, but I was stunned to see a literary(sic) reference in a /. link

    Q.

    --
    Insert Signature Here
  24. Re:What's the deal with the really weird key? by anichan · · Score: 2, Informative

    Not really. The idea, I expect, is that the key is there to allow someone to not have to use a mouse at all, for certain things. ie: Move through a list of files in a directory, hit this key, select open with, or whatever.

    It's useful if you are typing, with your hand away from the mouse, and want to do a right click on th highlighted item.

    Really...

    --

    karma is for the weak >)

  25. Also for execute by brunes69 · · Score: 2, Informative

    Enclosing statements in backticks causes the string to be executed at the shell level and the resulsts stored ina string. You can do this in bash, Perl, PHP, and a myrid of other lanuages. eg type "echo `ls`" at the prompt. Then again I am sure most everyone knew this already

  26. Re:Mad Props by rudedog · · Score: 4, Informative

    If I recall correctly, back in the days of openlook, the props key was used to bring up the properties menu for a window. That's as much as I can remember.

  27. Re:real application! - clip tool by ningcat · · Score: 2, Informative

    The "| clip" thing is not a WinXP thing. It's a 32-bit command line tool created by Dave Navarro.

    cmdtools website "clip" is near the bottom of the page

    clip.zip direct download

  28. Re:real application! by rolocroz · · Score: 3, Informative

    And, as you might expect, pbpaste lets you access what's currently on the clipboard.

    --

    I meta-mod all positive moderation Unfair, because it's abuse of the system.

  29. Yes, and here it is. by devphil · · Score: 2, Informative


    In theory, after running "apt-get install xclip" you can do things like

    producer | xclip -i

    and the primary X selection will be loaded up with the output, all reading for middle-clicking. Likewise, you can sweep a bunch of text and use it with

    consumer `xclip -o`

    Other options let you use other clipboards, etc.

    In practice, you can't just apt-get it. You have to apt-get the source, apply the content negotiation patch, and run buildpackage yourself. Then it works perfectly. (I have no clue what content negotiation means, but apparently kde wants it.)

    --
    You cannot apply a technological solution to a sociological problem. (Edwards' Law)
  30. SysReq by dlb · · Score: 2, Informative

    The SysReq (or "System Request") key is still heavily used in the as/400 world for job management on the system console. Using the SysReq key, you can send different signals to whatever current job was running

    Think of it as a key dedicated to the unix 'kill' command.

    ~dlb

    1. Re:SysReq by bccomm · · Score: 3, Informative

      Not to mention the SysRq key still in use on Linux for debugging---if you enable CONFIG_MAGIC_SYSRQ (Linux 2.4) or CONFIG_SYSRQ (Linux 2.6).

      I really doubt that ``it's days are numbered.''

  31. Magic SysRq by indianseason · · Score: 2, Informative

    I didn't see anyone comment on this, but the SysRq hooks to the Linux kernel. It allows the user to send commands to the kernel like sync, reboot, etc.

  32. Re:Wrong! by silvaran · · Score: 4, Informative

    It was used to lock the cursor in place, and the up and down arrow keys scrolled the entire screen, leaving the cursor locked.

    I'm not entirely certain what article you thought you read, but according to Una:

    The main intent of the Scroll Lock key was to allow scrolling of screen text up, down and presumably sideways using the arrow keys in the days before large displays and graphical scroll bars.

    According to you, it sounds like Una got it right at the start.

    RTFA

  33. Just a thought but... by pr0ntab · · Score: 3, Informative

    I imagine open files are tied to the "true" paths:
    multi(0)disk(0)rdisk(0)partition(1)/window s/system 32/ntoskrnl.exe
    etc, etc, etc...

    The C: drive thingies are just useful for the Win32API, so opening new files off that drive won't work, and explorer will probably fail in mysterious ways later on, if the C: is mentioned anywhere in the registry where it might be used to dynamically load some view or file operation.

    As you might expect, drives letters are just places where to start a mapping to a mounted filesystem (which is internally identified with a GUID, like everything else, the drive letter has no significance). Windows only needs C: to boot and load programs, but if you aren't opening files, you don't need it.

    --
    Fuck Beta. Fuck Dice
    1. Re:Just a thought but... by klep · · Score: 1, Informative

      windows will remount the drive automatically, whenever there is an access on it. Volumes and file systems are very much the same, unlike in unix environments.

      Unmounting forces a flush, so it can have a purpose though. Heck, even trying to lock a volume / file system will flush it for you. How's that for a sync :)

  34. Re:real application! by revmoo · · Score: 2, Informative
    Also, in WinXP or higher, you can pipe text into the copy buffer. I use this all the time.
    type reallybigfile.txt | clip


    Microsoft Windows XP [Version 5.1.2600] (C) Copyright 1985-2001 Microsoft Corp. C:\Documents and Settings\revmoo>echo moo | clip

    'clip' is not recognized as an internal or external command, operable program or batch file.
    Care to elaborate?
    --
    I would expect such blatant racism on Fark, but on Slashdot? Mods please ban this asshole.
  35. Sun Keyboards by acvolt · · Score: 2, Informative

    Can anybody please tell me that the "blank" key next to the help button on a Sun keyboard is used for?

  36. Re:real application! by FireBreathingDog · · Score: 2, Informative
    Mac OS X can do this via pbcopy and pbpaste, the pb standing for the NeXT-ism "pasteboard," or what Mac users normally call the clipboard.

    For example, is you issue the command:

    cat somefile | pbcopy

    the clipboard receives the contents of somefile, whereas if you type:

    pbpaste > somefile

    puts the contents of the clipboard into the file somefile.

  37. Re:More interesting question migth be... by pVoid · · Score: 2, Informative
    Actually, check this cool hack out.

    Mind you, this is not a registry thing because you actually need code to run it. With this, caps lock will go uppercase, and CTRL will release the lock.

  38. Re:An old one by Bios_Hakr · · Score: 2, Informative

    Wow, that looks exactly like a spellcheck function in PERL! :)

    --
    I'd rather you do it wrong, than for me to have to do it at all.
  39. Console Switch by Anonymous Coward · · Score: 1, Informative

    Obviously the scroll Lock key (next to the panic button key) is for console switching.

    On Belkin KVMs:
    [Scroll Lock]-[Scroll Lock]-UP

  40. (answered earlier in this thread) by pr0ntab · · Score: 2, Informative

    it's because Sun Type 6 keyboards are made for both Suns and Linux boxes they ship, and on Linux boxes it's the escape key. The just change the key covers.

    --
    Fuck Beta. Fuck Dice
  41. Re:Windows Key by capnjack41 · · Score: 2, Informative

    Here's a list...there are some other interesting ones on there too, like that weird Fn key on laptops.

  42. Alt-GR by terminal.dk · · Score: 2, Informative

    The "Alt Gr" key is used for us foreigners to reach seldomly used charatcers like @$ (Alt-Gr 2, 3 and 4 respectively), or {[]} (Alt-Gr 7890) or | (alt-GR `) or \ (alt-GR ). And more important, Alt-Gr e is the Euro character. You know, the european dollar, way stonger than the US dollar.

    On the other hand, we get often used charatcers like aeoa as primary keys, and have access "# with Shift + 2, 3 and 4.

    This is all based on a danish keyboard. Some people have grown beyond US-ASCII (7-bit crap)

  43. Re:Wrong! by sakusha · · Score: 1, Informative

    I read it, but that description was completely unclear. You can move text up, down, and sideways using the cursor too. Una never was a very clear writer, she's more interested in her lesbian porn than clarity. She focuses on minutiae like her incorrect assertion that ScrlLk was intended for pausing, and ignores its original design function. I repeat: The ScrlLk key is a vestige of IBM WPS, it should really be called Cursor Lock because it locks the cursor, not scrolling.

  44. wmaker: wxcopy, wxpaste by nutsy · · Score: 2, Informative

    In Window Maker, 'wxcopy --help' and 'wxpaste --help' for help on using those.

    I'm afraid I don't know about the others. Anyone? Anyone?

  45. Re:Windows Key by irc.goatse.cx+troll · · Score: 2, Informative

    " This is one of my major "wow that is a PITA" points about Linux.

    WHERE ARE MY HOTKEYS???"

    Wherever you set them.
    I have alt+c close current window, alt+k,c to sigkill it, alt+mwheeldown/up to cycle through tabs in my current pane (I use ion. I'll provide screenshots if someone asks). Then theres the GNU ReadLine shorcuts that a lot of apps respect(most because they actually use ReadLine, then the rest just because theyre standard.

    ^A - begining of line
    ^E - end of line
    ^K - delete text from cursor to end of line
    ^U - delete text from cursor to begining of line
    ^V - insert raw char regardless of other bindings

    Theres plenty more, see man ReadLine. They're all configurable of course.

    --
    Pain lasts, kid. Its how you know you're alive. Sometimes I think this growing up thing is just pain management-TheMaxx
  46. Re:Windows Key by redhog · · Score: 4, Informative

    All the mysterious keys are there for you to remap using xmodmap! And having a spare one left over is allways good if a key fails (as a result of piping tea through yourr keyboard). And of course, the windows-key is in the correct place of a meta key, so you could be a better emacs-user in just minutes! And when talking about SysReq, it really is a request to the system, if you gave Magique SysReq compiled in in your Linux-kernel - then press Alt-SysReq-key where key is b to reboot, s to sync disks and r to remount all disks read-only. And this works even if some user-space program fucks up your screen and keyboard...

    --
    --The knowledge that you are an idiot, is what distinguishes you from one.
  47. Missing some info by Jack+Schitt · · Score: 4, Informative

    The Scroll Lock was also used by a DOS TSR known as ANSI. When loaded, it allowed scrolling of the entire screen history when the Scroll Lock was on. When you dir a huge folder, you could hit scroll lock and use the arrow keys to navigate the entire list of files. More useful than dir /p...

    The Print Screen/SysRq key was used in Dos to send the current screen of text directly to lpt1: (your printer), hence the name "Print Screen". In Windows (all the way back to Windows 3.x), Print Screen executes a screen capture (without the mouse cursor) and puts it on the clipboard. Alt+PrintScreen copies just the current window.

    In addition to what was said in the article about Pause/Break, pressing it _during_ a dir or other scrolling text operation will halt the screen. (This includes during booting before the OS loads.) Press any key to continue.

    As for the `/~ key? Still haven't found a useful function for it other than typing a ` or a ~.

    And the |? That one serves just about the same purpose to me as the "Context Menu" button on many newer keyboards, which is to say, none.

    --
    This message brought to you by Jack Schitt's Previously Shat Shit
  48. Re:real application! by Phroggy · · Score: 2, Informative

    Ah... in NeXTStep it was called the Pasteboard?

    --
    $x='S24;r)>63/* h@<5+oZ)32"5cz';$me='phroggy'x$];
    $x=~y+ -xz+\0-Tx+;print$_^chop$me for split'',$x;
  49. What's Alt Gr for? by jonbryce · · Score: 4, Informative

    For people who don't speak english, Alt Gr is pretty useful, as it lets you type accented characters. In EU countries, it is also used to let you type the Euro symbol - Alt-Gr+4 on UK and Irish Keyboards, Alt-Gr+E on most others.

  50. Re:real application! by Urkki · · Score: 2, Informative

    You apparently have never copy-pasted something very long from terminal window... Sure you can scroll, but it's still pita if it's even moderately long.

  51. Re:real application! by olderchurch · · Score: 3, Informative

    Try irfanview an excellent image viewer, with automatic resize and slideshow!

    --
    Disclaimer: This opinion was created without the use of any facts
  52. Re:Alt Graph on WinDOS by Anonymous Coward · · Score: 1, Informative

    I have noticed that ALT+0xxx give you the Windows character xxx, but alt+xxx gives you the approximate DOS character xxx. The box-drawing characters (e.g. used in WinDOS ports of NetHack) come out as +|-=_ or similar.

  53. Re:real application! by Jeremy+Erwin · · Score: 2, Informative

    Yes, there's a class named NSPasteboard in the AppKit. Unfortunately, apple has not seen fit to write a manpage for "pbcopy", so I'm not sure if there is a way to individually access the more specialized pasteboards--MacOSX has at least five of them.

  54. I use it for... by ganiman · · Score: 1, Informative

    I use the ScrLk key to make my Belkin KVM switch change displays. If I hit it twice (it beeps) then hit the up/down key, it goes to the next/previous display. And I can even hit a number rather than an arrow key and it goes straight to the terminal plugged into the number key I hit. And if I hit the space bar after it beeps I am presented with an OSD for the KVM switch.

    If I hit Ctrl then hit Esc (not to be confused with pressing them at the same time) on my Black Box KVM switch, I get an OSD that allows me to navigate to the terminal I want (very nice when you have 30 servers on KVMs).

    --
    geek n performer who performs morbid or disgusting acts, as biting off the head of a live chicken
  55. Re:real application! by NihilSmurf · · Score: 2, Informative

    Maybe CSHOW? It had a palette-rotation feature which was good for viewing fractals (they were all the rage back then).

  56. Scroll lock lives by An+Elephant · · Score: 2, Informative
    There is a Windows application that makes Scroll Lock perform its original function on most applications (not just Excel).

    It's here.

    (Plug alert: I work for Platonix; this is a toy).