def previous_sibling()
      if siblings = parent.children
        siblings.each_with_index do |node, i|
          return siblings[i - 1] if node.equal?(self)
        end
      end
      nil
    end
def previous_sibling()
      if siblings = parent.children
        siblings.each_with_index do |node, i|
          return siblings[i - 1] if node.equal?(self)
        end
      end
      nil
    end
Returns the previous sibling node.