Find the Right Note Without Losing Your Place

In a molecular model, notes can be useful landmarks—but as a project grows, finding one particular note among many can become a small distraction from the science. SAMSON’s Node Specification Language (NSL) offers a way to describe note nodes by their attributes, so you can focus a search on properties such as a note’s name, visibility, or selection state.

Note attributes live in the note attribute space, abbreviated nt. This matters because a query such as nt.v is specifically about note nodes that are visible; it is not a general query for every visible object in the model. The note attribute space also inherits several attributes from the broader node space.

Start with the question you need to answer

Rather than trying to remember every attribute, translate the task into a simple question:

  • Is the note hidden? Use nt.h; use not nt.h to ask for notes that are not hidden.
  • Is the note visible? Use nt.v; use not nt.v for notes that are not visible.
  • Is the note selected? Use nt.selected; use not nt.selected for notes that are not selected.
  • Does its name match the name I have in mind? Use the name attribute, for example nt.n "A" or the documented example nt.n "L*".

These short expressions make a useful checklist when notes are difficult to pick out visually. They also make the intent of a selection easier to read later: nt.v clearly expresses a visibility-based criterion, while nt.selected expresses a selection-state criterion.

Keep similar-sounding attributes distinct

It is tempting to treat “hidden” and “not visible” as interchangeable. The reference lists hidden and visible as separate attributes, however, so it is safer to query the exact property you mean rather than assume one is simply the inverse of the other. The same care applies to selected and selectionFlag, or to visible and visibilityFlag: they are distinct attribute names in the reference.

For note nodes, the full attribute names and their short forms are:

  • hidden — h
  • name — n
  • selected — no short name in the note attribute space
  • selectionFlag — sf
  • visibilityFlag — vf
  • visible — v

For example, nt.sf false checks the selection flag value, while nt.selected checks the selected attribute. Writing out the longer form can make a query easier to understand when sharing it with a colleague or revisiting it later. The shorter forms are handy when you already know which attribute you want.

A small habit that saves time

When a note seems to have disappeared, check the question before changing the model: are you looking for a note by name, by whether it is hidden, by whether it is visible, or by its selection state? Choose the corresponding attribute and make the query’s intent explicit. This avoids relying on visual inspection alone and helps prevent confusion between properties that have similar everyday meanings.

Note attributes inherit behavior from the node attribute space, and the note reference provides the complete list of names, aliases, values, and examples. Read the SAMSON note attributes reference to learn more.

Note: SAMSON and all SAMSON Extensions are free for non-commercial use. Get SAMSON.

Comments are closed.