indexing description: "[ The metrics for a given glyph of a given ttf-font and size. See documentation at http://jcatki.no-ip.org/SDL_ttf/ for more info. ]" author: "" date: "$Date$" revision: "$Revision$" class EM_TTF_GLYPH_METRICS inherit SDL_TTF_FUNCTIONS_EXTERNAL export {NONE} all end create {EM_TTF_FONT} make feature {NONE} -- Initialization make (font: POINTER; unicode: INTEGER) is -- Create new glyph metrics for `unicode' character of `font' -- If the external function fails, all metrics will be 0 local minx, miny, maxx, maxy, adv: INTEGER do if ttf_glyph_metrics_external (font, unicode, $minx, $maxx, $miny, $maxy, $adv) /= -1 then min.set (minx, miny) max.set (maxx, maxy) advance := adv else min.set (0, 0) max.set (0, 0) advance := 0 end end feature -- Access min: EM_VECTOR2I -- max: EM_VECTOR2I -- advance: INTEGER -- end