TrueTypeFontMode Enumeration
Collapse the table of content
Expand the table of content

TrueTypeFontMode Enumeration


Specifies how a printer handles text that is formatted with a TrueType font.

Namespace:   System.Printing
Assembly:  ReachFramework (in ReachFramework.dll)

public enum TrueTypeFontMode

Member nameDescription

The printer driver decides the best method for handling TrueType fonts.


The printer driver downloads the TrueType font.


The printer driver downloads the TrueType font as an outline font.


The printer driver creates a raster font for each size of the TrueType font that it needs and downloads them all.


The printer driver downloads each area of text as a graphic.


The feature (whose options are represented by this enumeration) is set to an option not defined. in the Print Schema.

TrueType fonts are vector fonts, which instruct printer drivers and screen drivers how to draw the shapes of the letters and fill them in. Vector fonts contrast with raster fonts, which are simply lists. A raster font has a list for each letter of each available font size, and the lists determine, for every pixel in the letter, whether it prints.

You can enlarge or reduce vector fonts to almost any point size; however, vector fonts can slow printing because they occupy a large amount of printer memory. Also, some printers do not support TrueType fonts.

Newer printers often avoid these problems by doing the following.

  • Converting a TrueType font into an outline font, which is a generic vector font. Many printers that do not support TrueType fonts, do support outline fonts.

  • Creating a temporary raster font that looks just like a TrueType font. The printer must create a separate temporary raster font for each font size that the document uses. For that reason, if a print job uses many font sizes, the total memory that the printer uses might be greater than what a TrueType font would use.

  • Treating each text area in the document as a graphic. If a device needs to print a document that contains very little text, downloading text as a graphic can use less printer memory than downloading a font.

Use the values of this type for these purposes:

  • As members of the TrueTypeFontModeCapability collection, which is a property of PrintCapabilities, these values indicate which of the preceding techniques is available for a particular printer. Many printers support more than one of these techniques.

  • As the value of the TrueTypeFontMode property of a PrintTicket, the value instructs the printer to handle TrueType fonts in a particular way.

The Unknown value is never used in properties of PrintCapabilities objects.

You should never set a PrintTicket property to Unknown. If some other PrintTicket producing application has created a PrintTicket document that sets the TrueType font handling feature to an unrecognized option (that is, an option that is not defined in the Print Schema, then a PrintTicket object in your application that is constructed with that document will have Unknown as the value of the TrueTypeFontMode property.

Although the PrintTicket and PrintCapabilities classes cannot be inherited, you can extend the Print Schema to recognize print device features that are not accounted for in the PrintTicket or PrintCapabilities classes. For more information see NOTINBUILD: How to: Extend the Print Schema and Create New Print System Classes.

The following example shows how to test a printer's capabilities and configure the print job to take advantage of them.

// ---------------------- GetPrintTicketFromPrinter -----------------------
/// <summary>
///   Returns a PrintTicket based on the current default printer.</summary>
/// <returns>
///   A PrintTicket for the current local default printer.</returns>
PrintTicket^ GetPrintTicketFromPrinter () 
   PrintQueue^ printQueue = nullptr;

   LocalPrintServer^ localPrintServer = gcnew LocalPrintServer();

   // Retrieving collection of local printer on user machine
   PrintQueueCollection^ localPrinterCollection = localPrintServer->GetPrintQueues();

   System::Collections::IEnumerator^ localPrinterEnumerator = localPrinterCollection->GetEnumerator();

   if (localPrinterEnumerator->MoveNext())
      // Get PrintQueue from first available printer
      printQueue = ((PrintQueue^)localPrinterEnumerator->Current);
   } else
      return nullptr;
   // Get default PrintTicket from printer
   PrintTicket^ printTicket = printQueue->DefaultPrintTicket;

   PrintCapabilities^ printCapabilites = printQueue->GetPrintCapabilities();

   // Modify PrintTicket
   if (printCapabilites->CollationCapability->Contains(Collation::Collated))
      printTicket->Collation = Collation::Collated;
   if (printCapabilites->DuplexingCapability->Contains(Duplexing::TwoSidedLongEdge))
      printTicket->Duplexing = Duplexing::TwoSidedLongEdge;
   if (printCapabilites->StaplingCapability->Contains(Stapling::StapleDualLeft))
      printTicket->Stapling = Stapling::StapleDualLeft;
   return printTicket;
};// end:GetPrintTicketFromPrinter()

.NET Framework
Available since 3.0
Return to top
© 2015 Microsoft