ashok _ wrote:
...
Is there a standard way I can make openoffice send notifications to my
application about such changes ? I have been looking at attaching an
XEventLister to the document's XComponent object and notifiying the
application from within the XEventListener class .... but is this the
correct way to do it ? or is there a better way to do this ?
The Accessibility API supplies events on changes in state on components,
although I don't know if it covers all the properties you're interested
in. Chapter 17 of the Developer Guide.
http://wiki.services.openoffice.org/wiki/Documentation/DevGuide/Accessibility/Listeners_and_Broadcasters
Also there are property and container change events, which is probably
what you're after.
http://doc.services.openoffice.org/wiki/Documentation/DevGuide/ProUNO/Properties
http://api.openoffice.org/docs/common/ref/com/sun/star/container/XContainerListener.html
http://api.openoffice.org/docs/common/ref/com/sun/star/container/XContainer-xref.html
And I'm not really sure how to listen for changes to the cursor itself,
but TextCursor does supply XPropertySet which support change events.
http://api.openoffice.org/docs/common/ref/com/sun/star/text/TextCursor.html
http://api.openoffice.org/docs/common/ref/com/sun/star/beans/XPropertySet.html
There is a lot in the OOo UNO API and anything that doesn't already have
an example can be difficult to suss out. It would be great if you
worked up an article for the wiki or whatever that explains what you
figure out about dealing with document and cursor change events.
Jim
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]