FlowDocumentReader.IsFindEnabled Propriété

Définition

Obtient ou définit une valeur qui indique si la commande routée Find est activée.

public:
 property bool IsFindEnabled { bool get(); void set(bool value); };
public bool IsFindEnabled { get; set; }
member this.IsFindEnabled : bool with get, set
Public Property IsFindEnabled As Boolean

Valeur de propriété

true pour activer la commande routée Find ; sinon, false. La valeur par défaut est true.

Exemples

L’exemple suivant montre comment définir l’attribut IsFindEnabled .

<FlowDocumentReader
  IsFindEnabled="True"  
  IsPrintEnabled="True"
  MinZoom="50" MaxZoom="1000"
  Zoom="120" ZoomIncrement="5"
>
  <FlowDocument>
    <Paragraph>
      Flow content...
    </Paragraph>
  </FlowDocument>
</FlowDocumentReader>

L’exemple suivant montre comment définir la IsFindEnabled propriété par programmation.

FlowDocumentReader flowDocRdr = new FlowDocumentReader();

// Enable find...
flowDocRdr.IsFindEnabled = true;
// Enable printing...
flowDocRdr.IsPrintEnabled = true;
// Set zoom between 50% and 1000%.
flowDocRdr.MinZoom = 50;
flowDocRdr.MaxZoom = 1000;
// Set the zoom increment to 5%.
flowDocRdr.ZoomIncrement = 5;
// Set the initial zoom to 120%.
flowDocRdr.Zoom = 120;

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

' Enable find...
flowDocRdr.IsFindEnabled = True
' Enable printing...
flowDocRdr.IsPrintEnabled = True
' Set zoom between 50% and 1000%.
flowDocRdr.MinZoom = 50
flowDocRdr.MaxZoom = 1000
' Set the zoom increment to 5%.
flowDocRdr.ZoomIncrement = 5
' Set the initial zoom to 120%.
flowDocRdr.Zoom = 120

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

Remarques

L’interface utilisateur par défaut FlowDocumentReader inclut un bouton Rechercher qui active la boîte de dialogue Rechercher. L’illustration suivante montre la boîte de dialogue Rechercher sur un avec l’interface FlowDocumentReader utilisateur par défaut.

Capture d’écran avec légendes : FlowDocumentReader

Lorsque IsFindEnabled a falsela valeur , le bouton Rechercher n’apparaît pas dans l’interface FlowDocumentReaderutilisateur.

Informations sur les propriétés de dépendance

Champ Identificateur IsFindEnabledProperty
Propriétés de métadonnées définies sur true Aucun

S’applique à

Voir aussi