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 2008 by Sun Microsystems, Inc.
7 '* OpenOffice.org - a multi-platform office productivity suite
9 '* $RCSfile: w_redlining1.inc,v $
13 '* last change: $Author: vg $ $Date: 2008-08-18 12:33:53 $
15 '* This file is part of OpenOffice.org.
17 '* OpenOffice.org is free software: you can redistribute it and/or modify
18 '* it under the terms of the GNU Lesser General Public License version 3
19 '* only, as published by the Free Software Foundation.
21 '* OpenOffice.org is distributed in the hope that it will be useful,
22 '* but WITHOUT ANY WARRANTY; without even the implied warranty of
23 '* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
24 '* GNU Lesser General Public License version 3 for more details
25 '* (a copy is included in the LICENSE file that accompanied this code).
27 '* You should have received a copy of the GNU Lesser General Public License
28 '* version 3 along with OpenOffice.org. If not, see
29 '* <http://www.openoffice.org/license.html>
30 '* for a copy of the LGPLv3 License.
32 '/************************************************************************
34 '* owner : helge.delfs@sun.com
36 '* short description : Test of the Redlinig function - 1
38 '************************************************************************
40 ' #1 tRedlining_1 'Test Default settings
41 ' #1 tRedlining_2 'Inserted text : from Typing
42 ' #1 tRedlining_3 'Inserted text : from Clipboard
43 ' #1 tRedlining_4 'Inserted text : from another file
44 ' #1 tRedlining_5 'Inserted text : from Autotext
45 ' #1 tRedlining_6 'Deleteed text
46 ' #1 tRedlining_7 'sorted text
47 ' #1 tRedlining_8 'Searched and replaced text
48 ' #1 tRedlining_9 'text attributs
49 ' #1 tRedlining_10 'Inserted Section
50 ' #1 tRedlining_11 'Inserted Table
51 ' #1 tRedlining_12 'Inserted field (Date)
52 ' #1 tRedlining_13 'Inserted footnotes
53 ' #1 tRedlining_14 'Inserted headers
54 ' #1 tRedlining_15 'Inserted footers
55 ' #1 tRedlining_16 'moved paragraphs/chapters
57 '\***********************************************************************
61 Dim iInsertionAttr as Integer
62 Dim iInsertionColor as Integer
63 Dim iDeletionAttr as Integer
64 Dim iDeletionColor as Integer
65 Dim iChangedAttr as Integer
66 Dim iChangedColor as Integer
67 Dim iLineChangedMark as Integer
68 Dim iLineChangedColor as Integer
70 iInsertionAttr = 4 : iInsertionColor = 2
71 iDeletionAttr = 4 : iDeletionColor = 2
72 iChangedAttr = 2 : iChangedColor = 2
73 iLineChangedMark = 2 : iLineChangedColor = 1
77 PrintLog "- Test Default settings"
78 '/// Test Default settings
80 '/// The default setting for Redlining is Off
81 Call wTypeKeys "Redlining test"
82 Call wTypeKeys "<Backspace>",2
84 Call wTypeKeys "<End>"
85 Call wTypeKeys "<Shift Left>" , 4
87 if GetClipboardText <> "g te" then Warnlog "The default setting for Redlining is NO Off"
89 '/// Tools / Options / Textdocument / Changes
91 Call hToolsOptions("WRITER","CHANGES")
93 '/// Check default settings
95 '/// 1) Insertion Attributes , Insertion color
96 if EinfuegenAttribute.GetSelIndex <> iInsertionAttr then
97 warnlog "The default settings for Insertion Attribute isn't correct, should be " + EinfuegenAttribute.GetItemText(iInsertionAttr) + " but get " +EinfuegenAttribute.GetItemText(EinfuegenAttribute.GetSelIndex)
99 if EinfuegenFarbe.GetSelIndex <> iInsertionColor then
100 warnlog "The default settings for Insertion color isn't correct, should be " + EinfuegenFarbe.GetItemText(iInsertionColor) + " but get " +EinfuegenFarbe.GetItemText(EinfuegenFarbe.GetSelIndex)
103 '/// 2) Deletion Attribute , Deletion color
104 if LoeschenAttribute.GetSelIndex <> iDeletionAttr then
105 warnlog "The default settings for Deletion Attribute isn't correct, should be " + LoeschenAttribute.GetItemText(iDeletionAttr) + " but get " +LoeschenAttribute.GetItemText(LoeschenAttribute.GetSelIndex)
107 if LoeschenFarbe.GetSelIndex <> iDeletionColor then
108 warnlog "The default settings for Deletion color isn't correct, should be " + LoeschenFarbe.GetItemText(iDeletionColor) + " but get " +LoeschenFarbe.GetItemText(LoeschenFarbe.GetSelIndex)
111 '/// 3) Changed Attribute , Changed color
112 if AendernAttribute.GetSelIndex <> iChangedAttr then
113 warnlog "The default settings for Changed Attribute isn't correct, should be " + AendernAttribute.GetItemText(iChangedAttr) + " but get " +AendernAttribute.GetItemText(AendernAttribute.GetSelIndex)
115 if AendernFarbe.GetSelIndex <> iChangedColor then
116 warnlog "The default settings for Changed color isn't correct, should be " + AendernFarbe.GetItemText(iChangedColor) + " but get " +AendernFarbe.GetItemText(AendernFarbe.GetSelIndex)
119 '/// 4) Lines changed Mark , Lines changed color
120 if ZeilenMarkierung.GetSelIndex <> iLineChangedMark then
121 warnlog "The default settings for Lines Changed Mark isn't correct, should be " + ZeilenMarkierung.GetItemText(iLineChangedMark) + " but get " +ZeilenMarkierung.GetItemText(ZeilenMarkierung.GetSelIndex)
123 if ZeilenFarbe.GetSelIndex <> iLineChangedColor then
124 warnlog "The default settings for Lines Changed color isn't correct, should be " + ZeilenFarbe.GetItemText(iLineChangedColor) + " but get " +ZeilenFarbe.GetItemText(ZeilenFarbe.GetSelIndex)
127 '/// Close the tools/option dialogue
128 Kontext "ExtrasOptionenDlg"
129 ExtrasOptionenDlg.Cancel
135 '-------------------------------------------------------------------------------------------
137 testcase tRedlining_2
139 '/// Test Inserted text : from Typing
140 printlog "Inserted text : from Typing"
145 '/// Insert any sentence into document
146 Call wTypeKeys "Redlining test => OK_1<Return>"
149 '/// Edit / Changes / Record
152 '/// Insert some new sentence
153 Call wTypeKeys "Redlining test => OK_2<Return>"
155 '/// Edit / Changes / Accept or Reject
156 EditChangesAcceptOrReject
158 '/// + Select tabpage 'List' ///
159 TabControl.SetPage TabListe
160 '/// + Select 'Accept All'///
161 AlleAkzeptieren.Click
163 '/// + Close Redlining dialog
166 '/// Check if the changes have been accepted
167 Call wTypeKeys "<Up>", 2
168 Call wTypeKeys "<Down>"
169 Call wTypeKeys "<End>"
170 Call wTypeKeys "<Shift Left>"
173 if GetClipboardText <> "2" then Warnlog "The 2nd line is incorrect!"
175 '/// Close the document
180 '--------------------------------------------------------------------------
182 testcase tRedlining_3
184 '/// Test Inserted text : from Clipboard
185 printlog "Inserted text : from Clipboard"
190 '/// Insert any sentence into document , and copy it to clipboard
191 Call wTypeKeys "Redlining test => OK_2<Return>"
196 '/// Insert a new sentence into document
197 Call wTypeKeys "Redlining test => OK_1<Return>"
200 '/// Edit / Changes / Record
203 '/// copy the clipboard into the document
207 '/// Edit / Changes / Accept or Reject
208 EditChangesAcceptOrReject
210 '/// + Select tabpage 'List' ///
211 TabControl.SetPage TabListe
212 '/// + Select 'Accept All'///
213 AlleAkzeptieren.Click
215 '/// + Close Redlining dialog
218 '/// Check if the changes have been accepted
219 Call wTypeKeys "<Up>", 2
220 Call wTypeKeys "<Down>"
221 Call wTypeKeys "<End>"
222 Call wTypeKeys "<Shift Left>"
225 if GetClipboardText <> "2" then Warnlog "The 2nd Line is incorrect!"
227 '/// Close the document
232 '----------------------------------------------------------------------------
234 testcase tRedlining_4
236 '/// Test Inserted text : from another file
237 printlog "Inserted text : from another file"
242 '/// Insert a sentence into document
243 Call wTypeKeys "Redlining test => OK_1<Return>"
246 '/// Edit / Changes / Record
249 '/// insert a file - Insert/File
252 Dateiname.Settext Convertpath (gTesttoolpath + "writer\optional\input\redlining\tRedlining_4.sxw")
256 '/// Edit / Changes / Accept or Reject
257 EditChangesAcceptOrReject
259 '/// + Select tabpage 'List' ///
260 TabControl.SetPage TabListe
261 '/// + Select 'Accept All'///
262 AlleAkzeptieren.Click
264 '/// + Close Redlining dialog
267 '/// Check if the changes have been accepted
268 Call wTypeKeys "<Up>", 2
269 Call wTypeKeys "<Down>"
270 Call wTypeKeys "<End>"
271 Call wTypeKeys "<Shift Left>"
274 if GetClipboardText <> "2" then Warnlog "i35222 - The 2nd Line is incorrect!"
276 '/// Close the document
281 '----------------------------------------------------------------------------
283 testcase tRedlining_5
288 '/// Test Inserted text : from Autotext
289 printlog "Inserted text : from Autotext"
295 Call wCreateAutotextCategory("1-MyTest")
301 '-----------------------------------------------------
302 Call wTypeKeys "Redlining test => OK_2<Return>"
311 Liste.Select 1 '1-MyTest'
314 'Insert a name for the Autotext and a Shortcut
315 NameText.Settext "AutotextForRedlininggTest"
317 Kuerzel.Settext "AFT"
319 'Select 'New' in Menubutton 'Autotext'
323 Call hMenuSelectNr ( 1 )
327 '-----------------------------------------------------
329 '/// Insert a sentence into document
330 Kontext "DocumentWriter"
332 Call wTypeKeys "Redlining test => OK_1<Return>"
335 '/// Edit / Changes / Record
340 Call wTypeKeys "<F3>"
343 '/// Edit / Changes / Accept or Reject
344 EditChangesAcceptOrReject
346 '/// Select tabpage 'List' ///
347 TabControl.SetPage TabListe
348 '/// Select 'Accept All'///
349 AlleAkzeptieren.Click
351 '/// Close Redlining dialog
354 '/// Check if the changes have been accepted
355 Call wTypeKeys "<Up>", 2
356 Call wTypeKeys "<Down>"
357 Call wTypeKeys "<End>"
358 Call wTypeKeys "<Shift Left>"
361 if GetClipboardText <> "2" then Warnlog "The 2nd Line is incorrect!"
363 ' Delete the new category
364 ' ------------------------------------------------
371 Kontext "BereicheBearbeitenAutoText"
376 BereicheBearbeitenAutoText.OK
379 if Active.Exists then Active.Yes
382 '-------------------------------------------------
384 '/// Close the document
389 '----------------------------------------------------------------------------
391 testcase tRedlining_6
393 '/// Test Deleted text
394 printlog "Deleted text"
399 '/// Insert a sentence into document
400 Call wTypeKeys "Redlining test => OK_1"
403 '/// Edit / Changes / Record
406 '/// Delete the last 2 characters
407 Call wTypeKeys "<Backspace>",2
410 '/// Check if the changes is OK => The characters are deleted ,
411 '/// + but their location exists
412 Call wTypeKeys "<End>"
414 Call wTypeKeys "<Shift Left>" , 2
418 if Len(GetClipboardText)>0 then Warnlog "Something is wrong in deleting text before accepting the changes!"
420 '/// Edit / Changes / Accept or Reject
421 EditChangesAcceptOrReject
425 '/// + Select tabpage 'List' ///
426 TabControl.SetPage TabListe
428 '/// + Select 'Accept All'///
429 AlleAkzeptieren.Click
431 '/// + Close Redlining dialog
434 '/// Check if the changes have been accepted => The
435 '/// + characters are deleted , and their location doesn't exist
436 Call wTypeKeys "<End>"
438 Call wTypeKeys "<Shift Left>" , 2
443 if GetClipboardText <> "OK" then Warnlog "Something is wrong in deleting text after accepting the changes! Getting " + GetClipboardText
445 '/// Close the document
450 '----------------------------------------------------------------------------
452 testcase tRedlining_7
454 '/// Test sorted text
455 printlog "sorted text"
460 '/// Insert some test text
461 Call wTypeKeys "XYZ<Return>"
465 '/// Edit / Changes / Record
468 '/// Select Tools / Sort , Language (English USA) , Alphanumeric
472 Schluesseltyp1.Select 1
476 '/// Check if the changes is OK => The characters are changed ,
477 '/// + but their location exists
478 Call wTypeKeys "<Down>" , 4
479 Call wTypeKeys "<End>"
480 Call wTypeKeys "<Shift Home>"
482 if Len(GetClipboardText)>0 then Warnlog "Something is wrong in sorting text before accepting the changes!"
484 Call wTypeKeys "<Up>" , 4
485 Call wTypeKeys "<End>"
486 Call wTypeKeys "<Shift Home>"
488 if GetClipboardText <> "ABC" then Warnlog "Should get ABC in the first line, but get " +GetClipboardText + " before accepting the changes!"
490 '/// Edit / Changes / Accept or Reject
491 EditChangesAcceptOrReject
494 '/// + Select tabpage 'List' ///
495 TabControl.SetPage TabListe
497 '/// + Select 'Accept All'///
498 AlleAkzeptieren.Click
500 '/// + Close Redlining dialog
503 '/// Check if the changes have been accepted => The characters
504 '/// + are changed , and their location doesn't exist
505 Call wTypeKeys "<Down>" , 4
506 Call wTypeKeys "<End><Backspace>"
507 Call wTypeKeys "<Shift Home>"
509 if Len(GetClipboardText) <> 3 then Warnlog "Something is wrong in sorting text after accepting the changes!"
511 Call wTypeKeys "<Up>" , 4
512 Call wTypeKeys "<End>"
513 Call wTypeKeys "<Shift Home>"
515 if GetClipboardText <> "ABC" then Warnlog "Should get ABC in the first line, but get " +GetClipboardText + " after accepting the changes!"
517 '/// Close the document
522 '----------------------------------------------------------------------------
524 testcase tRedlining_8
526 '/// Test searched and replaced text
527 printlog "searched and replaced text"
532 '/// Insert a sentence into document
533 Call wTypeKeys "Redlining test => OK_1"
536 '/// Edit / Changes / Record
539 '/// Select Edit / Find & Replace
541 Kontext "FindAndReplace"
543 '/// + Set OK_1 in search for editbox
544 SearchFor.SetText "OK_1"
547 '/// + set OK_2 in replace with editbox
548 ReplaceWith.SetText "OK_2"
551 '/// + Replace all and close the dialogue
555 if Active.Exists then
556 if Active.GetRT = 304 then
560 Warnlog "Messagebox, how often replaced, not up !"
564 Kontext "FindAndReplace"
567 '/// Check if the changes is OK => The characters are changed ,
568 '/// + but their location exists
569 Call wTypeKeys "<End>"
571 Call wTypeKeys "<Shift Left>"
575 if GetClipboardText <> "2" then Warnlog "Something is wrong in changing text before accepting the changes!"
577 Call wTypeKeys "<Left>" , 3
579 Call wTypeKeys "<Shift Left>" , 4
583 if Len(GetClipboardText) > 0 then Warnlog "Something is wrong in changing text before accepting the changes!"
585 '/// Edit / Changes / Accept or Reject
586 EditChangesAcceptOrReject
590 '/// + Select tabpage 'List' ///
591 TabControl.SetPage TabListe
593 '/// + Select 'Accept All'///
594 AlleAkzeptieren.Click
596 '/// + Close Redlining dialog
599 '/// Check if the changes have been accepted => The characters
600 '/// + are changed , and their location doesn't exist
601 Call wTypeKeys "<End>"
602 Call wTypeKeys "<Shift Left>"
606 if GetClipboardText <> "2" then Warnlog "Something is wrong in changing text after accepting the changes!"
608 Call wTypeKeys "<Left>" , 3
610 Call wTypeKeys "<Shift Left>" , 4
613 if Len(GetClipboardText) <> 4 then Warnlog "Something is wrong in changing text after accepting the changes!"
615 '/// Close the document
620 '----------------------------------------------------------------------------
622 testcase tRedlining_9
624 Dim iComparison1$,iComparison2$,iComparison3$,iComparison4$
626 '/// Test text attributs
627 printlog "Test text attributs"
632 '/// Insert a sentence into document
633 Call wTypeKeys "Redlining test => OK_1<Home>"
634 Call wTypeKeys "<Shift Right>" , 9
638 '/// Edit / Changes / Record
641 '/// Select Format / Character , changes some font Attributes
644 Active.SetPage TabFont
647 if gAsianSup = True then
649 iComparison1$ = FontWest.GetSelText
653 StyleWest.Select StyleWest.GetItemCount
655 iComparison2$ = StyleWest.GetSelText
657 iComparison3$ = SizeWest.GetSelText
660 iComparison1$ = Font.GetSelText
664 Style.Select Style.GetItemCount
666 iComparison2$ = Style.GetSelText
668 iComparison3$ = Size.GetSelText
672 Active.Setpage TabHyperlinkZeichen
673 Kontext "TabHyperlinkZeichen"
674 UrlName.Settext "http://www.sun.com/"
678 iComparison4$ = TargetFrame.GetSelText
680 TabHyperlinkZeichen.Ok
683 Call wTypeKeys "<Left>" , 2
686 '/// Check if the Attribute changes id OK before accepting the changes
687 printlog "Check if the Attribute changes id OK before accepting the changes"
690 Active.SetPage TabFont
692 if gAsianSup = True then
693 if iComparison1$ <> FontWest.GetSelText then Warnlog "Wrong Font in Autotext!"
694 if iComparison2$ <> StyleWest.GetSelText then Warnlog "Wrong Fontstyle in Autotext!"
695 if iComparison3$ <> SizeWest.GetSelText then QAErrorlog "#108881#Wrong Fontsize in Autotext!"
697 if iComparison1$ <> Font.GetSelText then Warnlog "Wrong Font in Autotext!"
698 if iComparison2$ <> Style.GetSelText then Warnlog "Wrong Fontstyle in Autotext!"
699 if iComparison3$ <> Size.GetSelText then Warnlog "Wrong Fontsize in Autotext!"
703 Active.Setpage TabHyperlinkZeichen
704 Kontext "TabHyperlinkZeichen"
705 if UrlName.Gettext <> "http://www.sun.com/" then Warnlog "Wrong hyperlink has been added to text!"
706 if iComparison4$ <> TargetFrame.GetSelText then Warnlog "Wrong targetFrame has been added to text!"
707 TabHyperlinkZeichen.Cancel
709 '/// Edit / Changes / Accept or Reject
710 EditChangesAcceptOrReject
712 '/// + Select tabpage 'List' ///
713 TabControl.SetPage TabListe
714 '/// + Select 'Accept All'///
715 AlleAkzeptieren.Click
717 '/// + Close Redlining dialog
720 '/// Check if the Attribute changes id OK after accepting the changes
721 printlog "Check if the Attribute changes id OK after accepting the changes"
724 Active.SetPage TabFont
726 if gAsianSup = True then
727 if iComparison1$ <> FontWest.GetSelText then Warnlog "Wrong Font in Autotext!"
728 if iComparison2$ <> StyleWest.GetSelText then Warnlog "Wrong Fontstyle in Autotext!"
729 if iComparison3$ <> SizeWest.GetSelText then QAErrorlog "#108881#Wrong Fontsize in Autotext!"
731 if iComparison1$ <> Font.GetSelText then Warnlog "Wrong Font in Autotext!"
732 if iComparison2$ <> Style.GetSelText then Warnlog "Wrong Fontstyle in Autotext!"
733 if iComparison3$ <> Size.GetSelText then Warnlog "Wrong Fontsize in Autotext!"
737 Active.Setpage TabHyperlinkZeichen
738 Kontext "TabHyperlinkZeichen"
739 if UrlName.Gettext <> "http://www.sun.com/" then Warnlog "Wrong hyperlink has been added to text!"
740 if iComparison4$ <> TargetFrame.GetSelText then Warnlog "Wrong targetFrame has been added to text!"
741 TabHyperlinkZeichen.Cancel
743 '/// Close the document
747 '----------------------------------------------------------------------------
749 testcase tRedlining_10
751 Dim sSectionName as String
753 sSectionName = "testForRedlining"
755 '/// Test inserted sections
756 printlog "inserted sections"
761 '/// Insert a sentence into document
762 Call wTypeKeys "Redlining test => OK_1<Shift Home>"
765 '/// Edit / Changes / Record
768 '/// Insert a section in the testing sentence , insert / section
772 Active.Setpage TabBereiche
773 Kontext "TabBereiche"
774 Bereichsliste.Settext sSectionName
778 '/// Check if the section is inserted correctly before accepting the changes , format / sections
780 Kontext "BereicheBearbeiten"
781 if BereichsName.GetText <> sSectionName then warnlog "the section is NOt inserted correctly before accepting the changes "
782 BereicheBearbeiten.Cancel
784 '/// Edit / Changes / Accept or Reject
785 EditChangesAcceptOrReject
787 '/// + Select tabpage 'List' ///
788 TabControl.SetPage TabListe
789 '/// + Select 'Accept All'///
790 AlleAkzeptieren.Click
792 '/// + Close Redlining dialog
795 '/// Check if the section is inserted correctly after accepting the changes , format / sections
797 Kontext "BereicheBearbeiten"
798 if BereichsName.GetText <> sSectionName then warnlog "the section is NOt inserted correctly after accepting the changes "
799 BereicheBearbeiten.Cancel
801 '/// Close the document
805 '----------------------------------------------------------------------------
807 testcase tRedlining_11
809 '/// Test inserted tables
810 printlog "inserted tables"
816 '/// Edit / Changes / Record
820 Call hTabelleEinfuegen
822 '/// Check if the table is inserted correctly before accepting the changes
823 Call wOpenContextMenu
828 Active.Setpage TabTabelle
830 if Right(TabellenName.GetText , 1) <> "1" then warnlog "the table is NOt inserted correctly before accepting the changes "
833 Warnlog "Something wrong in inserting table before accepting the changes!"
836 '/// Edit / Changes / Accept or Reject
837 EditChangesAcceptOrReject
839 '/// + Select tabpage 'List' ///
840 TabControl.SetPage TabListe
841 '/// + Select 'Accept All'///
842 AlleAkzeptieren.Click
844 '/// + Close Redlining dialog
847 '/// Check if the table is inserted correctly after accepting the changes
848 Call wOpenContextMenu
853 Active.Setpage TabTabelle
855 if Right(TabellenName.GetText , 1) <> "1" then warnlog "the table is NOt inserted correctly after accepting the changes "
858 Warnlog "Something wrong in inserting table after accepting the changes!"
861 '/// Close the document
865 '----------------------------------------------------------------------------
867 testcase tRedlining_12
869 '/// Test inserted field (date)
870 printlog "inserted field (date)"
876 '/// Edit / Changes / Record
879 '/// Insert a date , insert / field / date
882 Call wTypeKeys "<Home>"
885 '/// Check if the date is inserted correctly before accepting the changes
888 Kontext "FeldbefehlBearbeitenDokument"
889 FeldbefehlBearbeitenDokument.Cancel
891 Warnlog "Something wrong in inserting date before accepting the changes!"
894 '/// Edit / Changes / Accept or Reject
895 EditChangesAcceptOrReject
897 '/// + Select tabpage 'List' ///
898 TabControl.SetPage TabListe
899 '/// + Select 'Accept All'///
900 AlleAkzeptieren.Click
902 '/// + Close Redlining dialog
906 Call wTypeKeys "<Home>"
908 '/// Check if the date is inserted correctly after accepting the changes
911 Kontext "FeldbefehlBearbeitenDokument"
912 FeldbefehlBearbeitenDokument.Cancel
914 Warnlog "Something wrong in inserting date after accepting the changes!"
917 '/// Close the document
921 '----------------------------------------------------------------------------
923 testcase tRedlining_13
925 '/// Test inserted footnotes
926 printlog "inserted footnotes"
932 '/// Edit / Changes / Record
935 '/// Insert a footnote , insert / footnotes
937 Kontext "FussnoteEinfuegen"
941 Call wTypeKeys "<PageUp><Home>"
943 '/// Check if the footnote is inserted correctly before
944 '/// + accepting the changes
947 Kontext "FussnoteBearbeiten"
948 FussnoteBearbeiten.Cancel
950 Warnlog "Something wrong in inserting footnote before accepting the changes!"
953 '/// Edit / Changes / Accept or Reject
954 EditChangesAcceptOrReject
956 '/// + Select tabpage 'List' ///
957 TabControl.SetPage TabListe
958 '/// + Select 'Accept All'///
959 AlleAkzeptieren.Click
961 '/// + Close Redlining dialog
964 Call wTypeKeys "<Home>"
966 '/// Check if the footnote is inserted correctly after accepting the changes
969 Kontext "FussnoteBearbeiten"
970 FussnoteBearbeiten.Cancel
972 Warnlog "Something wrong in inserting footnote after accepting the changes!"
975 '/// Close the document
980 '----------------------------------------------------------------------------
982 testcase tRedlining_14
984 '/// Test inserted header
985 printlog "inserted header"
990 '/// Edit / Changes / Record
993 '/// Insert a header , insert / header
994 DocumentWriter.UseMenu
995 MenuSelect(Menugetitemid(4))
997 MenuSelect(Menugetitemid(9))
999 MenuSelect(Menugetitemid(1))
1002 '/// input some test words in the header
1003 Call wTypeKeys "Header Test"
1005 '/// Check if the header is inserted correctly before
1006 '/// + accepting the changes
1009 Active.SetPage TabKopfzeile
1010 Kontext "TabKopfzeile"
1011 if Not KopfzeileMitAbstand.IsChecked then Warnlog "The header is NOT inserted correctly before accepting the changes!"
1014 '/// Edit / Changes / Accept or Reject
1015 EditChangesAcceptOrReject
1017 '/// + Select tabpage 'List' ///
1018 TabControl.SetPage TabListe
1019 '/// + Select 'Accept All'///
1020 AlleAkzeptieren.Click
1022 '/// + Close Redlining dialog
1025 '/// Check if the header is inserted correctly after accepting the changes
1028 Active.SetPage TabKopfzeile
1029 Kontext "TabKopfzeile"
1030 if Not KopfzeileMitAbstand.IsChecked then Warnlog "The header is NOT inserted correctly after accepting the changes!"
1033 '/// Close the document
1038 '----------------------------------------------------------------------------
1040 testcase tRedlining_15
1042 '/// Test inserted footer
1043 printlog "inserted footer"
1048 '/// Edit / Changes / Record
1051 '/// Insert a footer , insert / footer
1052 DocumentWriter.UseMenu
1053 MenuSelect(Menugetitemid(4))
1055 MenuSelect(Menugetitemid(10))
1057 MenuSelect(Menugetitemid(1))
1060 Call wTypeKeys "Footer Test"
1062 '/// Check if the footer is inserted correctly before
1063 '/// + accepting the changes
1066 Active.SetPage TabFusszeile
1067 Kontext "TabFusszeile"
1068 if Not FusszeileMitAbstand.IsChecked then Warnlog "The footer is NOT inserted correctly before accepting the changes!"
1071 '/// Edit / Changes / Accept or Reject
1072 EditChangesAcceptOrReject
1074 '/// + Select tabpage 'List' ///
1075 TabControl.SetPage TabListe
1076 '/// + Select 'Accept All'///
1077 AlleAkzeptieren.Click
1079 '/// + Close Redlining dialog
1082 '/// Check if the footer is inserted correctly after accepting the changes
1085 Active.SetPage TabFusszeile
1086 Kontext "TabFusszeile"
1087 if Not FusszeileMitAbstand.IsChecked then Warnlog "The footer is NOT inserted correctly after accepting the changes!"
1090 '/// Close the document
1095 '----------------------------------------------------------------------------
1097 testcase tRedlining_16
1099 Dim iComparison1$ , iComparison2$
1101 '/// Test moved paragraphs/chapters
1102 printlog "moved paragraphs/chapters"
1107 '/// Insert a paragraph ( Open the test file )
1108 '/// + There are 3 lines
1109 '/// + Redlining test => OK_1 <-- No numbering
1110 '/// + Redlining test => OK_2 <-- Numbering style : list 2
1111 '/// + Redlining test => OK_3 <-- Numbering style : list 3
1113 Call hFileOpen ( gTesttoolPath + "writer\optional\input\redlining\tRedlining_15.sxw" )
1114 Call sMakeReadOnlyDocumentEditable
1116 Call wTypeKeys "<Up>" , 3
1118 Call wTypeKeys "<Down>"
1121 Active.SetPage TabNumerierungAbsatz
1122 Kontext "TabNumerierungAbsatz"
1123 iComparison1$ = Vorlage.GetSelText
1124 TabNumerierungAbsatz.Cancel
1126 Call wTypeKeys "<Down>"
1129 Active.SetPage TabNumerierungAbsatz
1130 Kontext "TabNumerierungAbsatz"
1131 iComparison2$ = Vorlage.GetSelText
1132 TabNumerierungAbsatz.Cancel
1135 '/// Edit / Changes / Record
1138 Call wTypeKeys "<Up><End>"
1139 Call wTypeKeys "<Shift Down Right>"
1140 '/// Cut the selection
1143 Call wTypeKeys "<Up>" , 3
1144 Call wTypeKeys "<End><Return>"
1145 '/// paste under the first line
1148 Call wTypeKeys "<Up><Up><End><Delete>"
1150 '/// Check if the paragraph is moved correctly before
1151 '/// + accepting the changes
1152 Call wTypeKeys "<Up>" , 3
1153 Call wTypeKeys "<Down><End>"
1154 Call wTypeKeys "<Shift Left>"
1158 Warnlog "#i41424# Bullets cannot be removed by Del key"
1159 Call wTypeKeys "<Down><End>"
1160 Call wTypeKeys "<Shift Left>"
1164 if GetClipboardText <> "3" then Warnlog "A.The paragraph is moved incorrect before accepting the changes - 2nd line"
1168 Active.SetPage TabNumerierungAbsatz
1169 Kontext "TabNumerierungAbsatz"
1170 if iComparison2$ <> Vorlage.GetSelText then Warnlog "B.The paragraph is moved incorrect before accepting the changes - 2nd line"
1171 TabNumerierungAbsatz.Cancel
1173 Call wTypeKeys "<Down><End>"
1174 Call wTypeKeys "<Shift Left>"
1176 if GetClipboardText <> "2" then Warnlog "A. The paragraph is moved incorrect before accepting the changes - 3rd line"
1180 Active.SetPage TabNumerierungAbsatz
1181 Kontext "TabNumerierungAbsatz"
1182 if iComparison1$ <> Vorlage.GetSelText then Warnlog "B . The paragraph is moved incorrect before accepting the changes - 3rd line"
1183 TabNumerierungAbsatz.Cancel
1185 '/// Edit / Changes / Accept or Reject
1186 EditChangesAcceptOrReject
1190 '/// + Select tabpage 'List' ///
1191 TabControl.SetPage TabListe
1193 '/// + Select 'Accept All'///
1194 AlleAkzeptieren.Click
1196 '/// + Close Redlining dialog
1200 '/// Check if the footnote is inserted correctly after
1201 '/// + accepting the changes
1202 Call wTypeKeys "<Up>" , 3
1203 Call wTypeKeys "<Down><End>"
1204 Call wTypeKeys "<Shift Left>"
1208 Warnlog "#i41424# Bullets cannot be removed by Del key"
1209 Call wTypeKeys "<Down><End>"
1210 Call wTypeKeys "<Shift Left>"
1213 if GetClipboardText <> "3" then Warnlog "A.The paragraph is moved incorrect after accepting the changes - 2nd line"
1217 Active.SetPage TabNumerierungAbsatz
1218 Kontext "TabNumerierungAbsatz"
1219 if iComparison2$ <> Vorlage.GetSelText then Warnlog "B.The paragraph is moved incorrect after accepting the changes - 2nd line"
1220 TabNumerierungAbsatz.Cancel
1222 Call wTypeKeys "<Down><End>"
1223 Call wTypeKeys "<Shift Left>"
1225 if GetClipboardText <> "2" then Warnlog "A. The paragraph is moved incorrect after accepting the changes - 3rd line"
1229 Active.SetPage TabNumerierungAbsatz
1230 Kontext "TabNumerierungAbsatz"
1231 if iComparison1$ <> Vorlage.GetSelText then Warnlog "The paragraph is moved incorrect after accepting the changes - 3rd line"
1232 TabNumerierungAbsatz.Cancel
1234 PrintLog "Close active documents"
1235 Do Until GetDocumentCount = 0