Exemple #1
0
void Settings::SetFont(const char *name, const BFont *font, fontspec family)
{
	BString pname(name);
	FFont ff(font);
	FFont dummy;
	if (family == M_PLAIN_FONT) pname.Append(FONT);
	else if (family == M_BOLD_FONT) pname.Append(BFONT);
	else pname.Append(FFONT);
	if (FindMessageFont(&pref, pname.String(), 0, &dummy) != B_OK)
		AddMessageFont(&pref, pname.String(), &ff);
	else
		pref.ReplaceFlat(pname.String(), &ff);
}
Exemple #2
0
status_t ArpMessage::AddFont(const char *name, const BFont *font)
{
	return AddMessageFont(this, name, font);
}