/* The node is not changed if it (or its first child) is not an opaque node.  */
int mxmlSetOpaque(mxml_node_t *node, const char *opaque)
/* The node is not changed if it (or its first child) is not an opaque node.  */
int mxmlSetOpaque(mxml_node_t *node, const char *opaque)
{
  if (node && node->type == MXML_ELEMENT &&
      node->child && node->child->type == MXML_OPAQUE)
    node = node->child;
  if (!node || node->type != MXML_OPAQUE || !opaque)
    return (-1);
  if (node->value.opaque)
    free(node->value.opaque);
  node->value.opaque = strdup(opaque);
  return (0);
}