Figures in a FlowDocument : FlowDocument « Windows Presentation Foundation « C# / C Sharp

Home
C# / C Sharp
1.2D Graphics
2.Class Interface
3.Collections Data Structure
4.Components
5.Data Types
6.Database ADO.net
7.Design Patterns
8.Development Class
9.Event
10.File Stream
11.Generics
12.GUI Windows Form
13.Language Basics
14.LINQ
15.Network
16.Office
17.Reflection
18.Regular Expressions
19.Security
20.Services Event
21.Thread
22.Web Services
23.Windows
24.Windows Presentation Foundation
25.XML
26.XML LINQ
C# / C Sharp by API
C# / CSharp Tutorial
C# / CSharp Open Source
C# / C Sharp » Windows Presentation Foundation » FlowDocumentScreenshots 
Figures in a FlowDocument
Figures in a FlowDocument
     
<Window x:Class="Documents.Figures"
    xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
    xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
    Title="FloatersAndFigures" Height="478" Width="740">
  <Window.Resources>
    <Style x:Key="myStyle">
      <Setter Property="Paragraph.FontSize" Value="30" ></Setter>
      <Setter Property="Paragraph.FontStyle" Value="Italic" ></Setter>
      <Setter Property="Paragraph.Foreground" Value="Green" ></Setter>
      <Setter Property="Paragraph.Padding" Value="5"></Setter>
      <Setter Property="Paragraph.Margin" Value="5,10,15,10"></Setter>
    </Style>
  </Window.Resources>
  <FlowDocumentScrollViewer Name="docViewer" MinZoom="1" MaxZoom="1000" IsToolBarVisible ="True">
    <FlowDocument IsOptimalParagraphEnabled="True" IsHyphenationEnabled="True" >
      <Paragraph>
        text
        <Figure Width="100" Padding="5,0,5,0" HorizontalAnchor="PageRight">
          <BlockUIContainer>
            <Image Source="c:\image.jpg" ></Image>
          </BlockUIContainer>
        </Figure>
        text
      </Paragraph>
      <Paragraph>
        The hallway smelt of boiled cabbage and old rag mats.<Run xml:space="preserve"> </Run>
        <Floater Style="{StaticResource myStyle}" Width="205" HorizontalAlignment="Left">
          <Paragraph>this is a test</Paragraph>
        </Floater>
        text
      </Paragraph>
    </FlowDocument>
  </FlowDocumentScrollViewer>

</Window>

   
    
    
    
    
  
Related examples in the same category
1.FlowDocument with SectionFlowDocument with Section
2.FlowDocument with UI containerFlowDocument with UI container
3.FlowDocument with TableFlowDocument with Table
4.Span and FlowDoucmentSpan and FlowDoucment
5.FlowDocument with Figure.xamlFlowDocument with Figure.xaml
6.Paragraph FontWeightParagraph FontWeight
7.FlowDocument with Hyperlink and ListFlowDocument with Hyperlink and List
8.Adding style to ParagraphAdding style to Paragraph
9.Bold text in Flow documentBold text in Flow document
10.Create Table layout in FlowDocument
11.Styled DocumentStyled Document
12.Add ListItem to FlowDocumentAdd ListItem to FlowDocument
13.FlowDocument with TextAlignment, ColumnWidth. Italic and bold fontFlowDocument with TextAlignment, ColumnWidth. Italic and bold font
14.Flow Document ReaderFlow Document Reader
15.Add FlowDocument to ButtonAdd FlowDocument to Button
16.FlowDocument with imagesFlowDocument with images
17.Add Shape(Ellipse, Rectangle) to ListAdd Shape(Ellipse, Rectangle) to List
18.Change FlowDocument Width and HeightChange FlowDocument Width and Height
19.Programmatically change the FlowDirection of content within a FlowDocumentReader elementProgrammatically change the FlowDirection of content within a FlowDocumentReader element
20.Use FlowDocumentReader to display FlowDocumentUse FlowDocumentReader to display FlowDocument
21.Programmatically Create and Save a FlowDocumentProgrammatically Create and Save a FlowDocument
22.Use XamlDesignerSerializationManager to write FlowDocumentUse XamlDesignerSerializationManager to write FlowDocument
23.Show FlowDocumentShow FlowDocument
24.Load a FlowDocument into a FlowDocumentReader,Load a FlowDocument into a FlowDocumentReader,
25.Convert Xaml file to FlowDocument with as operator
26.Save a FlowDocument as a Extensible Application Markup Language (XAML) file
27.Clear FlowDocumentReaderClear FlowDocumentReader
28.Programmatically add rows to a Table element.Programmatically add rows to a Table element.
29.Table Flow ContentTable Flow Content
30.Annotation ServiceAnnotation Service
31.Toggle Hyphenation, Optimal Paragraph, and Column FlexToggle Hyphenation, Optimal Paragraph, and Column Flex
32.Change font Change font
www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.