1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

Insert/Overwrite

Discussion in 'Support' started by cjewison, Apr 5, 2011.

  1. cjewison

    Joined:
    Apr 5, 2011
    Messages:
    2
    Likes Received:
    0
    Is there any way of force TC to start in "Insert" Mode

    As I am a Mac user, and Use TC through a Virtual machine my mac has no Insert Key
    This hasn't been a problem in the past but suddenly in Version 12.10 it seems to have appeared.

    If I start the command shell of Windows no problem Insert mode is on by default but not in TC
     
  2. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,277
    Likes Received:
    38
    Type OPTION and press Enter. Select the third tab ("Command Line"); edit mode is the box in the upper right.

    If you change the default edit mode, you may also want to exchange the cursor sizes.
     
  3. LuP

    LuP

    Joined:
    Oct 4, 2011
    Messages:
    18
    Likes Received:
    0
    Is there a way to force TCC to start in "Insert" mode, too?

    E.g. - what to write to .ini?
     
  4. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,788
    Likes Received:
    29
    On Tue, 04 Oct 2011 16:50:18 -0400, LuP <> wrote:

    |Is there a way to force TCC to start in "Insert" mode, too?
    |
    |E.g. - what to write to .ini?

    OPTION\CommandLine\Editing\Insert (radio button)

    ... which should write "EditMode=Insert" to the INI file.
     
  5. Jay Sage

    Joined:
    Jun 2, 2008
    Messages:
    284
    Likes Received:
    1
    On 10/4/2011 4:50 PM, LuP wrote:

    From Take Command's "Options" menu, open "Configure TCC..." or from TCC
    run the "option" command. Select the "Command Line" tab. At the top
    right you'll see the setting you're looking for.

    -- Jay
     
  6. LuP

    LuP

    Joined:
    Oct 4, 2011
    Messages:
    18
    Likes Received:
    0
    OK, thanks.

    And does the TCC/LE use an .ini file, too?

    (I mistyped in my previous question - I meant TCC/LE, not TakeCommand[/LE])?

    If so, where is it located and what's its name? (I found only updater.ini in the TCC/LE installation directory.)

    LuP
     
  7. Steve Fabian

    Joined:
    May 20, 2008
    Messages:
    3,523
    Likes Received:
    4
    From: LuP
    | And does the TCC/LE use an .ini file, too?
    |
    | (I mistyped in my previous question - I meant TCC/LE, not
    | TakeCommand[/LE])?
    |
    | If so, where is it located and what's its name? (I found only
    | updater.ini in the TCC/LE installation directory.)

    Yes, it does. Once you start TCC/LE, the value of the _ininame variable is the fully qualified name of the .INI file it uses:

    echo %_ininame

    BTW, you can explicitly specify in the command line that start TCC/LE which file it is to use. See HELP topic TCC Startup Options.
    --
    HTH, Steve
     
  8. LuP

    LuP

    Joined:
    Oct 4, 2011
    Messages:
    18
    Likes Received:
    0
    Perfect, thank you.

    I also added some more key=value pairs to the TCC .ini file (via help):

    Code:
    CursorIns=10
    CursorOver=100
    
    - this looks more familiarly for those who comes from cmd.exe.

    I'd like to modify the prompt as well; I know this may be done via "prompt" command and thus via a startup file.

    Is it possible to specify the prompt also via a key/value pair in the .ini file?

    And - I'm just curious - what is the ".BMT" (TCC batch file) abbreviation of?

    Thanks again.

    LuP
     
  9. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,788
    Likes Received:
    29
    On Wed, 05 Oct 2011 16:06:10 -0400, LuP <> wrote:

    |I'd like to modify the prompt as well; I know this may be done via "prompt" command and thus via a startup file.

    No, but you can put it in the System or User environment
    (MyComputer\Properties\Advanced\EnvironmentVariables).
     
  10. Charles Dye

    Charles Dye Super Moderator
    Staff Member

    Joined:
    May 20, 2008
    Messages:
    3,277
    Likes Received:
    38
    BTM = "Batch To Memory", because the shell slurps the entire file into memory once, as opposed to doing an open-seek-read-close cycle every time it fetches a line.
     
  11. Steve Fabian

    Joined:
    May 20, 2008
    Messages:
    3,523
    Likes Received:
    4
    LuP:
    | I'd like to modify the prompt as well; I know this may be done via
    | "prompt" command and thus via a startup file.

    vefatica:
    | No, but you can put it in the System or User environment
    | (MyComputer\Properties\Advanced\EnvironmentVariabl es).

    But beware! I suspect if you do that the same prompt will be used by CMD, and if your prompt contains anything TCC-unique it will fail in CMD.

    LuP:
    | And - I'm just curious - what is the ".BMT" (TCC batch file) abbreviation of?

    The default extension for TCC batch files is .BTM (not what you typed - I don't want to duplicate it). According to my internet search, it is an acronym for "Batch To Memory" - an allusion to a basic difference between 4DOS.COM (and its successors, 4NT.EXE and TCC.EXE) and COMMAND.COM (and its successor, CMD.EXE): 4DOS reads the whole batch file into memory at once before execution, COMMAND.COM reads and executes one line at a time.
    --
    Steve
     
  12. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,788
    Likes Received:
    29
    On Wed, 05 Oct 2011 17:15:16 -0400, Charles Dye <> wrote:

    |---Quote (Originally by LuP)---
    |And - I'm just curious - what is the ".BMT" (TCC batch file) abbreviation of?
    |---End Quote---
    |BTM = "Batch To Memory", because the shell slurps the entire file into memory once, as opposed to doing an open-seek-read-close cycle every time it fetches a line.

    This has advantages in addition to speed. You can edit/save a BTM file while
    it's running. And you can create BTM files which modify and restart themselves.
     
  13. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,788
    Likes Received:
    29
    On Wed, 05 Oct 2011 17:30:26 -0400, Steve Fabian <> wrote:

    |vefatica:
    || No, but you can put it in the System or User environment
    || (MyComputer\Properties\Advanced\EnvironmentVariabl es).
    |
    |But beware! I suspect if you do that the same prompt will be used by CMD, and if your prompt contains anything TCC-unique it will fail in CMD.

    Steve's right. And that's how it was for me for quite a while. But I used CMD
    so seldom it dodn't bother me much. Now I have a PROMPT command in CMD's
    autorun file.

    Has it ever been suggested that there be "Prompt=" and "TitlePrompt=" INI
    directives (OPTION)? They could be overridden by environment variables of the
    same names for compatibility and special uses.
     
  14. samintz

    samintz Scott Mintz

    Joined:
    May 20, 2008
    Messages:
    1,178
    Likes Received:
    11
    Even still, when you launch CMD from a
    TCC window, CMD inherits TCC's environment. So invariably, I have
    to type PROMPT to restore the default prompt in CMD.

    My TCC prompt is:
    PROMPT=^e[37;@if[%@remote[%_disk] eq 0,42,41];1m[$P]$s

    Which is pretty cool in TCC but a bunch
    of gibberish in CMD.

    -Scott




    On Wed, 05 Oct 2011 17:30:26 -0400, Steve
    Fabian <> wrote:

    |vefatica:
    || No, but you can put it in the System or User environment
    || (MyComputer\Properties\Advanced\EnvironmentVariabl es).
    |
    |But beware! I suspect if you do that the same prompt will be used by CMD,
    and if your prompt contains anything TCC-unique it will fail in CMD.

    Steve's right. And that's how it was for me for quite a while. But I used
    CMD
    so seldom it dodn't bother me much. Now I have a PROMPT command in CMD's
    autorun file.

    Has it ever been suggested that there be "Prompt=" and "TitlePrompt="
    INI
    directives (OPTION)? They could be overridden by environment variables
    of the
    same names for compatibility and special uses.
     
  15. vefatica

    Joined:
    May 20, 2008
    Messages:
    7,788
    Likes Received:
    29
    On Wed, 05 Oct 2011 20:15:34 -0400, samintz <> wrote:

    |Even still, when you launch CMD from a
    |TCC window, CMD inherits TCC's environment. So invariably, I have
    |to type PROMPT to restore the default prompt in CMD.

    Not so. If CMD's autorun file (HKEY_CURRENT_USER\Software\Microsoft\Command
    Processor\AutoRun) does a "SET PROMPT=...", the user doesn't have to do it and
    it's not propagated back to a parent TCC.

    |My TCC prompt is:
    |PROMPT=^e[37;@if[%@remote[%_disk] eq 0,42,41];1m[$P]$s
    |
    |Which is pretty cool in TCC but a bunch
    |of gibberish in CMD.

    I had forgotten ... a while back there was a discussion here about ANSICON. I
    DL'd the source, simplified and modified it a bit, and built a DLL that could be
    injected into CMD. My CMD autorun file is z:\windows\system32\cmdstart.bat (TCC
    doesn't run it, an INI option) and it now contains (instead of a SET PROMPT
    command)

    Code:
    d:\uty\injectdll.exe G:\Projects\ansi32dll\release\ANSI32.dll
    This allows CMD to use my preferred prompt, which is

    Code:
    $e[32;1m$p$g$s$e[0m
    It wouldn't like yours, though, with the @REMOTE variable function in it.
     
  16. ClintJCL

    Joined:
    Jun 21, 2011
    Messages:
    12
    Likes Received:
    0
    I put CPU usage into my prompt :)
     

Share This Page