diff --git a/ClosedXML/Excel/EnumConverter.cs b/ClosedXML/Excel/EnumConverter.cs index e1384ca..f35d89b 100644 --- a/ClosedXML/Excel/EnumConverter.cs +++ b/ClosedXML/Excel/EnumConverter.cs @@ -463,12 +463,12 @@ { case XLPivotCalculation.Normal: return ShowDataAsValues.Normal; case XLPivotCalculation.DifferenceFrom: return ShowDataAsValues.Difference; - case XLPivotCalculation.PctOf: return ShowDataAsValues.Percent; - case XLPivotCalculation.PctDifferenceFrom: return ShowDataAsValues.PercentageDifference; + case XLPivotCalculation.PercentageOf: return ShowDataAsValues.Percent; + case XLPivotCalculation.PercentageDifferenceFrom: return ShowDataAsValues.PercentageDifference; case XLPivotCalculation.RunningTotal: return ShowDataAsValues.RunTotal; - case XLPivotCalculation.PctOfRow: return ShowDataAsValues.PercentOfRaw; // There's a typo in the OpenXML SDK =) - case XLPivotCalculation.PctOfColumn: return ShowDataAsValues.PercentOfColumn; - case XLPivotCalculation.PctOfTotal: return ShowDataAsValues.PercentOfTotal; + case XLPivotCalculation.PercentageOfRow: return ShowDataAsValues.PercentOfRaw; // There's a typo in the OpenXML SDK =) + case XLPivotCalculation.PercentageOfColumn: return ShowDataAsValues.PercentOfColumn; + case XLPivotCalculation.PercentageOfTotal: return ShowDataAsValues.PercentOfTotal; case XLPivotCalculation.Index: return ShowDataAsValues.Index; #region default @@ -1085,12 +1085,12 @@ { case ShowDataAsValues.Normal: return XLPivotCalculation.Normal; case ShowDataAsValues.Difference: return XLPivotCalculation.DifferenceFrom; - case ShowDataAsValues.Percent: return XLPivotCalculation.PctOf; - case ShowDataAsValues.PercentageDifference: return XLPivotCalculation.PctDifferenceFrom; + case ShowDataAsValues.Percent: return XLPivotCalculation.PercentageOf; + case ShowDataAsValues.PercentageDifference: return XLPivotCalculation.PercentageDifferenceFrom; case ShowDataAsValues.RunTotal: return XLPivotCalculation.RunningTotal; - case ShowDataAsValues.PercentOfRaw: return XLPivotCalculation.PctOfRow; // There's a typo in the OpenXML SDK =) - case ShowDataAsValues.PercentOfColumn: return XLPivotCalculation.PctOfColumn; - case ShowDataAsValues.PercentOfTotal: return XLPivotCalculation.PctOfTotal; + case ShowDataAsValues.PercentOfRaw: return XLPivotCalculation.PercentageOfRow; // There's a typo in the OpenXML SDK =) + case ShowDataAsValues.PercentOfColumn: return XLPivotCalculation.PercentageOfColumn; + case ShowDataAsValues.PercentOfTotal: return XLPivotCalculation.PercentageOfTotal; case ShowDataAsValues.Index: return XLPivotCalculation.Index; #region default @@ -1259,4 +1259,4 @@ } #endregion } -} \ No newline at end of file +} diff --git a/ClosedXML/Excel/PageSetup/IXLPageSetup.cs b/ClosedXML/Excel/PageSetup/IXLPageSetup.cs index 463c0ee..5376f9a 100644 --- a/ClosedXML/Excel/PageSetup/IXLPageSetup.cs +++ b/ClosedXML/Excel/PageSetup/IXLPageSetup.cs @@ -76,7 +76,7 @@ public enum XLPageOrderValues { DownThenOver, OverThenDown } public enum XLShowCommentsValues { None, AtEnd, AsDisplayed } public enum XLPrintErrorValues { Blank, Dash, Displayed, NA } - + public interface IXLPageSetup { /// @@ -178,8 +178,8 @@ /// The worksheet will be printed on as many pages as necessary to print at the given scale. /// Setting this value will override the PagesWide and PagesTall values. /// - /// The scale at which the worksheet will be printed. - void AdjustTo(Int32 pctOfNormalSize); + /// The scale at which the worksheet will be printed. + void AdjustTo(Int32 percentageOfNormalSize); /// /// Gets or sets the number of pages the worksheet will be printed on. /// This is equivalent to setting both PagesWide and PagesTall properties. diff --git a/ClosedXML/Excel/PageSetup/XLPageSetup.cs b/ClosedXML/Excel/PageSetup/XLPageSetup.cs index 5eaa80a..9aca46d 100644 --- a/ClosedXML/Excel/PageSetup/XLPageSetup.cs +++ b/ClosedXML/Excel/PageSetup/XLPageSetup.cs @@ -8,7 +8,7 @@ { public XLPageSetup(XLPageSetup defaultPageOptions, XLWorksheet worksheet) { - + if (defaultPageOptions != null) { PrintAreas = new XLPrintAreas(defaultPageOptions.PrintAreas as XLPrintAreas, worksheet); @@ -23,7 +23,7 @@ _pagesTall = defaultPageOptions.PagesTall; _pagesWide = defaultPageOptions.PagesWide; _scale = defaultPageOptions.Scale; - + if (defaultPageOptions.Margins != null) { @@ -113,7 +113,7 @@ public IXLMargins Margins { get; set; } private Int32 _pagesWide; - public Int32 PagesWide + public Int32 PagesWide { get { @@ -126,7 +126,7 @@ _scale = 0; } } - + private Int32 _pagesTall; public Int32 PagesTall { @@ -158,9 +158,9 @@ } } - public void AdjustTo(Int32 pctOfNormalSize) + public void AdjustTo(Int32 percentageOfNormalSize) { - Scale = pctOfNormalSize; + Scale = percentageOfNormalSize; _pagesWide = 0; _pagesTall = 0; } diff --git a/ClosedXML/Excel/PivotTables/PivotValues/IXLPivotValue.cs b/ClosedXML/Excel/PivotTables/PivotValues/IXLPivotValue.cs index 48c6190..1784044 100644 --- a/ClosedXML/Excel/PivotTables/PivotValues/IXLPivotValue.cs +++ b/ClosedXML/Excel/PivotTables/PivotValues/IXLPivotValue.cs @@ -24,12 +24,12 @@ { Normal, DifferenceFrom, - PctOf, - PctDifferenceFrom, + PercentageOf, + PercentageDifferenceFrom, RunningTotal, - PctOfRow, - PctOfColumn, - PctOfTotal, + PercentageOfRow, + PercentageOfColumn, + PercentageOfTotal, Index } public enum XLPivotCalculationItem @@ -59,12 +59,12 @@ IXLPivotValue ShowAsNormal(); IXLPivotValueCombination ShowAsDifferenceFrom(String fieldSourceName); - IXLPivotValueCombination ShowAsPctFrom(String fieldSourceName); - IXLPivotValueCombination ShowAsPctDifferenceFrom(String fieldSourceName); + IXLPivotValueCombination ShowAsPercentageFrom(String fieldSourceName); + IXLPivotValueCombination ShowAsPercentageDifferenceFrom(String fieldSourceName); IXLPivotValue ShowAsRunningTotalIn(String fieldSourceName); - IXLPivotValue ShowAsPctOfRow(); - IXLPivotValue ShowAsPctOfColumn(); - IXLPivotValue ShowAsPctOfTotal(); + IXLPivotValue ShowAsPercentageOfRow(); + IXLPivotValue ShowAsPercentageOfColumn(); + IXLPivotValue ShowAsPercentageOfTotal(); IXLPivotValue ShowAsIndex(); } diff --git a/ClosedXML/Excel/PivotTables/PivotValues/XLPivotValue.cs b/ClosedXML/Excel/PivotTables/PivotValues/XLPivotValue.cs index 37ec344..e3ef842 100644 --- a/ClosedXML/Excel/PivotTables/PivotValues/XLPivotValue.cs +++ b/ClosedXML/Excel/PivotTables/PivotValues/XLPivotValue.cs @@ -34,16 +34,16 @@ SetCalculation(XLPivotCalculation.DifferenceFrom); return new XLPivotValueCombination(this); } - public IXLPivotValueCombination ShowAsPctFrom(String fieldSourceName) + public IXLPivotValueCombination ShowAsPercentageFrom(String fieldSourceName) { BaseField = fieldSourceName; - SetCalculation(XLPivotCalculation.PctOf); + SetCalculation(XLPivotCalculation.PercentageOf); return new XLPivotValueCombination(this); } - public IXLPivotValueCombination ShowAsPctDifferenceFrom(String fieldSourceName) + public IXLPivotValueCombination ShowAsPercentageDifferenceFrom(String fieldSourceName) { BaseField = fieldSourceName; - SetCalculation(XLPivotCalculation.PctDifferenceFrom); + SetCalculation(XLPivotCalculation.PercentageDifferenceFrom); return new XLPivotValueCombination(this); } public IXLPivotValue ShowAsRunningTotalIn(String fieldSourceName) @@ -51,19 +51,19 @@ BaseField = fieldSourceName; return SetCalculation(XLPivotCalculation.RunningTotal); } - public IXLPivotValue ShowAsPctOfRow() + public IXLPivotValue ShowAsPercentageOfRow() { - return SetCalculation(XLPivotCalculation.PctOfRow); + return SetCalculation(XLPivotCalculation.PercentageOfRow); } - public IXLPivotValue ShowAsPctOfColumn() + public IXLPivotValue ShowAsPercentageOfColumn() { - return SetCalculation(XLPivotCalculation.PctOfColumn); + return SetCalculation(XLPivotCalculation.PercentageOfColumn); } - public IXLPivotValue ShowAsPctOfTotal() + public IXLPivotValue ShowAsPercentageOfTotal() { - return SetCalculation(XLPivotCalculation.PctOfTotal); + return SetCalculation(XLPivotCalculation.PercentageOfTotal); } public IXLPivotValue ShowAsIndex()