mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
spelling: locals in src/System.Management.Automation/commands
This commit is contained in:
1 parent
498800160e
commit
c75e01a02f
7 files changed
+24
-24
No files matched your search
+5
-5
@@ -154,7 +154,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
hash.Add (FormatParameterDefinitionKeys.WidthEntryKey, width);
|
||||
|
||||
if (align != null)
|
||||
hash.Add (FormatParameterDefinitionKeys.AligmentEntryKey, align);
|
||||
hash.Add (FormatParameterDefinitionKeys.AlignmentEntryKey, align);
|
||||
|
||||
return hash;
|
||||
}
|
||||
@@ -244,9 +244,9 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
private bool _noGlobbing;
|
||||
}
|
||||
|
||||
internal class AligmentEntryDefinition : HashtableEntryDefinition
|
||||
internal class AlignmentEntryDefinition : HashtableEntryDefinition
|
||||
{
|
||||
internal AligmentEntryDefinition() : base(FormatParameterDefinitionKeys.AligmentEntryKey,
|
||||
internal AlignmentEntryDefinition() : base(FormatParameterDefinitionKeys.AlignmentEntryKey,
|
||||
new Type[] { typeof(string) })
|
||||
{
|
||||
}
|
||||
@@ -414,7 +414,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
internal const string FormatStringEntryKey = "formatString";
|
||||
|
||||
// specific to format-table
|
||||
internal const string AligmentEntryKey = "alignment";
|
||||
internal const string AlignmentEntryKey = "alignment";
|
||||
internal const string WidthEntryKey = "width";
|
||||
|
||||
// specific to format-table,list and wide
|
||||
@@ -453,7 +453,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
{
|
||||
base.SetEntries();
|
||||
this.hashEntries.Add(new WidthEntryDefinition());
|
||||
this.hashEntries.Add(new AligmentEntryDefinition());
|
||||
this.hashEntries.Add(new AlignmentEntryDefinition());
|
||||
this.hashEntries.Add(new LabelEntryDefinition());
|
||||
}
|
||||
}
|
||||
|
||||
+4
-4
@@ -920,7 +920,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
columnWidthsHint = tableHint.columnWidths;
|
||||
}
|
||||
|
||||
int columsOnTheScreen = this.InnerCommand._lo.ColumnNumber;
|
||||
int columnsOnTheScreen = this.InnerCommand._lo.ColumnNumber;
|
||||
|
||||
int columns = this.CurrentTableHeaderInfo.tableColumnInfoList.Count;
|
||||
if (columns == 0)
|
||||
@@ -939,7 +939,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
alignment[k] = tci.alignment;
|
||||
k++;
|
||||
}
|
||||
this.Writer.Initialize(0, columsOnTheScreen, columnWidths, alignment, this.CurrentTableHeaderInfo.hideHeader);
|
||||
this.Writer.Initialize(0, columnsOnTheScreen, columnWidths, alignment, this.CurrentTableHeaderInfo.hideHeader);
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
@@ -1200,7 +1200,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
return;
|
||||
}
|
||||
|
||||
string[] values = new string[_buffer.Lenght];
|
||||
string[] values = new string[_buffer.Length];
|
||||
for (int k = 0; k < values.Length; k++)
|
||||
{
|
||||
if (k < _buffer.CurrentCount)
|
||||
@@ -1231,7 +1231,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
/// <summary>
|
||||
/// get the size of the buffer
|
||||
/// </summary>
|
||||
internal int Lenght { get { return _arr.Length; } }
|
||||
internal int Length { get { return _arr.Length; } }
|
||||
|
||||
/// <summary>
|
||||
/// get the current number of entries in the buffer
|
||||
|
||||
+6
-6
@@ -349,8 +349,8 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
if (Database == null)
|
||||
{
|
||||
TypeInfoDataBase tempDataBase = new TypeInfoDataBase();
|
||||
AddPreLoadInstrinsics(tempDataBase);
|
||||
AddPostLoadInstrinsics(tempDataBase);
|
||||
AddPreLoadIntrinsics(tempDataBase);
|
||||
AddPostLoadIntrinsics(tempDataBase);
|
||||
Database = tempDataBase;
|
||||
}
|
||||
}
|
||||
@@ -393,7 +393,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
TypeInfoDataBase db = new TypeInfoDataBase();
|
||||
|
||||
// prepopulate the database with any necessary overriding data
|
||||
AddPreLoadInstrinsics(db);
|
||||
AddPreLoadIntrinsics(db);
|
||||
|
||||
var etwEnabled = RunspaceEventSource.Log.IsEnabled();
|
||||
|
||||
@@ -439,7 +439,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
}
|
||||
|
||||
// add any sensible defaults to the database
|
||||
AddPostLoadInstrinsics(db);
|
||||
AddPostLoadIntrinsics(db);
|
||||
|
||||
return db;
|
||||
}
|
||||
@@ -534,7 +534,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
/// helper to to add any pre-load intrinsics to the db
|
||||
/// </summary>
|
||||
/// <param name="db">db being initialized</param>
|
||||
private static void AddPreLoadInstrinsics(TypeInfoDataBase db)
|
||||
private static void AddPreLoadIntrinsics(TypeInfoDataBase db)
|
||||
{
|
||||
// NOTE: nothing to add for the time being. Add here if needed.
|
||||
}
|
||||
@@ -543,7 +543,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
/// helper to to add any post-load intrinsics to the db
|
||||
/// </summary>
|
||||
/// <param name="db">db being initialized</param>
|
||||
private static void AddPostLoadInstrinsics(TypeInfoDataBase db)
|
||||
private static void AddPostLoadIntrinsics(TypeInfoDataBase db)
|
||||
{
|
||||
// add entry for the output of update-formatdata
|
||||
// we want to be able to display this as a list, unless overridden
|
||||
|
||||
+3
-3
@@ -158,9 +158,9 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
internal const string True = "TRUE";
|
||||
internal const string False = "FALSE";
|
||||
|
||||
internal const string AligmentLeft = "left";
|
||||
internal const string AligmentCenter = "center";
|
||||
internal const string AligmentRight = "right";
|
||||
internal const string AlignmentLeft = "left";
|
||||
internal const string AlignmentCenter = "center";
|
||||
internal const string AlignmentRight = "right";
|
||||
}
|
||||
|
||||
// Flag that determines whether validation should be suppressed while
|
||||
|
||||
+3
-3
@@ -270,15 +270,15 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
return false; // fatal error
|
||||
}
|
||||
|
||||
if (string.Equals(n.InnerText, XMLStringValues.AligmentLeft, StringComparison.OrdinalIgnoreCase))
|
||||
if (string.Equals(n.InnerText, XMLStringValues.AlignmentLeft, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
alignmentValue = TextAlignment.Left;
|
||||
}
|
||||
else if (string.Equals(n.InnerText, XMLStringValues.AligmentRight, StringComparison.OrdinalIgnoreCase))
|
||||
else if (string.Equals(n.InnerText, XMLStringValues.AlignmentRight, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
alignmentValue = TextAlignment.Right;
|
||||
}
|
||||
else if (string.Equals(n.InnerText, XMLStringValues.AligmentCenter, StringComparison.OrdinalIgnoreCase))
|
||||
else if (string.Equals(n.InnerText, XMLStringValues.AlignmentCenter, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
alignmentValue = TextAlignment.Center;
|
||||
}
|
||||
|
||||
+1
-1
@@ -255,7 +255,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
// set the alignment
|
||||
if (a.OriginatingParameter != null)
|
||||
{
|
||||
object key = a.OriginatingParameter.GetEntry(FormatParameterDefinitionKeys.AligmentEntryKey);
|
||||
object key = a.OriginatingParameter.GetEntry(FormatParameterDefinitionKeys.AlignmentEntryKey);
|
||||
|
||||
if (key != AutomationNull.Value)
|
||||
ci.alignment = (int)key;
|
||||
|
||||
+2
-2
@@ -308,7 +308,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
return rows;
|
||||
}
|
||||
|
||||
private StringCollection GenerateMultiLineRowField(string val, int k, int aligment, DisplayCells dc)
|
||||
private StringCollection GenerateMultiLineRowField(string val, int k, int alignment, DisplayCells dc)
|
||||
{
|
||||
StringCollection sc = StringManipulationHelper.GenerateLines(dc, val,
|
||||
_si.columnInfo[k].width, _si.columnInfo[k].width);
|
||||
@@ -316,7 +316,7 @@ namespace Microsoft.PowerShell.Commands.Internal.Format
|
||||
for (int col = 0; col < sc.Count; col++)
|
||||
{
|
||||
if (dc.Length(sc[col]) < _si.columnInfo[k].width)
|
||||
sc[col] = GenerateRowField(sc[col], _si.columnInfo[k].width, aligment, dc);
|
||||
sc[col] = GenerateRowField(sc[col], _si.columnInfo[k].width, alignment, dc);
|
||||
}
|
||||
return sc;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user