Hello Ariel, Thanks for your answer.
2009/10/11 Ariel Constenla-Haile <[email protected]> > I understood you are talking here about a document UI, not a module level. > Yes, you are quite right. I have looked this sample. Its very useful for me. But there is problem: When you getting document configuration manager, it looks like Dim oDoc as Object > oDoc = ThisComponent > > Dim oUIConfigurationManager as Object > oUIConfigurationManager = oDoc.getUIConfigurationManager() > but I am writing application in Java. And I can not understand how to get this configuration manager. XComponentContext xContext = Bootstrap.bootstrap(); > XMultiComponentFactory xMCF = xContext.getServiceManager(); > Object oDesktop = > xMCF.createInstanceWithContext("com.sun.star.frame.Desktop", xContext); > XComponentLoader xCLoader = (XComponentLoader) > UnoRuntime.queryInterface(XComponentLoader.class, oDesktop); > PropertyValue[] szEmptyArgs = new PropertyValue[0]; > XComponent Doc = xCLoader.loadComponentFromURL("private:factory/swriter", > "_blank", 0, szEmptyArgs); > And now, how to get configuration manager. There is no getUIConfiguratinManager method in Doc. I know how to get module configuration manager. It is very simple XMultiServiceFactory xmsf = getMultiServiceFactory(xMCF, xContext); > Object o = > xmsf.createInstance("com.sun.star.ui.ModuleUIConfigurationManagerSupplier"); > XModuleUIConfigurationManagerSupplier xmuicms = > (XModuleUIConfigurationManagerSupplier) > UnoRuntime.queryInterface(XModuleUIConfigurationManagerSupplier.class, o); > XUIConfigurationManager xuicm = > xmuicms.getUIConfigurationManager("com.sun.star.text.TextDocument"); > Thank you in advance for your kind reply -- -- .''`. With best regards, : :' : Alexander Anisimov `. `' JID [email protected] `- Debian - when you have better things to do than fixing systems
