Hi all,
I would like to insert embedded graphics into Writer. By using the API,
I could successfully insert graphics which are linked to image files. I
realize that there is a "Link" menu under the Edit menu which displays a
dialog box and allow the removal of links. I suppose this option fits my
need perfectly and I started finding ways to achieve what the Links
dialog box does.
I tried record my actions as macro, the following code display the Edit
Links dialog box. But I do not want to have user intervention during the
link removal process, so I tried finding other ways...
dispatcher.executeDispatch(document, ".uno:LinkDialog", "", 0, Array())
Then, I found the interface XLinkageSupport, which I thought it might be
helpful as it offers the breakLink() method. However, I could not figure
out what objects should be used for querying the XLinkageSupport
interface. I have tried querying both the text document (XTextDocument)
and the graphic (XTextContent) but both return null.
Is there any possibility to do what I am attempting to do? If
XLinkageSupport does work for my need, could anyone please explain
briefly how to use the XLinkageSupport interface?
Thanks for any help in advance!
Best Regards,
MuiFull
PS. I browsed through the forum and knew that embedded graphics could be
created through the use of dispatch interface, but this is not the best
solution for my case. This is because I need to have an accurate
positioning for graphics, and by using dispatch, I need to obtain
references of the created graphics in further, and to do the positioning
through normal API. Performance issue is then a big concern...
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]