⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 freetype.mli

📁 是一个手机功能的模拟程序
💻 MLI
字号:
exception FT_Error of string
exception FT_Glyph_Error of string
exception FT_Handle_Error of string
exception FT_Driver_Error of string
exception FT_Memory_Error of string
exception FT_Stream_Error of string
exception FT_Raster_Error of string
exception FT_TrueType_Error of string
exception FT_CFF_Error of string

type library
type face
type glyph
type bitmap
type 'a matrix

type matrix_mode =
  VERTICAL_MODE
| HORIZONTAL_MODE


type load_kind = 
  LOAD_NO_SCALE
| LOAD_NO_HINTING
| LOAD_RENDER
| LOAD_NO_BITMAP
| LOAD_VERTICAL_LAYOUT
| LOAD_FORCE_AUTOHINT
| LOAD_CROP_BITMAP
| LOAD_PEDANTIC
| LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH
| LOAD_NO_RECURSE
| LOAD_IGNORE_TRANSFORM
| LOAD_MONOCHROME
| LOAD_LINEAR_DESIGN
| LOAD_DEFAULT


val init_freetype : unit -> library


val new_face : library -> font_path:string -> face_index:int -> face
val done_face : face -> unit
val set_pixel_sizes : face -> width:int -> height:int -> unit
val get_char_index : face -> char_index:int -> int
val load_glyph : face -> glyph_index : int -> load_kind list -> unit

val get_glyph : face -> glyph
val get_ascent : face -> int
val get_face_height : face -> int
val get_descent : face -> int
val get_leading : face -> int
val get_underline : face -> int

val get_width : glyph -> int
val get_height : glyph -> int
val get_x_advance : glyph -> int
val get_y_advance : glyph -> int
val get_left_origin : glyph -> int
val get_top_origin : glyph -> int




val get_bitmap : glyph -> bitmap

(* bitmap_height is not compute inside expand_bitmap
   but passed as argument since one needs the max height
   taken on all glyphs of the bitmap.
   So, the value is precomputed and passed to expand bitmap so that
   all bitmap have the same vertical size
*)
val expand_bitmap : glyph -> bitmap_height:int -> reversex:bool -> reversey:bool
-> vertical:bool -> int matrix

val get_matrix_size : int matrix -> int

val get_matrix_aligned_size : int matrix -> int

val get_matrix_max_size : int matrix -> int


val get_matrix_image_width : int matrix -> int

val get_matrix_image_height : int matrix -> int

val get_matrix_element : int matrix -> int -> int -> int

val set_matrix_element : int matrix -> int -> int -> int -> unit

val new_matrix : width:int -> height:int -> image_width:int 
-> image_height:int -> vertical:bool -> int matrix


val empty_matrix : int matrix

val list_of_matrix : 'a matrix -> 'a list

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -