Linewidth Home

Linewidth represents the exact width of an object's lines, multiplied by 1000. For example, if you want a line to be plotted with width 0.25 mm, you have to specify value 250, for 1.5 mm - 1500 and so on.

A linewidth value of 0 is displayed as one pixel and print at the thinnest width available on the specified printer. If an object is filled and its linewidth is 0, then the line is not drawn at all.
Use drawing's parameter LC_PROP_DRW_LWMODE to display or not display real linewidth in a window (LC_LW_THIN, LC_LW_REAL, LC_LW_PIXEL). A drawing's redraw time increases with linewights that are represented by more than one pixel.

On model space layout, you can set a mode to display linewidths in the same way as AutoCAD lineweights, i.e. in constant pixel values that does not represent an object's real-world width. For this, set non-zero value for drawing's parameter LC_PROP_DRW_LWSCALE, which means "pixel size for lineweight". For example, if LC_PROP_DRW_LWSCALE is 0.15, than a linewidth of 0.5 mm will be drawn with 3 pixel width ((int)(0.5/0.15)) and is always displayed using 3 pixels regardless of how far you zoom into your drawing. If LC_PROP_DRW_LWSCALE is set to zero, then LiteCAD displays real width, which depends of current zoom.
In a paper space layout, linewidths always display in the exact plotting width.

Using LC_PROP_DRW_LWMODE :

Mode Display entity's line width in a window
LC_LW_THIN Always 1 pixel width.
LC_LW_REAL Width is defined by LC_PROP_ENT_LWIDTH property. Visible width will depend on current zoom.
LC_LW_PIXEL Width (pixels) = (int)(C_PROP_ENT_LWIDTH / LC_PROP_DRW_LWSCALE)
Visible width will NOT depend on current zoom.
This mode is similar to displaying lineweights in AutoCAD .


Additional constants, used only for graphic objects:

Constant Meaning
LC_LWIDTH_DEFAULT Default lineweight. Width is controlled by LC_PROP_DRW_LWDEFAULT property.
LC_LWIDTH_BYLAYER Universal lineweight specified in the object's layer.
LC_LWIDTH_BYBLOCK Universal lineweight specified within Block Reference object.

See also

  Code sample