FigureLength 구조체

정의

Figure의 높이 또는 너비를 설명합니다.

public value class FigureLength : IEquatable<System::Windows::FigureLength>
[System.ComponentModel.TypeConverter(typeof(System.Windows.FigureLengthConverter))]
public struct FigureLength : IEquatable<System.Windows.FigureLength>
[<System.ComponentModel.TypeConverter(typeof(System.Windows.FigureLengthConverter))>]
type FigureLength = struct
Public Structure FigureLength
Implements IEquatable(Of FigureLength)
상속
FigureLength
특성
구현

예제

다음 예제에서는 사용자가 클릭할 때에 FigureWidthFigure 감소 합니다. 다음은 샘플에 대 한 XAML입니다.

<Page xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
  xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
  x:Class="SDKSample.FigureLengthExample" >

  <FlowDocumentReader>
    <FlowDocument >
      <Paragraph>
        Raw text inside the paragraph
        <Figure Name="myFigure" Width="300">
          <Paragraph FontStyle="Italic" MouseDown="OnMouseDownDecreaseWidth" >
            Text inside of paragraph that is inside Figure...
          </Paragraph>
        </Figure>
      </Paragraph>
    </FlowDocument>
  </FlowDocumentReader>



</Page>

다음은 감소 하는 데 코드를 WidthFigure.

using System;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Input;

namespace SDKSample
{
    public partial class FigureLengthExample : Page
    {

        void OnMouseDownDecreaseWidth(object sender, MouseButtonEventArgs args)
        {
            FigureLength myFigureLength = myFigure.Width;
            double widthValue = myFigureLength.Value;
            if (widthValue > 0)
            {
                myFigure.Width = new FigureLength((widthValue - 10), FigureUnitType.Pixel);
            }
        }
    }
}

설명

XAML 특성 사용

<object property="length"/>  

또는

<object property="qualifiedDouble"/>  

XAML 값

length
너비 또는 높이 Figure 으로 설명 된 픽셀에서을 Double 값입니다. 단위 선언 문자열을 사용 하 여이 값을 정규화 할 수 있습니다 또는 (px, incmpt) 참조 하십시오 아래.

qualifiedDouble
위에서 설명한 대로 double 값과 다음 단위 선언 문자열 px중 하나( , , in``cm``pt.

px (기본값)은 디바이스 독립적 단위(단위당 1/96인치)입니다.

in 인치; 1에서 96px = =

cm 센티미터; 1cm==(96/2.54) px

pt 포인트; 1pt==(96/72) px

생성자

FigureLength(Double)

길이에 지정된 수의 픽셀을 사용하여 FigureLength 클래스의 새 인스턴스를 초기화합니다.

FigureLength(Double, FigureUnitType)

지정된 FigureLengthValue를 사용하여 FigureUnitType 클래스의 새 인스턴스를 초기화합니다.

속성

FigureUnitType

Value의 단위 형식을 가져옵니다.

IsAbsolute

FigureLength에 절대값(픽셀)이 있는지 여부를 결정하는 값을 가져옵니다.

IsAuto

FigureLength가 자동(지정되지 않음)인지 여부를 결정하는 값을 가져옵니다.

IsColumn

FigureLengthFigureUnitType 속성 값이 Column인지 여부를 결정하는 값을 가져옵니다.

IsContent

FigureLengthFigureUnitType 속성 값이 Content인지 여부를 결정하는 값을 가져옵니다.

IsPage

FigureLengthFigureUnitType 속성 값이 Page인지 여부를 결정하는 값을 가져옵니다.

Value

FigureLength의 값을 가져옵니다.

메서드

Equals(FigureLength)

FigureLength 구조체가 같은지 여부를 비교합니다.

Equals(Object)

지정한 Object의 길이가 FigureLength이며 이 길이가 이 FigureLength와 같은지 여부를 결정합니다.

GetHashCode()

FigureLength의 해시 코드를 반환합니다.

ToString()

StringFigureLength 표현을 만듭니다.

연산자

Equality(FigureLength, FigureLength)

FigureLength 구조체가 같은지 여부를 비교합니다.

Inequality(FigureLength, FigureLength)

FigureLength 구조체가 다른지 여부를 비교합니다.

적용 대상