How to save document with resource references?

32 Views Asked by At

I am making a document editor. I want to mark the text with different colors (use SolidColorBrush Resources). When I save the flowdoucument , the resource reference just become definite color. Is there any way to save the flowdocument with keeping the resource references? I want to open the document in different theme, and the brush resources with same resourcekey may be different.

I tried put the resources in Flowdocument.Resources, save the resources with the document, the change still happened. I also edited the saved document, and added the resources reference manually, it was successful loaded, but it couldn't solve this problem.

0

There are 0 best solutions below