Class Font
java.lang.Object
com.raylib.Font
-
Field Summary
FieldsModifier and TypeFieldDescriptionfinal MemorySegment
The native FFI MemorySegment that holds the data this object wraps. -
Constructor Summary
ConstructorsConstructorDescriptionFont()
Construct with auto memory allocator and fields initialized to zero.Font
(int baseSize, int glyphCount, int glyphPadding, Texture texture, Rectangle recs, GlyphInfo glyphs) Construct with auto memory allocator and fields initialized as specifiedFont
(MemorySegment memorySegment) Construct by wrapping around an already allocated MemorySegment, perhaps from another objectFont
(SegmentAllocator arena) Construct with your owm memory allocator and fields not initializedFont
(SegmentAllocator arena, int baseSize, int glyphCount, int glyphPadding, Texture texture, Rectangle recs, GlyphInfo glyphs) Construct with your own memory allocator and fields initialized as specified -
Method Summary
Modifier and TypeMethodDescriptionstatic Font
allocateArray
(long elementCount) Allocate an array of Fontstatic Font
allocateArray
(long elementCount, SegmentAllocator allocator) Allocate an array of Fontint
baseSize()
Base size (default chars height)baseSize
(int value) Base size (default chars height)boolean
Equality is tested on basis of both wrapper objects must refer to same native memory location to be considered equalgetArrayElement
(int index) int
Base size (default chars height)int
Number of glyph charactersint
Padding around the glyph charactersGlyphs info datagetRecs()
Rectangles in texture for the glyphsTexture atlas containing the glyphsint
Number of glyph charactersglyphCount
(int value) Number of glyph charactersint
Padding around the glyph charactersglyphPadding
(int value) Padding around the glyph charactersglyphs()
Glyphs info dataGlyphs info dataint
hashCode()
recs()
Rectangles in texture for the glyphsRectangles in texture for the glyphsvoid
setBaseSize
(int value) Base size (default chars height)void
setGlyphCount
(int value) Number of glyph charactersvoid
setGlyphPadding
(int value) Padding around the glyph charactersvoid
Glyphs info datavoid
Rectangles in texture for the glyphsvoid
setTexture
(Texture value) Texture atlas containing the glyphstexture()
Texture atlas containing the glyphsTexture atlas containing the glyphs
-
Field Details
-
memorySegment
The native FFI MemorySegment that holds the data this object wraps.
-
-
Constructor Details
-
Font
public Font()Construct with auto memory allocator and fields initialized to zero. -
Font
Construct with your owm memory allocator and fields not initialized -
Font
Construct by wrapping around an already allocated MemorySegment, perhaps from another object -
Font
public Font(int baseSize, int glyphCount, int glyphPadding, Texture texture, Rectangle recs, GlyphInfo glyphs) Construct with auto memory allocator and fields initialized as specified- Parameters:
baseSize
- Base size (default chars height)glyphCount
- Number of glyph charactersglyphPadding
- Padding around the glyph characterstexture
- Texture atlas containing the glyphsrecs
- Rectangles in texture for the glyphsglyphs
- Glyphs info data
-
Font
public Font(SegmentAllocator arena, int baseSize, int glyphCount, int glyphPadding, Texture texture, Rectangle recs, GlyphInfo glyphs) Construct with your own memory allocator and fields initialized as specified- Parameters:
baseSize
- Base size (default chars height)glyphCount
- Number of glyph charactersglyphPadding
- Padding around the glyph characterstexture
- Texture atlas containing the glyphsrecs
- Rectangles in texture for the glyphsglyphs
- Glyphs info data
-
-
Method Details
-
equals
-
hashCode
-
getArrayElement
-
allocateArray
Allocate an array of Font -
allocateArray
Allocate an array of Font -
getBaseSize
public int getBaseSize()Base size (default chars height) -
setBaseSize
public void setBaseSize(int value) Base size (default chars height) -
baseSize
public int baseSize()Base size (default chars height) -
baseSize
Base size (default chars height) -
getGlyphCount
public int getGlyphCount()Number of glyph characters -
setGlyphCount
public void setGlyphCount(int value) Number of glyph characters -
glyphCount
public int glyphCount()Number of glyph characters -
glyphCount
Number of glyph characters -
getGlyphPadding
public int getGlyphPadding()Padding around the glyph characters -
setGlyphPadding
public void setGlyphPadding(int value) Padding around the glyph characters -
glyphPadding
public int glyphPadding()Padding around the glyph characters -
glyphPadding
Padding around the glyph characters -
getTexture
Texture atlas containing the glyphs -
setTexture
Texture atlas containing the glyphs -
texture
Texture atlas containing the glyphs -
texture
-
getRecs
Rectangles in texture for the glyphs -
setRecs
Rectangles in texture for the glyphs -
recs
Rectangles in texture for the glyphs -
recs
-
getGlyphs
Glyphs info data -
setGlyphs
Glyphs info data -
glyphs
Glyphs info data -
glyphs
-