Class GlyphInfo

java.lang.Object
com.raylib.GlyphInfo

public class GlyphInfo extends Object
GlyphInfo, font characters glyphs info
  • Field Details

    • memorySegment

      public final MemorySegment memorySegment
      The native FFI MemorySegment that holds the data this object wraps.
  • Constructor Details

    • GlyphInfo

      public GlyphInfo()
      Construct with auto memory allocator and fields initialized to zero.
    • GlyphInfo

      public GlyphInfo(SegmentAllocator arena)
      Construct with your owm memory allocator and fields not initialized
    • GlyphInfo

      public GlyphInfo(MemorySegment memorySegment)
      Construct by wrapping around an already allocated MemorySegment, perhaps from another object
    • GlyphInfo

      public GlyphInfo(int value, int offsetX, int offsetY, int advanceX, Image image)
      Construct with auto memory allocator and fields initialized as specified
      Parameters:
      value - Character value (Unicode)
      offsetX - Character offset X when drawing
      offsetY - Character offset Y when drawing
      advanceX - Character advance position X
      image - Character image data
    • GlyphInfo

      public GlyphInfo(SegmentAllocator arena, int value, int offsetX, int offsetY, int advanceX, Image image)
      Construct with your own memory allocator and fields initialized as specified
      Parameters:
      value - Character value (Unicode)
      offsetX - Character offset X when drawing
      offsetY - Character offset Y when drawing
      advanceX - Character advance position X
      image - Character image data
  • Method Details

    • equals

      public boolean equals(Object o)
      Equality is tested on basis of both wrapper objects must refer to same native memory location to be considered equal
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • getArrayElement

      public GlyphInfo getArrayElement(int index)
    • allocateArray

      public static GlyphInfo allocateArray(long elementCount, SegmentAllocator allocator)
      Allocate an array of GlyphInfo
    • allocateArray

      public static GlyphInfo allocateArray(long elementCount)
      Allocate an array of GlyphInfo
    • getValue

      public int getValue()
      Character value (Unicode)
    • setValue

      public void setValue(int value)
      Character value (Unicode)
    • value

      public int value()
      Character value (Unicode)
    • value

      public GlyphInfo value(int value)
      Character value (Unicode)
    • getOffsetX

      public int getOffsetX()
      Character offset X when drawing
    • setOffsetX

      public void setOffsetX(int value)
      Character offset X when drawing
    • offsetX

      public int offsetX()
      Character offset X when drawing
    • offsetX

      public GlyphInfo offsetX(int value)
      Character offset X when drawing
    • getOffsetY

      public int getOffsetY()
      Character offset Y when drawing
    • setOffsetY

      public void setOffsetY(int value)
      Character offset Y when drawing
    • offsetY

      public int offsetY()
      Character offset Y when drawing
    • offsetY

      public GlyphInfo offsetY(int value)
      Character offset Y when drawing
    • getAdvanceX

      public int getAdvanceX()
      Character advance position X
    • setAdvanceX

      public void setAdvanceX(int value)
      Character advance position X
    • advanceX

      public int advanceX()
      Character advance position X
    • advanceX

      public GlyphInfo advanceX(int value)
      Character advance position X
    • getImage

      public Image getImage()
      Character image data
    • setImage

      public void setImage(Image value)
      Character image data
    • image

      public Image image()
      Character image data
    • image

      public GlyphInfo image(Image value)
      Character image data