diff options
author | George Hazan <george.hazan@gmail.com> | 2024-02-19 20:38:48 +0300 |
---|---|---|
committer | George Hazan <george.hazan@gmail.com> | 2024-02-19 20:38:48 +0300 |
commit | e067f891787c54aac07ab2ac60ef866a7df69165 (patch) | |
tree | 774cd773ebf69c776141a9ef3471b0768890610b | |
parent | 7b2016dd3679ffc8f47a138348cd2e63bcc4b69e (diff) |
NS: code merge
-rw-r--r-- | plugins/NewStory/src/options.cpp | 3 | ||||
-rw-r--r-- | plugins/NewStory/src/resource.h | 5 | ||||
-rw-r--r-- | plugins/NewStory/src/stdafx.h | 6 | ||||
-rw-r--r-- | plugins/NewStory/src/utils.cpp | 6 |
4 files changed, 20 insertions, 0 deletions
diff --git a/plugins/NewStory/src/options.cpp b/plugins/NewStory/src/options.cpp index 1ac3e632c1..7decb0d967 100644 --- a/plugins/NewStory/src/options.cpp +++ b/plugins/NewStory/src/options.cpp @@ -261,6 +261,9 @@ public: AppendSymbol(wszVarHelp, L"%p", TranslateT("AM/PM symbol"));
AppendSymbol(wszVarHelp, L"%O", TranslateT("name of month, translatable"));
AppendSymbol(wszVarHelp, L"%M", TranslateT("the message string itself"));
+ AppendSymbol(wszVarHelp, L"[c0]", TranslateT("default text color"));
+ AppendSymbol(wszVarHelp, L"[c1]", TranslateT("nickname's color"));
+ AppendSymbol(wszVarHelp, L"[c2]-[c6]", TranslateT("one of the user defined custom color from the options page for the following text output (X is a number from 2 to 6, referring to the color index)"));
MessageBox(m_hwnd, wszVarHelp, TranslateT("Variables help"), MB_OK);
}
diff --git a/plugins/NewStory/src/resource.h b/plugins/NewStory/src/resource.h index c8de56f5fa..db0947d98b 100644 --- a/plugins/NewStory/src/resource.h +++ b/plugins/NewStory/src/resource.h @@ -99,6 +99,11 @@ #define IDC_TOPLINE 1062
#define IDC_DELSERVERHISTORY 1063
#define IDC_BOTH 1064
+#define IDC_COLOR1 1065
+#define IDC_COLOR2 1066
+#define IDC_COLOR3 1067
+#define IDC_COLOR4 1068
+#define IDC_COLOR5 1069
#define ID_FILTER_SHOWALLEVENTS 40001
#define ID_FILTER_SHOWINCOMINGEVENTSONLY 40002
#define ID_FILTER_SHOWOUTGOINGEVENTSONLY 40003
diff --git a/plugins/NewStory/src/stdafx.h b/plugins/NewStory/src/stdafx.h index 11fa8753b4..f1750a365b 100644 --- a/plugins/NewStory/src/stdafx.h +++ b/plugins/NewStory/src/stdafx.h @@ -104,12 +104,18 @@ struct CMPlugin : public PLUGIN<CMPlugin> bool bMsgGrouping, bDrawEdge, bHppCompat, bDisableDelete = false;
bool bShowType, bShowDirecction;
+ COLORREF clCustom[5];
+
CMPlugin();
+ void LoadOptions();
+
int Load() override;
int Unload() override;
};
extern CMOption<bool> g_bOptGrouping, g_bOptDrawEdge, g_bOptHppCompat, g_bShowType, g_bShowDirection;
+extern CMOption<uint32_t> g_clCustom0, g_clCustom1, g_clCustom2, g_clCustom3, g_clCustom4;
+
extern wchar_t* months[12];
extern int g_iPixelY;
diff --git a/plugins/NewStory/src/utils.cpp b/plugins/NewStory/src/utils.cpp index 732728bf0b..69057fcdd1 100644 --- a/plugins/NewStory/src/utils.cpp +++ b/plugins/NewStory/src/utils.cpp @@ -61,8 +61,14 @@ static bbcodes[] = { L"[color=", L"]" },
{ L"[/color]", nullptr },
+
{ L"[c0]", nullptr },
{ L"[c1]", nullptr },
+ { L"[c2]", nullptr },
+ { L"[c3]", nullptr },
+ { L"[c4]", nullptr },
+ { L"[c5]", nullptr },
+ { L"[c6]", nullptr },
{ L"[$hicon=", L"$]" },
|