Пример #1
0
int CFX_Font::GetULthickness() const {
  if (!m_Face)
    return 0;

  return EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face),
                   FXFT_Get_Face_UnderLineThickness(m_Face));
}
Пример #2
0
int CFX_Font::GetULPos() const {
  if (!m_Face)
    return 0;

  return EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face),
                   FXFT_Get_Face_UnderLinePosition(m_Face));
}
Пример #3
0
int CFX_Font::GetMaxAdvanceWidth() const {
  if (!m_Face)
    return 0;

  return EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face),
                   FXFT_Get_Face_MaxAdvanceWidth(m_Face));
}
Пример #4
0
int CFX_Font::GetHeight() const {
  if (!m_Face)
    return 0;

  return EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face),
                   FXFT_Get_Face_Height(m_Face));
}
Пример #5
0
int CFX_Font::GetULthickness()
{
    if (m_Face == NULL) {
        return 0;
    }
    int thickness = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Face_UnderLineThickness(m_Face));
    return thickness;
}
Пример #6
0
int CFX_Font::GetULPos()
{
    if (m_Face == NULL) {
        return 0;
    }
    int pos = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Face_UnderLinePosition(m_Face));
    return pos;
}
Пример #7
0
int CFX_Font::GetMaxAdvanceWidth()
{
    if (m_Face == NULL) {
        return 0;
    }
    int width = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Face_MaxAdvanceWidth(m_Face));
    return width;
}
Пример #8
0
int CFX_Font::GetHeight()
{
    if (m_Face == NULL) {
        return 0;
    }
    int height = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Face_Height(m_Face));
    return height;
}
Пример #9
0
int CFX_Font::GetDescent() const
{
    if (m_Face == NULL) {
        return 0;
    }
    int descent = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Face_Descender(m_Face));
    return descent;
}
Пример #10
0
int CFX_Font::GetGlyphWidth(FX_DWORD glyph_index)
{
    if (!m_Face) {
        return 0;
    }
    if (m_pSubstFont && (m_pSubstFont->m_SubstFlags & FXFONT_SUBST_MM)) {
        AdjustMMParams(glyph_index, 0, 0);
    }
    int err = FXFT_Load_Glyph(m_Face, glyph_index, FXFT_LOAD_NO_SCALE | FXFT_LOAD_IGNORE_GLOBAL_ADVANCE_WIDTH);
    if (err) {
        return 0;
    }
    int width = EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face), FXFT_Get_Glyph_HoriAdvance(m_Face));
    return width;
}
Пример #11
0
int CFX_Font::GetDescent() const {
  if (!m_Face)
    return 0;
  return EM_ADJUST(FXFT_Get_Face_UnitsPerEM(m_Face),
                   FXFT_Get_Face_Descender(m_Face));
}