How do I draw a stamp programatically?
on the PDFLayoutView I tried to use the following
// start drawing stamp
PDFSetStamp(0);
// programatically create stamp, using code from onDrawStamp()
if (m_status == STA_STAMP && canvas != null) {
if (m_icon != null) {
Rect rc = new Rect();
rc.left = left;
rc.top = top;
rc.right = right;
rc.bottom = bottom;
// crash here <<<<<<<<<<<<<
canvas.drawBitmap(m_icon, null, rc, null);
}
}
// end
PDFSetStamp(1);
the canvas i get here
public void OnPageDisplayed(Canvas canvas, VPage vpage) {
this.canvas = canvas;
this.vpage = vpage;
}
Please advise, drawing a selection using this canvas seems to work fine.