Package jexer.bits

Class UnicodeGlyphImage


  • public class UnicodeGlyphImage
    extends java.lang.Object
    UnicodeGlyphImage constructs a single character from the Unicode block-drawing elements ("Symbols For Legacy Computing") from a bitmap image.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Cell toHalfBlockGlyph()
      Create a single glyph using Unicode half-blocks that best represents this entire image.
      Cell toQuadrantBlockGlyph()
      Create a single glyph using Unicode quadrant-blocks that best represents this entire image.
      Cell toSextantBlockGlyph()
      Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image.
      Cell toSixDotGlyph()
      Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image, with one foreground color on a black background.
      Cell toSixDotSolidGlyph()
      Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • UnicodeGlyphImage

        public UnicodeGlyphImage​(Cell cell)
                          throws java.lang.IllegalArgumentException
        Public constructor.
        Parameters:
        cell - a Cell to read image data from
        Throws:
        java.lang.IllegalArgumentException - if cell does not have an image
      • UnicodeGlyphImage

        public UnicodeGlyphImage​(java.awt.image.BufferedImage image)
        Public constructor.
        Parameters:
        image - the bitmap image
    • Method Detail

      • toHalfBlockGlyph

        public Cell toHalfBlockGlyph()
        Create a single glyph using Unicode half-blocks that best represents this entire image.
        Returns:
        a cell with character, foreground, and background color set
      • toQuadrantBlockGlyph

        public Cell toQuadrantBlockGlyph()
        Create a single glyph using Unicode quadrant-blocks that best represents this entire image.
        Returns:
        a cell with character, foreground, and background color set
      • toSixDotGlyph

        public Cell toSixDotGlyph()
        Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image, with one foreground color on a black background.
        Returns:
        a cell with character and foreground color set
      • toSixDotSolidGlyph

        public Cell toSixDotSolidGlyph()
        Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image.
        Returns:
        a cell with character, foreground, and background color set
      • toSextantBlockGlyph

        public Cell toSextantBlockGlyph()
        Create a single glyph using Unicode 6-dot Braille blocks that best represents this entire image.
        Returns:
        a cell with character, foreground, and background color set