properties.put(propertyName, linkActiveFormat);
}
else
{
// Exception: Multiple LinkFormat elements are not allowed.
throw new FXGException(getStartLine(), getStartColumn(), "MultipleLinkFormatElements");
}
}
else if (FXG_LINKHOVERFORMAT_PROPERTY_ELEMENT.equals(propertyName))
{
if (linkHoverFormat == null)
{
linkHoverFormat = (TextLayoutFormatNode)node;
linkHoverFormat.setParent(this);
if (properties == null)
properties = new HashMap<String, TextNode>(3);
properties.put(propertyName, linkHoverFormat);
}
else
{
// Exception: Multiple LinkFormat elements are not allowed.
throw new FXGException(getStartLine(), getStartColumn(), "MultipleLinkFormatElements");
}
}
else if (FXG_LINKNORMALFORMAT_PROPERTY_ELEMENT.equals(propertyName))
{
if (linkNormalFormat == null)
{
linkNormalFormat = (TextLayoutFormatNode)node;
linkNormalFormat.setParent(this);
if (properties == null)
properties = new HashMap<String, TextNode>(3);
properties.put(propertyName, linkNormalFormat);
}
else
{
// Exception: Multiple LinkFormat elements are not allowed.
throw new FXGException(getStartLine(), getStartColumn(), "MultipleLinkFormatElements");
}
}
else
{
// Exception: Unknown LinkFormat element.
throw new FXGException(node.getStartLine(), node.getStartColumn(), "UnknownLinkFormat", propertyName);
}
}
else
{
super.addTextProperty(propertyName, node);