private PdfStructElem AddNewKid(AccessibilityProperties properties) { PdfStructElem kid = new PdfStructElem(GetDocument(), PdfStructTreeRoot.ConvertRoleToPdfName(properties.GetRole ())); AccessibilityPropertiesToStructElem.Apply(properties, kid); ProcessKidNamespace(kid); return(AddNewKid(kid)); }
public override AccessibilityProperties AddAttributes(int index, PdfStructureAttributes attributes) { if (attributes == null) { return(this); } PdfObject attributesObject = GetBackingElem().GetAttributes(false); PdfObject combinedAttributes = AccessibilityPropertiesToStructElem.CombineAttributesList(attributesObject, index, JavaCollectionsUtil.SingletonList(attributes), GetBackingElem().GetPdfObject().GetAsNumber(PdfName .R)); GetBackingElem().SetAttributes(combinedAttributes); return(this); }