insert inline image

Previous topic - Next topic


I want to insert inline image in text frame with python. I searched in APi and source but I think there is not yet a function for that.
I'm right?


In the UI I think the only way is to paste it, are there not Python options to cut/copy and paste?


Sorry, I forgot to say it for a CLI use, so I can't manually put the cursor at the position in a text frame where I want to include the image. 

For copy paste, there is:

Definition of "pasteObjects" says it call "slotEditPaste" that will call what is necessary to create an inline frame, I think, but the cursor need to be in a text frame.

Inserttext is a good exemple cause it insert text at a position but it manipulate directly "string" inside the text box so I can't take inspiration from this function.

What I'm searching is I think an equivalent of setEditMode() mentioned here with position parameter for text frame :