2012-05-21 04:12:37 -07:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2011-06-15 23:31:36 -07:00
|
|
|
|
|
|
|
#ifndef __nsFontFace_h__
|
|
|
|
#define __nsFontFace_h__
|
|
|
|
|
|
|
|
#include "nsIDOMFontFace.h"
|
2013-10-01 14:02:16 -07:00
|
|
|
#include "nsAutoPtr.h"
|
2011-06-15 23:31:36 -07:00
|
|
|
|
2013-10-01 14:02:16 -07:00
|
|
|
class gfxFontEntry;
|
|
|
|
class gfxFontGroup;
|
2011-06-15 23:31:36 -07:00
|
|
|
class nsCSSFontFaceRule;
|
|
|
|
|
2011-06-15 23:31:36 -07:00
|
|
|
class nsFontFace : public nsIDOMFontFace
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
NS_DECL_ISUPPORTS
|
|
|
|
NS_DECL_NSIDOMFONTFACE
|
|
|
|
|
2011-06-15 23:31:37 -07:00
|
|
|
nsFontFace(gfxFontEntry* aFontEntry,
|
2012-12-19 01:42:25 -08:00
|
|
|
gfxFontGroup* aFontGroup,
|
|
|
|
uint8_t aMatchInfo);
|
2011-06-15 23:31:36 -07:00
|
|
|
|
|
|
|
gfxFontEntry* GetFontEntry() const { return mFontEntry.get(); }
|
|
|
|
|
2012-08-22 08:56:38 -07:00
|
|
|
void AddMatchType(uint8_t aMatchType) {
|
2011-06-15 23:31:37 -07:00
|
|
|
mMatchType |= aMatchType;
|
|
|
|
}
|
|
|
|
|
2011-06-15 23:31:36 -07:00
|
|
|
protected:
|
2014-06-23 15:40:01 -07:00
|
|
|
virtual ~nsFontFace();
|
|
|
|
|
2011-06-15 23:31:36 -07:00
|
|
|
nsRefPtr<gfxFontEntry> mFontEntry;
|
2012-12-19 01:42:25 -08:00
|
|
|
nsRefPtr<gfxFontGroup> mFontGroup;
|
2012-08-22 08:56:38 -07:00
|
|
|
uint8_t mMatchType;
|
2011-06-15 23:31:36 -07:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // __nsFontFace_h__
|