![]() |
Libraries (Introduction) |
www.CAD6.com |
DefinitionLibrary: A library is an external file (*.MKL) which is independent from the drawing. Libraries are organized in a hierarchical structure similar to the file system.
Block: A block is a collection of objects, such as lines, rectangles, circles, or texts. Blocks located in a library are called external blocks.
Blocks can also be located in a so-called pseudo-library named "*Internal Blocks". The pseudo-library "*Internal Blocks" is not an external file, but it is located in the drawing. Consequently the blocks of the pseudo-library are called internal blocks.
Instance: When saving a graphical element as a block, it can frequently be used in multiple drawings. The main advantage is that these blocks do not have to be part of each drawing, but only a reference to the block, consisting of block name and library name, is stored in the drawing. This reference is called Block Instance. Each instance can be modified in its display parameters like position, scaling, rotation, etc. When drawing a block, the program uses the block and library name to locate the block definition in the library.
Blocks can contain multiple attributes. An attribute is not visible and consists of a attribute name which identifies a specific value. This value can be a text, a number, or a URL. In addition, every instance has implicit attributes (block name, library name, position, etc.) which are always available.
A variable is a character string contained in any kind of text. It begins and ends will a ~ character (Ansi 126). In between these two delimiters stands the name of the variable. This name usually corresponds with the name of an attribute of a block or an implicit attribute of a block or object.
Example: The block "Resistance" shows the symbol of an electric resistance and the text "~Value~ Ohm". The block has an attribute "Value". During the insertion process of the instance, the attribute "Value" can be edited.
Transmission: A block instance can transmit its properties to its objects, provided that the object properties are not fixed. The principle corresponds to the transmission principle of layers and pens (see chapter Modify Objects).
Why Blocks?The use of blocks is obviously an efficient concept for organizing frequently accessed graphical data. When drawing a block, the program uses the block and library name stored in the instance to locate the block definition in the library. The program then uses the graphical data in the block definition and the display parameters stored in the instance to draw the block. Since normally an instance requires much less storage than the actual block data, this concept dramatically reduces memory consumption.
When creating your own libraries, you should consider the advantages and disadvantages of both block types. External libraries can easily be used by several people in different drawings. If, for example, all people in a company use the same libraries located on a central server, this helps to standardize drawings and also makes it easy to update them. Because if you replace a library with an updated version (of course the block names must remain unchanged), this update automatically will have an effect on each drawing which contains instances of blocks of that updated library once the drawing is reloaded.
Of course, if you want to pass on your drawing files to another company or a client, you either have to pass on the used library files or you have to convert the external blocks into internal blocks.
In general if blocks only need in one drawing it makes more sense to use internal blocks. Otherwise if blocks use in more than one drawing, if more than one user accesses the blocks, or the maintenance should make of a central place external block are recommended.
Library ManagementIn order to use a block of a specific library the library must be loaded first by using Library > Manage Libraries.
Library Management
Among other things, this dialog is used to create new libraries or load existing libraries. All changes are actually carried out by closing the dialog.
All settings are described in detail in the manual. If the dialog is open the corresponding topic of the reference can be opened by pressing the key "F1".
Block OperationsInsert BlockWhen using Library > Block > Insert..., a dialog appears in which the required block can be selected. The block can be either internal or external. The view of the library list is similar to a file manager (e.g. Explorer).
Insert Block
All settings are described in detail in the manual. If the dialog is open the corresponding topic of the reference can be opened by pressing the key "F1".
Create BlockThere are two methods to create a new block:
Library > Block > Create (Insertion Point) All objects and instances which are to make up the new block are chosen. Click on objects to choose them. After that, an insertion point must be entered using the mouse, by clicking anywhere in the drawing. The insertion point should be placed at a distinct place in the block, e.g. at the end point of a line or the corner point of a rectangle.
Create Block
After entering the insertion point, the "Create Block" dialog appears, in which the name of the block to be generated can be entered. For entering the block name, mark the default name "*New Block" and click on the selection again. Now it is possible to enter an arbitrary block name.
Library > Block > Create (Frame) This command can also be used to create a new block. After selecting the objects and instances which should make up the block, an area which specifies the extent of the block is entered. The area is defined by editing two corner points by clinking anywhere in the drawing. Last the reference point must be entered by clicking on an arbitrary point in the drawing. The insertion point should be placed at a distinct place in the block, e.g. at the end point of a line or the corner point of a rectangle.
After entering the Generate Block dialog appears (see above).
All settings are described in detail in the manual. If the dialog is open the corresponding topic of the reference can be opened by pressing the key "F1".
Edit BlocksUsing Library > Block > Edit, both the hierarchic structure of the library management and the properties and attributes of the blocks can be modified. By selecting the required block/ library name and clicking the right mouse button, a popup menu appears for choosing the desired command.
Resolve Block InstancesUsing Library > Block > Resolve Block Instances and identifying an instance, the instance can be resolved. This means that the objects from which the blocks are made up are inserted into the drawing instead of the instance. The attributes of the blocks are deleted.
|
CAD6studio Release 2025.0 - Copyright 2025 Malz++Kassner® GmbH