public: //only used by: GrSegment* makeAndInitialize(const GrFont *font, const GrFace *face, uint32 script, const FeaturesHandle& pFeats/*must not be IsNull*/, encform enc, const void* pStart, size_t nChars, int dir); bool read_text(const Face *face, const Features* pFeats/*must not be NULL*/, gr_encform enc, const void*pStart, size_t nChars); void finalise(const Font *font, bool reverse=false); float justify(Slot *pSlot, const Font *font, float width, enum justFlags flags, Slot *pFirst, Slot *pLast); bool initCollisions();
private:
Position m_advance; // whole segment advance
SlotRope m_slots; // Vector of slot buffers
AttributeRope m_userAttrs; // Vector of userAttrs buffers
JustifyRope m_justifies; // Slot justification info buffers
FeatureList m_feats; // feature settings referenced by charinfos in this segment
Slot * m_freeSlots; // linked list of free slots
SlotJustify * m_freeJustifies; // Slot justification blocks free list
CharInfo * m_charinfo; // character info, one per input character
SlotCollision * m_collisions; const Face * m_face; // GrFace const Silf * m_silf;
Slot * m_first; // first slot in segment
Slot * m_last; // last slot in segment
size_t m_bufSize, // how big a buffer to create when need more slots
m_numGlyphs,
m_numCharinfo; // size of the array and number of input characters int m_defaultOriginal; // number of whitespace chars in the string
int8 m_dir;
uint8 m_flags, // General purpose flags
m_passBits; // if bit set then skip pass
};
inline
int8 Segment::getSlotBidiClass(Slot *s) const
{
int8 res = s->getBidiClass(); if (res != -1) return res;
res = int8(glyphAttr(s->gid(), m_silf->aBidi()));
s->setBidiClass(res); return res;
}
inline void Segment::finalise(const Font *font, bool reverse)
{ if (!m_first || !m_last) return;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.