Buttonbar

From TotalcmdWiki
Jump to: navigation, search


The Button bar

Bar1.png

The Button bar

With the button bar you can call menu commands, external programs and even other button bars. If you leave the mouse cursor on a button for a moment, a small window with a description will appear( if you haven't deactivated it in Help texts).

You can easily add buttons to the button bar using Drag&Drop (with pressed SHIFT key). By pressing the right mouse button, you can open a local menu, which allows to change or delete buttons. For further changes in the button bar you should use the Dialog box to change the whole button bar.

Dialogbox: Configuration - Change button bar

Buttonbar dialog.png

Hint: By dragging a file on the button bar with pressed SHIFT key you can easily add buttons to the button bar. By pressing the right mouse button on the button bar, you can open a local menu which allows to change or delete the button under the mouse cursor. The Change button dialog box has exactly the same structure as the lower part of the Change button bar dialog box.

Field Description
Button bar:
Behind this identifier the file name of the actual button bar is shown. Behind the file name, you can choose another button bar using the >> button. You cannot change the bar name if you are in a subbar. You can only change the name of the default bar (loaded at startup).

Below this identifier you can see the actual button bar in a raw form (only the icons). Hint: You can use SHIFT+arrow keys to move buttons or drag them around with your mouse!

Size:
Here you can choose a size for the buttons in the button bar. A size of 32 corresponds to the normal icon size.
Flat Icons
If checked the icons are shown without 3d effect
Small icons
If checked, the icons are shown in 16x16 size, otherwise they are resized to the given size.
Add
Adds a new entry in the button bar directly BEHIND the current position.
Delete
Deletes the currently selected icon.
Command:
There are many possible commands which can be placed in this field:
1. You may specify the program to be run, including its search path. You can also specify fixed parameters here.

Important: You must give the extensions .com and .bat, because by default Windows only finds .exe! With >> you can search for the desired program.

2. You can also place one of Total Commander's internal menu commands here. Just click on the button with the down arrow and choose a command.

In the 32-bit version, you can open a virtual folder with one of the following commands: cm_OpenDesktop, cm_OpenDrives, cm_OpenControls, cm_OpenFonts, cm_OpenNetwork, cm_OpenPrinters, cm_OpenRecycled

3. You can make a button to change directories, by specifying cd directory name as the command. You can even choose which files to show, e.g. using the command cd directory\*.txt
4. You can also open an ftp connection, using either cd ftp://ftp.meinserver.com

or: ftpopen session_name, where session_name is the name configured in the FTP connect dialog box.

5. With the command zipfromlist, you can create a zip file from a list of files. The command field must contain the zip file name, and the parameters field the name of the list file. The list file must contain a list of files to be packed, one file per line.
6. As a further possibility, you can insert a button to switch to another button bar. To do this, click on the button Add subbar >>. In the appearing dialog box you can choose an existing bar as a subbar or enter a name for a new bar. After this, another bar appears, which allows to change the subbar. You can make circular references (bar 1 calls bar 2 calls bar 3), but avoid to edit a bar for which you have already a window opened!

Note: If you want have another bar at this position, you must delete the file name of the old bar before pressing the Add subbar >> button.

7. appendtabs tabfile.tab appends the folder tabs stored in the file tabfile.tab to the current tab header
8. opentabs tabfile.tab same, but replaces the current tabs with these new tabs.
Parameter:
Here you can specify command line parameters. Fixed parameters must be specified directly after the file name, because otherwise, in a Drag&Drop, only the file name would be given to the program.

Special parameters:

?

?

as the first parameter causes a Dialog box to be displayed before starting the program, containing the following parameters. You can change the parameters before starting the program. You can even prevent the program's execution.
%P

%P

causes the source path to be inserted into the command line, including a backslash (\) at the end.
%N

%N

places the filename under the cursor into the command line.
%T

%T

inserts the current target path. Especially useful for packers.
%M

%M

places the current filename in the target directory into the command line.
%O

%O

places the current filename without extension into the command line.
%S

%S

places all selected filenames into the command line.
%E

%E

places the current extension (without leading period) into the command line.

Note: %N and %M insert the long name, while %n and %m insert the DOS alias name (8.3). %P and %T insert the long path name, and %p and %t the short path name. (Same for %o and %e)

%%

%%

inserts the percent-sign.

%L, %l, %F, %f, %D, %d create a list file in the TEMP directory with the names of the selected files and directories, and appends the name of the list file to the command line. The list is deleted automatically when the called program quits. 6 types of list files can be created:

%L

%L

Long file names including the complete path, e.g. c:\Program Files\Long name.exe
%l

%l

(lowercase L) Short file names including the complete path, e.g. C:\PROGRA~1\LONGNA~1.EXE
%F

%F

Long file names without path, e.g. Long name.exe
%f

%f

Short file names without path, e.g. LONGNA~1.EXE
%D

%D

Short file names including the complete path, but using the DOS character set for accents.
%d

%d

Short file names without path, but using the DOS character set for accents.
Run minimized:
Program will be started minimized (i.e. as an item in taskbar)
Run maximized:
Program will be started full screen (i.e. as a full screen window)
Start path:
Determines the path to be set before the program is started. If no path is given, then the path of the source window is set.

Important: If the command (given in the command box) is cd drive:\directory, then the path given in this edit box is set in the other window! This allows to set both paths (source and target) at the same time.

Icon file:
File which contains the icon for the button bar. For Windows programs, you can specify the name of the exe file itself. (e.g. notepad.exe). For internal commands, there are some icons available in wcmicons.dll. (By the way: Because of an internal Windows bug, you loose some bytes at every change of icon file. But after leaving Total Commander, these bytes are released. The same problem appears e.g. in program manager!)
Icon:
In this list, all icons contained in the specified icon file are shown. The number of the selected icon is shown in front of the list. Just click on an icon to select it for the button bar.
Tooltip:
Content of the small window which is shown when the mouse cursor is pointed on a button for more than one second.
OK
Saves the changes made to the specified icon file.
Cancel
Closes the dialog box without saving.
Help
Opens Windows Help with this page.

Other Button Bars

BAR2.png

Total Commander toolbar has a very good feature that lets you switch between bars so you can have multiple toolbars, for instance you can assign the most often used commands for the main bar and assign the less used commands to a subbar and assign folders link commands for another subbar and so on. For easily creating nested toolbar you can use the following program:

Nested Button Bar Creator 2.00

Download (48 KB)

NESTED.png

This porgram creates 2 to 9 Total Commander button bar files. Each bar contains the defined number of buttons that link to the other button bars. The button of the current bar is shown down and in red colour so you'll see easily which bar is currently active.

How to use:

The program will create button bar files in the following three steps:

   * Step 1: Specify how many button bar you need ( 2 to 20).
   * Step 2: Specify where the button bar files will be saved.
   * Step 3: In this step you can import an already button bar file and assign its content to the button number you select.

After pressing Create button, the button bar files will be created inside the folder you specified in step 2 and a message box will popup to tell you how to apply.

Important Notes:

  • It is recommended to save the program folder "Nested bar creator" inside your Total Commander installation directory, in this case the %Commander_Path% environment variable will be used when refering to number icons and bar files.
  • It is recommended to save the bar files inside the default folder. ("Nested bar creator\bars") or any other folder inside your Total Commander installation directory.
  • You can use another icons instead of icons come with the program, but you must use save your icons inside the default folder ("Nested bar creator\icons") also you must use the default icon file name ("Dn_x.ico", "Up_x.ico").

Back to Look and Feel