private void HPDF_NewDoc() { LibLogger.Debug(this.GetType(), "HPDF_NewDoc"); HPDF_FreeDoc(); Xref = new HPDF_Xref(); Trailer = Xref.Trailer; FontMgr = new HPDF_List(HPDF_Conf.HPDF_DEF_ITEMS_PER_BLOCK); if (FontdefList == null) { FontdefList = new HPDF_List(HPDF_Conf.HPDF_DEF_ITEMS_PER_BLOCK); } if (EncoderList == null) { EncoderList = new HPDF_List(HPDF_Conf.HPDF_DEF_ITEMS_PER_BLOCK); } Catalog = new HPDF_Catalog(Xref); RootPages = Catalog.HPDF_Catalog_GetRoot(); //PageList = new HPDF_List(HPDF_Conf.HPDF_DEF_PAGE_LIST_NUM); //CurPages = RootPages; //var ptr = "CSharpPdf library "; //var version = HPDF_GetVersion(); //ptr += version; //HPDF_SetInfoAttr((int)HPDF_InfoType.HPDF_INFO_PRODUCER, ptr); }
public static HPDF_Annotation HPDF_LinkAnnot_New(HPDF_Xref xref, HPDF_Rect rect, HPDF_Destination dest) { LibLogger.Debug(MethodBase.GetCurrentMethod().DeclaringType, "HPDF_LinkAnnot_New"); HPDF_Annotation annot = new HPDF_Annotation(xref, (uint)HPDF_AnnotType.HPDF_ANNOT_LINK, rect); annot.HPDF_Dict_Add("Dest", dest); return(annot); }
public HPDF_Catalog(HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_Catalog"); Header.ObjClass |= HPDF_Obj_Header.HPDF_OSUBCLASS_CATALOG; xref.HPDF_Xref_Add(this); HPDF_Dict_AddName("Type", "Catalog"); HPDF_Dict_Add("Pages", new HPDF_Pages(null, xref)); }
public void HPDF_FreeDoc() { LibLogger.Debug(this.GetType(), "HPDF_FreeDoc"); Error = new HPDF_Error(); if (Xref != null) { Xref.HPDF_Xref_Free(); Xref = null; } PdfVersion = (int)HPDF_PdfVer.HPDF_VER_13; }
public HPDF_Pages(HPDF_Pages parent, HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_Pages"); Header.ObjClass |= HPDF_Obj_Header.HPDF_OSUBCLASS_PAGES; xref.HPDF_Xref_Add(this); HPDF_Dict_AddName("Type", "Pages"); HPDF_Dict_Add("Kids", new HPDF_Array()); HPDF_Dict_Add("Count", new HPDF_Number(0)); if (parent != null) { parent.HPDF_Pages_AddKids(this); } }
public HPDF_Annotation HPDF_URILinkAnnot_New(HPDF_Xref xref, HPDF_Rect rect, string uri) { LibLogger.Debug(this.GetType(), "HPDF_URILinkAnnot_New"); HPDF_Annotation annot; HPDF_Dict action; annot = new HPDF_Annotation(xref, (uint)HPDF_AnnotType.HPDF_ANNOT_LINK, rect); /* create action dictionary */ action = new HPDF_Dict(); annot.HPDF_Dict_Add("A", action); action.HPDF_Dict_AddName("Type", "Action"); action.HPDF_Dict_AddName("S", "URI"); action.HPDF_Dict_Add("URI", new HPDF_String(uri, null)); return(annot); }
// TODO body public HPDF_DictStream(HPDF_Xref xref) { }
public HPDF_Page(HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_Page"); }
public HPDF_ExtGState(HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_GState"); }
// TODO: body public void HPDF_TextAnnot_New(HPDF_Xref xref, HPDF_Rect rect, string text, HPDF_Encoder enecoder) { LibLogger.Debug(this.GetType(), "HPDF_TextAnnot_New"); }
// TODO: body public HPDF_Annotation(HPDF_Xref xref, uint type, HPDF_Rect rect) { LibLogger.Debug(this.GetType(), "HPDF_Annotation"); }
// TODO body public HPDF_Outline(bool root = false, HPDF_Outline parent = null, string title = "", HPDF_Encoder encoder = null, HPDF_Xref xref = null) { LibLogger.Debug(this.GetType(), "HPDF_Outline"); }
public HPDF_EncryptDict(HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_EncryptDict"); }
public void HPDF_EncryptDict_CreateID(HPDF_Dict info, HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_EncryptDict_CreateID"); }
public HPDF_Destination(HPDF_Page target, HPDF_Xref xref) { LibLogger.Debug(this.GetType(), "HPDF_Destination"); }