Lines Matching refs:hdc
154 static unsigned calculateGlyphCount(HDC hdc, const LOGFONT& lf) {
156 if (0 == GetTextMetrics(hdc, &textMetric)) {
159 GetTextMetrics(hdc, &textMetric);
168 if (GDI_ERROR != GetFontData(hdc, SkOTTableMaximumProfile::TAG, 4, &glyphs, sizeof(glyphs))) {
179 if (GetGlyphOutlineW(hdc, mid, GGO_METRICS | GGO_GLYPH_INDEX, &gm, 0,
190 static unsigned calculateUPEM(HDC hdc, const LOGFONT& lf) {
192 if (0 == GetTextMetrics(hdc, &textMetric)) {
195 GetTextMetrics(hdc, &textMetric);
203 unsigned int otmRet = GetOutlineTextMetrics(hdc, sizeof(otm), &otm);
206 otmRet = GetOutlineTextMetrics(hdc, sizeof(otm), &otm);
242 SkAutoHDC hdc(fLogFont);
244 if (0 == GetTextMetrics(hdc, &textMetric)) {
246 if (0 == GetTextMetrics(hdc, &textMetric)) {
1607 SkAutoHDC hdc(fLogFont);
1608 dcfontname_to_skstring(hdc, fLogFont, familyName);
1621 SkAutoHDC hdc(fLogFont);
1622 unsigned int glyphCount = calculateGlyphCount(hdc, fLogFont);
1623 populate_glyph_to_unicode(hdc, glyphCount, dstArray);
1633 SkAutoHDC hdc(lf);
1642 unsigned int otmRet = GetOutlineTextMetrics(hdc, sizeof(otm), &otm);
1645 otmRet = GetOutlineTextMetrics(hdc, sizeof(otm), &otm);
1647 if (!otmRet || !GetTextFace(hdc, LF_FACESIZE, lf.lfFaceName)) {
1652 SelectObject(hdc, designFont.get());
1653 if (!GetOutlineTextMetrics(hdc, sizeof(otm), &otm)) {
1656 glyphCount = calculateGlyphCount(hdc, fLogFont);
1713 if (GetCharABCWidths(hdc, stem_chars[i], stem_chars[i], &abcWidths)) {
1828 SkAutoHDC hdc(lf);
1833 DWORD bufferSize = GetFontData(hdc, tables[i], 0, nullptr, 0);
1836 bufferSize = GetFontData(hdc, tables[i], 0, nullptr, 0);
1840 if (GetFontData(hdc, tables[i], 0, (void*)stream->getMemoryBase(), bufferSize)) {
1854 static void bmpCharsToGlyphs(HDC hdc, const WCHAR* bmpChars, int count, uint16_t* glyphs,
1872 DWORD result = GetGlyphIndicesW(hdc, bmpChars, count, glyphs, GGI_MARK_NONEXISTING_GLYPHS);
1895 static uint16_t nonBmpCharToGlyph(HDC hdc, SCRIPT_CACHE* scriptCache, const WCHAR utf16[2]) {
1936 HRZM(ScriptShape(hdc, scriptCache, utf16, numWCHAR, maxGlyphs, &script,
1948 SkAutoHDC hdc(fLogFont);
1951 if (0 == GetTextMetrics(hdc, &tm)) {
1953 if (0 == GetTextMetrics(hdc, &tm)) {
1973 bmpCharsToGlyphs(hdc, scratch, runLength, &glyphs[glyphIndex], Ox1FHack);
1980 glyphs[glyphIndex] = nonBmpCharToGlyph(hdc, &sc, scratch);
1991 SkAutoHDC hdc(fLogFont);
1992 return calculateGlyphCount(hdc, fLogFont);
1998 SkAutoHDC hdc(fLogFont);
1999 return calculateUPEM(hdc, fLogFont);
2040 SkAutoHDC hdc(lf);
2046 DWORD bufferSize = GetFontData(hdc, tag, (DWORD) offset, data, (DWORD) length);
2049 bufferSize = GetFontData(hdc, tag, (DWORD) offset, data, (DWORD) length);
2056 SkAutoHDC hdc(lf);
2059 DWORD size = GetFontData(hdc, tag, 0, nullptr, 0);
2062 size = GetFontData(hdc, tag, 0, nullptr, 0);
2068 if (GetFontData(hdc, tag, 0, data->writable_data(), size) == GDI_ERROR) {
2187 HDC hdc = ::CreateCompatibleDC(nullptr);
2188 ::EnumFontFamiliesEx(hdc, &lf, enum_family_proc, (LPARAM)&fArray, 0);
2189 ::DeleteDC(hdc);
2232 HDC hdc = ::CreateCompatibleDC(nullptr);
2233 ::EnumFontFamiliesEx(hdc, &lf, enum_family_proc, (LPARAM)&fLogFontArray, 0);
2234 ::DeleteDC(hdc);