1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27#ifndef __com_sun_star_text_XTextTableCursor_idl__ 28#define __com_sun_star_text_XTextTableCursor_idl__ 29 30#ifndef __com_sun_star_uno_XInterface_idl__ 31#include <com/sun/star/uno/XInterface.idl> 32#endif 33 34 35//============================================================================= 36 37module com { module sun { module star { module text { 38 39//============================================================================= 40 41/** The TextTableCursor provide methods to navigate throught the table structure, to merge and split cells 42 43 @see com::sun::star::text::TextTable 44 @see com::sun::star::text::TextTableCursor 45 @see com::sun::star::text::Cell 46 @see com::sun::star::text::XTextTable 47 */ 48published interface XTextTableCursor: com::sun::star::uno::XInterface 49{ 50 //------------------------------------------------------------------------- 51 52 /** @returns 53 the name of the cell range that is selected by this cursor. 54 <p>The name is the cell name of the top left table cell of the range 55 contatenated by ':' with the table cell name of the bottom left table cell of the cell range. 56 If the range consists of one table cell only then the name of that table cell is returned. 57 </p> 58 @see com::sun:star::text::CellRange 59 */ 60 string getRangeName(); 61 62 //------------------------------------------------------------------------- 63 64 /** moves the cursor to the cell with the specified name. 65 66 @param aCellName 67 specifies the name of the cell to go to. 68 69 @param bExpand 70 determines wether the selection is to be expanded. 71 72 @see com::sun::star::text::Cell 73 */ 74 boolean gotoCellByName( [in] string aCellName, 75 [in] boolean bExpand ); 76 77 //------------------------------------------------------------------------- 78 79 /** moves the cursor to the left neighbor. 80 81 @param nCount 82 the number of cells to move. 83 84 @param bExpand 85 determines wether the selection is to be expanded. 86 */ 87 boolean goLeft( [in] short nCount, 88 [in] boolean bExpand ); 89 90 //------------------------------------------------------------------------- 91 92 /** moves the cursor to the right neighbor. 93 94 @param nCount 95 the number of cells to move. 96 97 @param bExpand 98 determines wether the selection is to be expanded. 99 */ 100 boolean goRight( [in] short nCount, 101 [in] boolean bExpand ); 102 103 //------------------------------------------------------------------------- 104 105 /** moves the cursor to the top neighbor. 106 107 @param nCount 108 the number of cells to move. 109 110 @param bExpand 111 determines wether the selection is to be expanded. 112 */ 113 boolean goUp( [in] short nCount, 114 [in] boolean bExpand ); 115 116 //------------------------------------------------------------------------- 117 118 /** moves the cursor to the bottom neighbor cell. 119 120 @param nCount 121 the number of cells to move. 122 123 @param bExpand 124 determines wether the selection is to be expanded. 125 */ 126 boolean goDown( [in] short nCount, 127 [in] boolean bExpand ); 128 129 //------------------------------------------------------------------------- 130 131 /** moves the cursor to the top left cell of the table. 132 133 @param bExpand 134 determines wether the selection is to be expanded. 135 */ 136 void gotoStart( [in] boolean bExpand ); 137 138 //------------------------------------------------------------------------- 139 140 /** moves the cursor to the bottom right cell of the table. 141 142 @param bExpand 143 determines wether the selection is to be expanded. 144 */ 145 void gotoEnd( [in] boolean bExpand ); 146 147 //------------------------------------------------------------------------- 148 149 /** merges the selected range of cells. 150 151 @see com:sun::star::CellRange 152 */ 153 boolean mergeRange(); 154 155 //------------------------------------------------------------------------- 156 157 /** splits the range of cells. 158 159 @param nCount 160 specifies the number of new cells that will be created 161 for each cell contained in the range. 162 163 @param bHorizontal 164 <true/> if the range should be split vertically. 165 Otherwise it will be split horizontally. 166 167 @see com:sun::star::Cell 168 @see com:sun::star::CellRange 169 */ 170 boolean splitRange( [in] short nCount, 171 [in] boolean bHorizontal ); 172 173}; 174 175//============================================================================= 176 177}; }; }; }; 178 179#endif 180