// void cairo_show_text_glyphs(cairo_t *cr, const char *utf8, int utf8_len, // const cairo_glyph_t *glyphs, int num_glyphs, // const cairo_text_cluster_t *clusters, int num_clusters, // cairo_text_cluster_flags_t cluster_flags ); func (self *Surface) ShowTextGlyphs(text string, glyphs []Glyph, clusters []TextCluster, flag TextClusterFlag) { utf8 := C.CString(text) defer C.free(unsafe.Pointer(utf8)) C.cairo_show_text_glyphs(self.context, utf8, C.int(len(text)), (*C.cairo_glyph_t)(unsafe.Pointer(&glyphs[0])), C.int(len(glyphs)), (*C.cairo_text_cluster_t)(unsafe.Pointer(&clusters[0])), C.int(len(clusters)), C.cairo_text_cluster_flags_t(flag)) }
func (t TextClusterFlags) c() C.cairo_text_cluster_flags_t { return C.cairo_text_cluster_flags_t(t) }