FlowDocumentPageViewer.ZoomIncrement 属性

定义

获取或设置缩放增量。

public:
 property double ZoomIncrement { double get(); void set(double value); };
public double ZoomIncrement { get; set; }
member this.ZoomIncrement : double with get, set
Public Property ZoomIncrement As Double

属性值

当前缩放增量,以百分比表示。 默认值为 10.0(缩放增量为 10%)。

示例

以下示例演示如何使用此属性。

<FlowDocumentPageViewer
  MinZoom="50" MaxZoom="1000"
  Zoom="120" ZoomIncrement="5"
>
  <FlowDocument>
    <Paragraph>
      Flow content...
    </Paragraph>
  </FlowDocument>
</FlowDocumentPageViewer>
FlowDocumentPageViewer flowDocPageViewer = new FlowDocumentPageViewer();

// Set zoom between 50% and 1000%.
flowDocPageViewer.MinZoom = 50;
flowDocPageViewer.MaxZoom = 1000;
// Set the zoom increment to 5%.
flowDocPageViewer.ZoomIncrement = 5;
// Set the initial zoom to 120%.
flowDocPageViewer.Zoom = 120;

FlowDocument flowDoc = new FlowDocument(new Paragraph(new Run("Flow content...")));
flowDocPageViewer.Document = flowDoc;
Dim flowDocPageViewer As New FlowDocumentPageViewer()

' Set zoom between 50% and 1000%.
flowDocPageViewer.MinZoom = 50
flowDocPageViewer.MaxZoom = 1000
' Set the zoom increment to 5%.
flowDocPageViewer.ZoomIncrement = 5
' Set the initial zoom to 120%.
flowDocPageViewer.Zoom = 120

Dim flowDoc As New FlowDocument(New Paragraph(New Run("Flow content...")))
flowDocPageViewer.Document = flowDoc

注解

缩放增量是分别执行 或 DecreaseZoom 命令时IncreaseZoom级别增加或减少的百分比Zoom

依赖项属性信息

标识符字段 ZoomIncrementProperty
元数据属性设置为 true

适用于

另请参阅