diff --git a/Xceed.Document.NET/AssemblyVersionInfo.cs b/Xceed.Document.NET/AssemblyVersionInfo.cs index c034dc61..78b7f293 100644 --- a/Xceed.Document.NET/AssemblyVersionInfo.cs +++ b/Xceed.Document.NET/AssemblyVersionInfo.cs @@ -1,31 +1,31 @@ -/*************************************************************************************** +///*************************************************************************************** - DocX – DocX is the community edition of Xceed Words for .NET +// DocX – DocX is the community edition of Xceed Words for .NET - Copyright (C) 2009-2017 Xceed Software Inc. +// Copyright (C) 2009-2017 Xceed Software Inc. - This program is provided to you under the terms of the Microsoft Public - License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license +// This program is provided to you under the terms of the Microsoft Public +// License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license - For more features and fast professional support, - pick up Xceed Words for .NET at https://xceed.com/xceed-words-for-net/ +// For more features and fast professional support, +// pick up Xceed Words for .NET at https://xceed.com/xceed-words-for-net/ - *************************************************************************************/ +// *************************************************************************************/ -#pragma warning disable 0436 -[assembly: System.Reflection.AssemblyVersion( _XceedVersionInfo.Version )] -#pragma warning restore 0436 +//#pragma warning disable 0436 +//[assembly: System.Reflection.AssemblyVersion( _XceedVersionInfo.Version )] +//#pragma warning restore 0436 -internal static class _XceedVersionInfo -{ - [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] - public const string BaseVersion = "1.4"; - [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] - public const string Version = BaseVersion + - ".0.0"; - [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] - public const string PublicKeyToken = "ba83ff368b7563c6"; +//internal static class _XceedVersionInfo +//{ +// [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] +// public const string BaseVersion = "1.4"; +// [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] +// public const string Version = BaseVersion + +// ".0.0"; +// [System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] +// public const string PublicKeyToken = "ba83ff368b7563c6"; -} +//} diff --git a/Xceed.Document.NET/AssemblyVersionInfoCommon.cs b/Xceed.Document.NET/AssemblyVersionInfoCommon.cs deleted file mode 100644 index 4beadfcf..00000000 --- a/Xceed.Document.NET/AssemblyVersionInfoCommon.cs +++ /dev/null @@ -1,21 +0,0 @@ -/*************************************************************************************** - - DocX – DocX is the community edition of Xceed Words for .NET - - Copyright (C) 2009-2017 Xceed Software Inc. - - This program is provided to you under the terms of the Microsoft Public - License (Ms-PL) as published at http://wpftoolkit.codeplex.com/license - - For more features and fast professional support, - pick up Xceed Words for .NET at https://xceed.com/xceed-words-for-net/ - - *************************************************************************************/ - - -internal static class _XceedVersionInfoCommon -{ -[System.Diagnostics.CodeAnalysis.SuppressMessage( "Microsoft.Performance", "CA1823:AvoidUnusedPrivateFields" )] - public const string Build = ".*"; - -} diff --git a/Xceed.Document.NET/Properties/AssemblyInfo.cs b/Xceed.Document.NET/Properties/AssemblyInfo.cs index 94dcdc5e..4f7f2853 100644 --- a/Xceed.Document.NET/Properties/AssemblyInfo.cs +++ b/Xceed.Document.NET/Properties/AssemblyInfo.cs @@ -21,49 +21,57 @@ This program is provided to you under the terms of the Microsoft Public // General Information about an assembly is controlled through the following // set of attributes. Change these attribute values to modify the information // associated with an assembly. -[assembly: AssemblyTitle( "Xceed Document for .NET" )] -[assembly: AssemblyDescription( "This assembly implements the classes for Xceed Document for .NET." )] +//[assembly: AssemblyTitle( "Xceed Document for .NET" )] +//[assembly: AssemblyDescription( "This assembly implements the classes for Xceed Document for .NET." )] -[assembly: AssemblyCompany( "Xceed Software Inc." )] -[assembly: AssemblyProduct( "Xceed Document for .NET" )] -[assembly: AssemblyCopyright( "Copyright (C) Xceed Software Inc. 2009-2018" )] -[assembly: AssemblyCulture("")] +//[assembly: AssemblyCompany( "Xceed Software Inc." )] +//[assembly: AssemblyProduct( "Xceed Document for .NET" )] +//[assembly: AssemblyCopyright( "Copyright (C) Xceed Software Inc. 2009-2018" )] +//[assembly: AssemblyCulture("")] // Setting ComVisible to false makes the types in this assembly not visible // to COM components. If you need to access a type in this assembly from // COM, set the ComVisible attribute to true on that type. -[assembly: ComVisible(false)] -// Allow the Xceed.Words.NET to get at internal stuff. -[assembly: InternalsVisibleTo( "Xceed.Words.NET" + ",PublicKey=" + - "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + - "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + - "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + - "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + - "f92cbfb5")] -[assembly: InternalsVisibleTo( "Xceed.PdfCreator.NET" + ",PublicKey=" + - "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + - "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + - "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + - "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + - "f92cbfb5")] -[assembly: InternalsVisibleTo( "UnitTests" + ",PublicKey=" + - "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + - "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + - "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + - "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + - "f92cbfb5")] + +#pragma warning disable 1699 +//[assembly: AssemblyDelaySign( false )] +//[assembly: AssemblyKeyFile( @"..\..\sn.snk" )] +//[assembly: AssemblyKeyName( "" )] +#pragma warning restore 1699 + +[assembly: ComVisible(false)] +// Allow the Xceed.Words.NET to get at internal stuff. +[assembly: InternalsVisibleTo("Xceed.Words.NET" + ",PublicKey=" + + "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + + "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + + "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + + "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + + "f92cbfb5")] +[assembly: InternalsVisibleTo("Xceed.Words.NETCore" + ",PublicKey=" + + "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + + "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + + "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + + "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + + "f92cbfb5")] -#pragma warning disable 1699 -[assembly: AssemblyDelaySign( false )] -[assembly: AssemblyKeyFile( @"..\..\sn.snk" )] -[assembly: AssemblyKeyName( "" )] -#pragma warning restore 1699 +[assembly: InternalsVisibleTo("Xceed.PdfCreator.NET" + ",PublicKey=" + + "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + + "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + + "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + + "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + + "f92cbfb5")] +[assembly: InternalsVisibleTo("UnitTests" + ",PublicKey=" + + "0024000004800000940000000602000000240000525341310004000001000100d59d8147eb2015" + + "ca98a92da860fd766d101271d8c2f545894870fd6183255737d79347bbf5250291ae75651e1150" + + "1b7452ee003b80b936614cdda51db8eb6f8fde913e67d45395b480a992be17bf04744a7fe803ea" + + "131b925dcf84a73d22264352eca7c3fcf9387f3eee1d60ac7974f04866e6c72928dc0609abe341" + + "f92cbfb5")] \ No newline at end of file diff --git a/Xceed.Document.NET/Src/Container.cs b/Xceed.Document.NET/Src/Container.cs index 5a2acc1b..a3d09c6b 100644 --- a/Xceed.Document.NET/Src/Container.cs +++ b/Xceed.Document.NET/Src/Container.cs @@ -286,12 +286,40 @@ public virtual List FindUniqueByPattern( string pattern, RegexOptions op { var rawResults = new List(); - foreach( Paragraph p in Paragraphs ) - { // accumulate the search results from all paragraphs + // Search in headers + var headerList = new List
() { this.Document.Headers.First, this.Document.Headers.Even, this.Document.Headers.Odd }; + foreach (Header h in headerList) + { + if (h != null) + { + foreach (Paragraph p in h.Paragraphs) + { + var partials = p.FindAllByPattern(pattern, options); + rawResults.AddRange(partials); + } + } + } + + foreach ( Paragraph p in Paragraphs ) + { var partials = p.FindAllByPattern( pattern, options ); rawResults.AddRange( partials ); } + // Search in footers + var footerList = new List