Skip to content

Commit

Permalink
mute pango warning about depreciation of pango_coverage_unref for pan…
Browse files Browse the repository at this point in the history
…go>=1.50.4
  • Loading branch information
zdenop committed Dec 28, 2024
1 parent dcb2ef9 commit 65e864b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions src/training/pango/pango_font_info.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ bool PangoFontInfo::CoversUTF8Text(const char *utf8_text, int byte_length) const
int len = it.get_utf8(tmp);
tmp[len] = '\0';
tlog(2, "'%s' (U+%x) not covered by font\n", tmp, *it);
#if PANGO_VERSION_CHECK(1, 52, 0)
#if PANGO_VERSION_CHECK(1, 50, 4)
g_object_unref(coverage);
#else
pango_coverage_unref(coverage);
Expand All @@ -239,7 +239,7 @@ bool PangoFontInfo::CoversUTF8Text(const char *utf8_text, int byte_length) const
return false;
}
}
#if PANGO_VERSION_CHECK(1, 52, 0)
#if PANGO_VERSION_CHECK(1, 50, 4)
g_object_unref(coverage);
#else
pango_coverage_unref(coverage);
Expand Down Expand Up @@ -311,7 +311,7 @@ int PangoFontInfo::DropUncoveredChars(std::string *utf8_text) const {
my_strnmove(out, utf8_char, utf8_len);
out += utf8_len;
}
#if PANGO_VERSION_CHECK(1, 52, 0)
#if PANGO_VERSION_CHECK(1, 50, 4)
g_object_unref(coverage);
#else
pango_coverage_unref(coverage);
Expand Down Expand Up @@ -615,7 +615,7 @@ int FontUtils::FontScore(const std::unordered_map<char32, int64_t> &ch_map,
ch_flags->push_back(covered);
}
}
#if PANGO_VERSION_CHECK(1, 52, 0)
#if PANGO_VERSION_CHECK(1, 50, 4)
g_object_unref(coverage);
#else
pango_coverage_unref(coverage);
Expand Down

0 comments on commit 65e864b

Please sign in to comment.