Closed jbe2277 closed 5 years ago
@jbe2277 can you confirm this is still happening in the latest preview? i just tried this out and it doesn't seem to repro with this SDK/runtime combo:
SDK: 3.0.100-preview6-012105 Microsoft.WindowsDesktop.App 3.0.0-preview6-27728-04
@stevenbrix I had a repro too, although it might be a different issue as the exception is of a different type. Glad to open separate issue then. I get a NotSupportedException when calling into GetFixedDocumentSequence, Exception details are
System.NotSupportedException
HResult=0x80131515
Message=This operation is not supported.
Source=System.IO.Compression
StackTrace:
at System.IO.Compression.DeflateStream.get_Position()
at System.IO.Packaging.ZipWrappingStream.get_Position()
at MS.Internal.IO.Packaging.SynchronizingStream.get_Position() in /_/src/Microsoft.DotNet.Wpf/src/shared/MS/Internal/IO/SynchronizingStream.cs:line 207
at MS.Internal.IO.Packaging.DeobfuscatingStream.Read(Byte[] buffer, Int32 offset, Int32 count) in /_/src/Microsoft.DotNet.Wpf/src/PresentationCore/MS/Internal/IO/Packaging/DeobfuscatingStream.cs:line 56
at MS.Internal.FontCache.FontSource.StreamToByteArray(Stream fontStream) in /_/src/Microsoft.DotNet.Wpf/src/PresentationCore/MS/Internal/FontCache/FontSource.cs:line 419
at MS.Internal.FontCache.FontSource.GetUnmanagedStream() in /_/src/Microsoft.DotNet.Wpf/src/PresentationCore/MS/Internal/FontCache/FontSource.cs:line 279
at MS.Internal.Text.TextInterface.FontFileStream..ctor(IFontSource fontSource)
at MS.Internal.Text.TextInterface.FontFileLoader.CreateStreamFromKey(Void* fontFileReferenceKey, UInt32 fontFileReferenceKeySize, IntPtr* fontFileStream)
Tested on preview 6. Just let me know if I should open a separate issue for this. I'll then try to minimize my app.
@jbartlau definitely a different issue, the non-seekable package streams are a known issue (#585) but your particular scenario wasn't mentioned anywhere yet, probably a good idea to add some details there so it doesn't get missed
@weltkante Thanks, done.
@jbartlau thanks for letting us know! We'll continue the discussion on #585
This issue has been automatically marked as stale because it has marked as requiring author feedback but has not had any activity for 4 days. It will be closed if no further activity occurs within 3 days of this comment. Thank you for your contributions!
Reproduce:
System.Waf.sln
in VS 2019.Samples/Writer/Writer.Presentation
as start-up projectExpected: The Print preview should be shown. You could compare this with the master branch (targets .NET 4.6.1)
Actual: The exception
System.Windows.Markup.XamlParseException: 'Add value to collection of type 'System.Windows.Documents.DocumentReferenceCollection' threw an exception.' Line number '1' and line position '136'. ---> System.UriFormatException: Invalid URI: The format of the URI could not be determined.
is thrown.Details: The line
FixedDocumentSequence documentSequence = xpsDocument.GetFixedDocumentSequence();
results in the following exception: