Created
October 26, 2023 14:11
-
-
Save bjoerntx/ed4e5ce4dbd1c452a6126c86e2b67e38 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private bool IsParagraphFormatEqual(ParagraphFormat format1, ParagraphFormat format2) | |
{ | |
foreach (var property in typeof(ParagraphFormat).GetProperties()) | |
{ | |
if (_positiveListParagraphFormat.Contains(property.Name)) | |
{ | |
object value1 = property.GetValue(format1); | |
object value2 = property.GetValue(format2); | |
if (!object.Equals(value1, value2)) | |
{ | |
return false; | |
} | |
} | |
} | |
return true; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment