No announcement yet.

Forcing caps lock

  • Filter
  • Time
  • Show
Clear All
new posts

  • Mike Luther
    Amos ..

    You are very gracious to even think about it. Yes, I know it is
    a large task and as well, it might not, as you say, work. It was
    just a thought ..

    Mike Luther
    [email protected]

    Leave a comment:

  • Amos Vryhof
    Guest replied
    First, the eInput function is just a unit that gets linked into
    a PB/DOS 3.5 program, and replaces the standard Input function.

    If a user shells out and runs an external program, these mappings
    and capabilities are not applied.

    Doing what you spreak of is much easier in DOS than it would be
    in Windows. Primarily because a DOS program can directly access
    the hardware much easier than a Windows program (unless the
    DOSZilla project got continued...Netscape is not a DOS program).

    With DOS applications, most of what you speak of can be done with
    a TSR similar to ANSI.SYS. I remember pulling all of the keys
    off a keyboard, replacing them in a dvorak layout, and remapping
    the keys with ANSI.SYS and a batch file just to see if it could
    be done. In some of my older versions of the eInput function
    (not so modular) I tried to do keymapping, but was not patient
    enough to make it read external map files.

    I guess what I am saying is... It's a large task, and would take
    a lot of time. If anyone wants to take it on, I will offer any
    help I can. Even while writing this post, I am contemplating
    ways to do keymap files.

    BTW: MS-DOS Edit supports a great deal of WordStar mappings.


    Leave a comment:

  • Mike Luther
    Alan ..

    After years of addressing this issue for other reasons, experience
    says Tom is right on the money. The use of global techniques for
    handling the conversion ot upper case is far safer. That said,
    we really should think about what Amos is saying.

    Amos, is there any way you are considering or might consider the
    workup of a global keyboard key, assignment utility? The reason I
    ask is that for certain programs that have been created more
    recently, little is either known or favored by their authors
    as to keeping the old first CP/M, then WordStar <Cntrl key>
    macro operations enabled. There are many of us, not just the
    older folks, at least computer-wise, that have long ago found
    that the sometimes hated W/S keyboard operations are still *FAR*
    faster at text I/O than any other keyboard template.

    Most of the time, really, there are very few, if any conflicts
    that will be important, between what the modern programs use for
    intelligent keyboard program-function shortcuts, and what could
    be very simply enabled as *ADDITIONAL* ways to do what they are
    now using.

    For example, cursor-right is obviously equal to right-arrow in
    most any program today! But! It's also, for the really touch-
    typing folks - <CTRL +F> key in a ton of old programs, including
    a better implementation of it in the PowerBASIC for DOS IDE, in
    a few ways! Now, right-arrow also works in the PB 3.5 IDE, as
    well as in WordStar way back when John Barnaby wrote it! Actually
    he EXPANDED the CP/M concept, providing the love-it and hate-it
    double string-together <CTRL +> combos that are the REAL power
    of the technique. For those who don't use it or know it, here,
    as example, <CTRL>, followed by a <Q> and then a <C> moves you
    to the top of the entire document.

    What would *REALLY* help the community, is a utility that could
    be used as a master keyboard re-mapper that could be called just
    prior to the use of, say Netscape. It would, until reset, map
    the <CTRL + Q + R>, as a combo .. to what the <HOME> key does!
    In that way .. for example, as I type this, and Netscape plus
    whatever is allowing me to compose this, wouldn't know that I
    hit <CTRL + A> at all! It would *THINK* that I told it word-left,
    even though all that happened was the LOCAL keyboard had been
    re-mapped to do that!

    When, for example, I get finished with Netscape and this message,
    and I wished to reset the keyboard to the native state, you would
    just run the same template program over with a different command
    line switch <R> or /R, perhaps. Presto .. the keyboard is back
    to the original state....

    It is terribly frustrating to want to <SAVE> something and be
    totally oriented to <CTRL + K + D> to do that .. and/or enter
    things you use all day long in, say Post Road Mailer, and have
    that same thing do nothing .. or .. in some cases something
    you don't want it to do at all!

    It would cut my response time and I/O time with the PowerBASIC
    forum here by a good 30% of my time. That's how much better
    the technique is for pure text I/O. And that is *NOT* to say
    the the mouse or other macro I/O techniques aren't important,
    either! They are very much better for some things!

    What we need is a way to confuse an application to think it is
    being used for I/O as intended! It isn't necesarry to fight
    over this at all, if wee could just re-map on command externally.

    If, as you journey down this road, you want to contemplate a
    trip that really would help us all, in my humble opinion, and
    don't have the all WordStar complement of that these control
    strokes do, or it is wanted here on the forum as well, I'll be
    happy to post the key and major set of them.

    Yes, I know W/S was a copyrighted program. However, I also know
    that QB4, MicroSoft's PD7, Qedit, Sem-ware, Sem-Ware Pro, the
    public Domain Word Star for OS/2!, and even PB 3.5 all use this
    technique and the time for protection for it is gone anyway.
    Thus the offer is made. As you go forward with your I/O template,
    you might do an awful lot of good.

    In case anyone thinks that big business doesn't care, after a
    flame-war started over this in the OS/2 applications forum in
    trying to get IBM to incorporate it in NS 4.6 - forward, they
    spoke firmly to the critics that were saying, 'Obsolete!'

    It was Scott Garfinkle who shut up the thread, "IBM cares very
    much about pure keyboard control without a mouse for systems.
    When was the last time you saw an airline reservations counter
    clerk with one?"

    Mike Luther
    [email protected]

    Leave a comment:

  • Amos Vryhof
    Guest replied
    My console program sCon ( has a
    custom input routine that allows you to do a number of things.

    You could download it, and integrate it into your program. With
    some flags, it makes it possible to disable keys altogether.

    I will extract it from sCon and put it together as a unit, or
    something. I think its one of the most powerful Input
    replacements for PowerBASIC. In the extraction I will keep the
    scrollback buffer capabilities, and all enhancements I made.

    Look for it in the future...unless you want to extract it yourself.


    Leave a comment:

  • Tom Hanlin
    It's possible to enter lowercase characters even with Caps Lock on.
    I'd suggest sticking with UCASE$ for this reason. You might find it
    useful to create a specialized input function to avoid redundant
    UCASE$ calls.

    Tom Hanlin
    PowerBASIC Staff

    Leave a comment:

  • Dave Stanton
    I use
         SUB Setcapslock
             Setkeycontrol 64
         END SUB
         SUB Setnumlock
             Setkeycontrol 32
         END SUB
         SUB Setkeycontrol(Q?)
             DIM Keycontrol AS LOCAL BYTE PTR
             @[email protected] OR Q?
         END SUB


    Leave a comment:

  • Gary Stout
    I use the following...

    DEF SEG = 0
    POKE &H417,PEEK(&H417) OR &H60 'this does caplock and numlock

    POKE &H417,PEEK(&H417) OR &H40 'this does only caplock

    DEF SEG = 0
    POKE &H417,PEEK(&H417) OR &H00 'this shuts both off

    Hope this helps,
    Gary Stout


    Leave a comment:

  • Alan Hanson
    Guest started a topic Forcing caps lock

    Forcing caps lock

    I have a program that requires a lot of data entry.
    At the moment I am using UCASE$ all over the place.
    It would be easier if I could just lock the caps lock on.