-
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 4 replies
-
The issue title says "text field" and the description talks about an image field, so I'm not sure what you really mean. Generally, an "image field" in AcroForm doesn't really exist. However, it can be emulated using a button with an icon only layout that uses a Javascript action to update that icon on clicking. Could you provide a sample form that you want to fill out? If it is not necessary to preserve the form field in question, you could get the positions and dimensions from the field's widget(s), remove the widget(s) and just paint the image at the correct location. |
Beta Was this translation helpful? Give feedback.
So, basically, you need to do this:
:Rect
entry specifying the rectangle it occupies.:Rect
entry, draw the image using the overlay canvas (https://hexapdf.gettalong.org/documentation/api/HexaPDF/Type/Page.html#method-i-canvas) inside that rectangle, and then delete the widget from the field (https://hexapdf.gettalong.org/documentation/api/HexaPDF/Type/AcroForm/Field/index.html#method-i-each_widget)