Detailed clarification of layer order


Short version

  • The user can handle the display of AutoCAD and TeleCAD-GIS objects (moving objects "above" or "below")
    (by means of: Right click > Draw order > Send to Back (or - Bring to front) ACAD commands or the following TCG commands: To Back and To Front).
  • After such a handling, the user will often wish to return to the familiar status (i.e. default order);
    (this is also the essence of the whole layer order issue (or objects order to be more precise - see the "Long version" if you wish)).
    (For this purpose, use  Optimal layer order command.)
  • In order for Optimal layer order command to perform its function, there must be a default layer order.
    (The default order is defined by means of System Settings and Define Layer Order commands.)
  • In order for Optimal layer order command to perform its function "as expected",
    all TCG objects must be on their default layers. This is insured by using Synchronize command.


Conclusion:

If you have moved infrastructure elements between layers and wish to return them into the default layer order, run Synchronize command, and then Optimal layer order command.
If you are not satisfied with the default layer order, redefine it by means of System Settings or Define layer order command.


Long version
(For those who want to understand the background of the problem)


TeleCAD-GIS users will often have a need to change the order in which certain infrastructure types are shown. For instance, if there are optical cables and duct bank in the drawing, the cables are shown "below" the duct bank (default). In this case, the user may select the entire duct bank ( Select command), and then push it below the cables (right click > Draw Order > Send to Back command) which will make the cables visible.

However, if you take a closer look, the objects (duct bank and cables) maintained their positions on the same layers as before. The order of elements has been changed but the layers themselves did not change their order.

Why is this the case?

AutoCAD is a 3D program and its objects can be arranged in a 3D space. Let us take any kind of window for the example. A window has a wooden frame and glass. Imagine that we have drawn such a window in AutoCAD, then placed the frame on "WoodenFrame" layer, and the glass on "Glass" layer. The glass is WITHIN the frame, hence it would make no sense placing these layers one above the other, for it does not affect the mutual position of the objects on them.

The basic role of layers in AutoCAD is to organize objects into logical units (cable layer, duct bank layer...).

On the other hand, bear in mind that what we see on the screen is actually the display of 2D projection. In the projection, AutoCAD objects "closer" to the viewer will obstruct those "farther" away. Nevertheless, the display does not have to be such. AutoCAD enables us to handle the display (by running the commands of Draw Order sub-menu) and bring to front the objects which would naturally be obstructed by other objects. This has been enabled so that we could have an easy access to the objects we wish to arrange.

In TeleCAD-GIS we work with the infrastructure shown in the projection, thus all the elements are on the same "Z" coordinate (i.e. same "X-Y" plane), so we cannot discuss "above" or "below" (all the infrastructure objects are at the same distance from the observer). However, the objects must be displayed in some sort of way, so we return to display handling. Every AutoCAD object (and thereby TCG object) has a defined position (in the form of an ordinal number) where it will be displayed , upon which it depends whether it will obstruct some other object or will be obstructed by one.

So, the objects can be displayed "above" or "below", regardless of which layer  a certain object is on, the only thing that matters is its position in relation to the other objects.

What does layer order have to do with the order of objects on it?
In AutoCAD - nothing.
But when it comes to TeleCAD-GIS, things are slightly different.


Setting the order of ACAD/TCG objects based on layer order

There are two things which enable object ordering based on layer order:

  • the list in which we define the default layer order  (there are two such lists) and
  • Optimal command which arranges the order of objects based on the default layer order

and an additional command (Synchronize) which (in this case) takes care that everything is done according to our expectations.


Default layer order (list)

The default layer order can be defined on the system level (in System Settings) and drawing level ( Order Layers command). (The other list (on drawing level) has priority when Optimal command is run.)

On both lists the user can define the default order at their own discretion.

Note:

The way in which the layers are shown in the list on the drop-down menu of "Object Properties" toolbar or "Layer Properties Manager",

rasporedlayera_pojasnjenje.png

has nothing to do with object order or the default layer order. Layers are here arranged (sorted) based on properties of some of the following columns: Name, Color, Lineweight... They are most commonly arranged in the alphabetical order as per the layer names.

("Object Properties" toolbar and "Layer Properties Manager" are standard AutoCAD tools, unlike
the lists where the default layer order is defined, which are specialized TeleCAD-GIS tools.)


Optimal layer order command

In TeleCAD-GIS  Optimal command is the one which arranged the objects in the order of layers arrangement in the list (see: "Priorities").
So, if TCG_DUCT_BANK layer is above TCG_CABLE_OPTICS layer (in the layer list), the TCG objects of duct bank in the drawing will be displayed "above" the TCG objects of optical cables after running this command, if the objects have been on their default layers.

We say "if" because, if the user previously moved TCG objects to another layer which is not their default layer (e.g. optical cables onto "0" layer), the objects will be shown in the position of that layer (in our example optical cables would be above all the other objects, for "0" layer is usually at the top).

We can state that we do not need any additional mess resulting from the situation when we have TCG objects which are not on their layers. In order to avoid that, use Synchronize command.


Synchronize command

All TCG objects have their default layers, and at any point TeleCAD-GIS exactly "knows" which object belongs to which default layer (even when the user moves a TCG object to a layer which is not its default layer). Run Synchronize command and TeleCAD-GIS will automatically return all TCG objects on their default layers. After this,  Optimal  command will perform its function just according to our expectations.