Customizing Toolbars


Customizing Toolbars

The most direct way to adapt AutoCAD to your way of working is to customize the toolbars. Auto- CAD offers new users an easy route to customization through the Customize dialog box. With the Customize dialog box, you can create new toolbars, customize tools, and even create new icons. You can also create keyboard shortcuts. In this section, you'll discover how easy it is to add menu and toolbar features to AutoCAD.

Getting Familiar with the Customize Dialog Box

Throughout this book, you've used the toolbar shortcut menu to open toolbars that are normally closed. You might have noticed the Customize option at the bottom of the toolbar shortcut menu. In the preceding chapter, you had a chance to use it briefly . This Customize option is the doorway to customizing toolbars.

Let's take a look at what it has to offer:

  1. Right-click the Draw toolbar and then choose Customize from the shortcut menu to open the Customize dialog box.

    click to expand
  2. Click the Toolbars tab. You see a Toolbars list to the left and a Menu Group list to the right. You'll learn about menu groups in the "Adding Your Own Pull-Down Menu" section later in this chapter.

  3. In the Toolbars list, click the Inquiry check box to display the Inquiry toolbar. (You might have to move the Customize dialog box to see the Inquiry toolbar.)

As you have just seen, you can use the Customize dialog box to open a toolbar, but toolbars behave in a different way when you have the Customize dialog box open, as you'll see in the next set of steps:

  1. Click the Distance tool in the Inquiry toolbar to open the Customize dialog box at the Button Properties tab. You see the properties of the Distance tool.

    click to expand
  2. Click the Line tool in the Drawing toolbar. The information in the Button Properties tab changes to show you the properties of the Line tool.

    click to expand
  3. Click the Close button to close the Customize dialog box.

As you can see from this exercise, when you click tools in the Customize dialog box, they display their properties instead of performing their usual function. This enables you to change the tools' behavior and appearance.

Understanding the Button Properties Tab

Let's take a moment to look at the contents of the Button Properties tab. At the top, you see the name of the tool in an input box. You can use this Name input box to create a custom tool tip. Right now, it shows the word Line, which appears as a tool tip when you point to the Line tool.

Below the Name input box is the Description input box. Here you can enter a full description of the tool. The description you enter appears in the status bar at the bottom of the AutoCAD window whenever you point to the tool.

The heart of the Button Properties tab is the Macro Associated With This Button input box. This input box contains the explicit instructions that AutoCAD is to execute when the tool is selected. For the Line tool, you see ^C^C_line . The two ^C s are a special AutoCAD menu notation indicating the Esc key. In other words, the presence of the ^C s in the macro is the same as pressing the Esc key. Two are used to ensure that AutoCAD returns to the command prompt even if it is in the middle of another command.

The two ^C s are followed by the line command. You enter this command in the macro just as you would enter it through the keyboard, with the exception of the underline at the beginning. The underline is a special AutoCAD menu notation that ensures that the command is understood by any language version of AutoCAD. You could leave it out if you are certain that you will not be using your macro on a foreign-language version of AutoCAD.

Finally, to the right on the Button Properties tab, you see an enlarged version of the tool icon. Just below the icon, you see a set of predefined icons. When you create your own custom tools, you can select an icon from the set of predefined ones, or you can select the Edit button to create your own custom icon.

Now you've seen how to gain access to the properties of existing tools. In the next sections, you'll learn how to create new toolbars and tools.

Tip  

Typically, AutoCAD stores menu bar options, toolbars, and buttons in the Acad.mns file (see "The Windows Menu Files"sidebar later in this chapter). You can also store them in your own custom menu files. After you've created and loaded your menu file, as described in the section "Adding Your Own Pull-Down Menu" later in this chapter, choose your menu from the Menu Group list in the Toolbars tab of the Customize dialog box.

Creating Your Own Toolbar

You might find that instead of using one toolbar or flyout, you are moving from flyout to flyout from a variety of toolbars. If you keep track of the tools you use most frequently, you can create your own custom toolbar containing your favorite tools.

Here's how it's done:

  1. Right-click any icon in any toolbar and then choose Customize from the shortcut menu to open the Customize dialog box.

  2. Click the Toolbars tab and then select Custom from the Menu Group list. You'll add your custom menu features to the Custom menu group. This helps keep your personal custom entries in a separate part of the AutoCAD menu system.

  3. Click the New button to open the New Toolbar dialog box.

  4. Enter My Toolbar in the Toolbar Name input box and then click OK. A small, blank toolbar appears in the AutoCAD window. (You might need to move the Customize dialog box to view the new toolbar.)

    Notice that My Toolbar appears in the Toolbars list box. You can now begin to add buttons to your toolbar.

  5. In the Customize dialog box, click the Commands tab and look at the Categories list. Notice that it contains the names of menus in the AutoCAD menu bar.

  6. Choose Draw from the list. The Commands list box to the right displays all the tools available for the Draw pull-down menu. If you scroll down the Commands list, you'll notice that it offers several additional arc and circle tools not found in the Draw toolbar.

  7. Click the first tool at the top of the list: the Line tool. You'll see a description of the tool in the Description box below the Categories list box. You'll also see a tip in the lower-right corner telling you what you can do with the selected option.

  8. Click and drag the Line tool from the Commands list into the new toolbar you just created. The Line tool now appears in your toolbar.

  9. Click and drag the Arc Start End Direction tool to your new toolbar. You will have to scroll down the Commands list to get to Arc Start End Direction.

    click to expand
  10. Close the Customize dialog box.

You now have a custom toolbar with two buttons. You can add buttons from different categories if you like. You are not restricted to buttons in one category.

Tip  

If you need to remove a tool from your toolbar, click and drag it out of your toolbar into the blank area of the drawing. Do this while the Customize dialog box is open.

AutoCAD treats your custom toolbar just like any other toolbar. It appears when you start AutoCAD and remains until you close it. You can recall it by using the steps in the first exercise in this chapter.

start sidebar
Opening Toolbars from the Command Line

Opening toolbars from the command line can be especially helpful if you want to create toolbar buttons that open other toolbars. Follow these steps:

  1. At the command prompt, type “Toolbar . (Don't forget to include the minus sign at the beginning of the Toolbar command.)

  2. At the Enter toolbar Name or [All]: prompt, enter the name of the toolbar you want to open.

  3. At the Enter an option [Show/Hide/Left/Right/Top/Bottom/Float] <Show>: prompt, press . The toolbar appears on the screen.

A typical button macro for opening a toolbar might look like this:

^c^cToolbar[space]inquiry[space][space]

Here, the [space] is added for clarity. You would press the spacebar in its place. This example shows a macro that opens the Inquiry toolbar. You can use the name shown in the toolbar shortcut menu to specify the name of the toolbar in the command-line version of the Toolbar command. For compound names such as Object Snap, you need to add an underline between the two words in the name: Object_Snap.

As the prompt in step 3 indicates, you can specify the location of the toolbar by left, right, top, or bottom. Float lets you specify the location and number of rows for the toolbar.

end sidebar
 



Mastering AutoCAD 2005 and AutoCAD LT 2005
Mastering AutoCAD 2005 and AutoCAD LT 2005
ISBN: 0782143407
EAN: 2147483647
Year: 2004
Pages: 261
Authors: George Omura

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net