X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Finclude%2Fopen-type-font.hh;h=76d015325591ab602900aa356146fb0cf4d8431c;hb=72bc777a01c0437d766bf50c3bb3913a8f3d4bdb;hp=49b257586c9e05c0bf780fa2cdabcbb677b8ce4f;hpb=cb0b407e567feca71cbc5f9479a06b266c69a26c;p=lilypond.git diff --git a/lily/include/open-type-font.hh b/lily/include/open-type-font.hh index 49b257586c..76d0153255 100644 --- a/lily/include/open-type-font.hh +++ b/lily/include/open-type-font.hh @@ -26,15 +26,19 @@ Index_to_charcode_map make_index_to_charcode_map (FT_Face face); void get_unicode_name (char *s, FT_ULong code); void get_glyph_index_name (char *s, FT_ULong code); -class Open_type_font : public Font_metric -{ - /* handle to face object */ - FT_Face face_; - +struct Preinit_Open_type_font { SCM lily_subfonts_; SCM lily_character_table_; SCM lily_global_table_; SCM lily_index_to_bbox_table_; + Preinit_Open_type_font (); +}; + +class Open_type_font : Preinit_Open_type_font, public Font_metric +{ + /* handle to face object */ + FT_Face face_; + string postscript_name_; Index_to_charcode_map index_to_charcode_map_; Open_type_font (FT_Face); @@ -48,22 +52,23 @@ public: SCM glyph_list () const; SCM get_glyph_outline (size_t signed_idx) const; Box get_glyph_outline_bbox (size_t signed_idx) const; - std::string get_otf_table (const std::string &tag) const; - static SCM make_otf (const std::string&); - std::string font_name () const; + string get_otf_table (const string &tag) const; + static SCM make_otf (const string&); + string font_name () const; ~Open_type_font (); - Offset attachment_point (const std::string&) const; + Offset attachment_point (const string&) const; size_t count () const; Box get_indexed_char_dimensions (size_t) const; Box get_unscaled_indexed_char_dimensions (size_t) const; - size_t name_to_index (std::string) const; + size_t name_to_index (string) const; size_t index_to_charcode (size_t) const; void derived_mark () const; SCM sub_fonts () const; Real design_size () const; }; -std::string get_otf_table (FT_Face face, const std::string &tag); -FT_Face open_ft_face (const std::string&, FT_Long idx); +string get_otf_table (FT_Face face, const string &tag); +FT_Face open_ft_face (const string&, FT_Long idx); +string get_postscript_name (FT_Face face); #endif /* OPEN_TYPE_FONT_HH */