Author Topic: VISRETAIN - System Variable  (Read 5918 times)

0 Members and 2 Guests are viewing this topic.

BlackBox

  • King Gator
  • Posts: 3770
Re: VISRETAIN - System Variable
« Reply #15 on: December 21, 2015, 12:43:10 PM »
To that end, it would be fantastic if Layer States operated more like Sheet Set Properties, where each sheet could be assigned a Layer State, and modifying the Layer State once propagated the other associated sheets - just save Layer State settings, or change the assigned Layer State, and print.
"How we think determines what we do, and what we do determines what we get."

roy_043

  • Water Moccasin
  • Posts: 1895
  • BricsCAD 18
Re: VISRETAIN - System Variable
« Reply #16 on: December 21, 2015, 01:00:10 PM »
... there is no way to configure the transparency of a layer without going through the LAYER command which would remove this compatibility.
In BricsCAD changing the transparency of a layer is a case of simply changing its Xdata. Assuming BricsCAD is compatible with 'the other product', and I am counting on this, this should therefore also be possible in a DBX context.
Code - Auto/Visual Lisp: [Select]
  1. (_Data_ObjectXdataSet
  2.   lyrObj
  3.   "AcCmTransparency"
  4.   (if (/= val 33554687) (list (cons 1071 val))) ; Remove Xdata if transparency is 0%.
  5. )

In my limited testing this does not appear to be the case in AutoCAD: the xdata associated with a layer will of course yield the correct transparency value, but appending/modifying such xdata seems to have no effect on the transparency of the layer.
More testing shows that the situation is not as simple as I have suggested in BricsCAD either.
You can change the transparency of  a layer by changing the Xdata. But if there are entities on that layer or if the original transparency was not equal to zero, you have to close and reopen the file to see any effect. Even _EXPLAYERS (BC's layer manager) will show the old value until you do. :-(

lamarn

  • Swamp Rat
  • Posts: 636
Re: VISRETAIN - System Variable
« Reply #17 on: December 21, 2015, 04:03:16 PM »
Thank you Lee, en Roy.
I dont fully understand but get a sort of a picture. :?
Design is something you should do with both hands. My 2d hand , my 3d hand ..

Lee Mac

  • Seagull
  • Posts: 12914
  • London, England
Re: VISRETAIN - System Variable
« Reply #18 on: December 22, 2015, 07:21:46 AM »
... there is no way to configure the transparency of a layer without going through the LAYER command which would remove this compatibility.
In BricsCAD changing the transparency of a layer is a case of simply changing its Xdata. Assuming BricsCAD is compatible with 'the other product', and I am counting on this, this should therefore also be possible in a DBX context.
Code - Auto/Visual Lisp: [Select]
  1. (_Data_ObjectXdataSet
  2.   lyrObj
  3.   "AcCmTransparency"
  4.   (if (/= val 33554687) (list (cons 1071 val))) ; Remove Xdata if transparency is 0%.
  5. )

In my limited testing this does not appear to be the case in AutoCAD: the xdata associated with a layer will of course yield the correct transparency value, but appending/modifying such xdata seems to have no effect on the transparency of the layer.
More testing shows that the situation is not as simple as I have suggested in BricsCAD either.
You can change the transparency of  a layer by changing the Xdata. But if there are entities on that layer or if the original transparency was not equal to zero, you have to close and reopen the file to see any effect. Even _EXPLAYERS (BC's layer manager) will show the old value until you do. :-(

In AutoCAD, changing the value of the layer entity xdata will cause the new transparency value to be shown in the Layer Manager, but no change will be seen in the drawing until the drawing is closed and reopened.

(Aside, perhaps this discussion should be moved to a separate thread - sorry for the derailment!)

tedg

  • Swamp Rat
  • Posts: 811
Re: VISRETAIN - System Variable
« Reply #19 on: December 28, 2015, 08:12:48 AM »
It is important for Arch. & struc. drawings to be 1.
+1 all day long... especially when sharing other discipline's drawings for backgrounds.
Written right in my Acaddoc.lsp (setvar "visretain" 1)
Windows 10 Pro 64bit, AutoCAD 2023, REVIT 2023