다음을 통해 공유


PrinterResolution 클래스

정의

프린터에서 지원하는 해상도를 나타냅니다.

public ref class PrinterResolution
public class PrinterResolution
[System.Serializable]
public class PrinterResolution
type PrinterResolution = class
[<System.Serializable>]
type PrinterResolution = class
Public Class PrinterResolution
상속
PrinterResolution
특성

예제

다음 코드 예제에서는 지원되는 해상도로 콤보 상자를 채웁 comboPrintResolution 니다. 이 예제에서는 이름이 지정된 printDoc 변수가 PrintDocument 있고 특정 콤보 상자가 있다고 가정합니다.

// Add list of printer resolutions found on the printer to the combobox.
// The PrinterResolution's ToString() method will be used to provide the display String.
PrinterResolution^ pkResolution;
for ( int i = 0; i < printDoc->PrinterSettings->PrinterResolutions->Count; i++ )
{
   pkResolution = printDoc->PrinterSettings->PrinterResolutions[ i ];
   comboPrintResolution->Items->Add( pkResolution );
}
// Add list of printer resolutions found on the printer to the combobox.
// The PrinterResolution's ToString() method will be used to provide the display string.

PrinterResolution pkResolution;
for (int i = 0; i < printDoc.PrinterSettings.PrinterResolutions.Count; i++){
    pkResolution = printDoc.PrinterSettings.PrinterResolutions[i];
    comboPrintResolution.Items.Add(pkResolution);
}
' Add list of printer resolutions found on the printer to the combobox.
' The PrinterResolution's ToString() method will be used to provide the display string.
Dim pkResolution As PrinterResolution
For i = 0 to printDoc.PrinterSettings.PrinterResolutions.Count - 1
    pkResolution = printDoc.PrinterSettings.PrinterResolutions.Item(i)
    comboPrintResolution.Items.Add(pkResolution)
Next

설명

이 클래스는 프린터 PageSettings.PrinterResolution 에서 사용할 수 있는 프린터 해상도를 가져오기 위해 사용 하 고 페이지에 대 한 인쇄 해상도 각각 설정 하는 속성에 사용 PrinterSettings.PrinterResolutions 됩니다.

Kind 속성을 사용하여 프린터 해상도 유형 PrinterResolutionKind 이 값인지 여부를 확인합니다 Custom. 이 경우 가로 방향과 세로 방향으로 프린터 해상도를 각각 확인하려면 해당 및 Y 속성을 사용합니다X.

인쇄에 대한 자세한 내용은 네임스페이스 개요를 System.Drawing.Printing 참조하세요.

생성자

Name Description
PrinterResolution()

PrinterResolution 클래스의 새 인스턴스를 초기화합니다.

속성

Name Description
Kind

프린터 해상도를 가져오거나 설정합니다.

X

가로 프린터 해상도를 인치당 점으로 가져옵니다.

Y

세로 프린터 해상도를 인치당 점으로 가져옵니다.

메서드

Name Description
Equals(Object)

지정된 개체가 현재 개체와 같은지 여부를 확인합니다.

(다음에서 상속됨 Object)
GetHashCode()

기본 해시 함수로 사용됩니다.

(다음에서 상속됨 Object)
GetType()

현재 인스턴스의 Type 가져옵니다.

(다음에서 상속됨 Object)
MemberwiseClone()

현재 Object단순 복사본을 만듭니다.

(다음에서 상속됨 Object)
ToString()

이 멤버는 메서드를 재정의 ToString() 합니다.

적용 대상

추가 정보