hb_buffer_ensure (buffer, size);
if (buffer->out_string == buffer->in_string)
{
+ assert (buffer->have_output);
if (!buffer->positions)
buffer->positions = calloc (buffer->allocated, sizeof (buffer->positions[0]));
void
hb_buffer_clear (hb_buffer_t *buffer)
{
+ buffer->have_output = FALSE;
buffer->in_length = 0;
buffer->out_length = 0;
buffer->in_pos = 0;
void
_hb_buffer_clear_output (hb_buffer_t *buffer)
{
+ buffer->have_output = TRUE;
buffer->out_length = 0;
buffer->out_pos = 0;
buffer->out_string = buffer->in_string;
hb_buffer_clear_positions (hb_buffer_t *buffer)
{
_hb_buffer_clear_output (buffer);
+ buffer->have_output = FALSE;
if (HB_UNLIKELY (!buffer->positions))
{
{
unsigned int tmp;
+ assert (buffer->have_output);
+
if (buffer->out_string != buffer->in_string)
{
hb_internal_glyph_info_t *tmp_string;
void
_hb_buffer_next_glyph (hb_buffer_t *buffer)
{
+ if (!buffer->have_output)
+ {
+ buffer->in_pos++;
+ return;
+ }
+
if (buffer->out_string != buffer->in_string)
{
hb_buffer_ensure (buffer, buffer->out_pos + 1);