mirror of
https://repo.dactyloidae.xyz/Dactyloidae/UXP.git
synced 2026-09-27 10:57:34 +09:00
Issue #2191 - Remove virtual from gfxFont::GetCairoScaledFont.
Backported from Mozilla bug 1385029.
This commit is contained in:
parent
0f7750cd27
commit
44b74873c1
3 changed files with 6 additions and 6 deletions
|
|
@ -458,7 +458,7 @@ gfxDWriteFont::GetSpaceGlyph()
|
|||
bool
|
||||
gfxDWriteFont::SetupCairoFont(DrawTarget* aDrawTarget)
|
||||
{
|
||||
cairo_scaled_font_t *scaledFont = GetCairoScaledFont();
|
||||
cairo_scaled_font_t *scaledFont = InitCairoScaledFont();
|
||||
if (cairo_scaled_font_status(scaledFont) != CAIRO_STATUS_SUCCESS) {
|
||||
// Don't cairo_set_scaled_font as that would propagate the error to
|
||||
// the cairo_t, precluding any further drawing.
|
||||
|
|
@ -495,7 +495,7 @@ gfxDWriteFont::CairoFontFace()
|
|||
|
||||
|
||||
cairo_scaled_font_t *
|
||||
gfxDWriteFont::GetCairoScaledFont()
|
||||
gfxDWriteFont::InitCairoScaledFont()
|
||||
{
|
||||
if (!mScaledFont) {
|
||||
cairo_matrix_t sizeMatrix;
|
||||
|
|
@ -693,7 +693,7 @@ gfxDWriteFont::GetScaledFont(mozilla::gfx::DrawTarget *aTarget)
|
|||
|
||||
if (aTarget->GetBackendType() == BackendType::CAIRO) {
|
||||
if (!mAzureScaledFont->GetCairoScaledFont()) {
|
||||
cairo_scaled_font_t* cairoScaledFont = GetCairoScaledFont();
|
||||
cairo_scaled_font_t* cairoScaledFont = InitCairoScaledFont();
|
||||
if (!cairoScaledFont) {
|
||||
return nullptr;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -69,9 +69,9 @@ public:
|
|||
virtual already_AddRefed<mozilla::gfx::ScaledFont>
|
||||
GetScaledFont(mozilla::gfx::DrawTarget *aTarget) override;
|
||||
|
||||
virtual cairo_scaled_font_t *GetCairoScaledFont() override;
|
||||
|
||||
protected:
|
||||
cairo_scaled_font_t *InitCairoScaledFont();
|
||||
|
||||
virtual const Metrics& GetHorizontalMetrics() override;
|
||||
|
||||
bool GetFakeMetricsForArialBlack(DWRITE_FONT_METRICS *aFontMetrics);
|
||||
|
|
|
|||
|
|
@ -1452,7 +1452,7 @@ public:
|
|||
const nsString& GetName() const { return mFontEntry->Name(); }
|
||||
const gfxFontStyle *GetStyle() const { return &mStyle; }
|
||||
|
||||
virtual cairo_scaled_font_t* GetCairoScaledFont() { return mScaledFont; }
|
||||
cairo_scaled_font_t* GetCairoScaledFont() { return mScaledFont; }
|
||||
|
||||
virtual gfxFont* CopyWithAntialiasOption(AntialiasOption anAAOption) {
|
||||
// platforms where this actually matters should override
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue