SCalc.java (34dd1e25) | SCalc.java (fb0b81f5) |
---|---|
1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 96 unchanged lines hidden (view full) --- 105 System.out.println("Opening an empty Calc document"); 106 myDoc = openCalc(xContext); 107 108 //*************************************************************************** 109 110 111 //oooooooooooooooooooooooooooStep 3oooooooooooooooooooooooooooooooooooooooooo 112 // create cell styles. | 1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 96 unchanged lines hidden (view full) --- 105 System.out.println("Opening an empty Calc document"); 106 myDoc = openCalc(xContext); 107 108 //*************************************************************************** 109 110 111 //oooooooooooooooooooooooooooStep 3oooooooooooooooooooooooooooooooooooooooooo 112 // create cell styles. |
113 // For this purpose get the StyleFamiliesSupplier and the the familiy | 113 // For this purpose get the StyleFamiliesSupplier and the family |
114 // CellStyle. Create an instance of com.sun.star.style.CellStyle and 115 // add it to the family. Now change some properties 116 //*************************************************************************** 117 118 try { 119 XStyleFamiliesSupplier xSFS = (XStyleFamiliesSupplier) 120 UnoRuntime.queryInterface(XStyleFamiliesSupplier.class, myDoc); 121 XNameAccess xSF = (XNameAccess) xSFS.getStyleFamilies(); --- 205 unchanged lines hidden (view full) --- 327 XComponentLoader xCLoader; 328 XSpreadsheetDocument xSpreadSheetDoc = null; 329 XComponent xComp = null; 330 331 try { 332 // get the servie manager rom the office 333 xMCF = xContext.getServiceManager(); 334 | 114 // CellStyle. Create an instance of com.sun.star.style.CellStyle and 115 // add it to the family. Now change some properties 116 //*************************************************************************** 117 118 try { 119 XStyleFamiliesSupplier xSFS = (XStyleFamiliesSupplier) 120 UnoRuntime.queryInterface(XStyleFamiliesSupplier.class, myDoc); 121 XNameAccess xSF = (XNameAccess) xSFS.getStyleFamilies(); --- 205 unchanged lines hidden (view full) --- 327 XComponentLoader xCLoader; 328 XSpreadsheetDocument xSpreadSheetDoc = null; 329 XComponent xComp = null; 330 331 try { 332 // get the servie manager rom the office 333 xMCF = xContext.getServiceManager(); 334 |
335 // create a new instance of the the desktop | 335 // create a new instance of the desktop |
336 Object oDesktop = xMCF.createInstanceWithContext( 337 "com.sun.star.frame.Desktop", xContext ); 338 339 // query the desktop object for the XComponentLoader 340 xCLoader = ( XComponentLoader ) UnoRuntime.queryInterface( 341 XComponentLoader.class, oDesktop ); 342 343 PropertyValue [] szEmptyArgs = new PropertyValue [0]; --- 58 unchanged lines hidden --- | 336 Object oDesktop = xMCF.createInstanceWithContext( 337 "com.sun.star.frame.Desktop", xContext ); 338 339 // query the desktop object for the XComponentLoader 340 xCLoader = ( XComponentLoader ) UnoRuntime.queryInterface( 341 XComponentLoader.class, oDesktop ); 342 343 PropertyValue [] szEmptyArgs = new PropertyValue [0]; --- 58 unchanged lines hidden --- |