Aracılığıyla paylaş


OutputColor Sabit listesi

Tanım

Gri renk veya tonları içeren içeriğin nasıl yazdırılacağını belirtir.

public enum class OutputColor
public enum OutputColor
type OutputColor = 
Public Enum OutputColor
Devralma
OutputColor

Alanlar

Name Değer Description
Unknown 0

Özellik (seçenekleri bu numaralandırmayla temsil edilen) Yazdırma Şemasında tanımlanmayan bir seçeneğe ayarlanır.

Color 1

Renkli yazdıran çıkış.

Grayscale 2

Gri tonlamalı yazdıran çıkış.

Monochrome 3

Tek bir renkte ve aynı yoğunlukta yazdıran çıkış.

Örnekler

Aşağıdaki örnekte, değerleri ayarlamak PrintTicket için bu numaralandırmanın nasıl kullanılacağı gösterilmektedir.

// Use different PrintTickets for different FixedDocuments.
PrintTicket ptFD = new PrintTicket();

if (_firstDocumentPrintTicket <= 1)
{   // Print the first document in black/white and in portrait
    // orientation.  Since the PrintTicket at the
    // FixedDocumentSequence level already specifies portrait
    // orientation, this FixedDocument can just inherit that
    // setting without having to set it again.
    ptFD.PageOrientation = PageOrientation.Portrait;
    ptFD.OutputColor = OutputColor.Monochrome;
    _firstDocumentPrintTicket++;
}

else // if (_firstDocumentPrintTicket > 1)
{   // Print the second document in color and in landscape
    // orientation.  Since the PrintTicket at the
    // FixedDocumentSequence level already specifies portrait
    // orientation, this FixedDocument needs to set its
    // PrintTicket with landscape orientation in order to
    // override the higher level setting.
    ptFD.PageOrientation = PageOrientation.Landscape;
    ptFD.OutputColor = OutputColor.Color;
}
' Use different PrintTickets for different FixedDocuments.
Dim ptFD As New PrintTicket()

If _firstDocumentPrintTicket <= 1 Then
    ' orientation.  Since the PrintTicket at the
    ' FixedDocumentSequence level already specifies portrait
    ' orientation, this FixedDocument can just inherit that
    ' setting without having to set it again.
    ptFD.PageOrientation = PageOrientation.Portrait
    ptFD.OutputColor = OutputColor.Monochrome
    _firstDocumentPrintTicket += 1

Else ' if (_firstDocumentPrintTicket > 1)
    ' orientation.  Since the PrintTicket at the
    ' FixedDocumentSequence level already specifies portrait
    ' orientation, this FixedDocument needs to set its
    ' PrintTicket with landscape orientation in order to
    ' override the higher level setting.
    ptFD.PageOrientation = PageOrientation.Landscape
    ptFD.OutputColor = OutputColor.Color
End If

Açıklamalar

Bu türdeki değerleri şu amaçlarla kullanın:

  • bir özelliği PrintCapabilitiesolan koleksiyonun OutputColorCapability üyeleri olarak, bu değerler yazıcının desteklediği çıkış türlerini belirtir. (Birçok yazıcı birden fazla türü destekler.)

  • özelliğinin OutputColorPrintTicketdeğeri olarak, yazıcıyı belirlenen çıkış türünü üretmeye yönlendirir.

Bilinmeyen değeri hiçbir zaman nesnelerin özelliklerinde PrintCapabilities kullanılmaz.

Bir özelliği hiçbir zaman olarak UnknownayarlamamalısınızPrintTicket. Başka PrintTicket bir üretim uygulaması çıktı rengi özelliğini tanınmayan bir seçeneğe (Yani, Yazdırma Şemasında tanımlanmayan bir seçenek) ayarlayan bir PrintTicket belgesi oluşturduysa, uygulamanızda bu belgeyle oluşturulan bir PrintTicket nesne özelliğin OutputColor değeri olarak yer alırUnknown.

ve PrintCapabilities sınıfları devralınamasa daPrintTicket, veya PrintCapabilities sınıflarında hesaba katılmayan yazdırma cihazı özelliklerini tanımak için Yazdırma ŞemasınıPrintTicket genişletebilirsiniz. Daha fazla bilgi için bkz . Nasıl yapılır: Yazdırma Şemasını Genişletme ve Yeni Yazdırma Sistemi Sınıfları Oluşturma.

Şunlara uygulanır

Ayrıca bkz.