提交 e62df436 编写于 作者: B Behdad Esfahbod

Add internal hb_buffer_t::get_scratch_buffer()

上级 71e7936f
......@@ -135,6 +135,8 @@ struct _hb_buffer_t {
{ return likely (size <= allocated) ? TRUE : enlarge (size); }
HB_INTERNAL bool make_room_for (unsigned int num_in, unsigned int num_out);
HB_INTERNAL void *get_scratch_buffer (unsigned int *size);
};
......
......@@ -135,6 +135,16 @@ hb_buffer_t::make_room_for (unsigned int num_in,
return TRUE;
}
void *
hb_buffer_t::get_scratch_buffer (unsigned int *size)
{
have_output = FALSE;
have_positions = FALSE;
out_len = 0;
*size = allocated * sizeof (pos[0]);
return pos;
}
/* HarfBuzz-Internal API */
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册