#ifndef __MUPAGE_ANNOTS_INCLUDED
#define __MUPAGE_ANNOTS_INCLUDED
 
#include <mupdf/pdf.h>
#include "xTcl_util.h"

#include "xGraftedPages.h"

pdf_annot* mu_GetAnnotFromObj(Tcl_Interp*interp, Tcl_Obj* Obj, fz_context* ctx, pdf_page* page);

Tcl_Obj*   mu_annots(Tcl_Interp* interp, fz_context* ctx, pdf_page* page);

pdf_annot* mu_annot_create(Tcl_Interp* interp, fz_context* ctx, CollectionOf_xGraftedPages *graftedPages, pdf_page* page, const char* annotTypeStr, int objc, Tcl_Obj* const objv[]);

TclResCode mu_annot_delete(Tcl_Interp* interp, fz_context* ctx, pdf_page* page,  int objc, Tcl_Obj* const objv[]);

pdf_annot* get_annot_from_xref( fz_context* ctx, pdf_page* page, int xref );

TclResCode mu_annot_set_attribs(Tcl_Interp* interp, fz_context* ctx,  CollectionOf_xGraftedPages *graftedPages, pdf_annot* annot, int objc, Tcl_Obj* const objv[]);

Tcl_Obj*   mu_annot_get_attribs(Tcl_Interp* interp, fz_context* ctx, CollectionOf_xGraftedPages *graftedPages, pdf_annot* annot, int objc, Tcl_Obj* const objv[]);


TclResCode mu_annot_flatten(Tcl_Interp* interp, fz_context* ctx, pdf_page* page,  int objc, Tcl_Obj* const objv[]);

#endif  // __MUPAGE_ANNOTS_INCLUDED

