int Chat_FontsChanged(WPARAM wParam,LPARAM lParam)
{
	LoadLogFonts();
	LoadMsgLogBitmaps();
	MM_FontsChanged();
	MM_FixColors();
	SM_BroadcastMessage(NULL, GC_SETWNDPROPS, 0, 0, TRUE);
	return 0;
}
Exemplo n.º 2
0
static int FontsChanged(WPARAM, LPARAM)
{
	LoadGlobalSettings();
	LoadLogFonts();

	FreeMsgLogBitmaps();
	LoadMsgLogBitmaps();

	SetIndentSize();
	g_Settings->bLogIndentEnabled = (db_get_b(NULL, CHAT_MODULE, "LogIndentEnabled", 1) != 0) ? TRUE : FALSE;

	ci.MM_FontsChanged();
	ci.MM_FixColors();
	ci.SM_BroadcastMessage(NULL, GC_SETWNDPROPS, 0, 0, TRUE);
	return 0;
}
Exemplo n.º 3
0
int Chat_FontsChanged(WPARAM wParam,LPARAM lParam)
{
	LoadLogFonts();
	{
		LOGFONT lf;
		HFONT hFont;
		int iText;

		LoadMsgDlgFont(0, &lf, NULL);
		hFont = CreateFontIndirect(&lf);
		iText = GetTextPixelSize(MakeTimeStamp(g_Settings.pszTimeStamp, time(NULL)),hFont, TRUE);
		DeleteObject(hFont);
		g_Settings.LogTextIndent = iText;
		g_Settings.LogTextIndent = g_Settings.LogTextIndent*12/10;
		g_Settings.LogIndentEnabled = (DBGetContactSettingByte(NULL, "Chat", "LogIndentEnabled", 1) != 0)?TRUE:FALSE;
	}
	MM_FontsChanged();
	MM_FixColors();
	SM_BroadcastMessage(NULL, GC_SETWNDPROPS, 0, 0, TRUE);
	return 0;
}
Exemplo n.º 4
0
int OptionsInit(void)
{
	LoadLogFonts();

	LOGFONT lf;
	LoadMsgDlgFont(18, &lf, NULL);
	lstrcpy(lf.lfFaceName, _T("MS Shell Dlg"));
	lf.lfUnderline = lf.lfItalic = lf.lfStrikeOut = 0;
	lf.lfHeight = -17;
	lf.lfWeight = FW_BOLD;
	g_Settings->NameFont = CreateFontIndirect(&lf);
	g_Settings->UserListFont = NULL;
	g_Settings->UserListHeadingsFont = NULL;
	g_Settings->iWidth = db_get_dw(NULL, CHAT_MODULE, "roomwidth", -1);
	g_Settings->iHeight = db_get_dw(NULL, CHAT_MODULE, "roomheight", -1);

	g_Settings->iSplitterX = db_get_w(NULL, CHAT_MODULE, "SplitterX", 105);
	if (g_Settings->iSplitterX <= 50)
		g_Settings->iSplitterX = 105;
	g_Settings->iSplitterY = db_get_w(NULL, CHAT_MODULE, "SplitterY", 90);
	if (g_Settings->iSplitterY <= 65)
		g_Settings->iSplitterY = 90;

	SkinAddNewSoundEx("ChatMessage", LPGEN("Group chats"), LPGEN("Incoming message"));
	SkinAddNewSoundEx("ChatHighlight", LPGEN("Group chats"), LPGEN("Message is highlighted"));
	SkinAddNewSoundEx("ChatAction", LPGEN("Group chats"), LPGEN("User has performed an action"));
	SkinAddNewSoundEx("ChatJoin", LPGEN("Group chats"), LPGEN("User has joined"));
	SkinAddNewSoundEx("ChatPart", LPGEN("Group chats"), LPGEN("User has left"));
	SkinAddNewSoundEx("ChatKick", LPGEN("Group chats"), LPGEN("User has kicked some other user"));
	SkinAddNewSoundEx("ChatMode", LPGEN("Group chats"), LPGEN("User's status was changed"));
	SkinAddNewSoundEx("ChatNick", LPGEN("Group chats"), LPGEN("User has changed name"));
	SkinAddNewSoundEx("ChatNotice", LPGEN("Group chats"), LPGEN("User has sent a notice"));
	SkinAddNewSoundEx("ChatQuit", LPGEN("Group chats"), LPGEN("User has disconnected"));
	SkinAddNewSoundEx("ChatTopic", LPGEN("Group chats"), LPGEN("The topic has been changed"));
	return 0;
}