diff options
author | George Hazan <george.hazan@gmail.com> | 2012-06-25 15:05:30 +0000 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2012-06-25 15:05:30 +0000 |
commit | ed1449fa491e90197b78b64b52c70910f1736dd7 (patch) | |
tree | 208788e9ee24ec2bcd90a4f4d7a166a534baa53e /plugins/Console | |
parent | 2a06d7b1dbe99233e078819c78956e346175b420 (diff) |
dynamic fonts' options translation
git-svn-id: http://svn.miranda-ng.org/main/trunk@633 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/Console')
-rw-r--r-- | plugins/Console/Console.cpp | 87 |
1 files changed, 37 insertions, 50 deletions
diff --git a/plugins/Console/Console.cpp b/plugins/Console/Console.cpp index 24f187cee1..3a5db7f64c 100644 --- a/plugins/Console/Console.cpp +++ b/plugins/Console/Console.cpp @@ -1259,56 +1259,43 @@ static int OnSystemModulesLoaded(WPARAM wParam,LPARAM lParam) CreateServiceFunction(MS_CONSOLE_SHOW_HIDE, ShowHideConsole);
- {
- FontIDT fid={0};
- fid.cbSize = sizeof(fid);
- _tcscpy(fid.group,_T("Console"));
- _tcscpy(fid.name,TranslateT("Text"));
- strcpy(fid.dbSettingsGroup,"Console");
- strcpy(fid.prefix,"ConsoleFont");
-
- _tcscpy(fid.backgroundGroup,_T("Console"));
- _tcscpy(fid.backgroundName,_T("Background"));
-
- fid.flags = FIDF_DEFAULTVALID;
-
- fid.deffontsettings.charset = DEFAULT_CHARSET;
- fid.deffontsettings.colour = RGB(0, 0, 0);
- fid.deffontsettings.size = 10;
- fid.deffontsettings.style = 0;
- _tcsncpy(fid.deffontsettings.szFace, _T("Courier"), LF_FACESIZE);
-
- CallService(MS_FONT_REGISTERT,(WPARAM)&fid,0);
-
- hHooks[i++] = HookEvent(ME_FONT_RELOAD,OnFontChange);
- }
-
- {
- ColourIDT cid = {0};
-
- cid.cbSize=sizeof(cid);
- _tcscpy(cid.group,_T("Console"));
- _tcscpy(cid.name,_T("Background"));
- strcpy(cid.dbSettingsGroup,"Console");
- strcpy(cid.setting,"BgColor");
-
- cid.defcolour = RGB(255,255,255);
-
- CallService(MS_COLOUR_REGISTERT,(WPARAM)&cid,0);
-
- hHooks[i++] = HookEvent(ME_COLOUR_RELOAD, OnColourChange);
- }
-
- {
- HOTKEYDESC hkd = {0};
- hkd.cbSize = sizeof(hkd);
- hkd.pszName = "Console_Show_Hide";
- hkd.pszDescription = LPGEN("Show/Hide Console");
- hkd.pszSection = "Main";
- hkd.pszService = MS_CONSOLE_SHOW_HIDE;
- hkd.DefHotKey = HOTKEYCODE(HOTKEYF_EXT, 'C');
- Hotkey_Register(&hkd);
- }
+ FontIDT fid = {0};
+ fid.cbSize = sizeof(fid);
+ _tcscpy(fid.group,_T("Console"));
+ _tcscpy(fid.name,TranslateT("Text"));
+ strcpy(fid.dbSettingsGroup,"Console");
+ strcpy(fid.prefix,"ConsoleFont");
+ _tcscpy(fid.backgroundGroup,_T("Console"));
+ _tcscpy(fid.backgroundName,_T("Background"));
+ fid.flags = FIDF_DEFAULTVALID;
+ fid.deffontsettings.charset = DEFAULT_CHARSET;
+ fid.deffontsettings.colour = RGB(0, 0, 0);
+ fid.deffontsettings.size = 10;
+ fid.deffontsettings.style = 0;
+ _tcsncpy(fid.deffontsettings.szFace, _T("Courier"), LF_FACESIZE);
+ FontRegisterT(&fid);
+
+ hHooks[i++] = HookEvent(ME_FONT_RELOAD,OnFontChange);
+
+ ColourIDT cid = {0};
+ cid.cbSize=sizeof(cid);
+ _tcscpy(cid.group,_T("Console"));
+ _tcscpy(cid.name,_T("Background"));
+ strcpy(cid.dbSettingsGroup,"Console");
+ strcpy(cid.setting,"BgColor");
+ cid.defcolour = RGB(255,255,255);
+ ColourRegisterT(&cid);
+
+ hHooks[i++] = HookEvent(ME_COLOUR_RELOAD, OnColourChange);
+
+ HOTKEYDESC hkd = {0};
+ hkd.cbSize = sizeof(hkd);
+ hkd.pszName = "Console_Show_Hide";
+ hkd.pszDescription = LPGEN("Show/Hide Console");
+ hkd.pszSection = "Main";
+ hkd.pszService = MS_CONSOLE_SHOW_HIDE;
+ hkd.DefHotKey = HOTKEYCODE(HOTKEYF_EXT, 'C');
+ Hotkey_Register(&hkd);
if (ServiceExists(MS_TB_ADDBUTTON)) {
TBButton tbb = {0};
|