fontservices/fontstore/inc/openfontsprivate.h
branchRCL_3
changeset 69 09b5fcf47b30
parent 60 dd58c6eee052
equal deleted inserted replaced
65:795cadd2b83a 69:09b5fcf47b30
   131 	inline const COpenFont* Font()const;
   131 	inline const COpenFont* Font()const;
   132 
   132 
   133 private:
   133 private:
   134 	inline COpenFontSessionCacheEntry(const COpenFont* aFont, TInt aCode, TInt aGlyphIndex, const TOpenFontCharMetrics& aMetrics);
   134 	inline COpenFontSessionCacheEntry(const COpenFont* aFont, TInt aCode, TInt aGlyphIndex, const TOpenFontCharMetrics& aMetrics);
   135 	~COpenFontSessionCacheEntry();
   135 	~COpenFontSessionCacheEntry();
       
   136 public:
       
   137     TInt iLastAccess;               // serial number of the last access to the glyph
   136 
   138 
   137 private: 
   139 private: 
   138     TInt iFontOffset;          // offset of the font that contains this glyph, (not owned by this class!)    
   140     TInt iFontOffset;          // offset of the font that contains this glyph, (not owned by this class!)    
   139 	};
   141 	};
   140 
   142 
   144 
   146 
   145  @internalComponent
   147  @internalComponent
   146  */
   148  */
   147 class COpenFontSessionCache
   149 class COpenFontSessionCache
   148     {
   150     {
   149 	friend class COpenFontSessionCacheList;
       
   150 public:
   151 public:
   151     static COpenFontSessionCache* NewL(RHeap* aHeap, TInt aSessionHandle, TInt aEntries);
   152     static COpenFontSessionCache* NewL(RHeap* aHeap, TInt aSessionHandle, TInt aEntries);
   152     void Delete(RHeap* aHeap);
   153     void Delete(RHeap* aHeap);
   153     
   154     
   154     TInt SessionHandle() { return iSessionHandle; }
   155     TInt SessionHandle() { return iSessionHandle; }
   155     const COpenFontGlyph* Glyph(const COpenFont* aFont, TInt aCode, TInt& aIndex) const;
   156     const COpenFontGlyph* Glyph(const COpenFont* aFont, TInt aCode, TInt& aIndex);
   156     void Insert(RHeap* aHeap, COpenFontSessionCacheEntry* aEntry, TInt aIndex);
   157     void Insert(RHeap* aHeap, COpenFontSessionCacheEntry* aEntry, TInt aIndex);
   157     
   158     
   158 private:
   159 private:
   159     COpenFontSessionCache(TInt aSessionHandle);
   160     COpenFontSessionCache(TInt aSessionHandle);
   160     ~COpenFontSessionCache();
   161     ~COpenFontSessionCache();
   161 private:
   162 public:
   162     TInt iSessionHandle;
   163     TInt iSessionHandle;    
   163     TInt64 iRandomSeed;
   164     TInt iLastAccess;
   164     ROffsetArray<COpenFontSessionCacheEntry> iEntryArray;
   165     ROffsetArray<COpenFontSessionCacheEntry> iEntryArray;
   165     };
   166     };
   166 
   167 
   167 
   168 
   168 // inline functions
   169 // inline functions