For molecular modelers working with SAMSON, efficient handling of nodes and their attributes can be a crucial part of their workflow. When dealing with light nodes, which often play a specific role in your molecular modeling projects, understanding their light attributes can help save time and avoid errors. This article unpacks the essentials of light attributes in SAMSON’s Node Specification Language (NSL) and highlights practical ways they can be applied in your projects.
What are Light Attributes?
Light attributes in NSL refer to specific properties associated with light nodes in SAMSON. They are part of the attribute space light, with a shorthand li. These attributes allow you to query, sort, or manipulate light nodes based on their properties effectively.
To clarify, light attributes only apply to light nodes, offering a more refined approach to node-based tasks. Understanding these properties can help molecular modelers streamline their workflows while working on complex projects with various node types.
Key Light Attributes and Their Uses
The table below summarizes the main light attributes you can use, their shorthand names, and possible values:
| Attribute name | Short name | Possible values | Examples |
|---|---|---|---|
| hidden | h |
true, false |
li.hnot li.h |
| name | n |
strings in quotes | li.n "A"li.n "L*" |
| selected | true, false |
li.selectednot li.selected |
|
| selectionFlag | sf |
true, false |
li.sf falseli.sf |
| visibilityFlag | vf |
true, false |
li.vf falseli.vf |
| visible | v |
true, false |
li.vnot li.v |
Practical Applications
Here are some examples of how light attributes can help in specific tasks:
- Filtering by name: To isolate light nodes with specific names, you can use the
nameattribute. For instance,li.n "Light A"selects a light node named “Light A”. - Visibility checks: Use
visible(v) orvisibilityFlag(vf) to ensure the light nodes you are analyzing are visible in your project view. - Selection operations: You might want to query only selected light nodes by using
selected, or set and clear selection withselectionFlag (sf).
These attributes provide flexibility when dealing with large systems, helping you efficiently manage visual and logical workflows in SAMSON.
Learn More
For a comprehensive understanding of light attributes in SAMSON’s Node Specification Language, visit the full documentation page here: Light Attributes Documentation.
SAMSON and all SAMSON Extensions are free for non-commercial use. You can get SAMSON at samson-connect.net.
