FlowDocument.FlowDirection Propiedad

Definición

Obtiene o establece la dirección relativa del flujo de contenido en FlowDocument.

public:
 property System::Windows::FlowDirection FlowDirection { System::Windows::FlowDirection get(); void set(System::Windows::FlowDirection value); };
public System.Windows.FlowDirection FlowDirection { get; set; }
member this.FlowDirection : System.Windows.FlowDirection with get, set
Public Property FlowDirection As FlowDirection

Valor de propiedad

FlowDirection

Uno de los valores de FlowDirection que especifica la dirección relativa del flujo. De manera predeterminada, es LeftToRight.

Ejemplos

En el ejemplo siguiente se muestra cómo establecer el FlowDirection atributo de un FlowDocument elemento .

<FlowDocumentReader>
  <FlowDocument 
    FlowDirection="LeftToRight"
  >
    <Paragraph>
      The FlowDirection of content typically corresponds to the innate flow direction
      of the language being represented.  Hebrew and Arabic provide examples of
      languages that naturally flow from right-to-left.  English, German, and Russian
      provide examples of languages that naturally flow from left-to-right.
    </Paragraph>
  </FlowDocument>
</FlowDocumentReader>

En el ejemplo siguiente se muestra cómo establecer la FlowDirection propiedad mediante programación.

FlowDocument flowDoc = new FlowDocument(new Paragraph(new Run("A bit of text content...")));
// Set the content flow direction to left-to-right.
flowDoc.FlowDirection = System.Windows.FlowDirection.LeftToRight;
Dim flowDoc As New FlowDocument(New Paragraph(New Run("A bit of text content...")))
' Set the content flow direction to left-to-right.
flowDoc.FlowDirection = System.Windows.FlowDirection.LeftToRight

Comentarios

La obtención de esta propiedad devuelve la dirección de flujo efectiva actual. Si se establece esta propiedad, el contenido del elemento FlowDocument se vuelve a redistribuir en la dirección indicada.

El FlowDirection de contenido normalmente corresponde a la dirección de flujo innato del idioma que se representa. Hebreo y árabe son ejemplos de idiomas que fluyen naturalmente de derecha a izquierda. Inglés, alemán y ruso son ejemplos de idiomas que fluyen naturalmente de izquierda a derecha.

Nota

El valor de esta propiedad no se cambia automáticamente para que coincida con el idioma utilizado por el sistema operativo. Si necesita usar un valor diferente, el valor predeterminado de LeftToRight, debe especificarlo usted mismo.

Información sobre propiedades de dependencia

Campo identificador FlowDirectionProperty
Propiedades de metadatos establecidas en true AffectsParentArrange, Inherits

Se aplica a