sk_typeface_get_table_tags() private method

private sk_typeface_get_table_tags ( IntPtr typeface, UInt32 tags ) : int
typeface System.IntPtr
tags System.UInt32
return int
Ejemplo n.º 1
0
        public bool TryGetTableTags(out UInt32[] tags)
        {
            var buffer = new UInt32[TableCount];

            if (SkiaApi.sk_typeface_get_table_tags(Handle, buffer) == 0)
            {
                tags = null;
                return(false);
            }
            tags = buffer;
            return(true);
        }
Ejemplo n.º 2
0
        public UInt32[] GetTableTags()
        {
            int tableCount = SkiaApi.sk_typeface_count_tables(Handle);

            UInt32[] result = new UInt32[tableCount];
            int      r      = SkiaApi.sk_typeface_get_table_tags(Handle, result);

            if (r == 0)
            {
                throw new Exception("Unable to read the tables for the file.");
            }
            return(result);
        }