diff options
author | Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> | 2015-05-20 13:05:49 +0200 |
---|---|---|
committer | Christian Lohmaier <lohmaier+LibreOffice@googlemail.com> | 2015-05-20 13:05:49 +0200 |
commit | ab465b90f6c6da5595393a0ba73f33a1e71a2b65 (patch) | |
tree | 36b77192de2799a11b4bf0b269cb3f74d0a0bb1f /sw/qa/complex | |
parent | 0db96caf0fcce09b87621c11b584a6d81cc7df86 (diff) |
bin/rename-sw-abbreviations.sh
libreoffice-5-0-branch-point
renames the most annoying abbreviations in Writer (and partially
in the shared code too).
Change-Id: I9a62759138126c1537cc5c985ba05cf54d6132d9
Diffstat (limited to 'sw/qa/complex')
-rw-r--r-- | sw/qa/complex/accessibility/AccessibleRelationSet.java | 12 | ||||
-rw-r--r-- | sw/qa/complex/writer/CheckCrossReferences.java | 112 | ||||
-rw-r--r-- | sw/qa/complex/writer/CheckTable.java | 2 |
3 files changed, 63 insertions, 63 deletions
diff --git a/sw/qa/complex/accessibility/AccessibleRelationSet.java b/sw/qa/complex/accessibility/AccessibleRelationSet.java index 562bcfe98d7e..b1d0b4cc58ea 100644 --- a/sw/qa/complex/accessibility/AccessibleRelationSet.java +++ b/sw/qa/complex/accessibility/AccessibleRelationSet.java @@ -71,11 +71,11 @@ public class AccessibleRelationSet { "didn't gain correct relation type for paragraph 0", types[2], types[firstrelation]); - XAccessibleText paraTxt2 = + XAccessibleText paraText2 = UnoRuntime.queryInterface(XAccessibleText.class, para2); assertEquals( "didn't gain correct target paragraph", atarget.getText(), - paraTxt2.getText()); + paraText2.getText()); } @Test public void contents_flows_from() { @@ -131,21 +131,21 @@ public class AccessibleRelationSet { "didn't gain correct relation type for paragraph 1", types[1], types[relationtypes[0]]); - XAccessibleText paraTxt1 = + XAccessibleText paraText1 = UnoRuntime.queryInterface(XAccessibleText.class, para1); assertEquals( "didn't gain correct target paragraph", atargets[0].getText(), - paraTxt1.getText()); + paraText1.getText()); assertEquals( "didn't gain correct relation type for paragraph 3", types[2], types[relationtypes[1]]); - XAccessibleText paraTxt3 = + XAccessibleText paraText3 = UnoRuntime.queryInterface(XAccessibleText.class, para3); assertEquals( "didn't gain correct target paragraph", atargets[1].getText(), - paraTxt3.getText()); + paraText3.getText()); } @Before public void before() diff --git a/sw/qa/complex/writer/CheckCrossReferences.java b/sw/qa/complex/writer/CheckCrossReferences.java index 508ca6cf6a04..651604b439b7 100644 --- a/sw/qa/complex/writer/CheckCrossReferences.java +++ b/sw/qa/complex/writer/CheckCrossReferences.java @@ -33,7 +33,7 @@ public class CheckCrossReferences { private com.sun.star.container.XEnumeration xParaEnum; private com.sun.star.container.XEnumeration xPortionEnum; - private com.sun.star.util.XRefreshable xFldsRefresh; + private com.sun.star.util.XRefreshable xFieldsRefresh; public com.sun.star.text.XTextField getNextField() throws com.sun.star.uno.Exception @@ -86,18 +86,18 @@ public class CheckCrossReferences { public void checkField( com.sun.star.text.XTextField xField, com.sun.star.beans.XPropertySet xProps, short nFormat, - String aExpectedFldResult ) + String aExpectedFieldResult ) throws com.sun.star.uno.Exception { // set requested format xProps.setPropertyValue("ReferenceFieldPart", Short.valueOf(nFormat)); // refresh fields in order to get new format applied - xFldsRefresh.refresh(); + xFieldsRefresh.refresh(); - String aFldResult = xField.getPresentation( false ); + String aFieldResult = xField.getPresentation( false ); assertEquals( "set reference field format doesn't result in correct field result", - aExpectedFldResult, aFldResult); + aExpectedFieldResult, aFieldResult); } @Test public void checkCrossReferences() throws com.sun.star.uno.Exception { @@ -114,25 +114,25 @@ public class CheckCrossReferences { com.sun.star.text.XTextFieldsSupplier xFieldSupp = UnoRuntime.queryInterface( com.sun.star.text.XTextFieldsSupplier.class, document); - xFldsRefresh = UnoRuntime.queryInterface( + xFieldsRefresh = UnoRuntime.queryInterface( com.sun.star.util.XRefreshable.class, xFieldSupp.getTextFields()); } // check first reference field { // strings for checking - final String FldResult1 = "*i*"; - final String FldResult2 = "+b+*i*"; - final String FldResult3 = "-1-+b+*i*"; - final String FldResult4 = "1"; - final String FldResult5 = "1"; - final String FldResult6 = "A.1"; - final String FldResult7 = "2(a)"; - final String FldResult8 = "2(b)"; - final String FldResult9 = "2"; - final String FldResult10 = "1(a)"; - final String FldResult11 = "(b)"; - final String FldResult12 = "(a)"; + final String FieldResult1 = "*i*"; + final String FieldResult2 = "+b+*i*"; + final String FieldResult3 = "-1-+b+*i*"; + final String FieldResult4 = "1"; + final String FieldResult5 = "1"; + final String FieldResult6 = "A.1"; + final String FieldResult7 = "2(a)"; + final String FieldResult8 = "2(b)"; + final String FieldResult9 = "2"; + final String FieldResult10 = "1(a)"; + final String FieldResult11 = "(b)"; + final String FieldResult12 = "(a)"; // variables for current field com.sun.star.text.XTextField xField = null; @@ -140,75 +140,75 @@ public class CheckCrossReferences { xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult2 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult1 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult3 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult2 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult1 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult3 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult1 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult1 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult3 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult1 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult1 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult3 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult3 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult1 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult3 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult3 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult1 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult3 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult5 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult6 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult5 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult6 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult6 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult6 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult6 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult6 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult6 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult6 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult7 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult12 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult7 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult7 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult12 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult7 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult8 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult11 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult8 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult8 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult11 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult8 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult9 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult9 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult9 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult9 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult9 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult9 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult4 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult4 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult4 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult10 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult12 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult10 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult10 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult12 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult10 ); xField = getNextField(); xProps = getFieldProps( xField ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FldResult12 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FldResult12 ); - checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FldResult7 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER, FieldResult12 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_NO_CONTEXT, FieldResult12 ); + checkField( xField, xProps, com.sun.star.text.ReferenceFieldPart.NUMBER_FULL_CONTEXT, FieldResult7 ); } // insert a certain cross-reference bookmark and a reference field to this bookmark @@ -267,7 +267,7 @@ public class CheckCrossReferences { UnoRuntime.queryInterface( com.sun.star.text.XTextRange.class, xParaEnum.nextElement()); xNewField.attach(xFieldTextRange.getEnd()); - xFldsRefresh.refresh(); + xFieldsRefresh.refresh(); } // check inserted reference field @@ -278,7 +278,7 @@ public class CheckCrossReferences { "J", xField.getPresentation( false ) ); xParaTextRange.getStart().setString( "Hallo new bookmark: " ); - xFldsRefresh.refresh(); + xFieldsRefresh.refresh(); assertEquals( "inserted reference field doesn't has correct field result", "Hallo new bookmark: J", xField.getPresentation( false ) ); } diff --git a/sw/qa/complex/writer/CheckTable.java b/sw/qa/complex/writer/CheckTable.java index 83b92da818f8..e4d33d3ee6f1 100644 --- a/sw/qa/complex/writer/CheckTable.java +++ b/sw/qa/complex/writer/CheckTable.java @@ -275,7 +275,7 @@ public class CheckTable // get anchor XTextRange xAnchor = xTable.getAnchor(); // check all properties on the anchor - shouldn't crash despite - // pointing to a non-SwTxtNode + // pointing to a non-SwTextNode XPropertySet xProps = UnoRuntime.queryInterface(XPropertySet.class, xAnchor); XPropertySetInfo xPropsInfo = xProps.getPropertySetInfo(); Property[] props = xPropsInfo.getProperties(); |