public FontCharInfo GetCharInfo(ushort CharCode)
            {
                var Glyph = GetGlyph(CharCode);
                var Face  = Glyph.Face;

                var Advance = PGF.GetAdvance(Face.AdvanceIndex);

                var FontCharInfo = new sceLibFont.FontCharInfo()
                {
                    BitmapWidth  = Face.Width,
                    BitmapHeight = Face.Height,
                    BitmapLeft   = Face.Left,
                    BitmapTop    = Face.Top,
                    Width        = Face.Width,
                    Height       = Face.Height,
                    Ascender     = Face.Top,
                    Descender    = Face.Height - Face.Top,
                    BearingHX    = Face.Left,
                    BearingHY    = Face.Top,
                    BearingVX    = Face.Left,
                    BearingVY    = Face.Top,
                    AdvanceH     = Advance.Width,
                    AdvanceV     = Advance.Height,
                    Unknown      = 0,
                };

                return(FontCharInfo);
            }
Example #2
0
            public FontCharInfo GetCharInfo(ushort CharCode)
            {
                var Glyph = GetGlyph(CharCode);
                var Face = Glyph.Face;

                var Advance = PGF.GetAdvance(Face.AdvanceIndex);

                var FontCharInfo = new sceLibFont.FontCharInfo()
                {
                    BitmapWidth = Face.Width,
                    BitmapHeight = Face.Height,
                    BitmapLeft = Face.Left,
                    BitmapTop = Face.Top,
                    Width = Face.Width,
                    Height = Face.Height,
                    Ascender = Face.Top,
                    Descender = Face.Height - Face.Top,
                    BearingHX = Face.Left,
                    BearingHY = Face.Top,
                    BearingVX = Face.Left,
                    BearingVY = Face.Top,
                    AdvanceH = Advance.Width,
                    AdvanceV = Advance.Height,
                    Unknown = 0,
                };

                return FontCharInfo;
            }
Example #3
0
            public FontCharInfo GetCharInfo(ushort CharCode)
            {
                var Glyph = GetGlyph(CharCode);
                var Face = Glyph.Face;

                var FontCharInfo = new sceLibFont.FontCharInfo()
                {
                    BitmapWidth = Face.Width,
                    BitmapHeight = Face.Height,
                    BitmapLeft = Face.Left,
                    BitmapTop = Face.Top,
                    Width = Face.Width,
                    Height = Face.Height,
                    Ascender = Face.Top,
                    Descender = Face.Height - Face.Top,
                    BearingHX = Face.Left,
                    BearingHY = Face.Top,
                    BearingVX = Face.Left,
                    BearingVY = Face.Top,
                    AdvanceH = PGF.AdvanceTable[Face.AdvanceIndex].Src,
                    AdvanceV = PGF.AdvanceTable[Face.AdvanceIndex].Dst,
                    Padding = 0,
                };

                return FontCharInfo;
            }