1 'encoding UTF-8 Do not remove or change this line!
2 '**************************************************************************
3 ' DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
5 ' Copyright 2000, 2010 Oracle and/or its affiliates.
7 ' OpenOffice.org - a multi-platform office productivity suite
9 ' This file is part of OpenOffice.org.
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.
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).
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.
26 '/************************************************************************
28 '* owner : helge.delfs@oracle.com
30 '* short description : Call all functions in table menu
32 '\***********************************************************************
36 printLog Chr(13) + "--------- Table Menu (w_006_.inc) ----------"
37 gApplication = "WRITER"
40 Call tFormatSplitTables
41 Call tFormatJoinTables
42 Call tFormatNumberFormat
45 Call tFormatAutoformatTable
49 '---------------------------------------------------------------------------------------------------------
52 PrintLog "- Format / Table"
54 printlog " Open new document"
57 printlog " Insert a table"
58 Call hTabelleEinfuegen
60 printlog " Format / Table"
64 printlog " In dialog step through all tabpages"
65 Active.SetPage TabTabelle
67 Call DialogTest ( TabTabelle )
70 Active.SetPage TabTextflussTabelle
71 Kontext "TabTextflussTabelle"
72 Call DialogTest ( TabTextflussTabelle )
75 Active.SetPage TabSpaltenTabelle
76 Kontext "TabSpaltenTabelle"
77 Call DialogTest ( TabSpaltenTabelle )
80 Active.SetPage TabUmrandung
81 Kontext "TabUmrandung"
82 Call DialogTest ( TabUmrandung )
85 Active.SetPage TabHintergrund
86 Kontext "TabHintergrund"
87 Call DialogTest ( TabHintergrund )
89 printlog " Close dialog"
92 printlog " Close active document"
97 '----------------------------------------------------------
99 testcase tFormatSplitTables
100 PrintLog "- Format / Split Table"
101 printlog " Open new document"
103 printlog " Insert a table"
104 Call hTabelleEinfuegen
105 printlog " Select all"
106 Call wTypeKeys ("<Mod1 a>")
108 printlog " Format / Split Table"
110 Kontext "TabelleAuftrennen"
111 Call DialogTest ( TabelleAuftrennen )
112 printlog " Close dialog"
113 TabelleAuftrennen.Cancel
114 printlog " Close active document"
118 '-----------------------------------------------------------
120 testcase tFormatJoinTables
121 PrintLog "- Format / Join Table"
122 printlog " Open new document"
124 printlog " Insert a table"
125 Call hTabelleEinfuegen
126 printlog " Point cursor under the table"
127 Call wTypeKeys ("<Down><Down>")
128 printlog " Insert a table"
129 Call hTabelleEinfuegen
130 printlog " Point cursor under the table"
131 Call wTypeKeys ("<Down><Down>")
132 printlog " Insert a table"
133 Call hTabelleEinfuegen
134 printlog " Point cursor in 3rd table"
135 Call wTypeKeys ("<Up><Up>")
136 printlog " Format / Merge Tables"
138 Kontext "TabellenVerbinden"
139 Call DialogTest (TabellenVerbinden)
140 printlog " Close dialog"
141 TabellenVerbinden.Cancel
142 printlog " Close active document"
146 '-----------------------------------------------------------
148 testcase tFormatNumberFormat
149 printLog "- Format / Number Format"
150 printlog " Open new document"
152 printlog " Format / Number Format"
153 Call hTabelleEinfuegen
155 Kontext "Zahlenformat"
156 Call DialogTest ( Zahlenformat )
157 printlog " Close dialog"
159 printlog " Close active document"
163 '-----------------------------------------------------------
166 PrintLog "- Format / Cell"
167 printlog " Open new document"
169 printlog " Insert a table"
170 Call hTabelleEinfuegen
172 printlog " Table / Column / Select"
174 printlog " Table / Merge Cells"
176 printlog " Table / Split Cells"
179 Kontext "ZellenTeilen"
180 Call DialogTest ( ZellenTeilen )
181 printlog " Close dialog 'Split Table'"
183 printlog " Table / Protect Cells"
186 Call wTypeKeys ("<Left>")
187 printlog " Open Contextmenu"
188 printlog " Select 'Cell->Unprotect"
189 Kontext "DocumentWriter"
190 Call wTypeKeys "<Shift F10>"
192 Call hMenuFindSelect (".uno:CellMenu", true, 9, false) 'Find "CellMenu" and call the slot.
195 Call hMenuFindSelect (20519, true, 1, false) 'Find "UnProtect" and call the slot.
197 Warnlog "Unable to unprotect cell"
199 printlog " Close active document"
203 '-----------------------------------------------------------
206 PrintLog "- Format / Row"
207 printlog " Open new document"
209 printlog " Insert a table"
210 Call hTabelleEinfuegen
212 printlog " Format / Row / Height"
214 Kontext "ZellenHoehe"
216 Call DialogTest ( ZellenHoehe )
217 printlog " Close dialog"
219 printlog " Format / Column / Select"
222 printlog " Format / Row / Space equally"
223 FormatRowSpaceEqually
225 printlog " Format / Row / Select"
228 printlog " Format / Row / Optimal Height"
229 TableAutoFitSetOptimalRowHeight
231 printlog " Format / Row / Insert"
233 Kontext "EinfuegenZeilen"
235 Call DialogTest ( EinfuegenZeilen )
236 printlog " Close dialog"
238 printlog " Format / Row / Delete"
241 printlog " Close active document"
245 '-----------------------------------------------------------
247 testcase tFormatAutoformatTable
248 PrintLog "- Format / Autoformat - Table"
251 printlog " Open new document"
253 printlog " Insert a table"
254 Call hTabelleEinfuegen
256 printlog " Format / Autoformat"
260 Kontext "AutoformatTabelle"
261 printlog " In dialog click 'More..'"
263 Call DialogTest ( AutoformatTabelle )
265 printlog " Click 'Add'"
267 Kontext "AutoformatHinzufuegenWriter"
268 Call DialogTest ( AutoformatHinzufuegenWriter )
269 TabellenName.SetText "Hallo"
270 printlog " Enter a new table name"
271 AutoformatHinzufuegenWriter.OK
273 Kontext "AutoformatTabelle"
274 printlog " Click 'Rename'"
276 Kontext "AutoformatHinzufuegenWriter"
277 Call DialogTest ( AutoformatHinzufuegenWriter )
278 printlog " Enter an new table name"
279 TabellenName.SetText "Hallo1"
280 AutoformatHinzufuegenWriter.OK
281 Kontext "AutoformatTabelle"
282 printlog " Click 'Delete'"
286 printlog " Close dialog"
287 AutoformatTabelle.Cancel
289 printlog " Close active document"