IntelliJ IDEA can smartly tell the nodes that belong to the same package from the extraneous ones.

To highlight sibling nodes
  1. Select a node element in diagram.
  2. Start navigating through the diagram. So doing, the classes and packages that reside in different packages, are automatically grayed out.

    umlHighlightNodes.png