Skip to content

Commit

Permalink
spell check corrections
Browse files Browse the repository at this point in the history
  • Loading branch information
tomjebo committed Jun 27, 2023
1 parent c5168fc commit 5fff7f7
Show file tree
Hide file tree
Showing 24 changed files with 32 additions and 32 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -47,9 +47,9 @@ private static void Initialize()

// root.Category = "1.1";

// Category modality is compsed by a keywords sequence.
// Category modality is composed by a keywords sequence.
// Only operator and function name are treated as keyword in schematron.
// Single category may have mutiple modalities due to optional parameters.
// Single category may have multiple modalities due to optional parameters.
AddCategoryModality("1.1", new string[] { "@" }, -1, -1);

AddCategoryModality("1.2", new string[] { "fn:matches", "@" }, -1, -1);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,11 +85,11 @@ private static void InitializeWeightDictionary()
/// <summary>
/// Identify keyword from specified text.
/// </summary>
/// <param name="text">Source text from which this method will indentify keyword.</param>
/// <param name="text">Source text from which this method will identify keyword.</param>
/// <param name="pos">
/// Index of specified text.
/// As input, it specifies start index of idenfication.
/// As output, it specifies index of matched keyword's last character in soure text.
/// As input, it specifies start index of identification.
/// As output, it specifies index of matched keyword's last character in source text.
/// i.e. if test="A KEYWORD B", matchedKeyword="KEYWORD" then pos=8 (index of 'D' in "A KEYWORD B").
/// </param>
/// <param name="keywordCandidates">Keyword candidates.</param>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ namespace DocumentFormat.OpenXml.Features
{
internal static class ElementEventFeatureExtensions
{
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Regsitered for disposal")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Registered for disposal")]
public static void AddElementEventFeature(this OpenXmlPackage package)
{
if (package.Features.Get<IElementEventFeature>() is null)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ public static class ParagraphIdFeatureExtensions
/// </summary>
/// <param name="doc">Document to add feature to.</param>
/// <param name="options">Options of how paragraph ids should be generated.</param>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Regsitered for disposal")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Registered for disposal")]
public static void AddParagraphIdFeature(this WordprocessingDocument doc, ParagraphIdOptions? options = default)
{
options ??= new();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ namespace DocumentFormat.OpenXml.Features
public class ParagraphIdOptions
{
/// <summary>
/// Gets a value indicating whether or not paragraph ids should be autogenerated on elements.
/// Gets a value indicating whether or not paragraph ids should be auto-generated on elements.
/// </summary>
public bool AutoGenerateIds { get; init; } = true;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,12 @@ public static ISharedFeature<IParagraphIdCollectionFeature> AddSharedParagraphId
}

/// <summary>
/// Registers a document to use a shared paragragraph collection, which potentially may ensure uniqueness among many documents.
/// Registers a document to use a shared paragraph collection, which potentially may ensure uniqueness among many documents.
/// </summary>
/// <param name="shared">Shared collection feature.</param>
/// <param name="doc">Document to register with shared paragraph collection.</param>
/// <returns></returns>
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Regsitered for disposal")]
[System.Diagnostics.CodeAnalysis.SuppressMessage("Reliability", "CA2000:Dispose objects before losing scope", Justification = "Registered for disposal")]
public static ISharedFeature<IParagraphIdCollectionFeature> Add(this ISharedFeature<IParagraphIdCollectionFeature> shared, WordprocessingDocument doc)
{
if (shared is null)
Expand Down
2 changes: 1 addition & 1 deletion src/DocumentFormat.OpenXml.Framework/DiagnosticIds.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ internal static class ExperimentalApis
internal static class PackageApis
{
public const string DiagnosticId = "OOXML0001";
public const string Message = "IPackage related APIs are currently experimental. Future versions may (or may not) change their shape before stabalizing.";
public const string Message = "IPackage related APIs are currently experimental. Future versions may (or may not) change their shape before stabilizing.";
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ namespace DocumentFormat.OpenXml.Features
public static class PartRootEventExtensions
{
/// <summary>
/// Adds a feature to track eventing for a package lifecycle events.
/// Adds a feature to track eventing for package life cycle events.
/// </summary>
/// <param name="container">Container to add the feature to.</param>
public static void AddPartRootEventsFeature(this OpenXmlPartContainer container)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Each element in the SDK is derived from the XSD definitions for OpenXML document
The particles within this SDK are of the following types:

- *Element:* Defines the actual child element.
- *Group:* Defines a reuseable group of child elements that are combined into the parent composite particle.
- *Group:* Defines a reusable group of child elements that are combined into the parent composite particle.
- *Sequence:* Defines a list of items where order matters.
- *All:* Defines a list of items where order does not matter.
- *Choice:* Defines a list of items where only one of them may occur.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -696,7 +696,7 @@ private protected override void Populate(XmlReader xmlReader, OpenXmlLoadMode lo

if (newnode is not OpenXmlUnknownElement)
{
// The following method will load teh element in MCMode.Full
// The following method will load the element in MCMode.Full
// since the node is already MC-processed when loading as unknown type, full loading the outerXml is fine
newnode.OuterXml = node.OuterXml;

Expand Down
2 changes: 1 addition & 1 deletion src/DocumentFormat.OpenXml.Framework/OpenXmlElement.cs
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ private protected Framework.Metadata.ElementState RawState
internal IElementMetadata Metadata => Features.GetRequired<IElementMetadata>();

/// <summary>
/// Gets an array of fixed attributes which will be parsed out if they are not yet parsed. If parsing is not requried, please
/// Gets an array of fixed attributes which will be parsed out if they are not yet parsed. If parsing is not required, please
/// use <see cref="RawState"/>.
/// </summary>
internal Framework.Metadata.ElementState ParsedState
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,7 @@ internal static bool CanContainChild(this OpenXmlElement parent, OpenXmlElement
}

/// <summary>
/// Trys to create an OpenXmlElement from the specified namespace URI and local name.
/// Tries to create an OpenXmlElement from the specified namespace URI and local name.
/// </summary>
/// <param name="parent">The parent element.</param>
/// <param name="fileFormat">The specified file format version.</param>
Expand Down
4 changes: 2 additions & 2 deletions src/DocumentFormat.OpenXml.Framework/OpenXmlPartReader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ public OpenXmlPartReader(OpenXmlPart openXmlPart)
/// <summary>
/// Initializes a new instance of the <see cref="OpenXmlPartReader"/> class.
/// </summary>
/// <param name="openXmlPart">The <see cref="OpenXmlPart"/> ro read.</param>
/// <param name="openXmlPart">The <see cref="OpenXmlPart"/> to read.</param>
/// <param name="options">Options on how to read the part.</param>
public OpenXmlPartReader(OpenXmlPart openXmlPart, OpenXmlPartReaderOptions options)
: this(GetPartStream(openXmlPart), openXmlPart.Features, options.UpdateForPart(openXmlPart))
Expand Down Expand Up @@ -719,7 +719,7 @@ private bool ReadRoot()
Debug.Assert(_elementStack.Count == 0);

// TODO: should we take care of entity? <!DOCTYPE page [ <!ENTITY company "Microsoft"> ]>
// TODO: is it OK that we skip all prolog ( DOCTYPE, Comment, PT ) ?
// TODO: is it OK that we skip all prologue ( DOCTYPE, Comment, PT ) ?
_xmlReader.MoveToContent();

while (!_xmlReader.EOF && _xmlReader.NodeType != XmlNodeType.Element)
Expand Down
2 changes: 1 addition & 1 deletion src/DocumentFormat.OpenXml.Framework/Packaging/IPackage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ public interface IPackage
/// <summary>
/// Deletes a part with a given URI from the package.
/// </summary>
/// <param name="uri">The URI fo the part to delete.</param>
/// <param name="uri">The URI of the part to delete.</param>
void DeletePart(Uri uri);

/// <summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -350,7 +350,7 @@ internal IPackagePart PackagePart
/// Gets a value that indicates the maximum allowable number of characters in an Open XML part. A zero (0) value specifies that the part can have an unlimited number of characters. A non-zero value specifies the maximum allowable number of characters in the part.
/// </summary>
/// <remarks>
/// This property allows you to mitigate denial of service attacks where the attacker submits package with extremely large Opexn XML part. By limiting the size of a part, you can detect the attack and recover reliably.
/// This property allows you to mitigate denial of service attacks where the attacker submits package with extremely large Open XML part. By limiting the size of a part, you can detect the attack and recover reliably.
/// </remarks>
internal long MaxCharactersInPart
{
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@
<value>Schemas with ParticleType.Any is not supported</value>
</data>
<data name="UnknownError" xml:space="preserve">
<value>An unknown error occured. Original message: '{0}'</value>
<value>An unknown error occurred. Original message: '{0}'</value>
</data>
<data name="FeatureNotRegistered" xml:space="preserve">
<value>Feature {0} is not available in this collection.</value>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public ValidationContext(IOpenXmlNamespaceResolver resolver, ValidationSettings
public bool Valid => Errors.Count == 0;

/// <summary>
/// If a <see cref="CancellationToken"/> is used and is cancelled, this will throw. Otherwise, it will
/// If a <see cref="CancellationToken"/> is used and is canceled, this will throw. Otherwise, it will
/// check the number of errors against the <see cref="MaxNumberOfErrors"/>.
/// </summary>
/// <returns><c>true</c> if error count is too high.</returns>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ public void ChangeDocumentType(SpreadsheetDocumentType newType)
/// </summary>
/// <typeparam name="T">The class of the part.</typeparam>
/// <param name="contentType">The content type of the part. Must match the defined content type if the part is fixed content type.</param>
/// <param name="id">The relationship id. The id will be automaticly generated if this param is null.</param>
/// <param name="id">The relationship id. The id will be automatically generated if this param is null.</param>
/// <returns>The added part.</returns>
/// <exception cref="OpenXmlPackageException">When the part is not allowed to be referenced by this part.</exception>
/// <exception cref="ArgumentOutOfRangeException">When the part is fixed content type and the passed in contentType does not match the defined content type.</exception>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,7 @@ public void ChangeDocumentType(WordprocessingDocumentType newType)
/// </summary>
/// <typeparam name="T">The class of the part.</typeparam>
/// <param name="contentType">The content type of the part. Must match the defined content type if the part is fixed content type.</param>
/// <param name="id">The relationship id. The id will be automaticly generated if this param is null.</param>
/// <param name="id">The relationship id. The id will be automatically generated if this param is null.</param>
/// <returns>The added part.</returns>
/// <exception cref="OpenXmlPackageException">When the part is not allowed to be referenced by this part.</exception>
/// <exception cref="ArgumentOutOfRangeException">When the part is fixed content type and the passed in contentType does not match the defined content type.</exception>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ public static class PowerPoint
public const string HCrestoredLeft_NormalViewRestoredTop_sz_100000_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]restoredLeft-NormalViewRestoredTop-sz-100000.pptx";
public const string HCsndtgt_SoundTarget_builtIn_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]sndtgt-SoundTarget-builtIn.pptx";
public const string HCtavlst_Time_tav_tm_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]tavlst-Time-tav-tm.pptx";
public const string HCval_Boolean_Varient_boolVal_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]val-Boolean Varient-boolVal.pptx";
public const string HCval_Boolean_Variant_boolVal_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]val-Boolean Variant-boolVal.pptx";
public const string HCviewPr_PresentationViewProperties_showComments_1_pptx = "TestDataStorage.O14ISOStrict.PowerPoint.[HC]viewPr-PresentationViewProperties-showComments-1.pptx";
}
}
Expand Down Expand Up @@ -289,13 +289,13 @@ public static class Smallset
public const string AllSlidesConverterSc = "TestDataStorage.v2FxTestFiles.presentation.AllSlidesConverterSC.pptx";
public const string AllSlidesConverterTc = "TestDataStorage.v2FxTestFiles.presentation.AllSlidesConverterTC.pptx";
public const string AutoShapes_2D_Default_styles = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_2D (Default Styles).pptx";
public const string AutoShapes_2D_Reflection = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_2D_Reflectioin (full).pptx";
public const string AutoShapes_2D_Reflection = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_2D_Reflection (full).pptx";
public const string AutoShapes_2D_Shadow = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_2D_Shadow (Offset, Diagonal).pptx";
public const string AutoShapes_2D_Soft_Edges = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_2D_Soft Edges (5 Point).pptx";
public const string AutoShapes_3D_Bevel_Circle_Shadow = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Bevel (Circle)+Shadow (Offset, Diagonal).pptx";
public const string AutoShapes_3D_Bevel_Circle_Soft_Edges = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Bevel (Circle)+Soft Edges (5 Point).pptx";
public const string AutoShapes_3D_Bevel_Circle = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Bevel (Circle).pptx";
public const string AutoShapes_3D_Bevel_Riblet_Reflection = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Bevel (Riblet)+Reflectioin (full).pptx";
public const string AutoShapes_3D_Bevel_Riblet_Reflection = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Bevel (Riblet)+Reflection (full).pptx";
public const string AutoShapes_3D_Rotation_Parallel = "TestDataStorage.v2FxTestFiles.presentation.AutoShapes_3D_Rotation_Parallel (Isometric Right Up).pptx";
public const string Block_hyperlink_crash = "TestDataStorage.v2FxTestFiles.presentation.block_hyperlink_crash.pptx";
public const string Chart_2D_Animation_Box_In_One_Object = "TestDataStorage.v2FxTestFiles.presentation.Chart_2D+Animation (Box In, as one object).pptx";
Expand Down
Binary file not shown.
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ namespace DocumentFormat.OpenXml.Tests.CommentEx
public static class Commons
{
/// <summary>
/// Comment object, Get support mothod.
/// Comment object, Get support method.
/// </summary>
/// <param name="commentsPart">Target comment include commentsPart</param>
/// <param name="commentID">Comment ID</param>
Expand All @@ -31,7 +31,7 @@ public static Comment GetComment(WordprocessingCommentsPart commentsPart, string
}

/// <summary>
/// CommentEx object, Get support mothod.
/// CommentEx object, Get support method.
/// </summary>
/// <param name="commentsPart">Target comment include commentsPart</param>
/// <param name="commentsExPart">Target comment include commentsExPart</param>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -136,10 +136,10 @@ private static void AddChildIdPartPairs(IList<IdPartPair> list, OpenXmlPartConta
}

/// <summary>
/// Check if current part is reflectable (with xml content).
/// Check if current part is reflect-able (with xml content).
/// </summary>
/// <param name="part">Current part</param>
/// <returns>return true if it has non-null root element, otherwise rturn false.</returns>
/// <returns>return true if it has non-null root element, otherwise return false.</returns>
public static bool IsReflectable(this OpenXmlPart part)
{
if (part is null)
Expand Down

0 comments on commit 5fff7f7

Please sign in to comment.