Lines Matching refs:item
242 static inline void positionCluster(HB_ShaperItem *item, int gfrom, int glast)
247 HB_Glyph *glyphs = item->glyphs;
248 HB_GlyphAttributes *attributes = item->attributes;
251 item->font->klass->getGlyphMetrics(item->font, glyphs[gfrom], &baseMetrics);
253 if (item->item.script == HB_Script_Hebrew
261 HB_Fixed size = item->font->klass->getFontMetric(item->font, HB_FontAscent) / 10;
270 bool rightToLeft = item->item.bidiLevel % 2;
280 item->font->klass->getGlyphMetrics(item->font, mark, &markMetrics);
398 item->offsets[gfrom+i].x = p.x;
399 item->offsets[gfrom+i].y = p.y;
401 item->offsets[gfrom+i].x = p.x - baseMetrics.xOffset;
402 item->offsets[gfrom+i].y = p.y - baseMetrics.yOffset;
404 item->advances[gfrom+i] = 0;
408 void HB_HeuristicPosition(HB_ShaperItem *item)
410 HB_GetGlyphAdvances(item);
411 HB_GlyphAttributes *attributes = item->attributes;
414 int i = item->num_glyphs;
419 positionCluster(item, i, cEnd);
428 void HB_HeuristicSetGlyphAttributes(HB_ShaperItem *item)
430 const HB_UChar16 *uc = item->string + item->item.pos;
431 hb_uint32 length = item->item.length;
438 assert(length <= item->num_glyphs);
441 // qDebug("QScriptEngine::heuristicSetGlyphAttributes, num_glyphs=%d", item->num_glyphs);
442 HB_GlyphAttributes *attributes = item->attributes;
443 unsigned short *logClusters = item->log_clusters;
462 // assert(glyph_pos == item->num_glyphs);
468 const bool symbolFont = item->face->isSymbolFont;
569 shaper_item->string + shaper_item->item.pos, shaper_item->item.length,
571 shaper_item->item.bidiLevel % 2);
1054 HB_Script script = shaper_item->item.script;
1152 HB_Bool HB_OpenTypeShape(HB_ShaperItem *item, const hb_uint32 *properties)
1157 HB_Face face = item->face;
1159 face->length = item->num_glyphs;
1174 hb_buffer_add_glyph(face->buffer, item->glyphs[i], properties ? properties[i] : 0, i);
1175 face->tmpAttributes[i] = item->attributes[i];
1176 face->tmpLogClusters[i] = item->log_clusters[i];
1183 // DEBUG(" log[%d] = %d", j, item->log_clusters[j]);
1184 DEBUG("original glyphs: %p", item->glyphs);
1201 // DEBUG(" log[%d] = %d", j, item->log_clusters[j]);
1212 HB_Bool HB_OpenTypePosition(HB_ShaperItem *item, int availableGlyphs, HB_Bool doLogClusters)
1214 HB_Face face = item->face;
1221 glyphs_positioned = HB_GPOS_Apply_String(item->font, face->gpos, face->current_flags, face->buffer, false, false) != HB_Err_Not_Covered;
1225 HB_GetGlyphAdvances(item);
1231 item->num_glyphs = face->buffer->in_length;
1235 HB_Glyph *glyphs = item->glyphs;
1236 HB_GlyphAttributes *attributes = item->attributes;
1244 item->num_glyphs = face->buffer->in_length;
1248 unsigned short *logClusters = item->log_clusters;
1273 HB_GetGlyphAdvances(item);
1275 HB_Fixed *advances = item->advances;
1297 HB_FixedPoint *offsets = item->offsets;
1307 if (item->item.bidiLevel % 2) {
1323 item->kerning_applied = face->has_opentype_kerning;
1325 HB_HeuristicPosition(item);
1332 DEBUG(" log[%d] = %d", j, item->log_clusters[j]);
1349 if (shaper_item->num_glyphs < shaper_item->item.length) {
1350 shaper_item->num_glyphs = shaper_item->item.length;
1353 assert(shaper_item->item.script < HB_ScriptCount);
1354 result = HB_ScriptEngines[shaper_item->item.script].shape(shaper_item);