Questions tagged [flowdocument]

Microsoft's WPF FlowDocument technology allows to render embedded, dynamically adjusted and re-flowing document content that supports columns, pagination and search.

A flow document is designed to "reflow content" depending on window size, device resolution, and other environment variables. Flow content can be complex, consisting of various elements including text, images, tables. In addition, flow documents have a number of built in features including search, viewing modes that optimize readability, and the ability to change the size and appearance of fonts.

571 questions
0
votes
1 answer

How to write async background workers that work on WPF flowdocument

I'm trying to write a background worker that processes a flowdocument. I can't access the properties of flowdocument objects because of the thread verification. I tried to serialize the document and loaded it on the worker thread which actually…
0
votes
1 answer

WPF: Defining "Templates" for Elements Not Inherited From Control

In this post I tried to find a way to re-template the contents of a FlowDocument. I've done several hours of research, and eventually come to this documentation on Control.Template property: The ControlTemplate specifies the appearance of a…
Scott Baker
  • 10,013
  • 17
  • 56
  • 102
0
votes
1 answer

How to use TextRange to replace letters of a Run?

I am completely new to FlowDocuments and can't seem to find this anywhere. I created a TextBlock where each Inline is a Run containing exactly one word. (The Inlines are created in code). I then use TextRange to replace some letters within the Run.…
Alan Wayne
  • 5,122
  • 10
  • 52
  • 95
0
votes
1 answer

How to obtain the character bounds of a right-jagged inline element of a TextBlock (WPF C#)?

I have not been able to find an answer to this. I am using a TextBlock that is being displayed within a scrollviewer. TextWrapping is set to wrap:
Alan Wayne
  • 5,122
  • 10
  • 52
  • 95
0
votes
1 answer

How to clear all properties from Paragraph.Inline

Is it possible to clear all properties like (background color...) from Paragraph.Inline elements, just like you can do with class TextRange ? Well, I wanted to clear background propery from previous Run element from Inline Collection. So I thought…
Kapparino
  • 988
  • 11
  • 33
0
votes
0 answers

Iteratively highlight text parts in Paragraph on button click

I have following FlowDocument with Paragraph in my XAML file:
Kapparino
  • 988
  • 11
  • 33
0
votes
1 answer

Rotate Windows.Documents.Table

I need to rotate a table clockwise up to 90 degrees. It's one of the blocks of a FlowDocument. Is there a way to apply some kind of rotation to a Table? The possible solution of creating TextEffect like this: var table = new Table(); ... //…
Andrey Neverov
  • 2,135
  • 1
  • 12
  • 21
0
votes
1 answer

Equivalent of html "" tag in WPF?

I have html file containing text with strong tag can say Windows Presentation Framework. I want to implement strong tag in flow document of WPF. I tried by setting font weight property to bold but not find an expected result/output…
madan
  • 773
  • 13
  • 38
0
votes
1 answer

Syntax Highlighting in FlowDocumentControl for RScript

We have use the following Regex function to highlight the string and numeric String Regex function public string StringRegEx { get { return @"@?""""|@?"".*?(?!\\).""|''|'.*?(?!\\).'"; } } Numeric Regex function public string NumberRegEX { …
Uthistran Selvaraj
  • 1,371
  • 1
  • 12
  • 31
0
votes
0 answers

WPF: Get TextPointer to previous/next line

Given a TextPointer, how do I get a TextPointer to the same horizontal position in the previous / next line? Basically the same as if the user pressed the up/down key in a RichTextBox.
devar
  • 95
  • 8
0
votes
1 answer

Flowdocument Run keep with next

In a Flowdocument how can I keep with next When the text wraps I do not want a line break between these two runs Run runMinus = new Run(); runMinus.Text = " -"; runMinus.Background = brushMinus; pargraph.Inlines.Add(runMinus); Run run = new…
paparazzo
  • 44,497
  • 23
  • 105
  • 176
0
votes
1 answer

C# FlowDocument cell width issue

Im having trouble sizing cells for each row added to a flowdocument. I want to manually set the flow document cells width. This code was taken and modified from a Microsoft example Code: internal static FlowDocument GetPicklistFlowDoc() { …
zerodoc
  • 393
  • 1
  • 4
  • 16
0
votes
1 answer

Display images in FlowDocument

I see these images in design but when I run the program no images I even see the ????? when I run the program How do I get these images to display when I run the program?
paparazzo
  • 44,497
  • 23
  • 105
  • 176
0
votes
0 answers

most economic way to display formatted rich text in wpf?

I'm looking for basically fastest way to display non-editable FlowDocument with continuous, variously decorated text. I know RichTextBox and usually use FlowDowcumentScrollViewer that can display FlowDocument content. I know TextBlock can (kind of)…
Riva
  • 637
  • 6
  • 14
0
votes
1 answer

How to create two tables side by side in flow document

I want to create two tables side by side in flow document. I don't want to use blockuicontainer.
siva
  • 357
  • 4
  • 7
  • 17