Interface SWTFontRegistry


public interface SWTFontRegistry
This class is used in the win32 implementation only to support re-usage of fonts.

IMPORTANT: This class is not part of the public API for SWT. It is marked public only so that it can be shared within the packages provided by SWT. It is not available on all platforms, and should never be called from application code.

Restriction:
This class is not intended to be referenced by clients
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Disposes all fonts managed by the font registry.
    getFont(FontData fontData, int zoom)
    Provides a font optimally suited for the specified zoom.
    getSystemFont(int zoom)
    Returns a system font optimally suited for the specified zoom.
  • Method Details

    • getSystemFont

      Font getSystemFont(int zoom)
      Returns a system font optimally suited for the specified zoom.
      Parameters:
      zoom - zoom in % of the standard resolution to determine the appropriate system font
      Returns:
      the system font best suited for the specified zoom
    • getFont

      Font getFont(FontData fontData, int zoom)
      Provides a font optimally suited for the specified zoom. Fonts created in this manner are managed by the font registry and should not be disposed of externally.
      Parameters:
      fontData - the data used to create the font
      zoom - zoom in % of the standard resolution to determine the appropriate font
      Returns:
      the font best suited for the specified zoom
    • dispose

      void dispose()
      Disposes all fonts managed by the font registry.