├── HexTest
├── HexTest.h
├── res
│ └── HexTest.ico
├── packages.config
├── stdafx.cpp
├── resource.h
├── AboutDlg.cpp
├── AboutDlg.h
├── HexTest.cpp
├── View.cpp
├── stdafx.h
├── View.h
├── MainFrm.h
├── MainFrm.cpp
└── HexTest.vcxproj.filters
├── BasicDemo
├── BasicDemo.h
├── res
│ └── BasicDemo.ico
├── packages.config
├── pch.cpp
├── AboutDlg.cpp
├── resource.h
├── AboutDlg.h
├── BasicDemo.cpp
├── pch.h
├── ProcessTreeListView.h
├── BasicDemo.vcxproj.filters
├── MainFrm.h
├── MainFrm.cpp
└── ProcessTreeListView.cpp
├── WTLHelper
├── WTLHelper.rc
├── res
│ ├── Collapsed.ico
│ ├── Expanded.ico
│ ├── Expanded2.ico
│ └── Collapsed2.ico
├── WTLHelper.cpp
├── README.md
├── ClipboardHelper.h
├── DarkModeHelper.h
├── StringHelper.h
├── pch.cpp
├── ColorHelper.h
├── IconHelper.h
├── WTLHelperRes.h
├── ToolbarHelper.h
├── StringHelper.cpp
├── IBufferManager.h
├── pch.h
├── CustomEdit.h
├── VersionResourceHelper.h
├── ClipboardHelper.cpp
├── CustomListView.h
├── Theme.cpp
├── IconHelper.cpp
├── SortHelper.h
├── Selection.h
├── CustomTreeView.h
├── ThemeHelper.h
├── FrameView.h
├── ColorHelper.cpp
├── WTLx.h
├── CustomComboBox.h
├── ToolbarHelper.cpp
├── Theme.h
├── IniFile.h
├── SizeGrip.h
├── CustomRebar.h
├── VersionResourceHelper.cpp
├── Selection.cpp
├── CompoundFileReaderWriter.cpp
├── CustomTabView.h
├── CustomDialog.h
├── CustomToolBar.h
├── SortHelper.cpp
├── CustomButton.h
├── DialogHelper.h
├── IListView.cpp
├── CustomTabControl.h
├── CustomSplitterWindow.h
├── ListViewhelper.h
├── CompoundFile.h
├── IATHook.h
├── QuickFindEdit.h
├── CompoundFile.cpp
├── OwnerDrawnMenu.cpp
├── CompoundFileReaderWriter.h
├── IniFile.cpp
├── ColumnManager.h
├── CustomStatusBar.h
├── CustomTabView.cpp
├── ColumnManager.cpp
├── Settings.cpp
├── CustomHeader.h
├── TreeViewHelper.h
├── SortedFilteredVector.h
├── Settings.h
├── HexControl.h
├── WTLHelper.vcxproj.filters
├── ListViewhelper.cpp
├── OwnerDrawnMenu.h
├── ThemeHelper.cpp
└── DarkModeHelper.cpp
├── packages.config
├── WTLHelper.sln
├── .gitattributes
└── .gitignore
/HexTest/HexTest.h:
--------------------------------------------------------------------------------
1 | // HexTest.h
2 |
--------------------------------------------------------------------------------
/BasicDemo/BasicDemo.h:
--------------------------------------------------------------------------------
1 | // BasicDemo.h
2 |
--------------------------------------------------------------------------------
/WTLHelper/WTLHelper.rc:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/WTLHelper/WTLHelper.rc
--------------------------------------------------------------------------------
/HexTest/res/HexTest.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/HexTest/res/HexTest.ico
--------------------------------------------------------------------------------
/BasicDemo/res/BasicDemo.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/BasicDemo/res/BasicDemo.ico
--------------------------------------------------------------------------------
/WTLHelper/res/Collapsed.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/WTLHelper/res/Collapsed.ico
--------------------------------------------------------------------------------
/WTLHelper/res/Expanded.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/WTLHelper/res/Expanded.ico
--------------------------------------------------------------------------------
/WTLHelper/res/Expanded2.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/WTLHelper/res/Expanded2.ico
--------------------------------------------------------------------------------
/WTLHelper/res/Collapsed2.ico:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/zodiacon/WTLHelper/HEAD/WTLHelper/res/Collapsed2.ico
--------------------------------------------------------------------------------
/WTLHelper/WTLHelper.cpp:
--------------------------------------------------------------------------------
1 | // WTLHelper.cpp : Defines the functions for the static library.
2 | //
3 |
4 | #include "pch.h"
5 |
--------------------------------------------------------------------------------
/WTLHelper/README.md:
--------------------------------------------------------------------------------
1 | # WTLHelper
2 | WTL helper library
3 |
4 | Something I use in my own tools (or working to port common parts to use WTLHelper).
5 |
--------------------------------------------------------------------------------
/WTLHelper/ClipboardHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct ClipboardHelper abstract final {
4 | static bool CopyText(HWND hWnd, PCWSTR text);
5 | };
6 |
7 |
--------------------------------------------------------------------------------
/BasicDemo/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/HexTest/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/WTLHelper/DarkModeHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct DarkModeHelper {
4 | static void Init();
5 | static void AllowDarkModeForApp(bool allow);
6 | static void RefreshTitleBarThemeColor(HWND hWnd);
7 | };
8 |
9 |
--------------------------------------------------------------------------------
/WTLHelper/StringHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | #include
4 |
5 | struct StringHelper {
6 | static CString Format(PCWSTR format, ...);
7 | static CString& Format(CString& text, PCWSTR format, ...);
8 | };
9 |
--------------------------------------------------------------------------------
/WTLHelper/pch.cpp:
--------------------------------------------------------------------------------
1 | // pch.cpp: source file corresponding to the pre-compiled header
2 |
3 | #include "pch.h"
4 |
5 | // When you are using pre-compiled headers, this source file is necessary for compilation to succeed.
6 |
--------------------------------------------------------------------------------
/BasicDemo/pch.cpp:
--------------------------------------------------------------------------------
1 | // stdafx.cpp : source file that includes just the standard includes
2 | // BasicDemo.pch will be the pre-compiled header
3 | // stdafx.obj will contain the pre-compiled type information
4 |
5 | #include "pch.h"
6 |
--------------------------------------------------------------------------------
/HexTest/stdafx.cpp:
--------------------------------------------------------------------------------
1 | // stdafx.cpp : source file that includes just the standard includes
2 | // HexTest.pch will be the pre-compiled header
3 | // stdafx.obj will contain the pre-compiled type information
4 |
5 | #include "stdafx.h"
6 |
--------------------------------------------------------------------------------
/WTLHelper/ColorHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct ColorHelper abstract final {
4 | static COLORREF Lighten(COLORREF color, int amount);
5 | static COLORREF Darken(COLORREF color, int amount);
6 | static bool IsSystemThemeDark();
7 | };
8 |
--------------------------------------------------------------------------------
/WTLHelper/IconHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct IImageList2;
4 |
5 | struct IconHelper {
6 | static HICON GetStockIcon(SHSTOCKICONID id, bool big = false);
7 | static HICON GetShieldIcon();
8 | static CComPtr CreateImageList();
9 | };
10 |
--------------------------------------------------------------------------------
/WTLHelper/WTLHelperRes.h:
--------------------------------------------------------------------------------
1 | //{{NO_DEPENDENCIES}}
2 | // Microsoft Visual C++ generated include file.
3 | // Used by WTLHelper.rc
4 | //
5 | #define IDI_COLLAPSED 10100
6 | #define IDI_COLLAPSED2 10101
7 | #define IDI_EXPANDED 10102
8 | #define IDI_EXPANDED2 10103
9 |
10 |
--------------------------------------------------------------------------------
/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/WTLHelper/ToolbarHelper.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct ToolBarButtonInfo {
4 | UINT id;
5 | int image;
6 | BYTE style = BTNS_BUTTON;
7 | PCWSTR text = nullptr;
8 | };
9 |
10 |
11 | struct ToolbarHelper {
12 | static HWND CreateAndInitToolBar(HWND hWnd, const ToolBarButtonInfo* buttons, int count, int size = 24);
13 | static POINT GetDropdownMenuPoint(HWND hToolBar, UINT buttonId);
14 | };
15 |
--------------------------------------------------------------------------------
/WTLHelper/StringHelper.cpp:
--------------------------------------------------------------------------------
1 | #include "pch.h"
2 | #include "StringHelper.h"
3 |
4 | CString StringHelper::Format(PCWSTR format, ...) {
5 | va_list argList;
6 | va_start(argList, format);
7 | CString text;
8 | text.Format(format, argList);
9 | va_end(argList);
10 | return text;
11 | }
12 |
13 | CString& StringHelper::Format(CString& text, PCWSTR format, ...) {
14 | va_list argList;
15 | va_start(argList, format);
16 | text.Format(format, argList);
17 | va_end(argList);
18 | return text;
19 | }
20 |
21 |
--------------------------------------------------------------------------------
/HexTest/resource.h:
--------------------------------------------------------------------------------
1 | //{{NO_DEPENDENCIES}}
2 | // Microsoft Visual C++ generated include file.
3 | // Used by HexTest.RC
4 | //
5 |
6 |
7 | #define IDD_ABOUTBOX 100
8 | #define IDR_MAINFRAME 128
9 | //#define IDR_HEXTESTTYPE 129
10 |
11 | // Next default values for new objects
12 | //
13 | #ifdef APSTUDIO_INVOKED
14 | #ifndef APSTUDIO_READONLY_SYMBOLS
15 | #define _APS_NEXT_RESOURCE_VALUE 201
16 | #define _APS_NEXT_CONTROL_VALUE 1000
17 | #define _APS_NEXT_SYMED_VALUE 101
18 | #define _APS_NEXT_COMMAND_VALUE 32775
19 | #endif
20 | #endif
21 |
--------------------------------------------------------------------------------
/BasicDemo/AboutDlg.cpp:
--------------------------------------------------------------------------------
1 | // aboutdlg.cpp : implementation of the CAboutDlg class
2 | //
3 | /////////////////////////////////////////////////////////////////////////////
4 |
5 | #include "pch.h"
6 | #include "resource.h"
7 | #include "aboutdlg.h"
8 |
9 | LRESULT CAboutDlg::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/) {
10 | CenterWindow(GetParent());
11 | return TRUE;
12 | }
13 |
14 | LRESULT CAboutDlg::OnCloseCmd(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/) {
15 | EndDialog(wID);
16 | return 0;
17 | }
18 |
--------------------------------------------------------------------------------
/WTLHelper/IBufferManager.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | struct IBufferManager {
4 | virtual ~IBufferManager() = default;
5 |
6 | virtual uint32_t GetData(int64_t offset, uint8_t* buffer, uint32_t count) = 0;
7 | virtual bool Insert(int64_t offset, const uint8_t* data, uint32_t count) = 0;
8 | virtual bool Delete(int64_t offset, size_t count) = 0;
9 | virtual bool SetData(int64_t offset, const uint8_t* data, uint32_t count) = 0;
10 | virtual int64_t GetSize() const = 0;
11 | virtual uint8_t* GetRawData(int64_t offset) = 0;
12 | virtual bool IsReadOnly() const = 0;
13 | };
14 |
15 |
--------------------------------------------------------------------------------
/HexTest/AboutDlg.cpp:
--------------------------------------------------------------------------------
1 | // aboutdlg.cpp : implementation of the CAboutDlg class
2 | //
3 | /////////////////////////////////////////////////////////////////////////////
4 |
5 | #include "stdafx.h"
6 | #include "resource.h"
7 |
8 | #include "aboutdlg.h"
9 |
10 | LRESULT CAboutDlg::OnInitDialog(UINT /*uMsg*/, WPARAM /*wParam*/, LPARAM /*lParam*/, BOOL& /*bHandled*/)
11 | {
12 | CenterWindow(GetParent());
13 | return TRUE;
14 | }
15 |
16 | LRESULT CAboutDlg::OnCloseCmd(WORD /*wNotifyCode*/, WORD wID, HWND /*hWndCtl*/, BOOL& /*bHandled*/)
17 | {
18 | EndDialog(wID);
19 | return 0;
20 | }
21 |
--------------------------------------------------------------------------------
/WTLHelper/pch.h:
--------------------------------------------------------------------------------
1 | #pragma once
2 |
3 | #include
4 | #include
5 | #include
6 | #include
7 | #include
8 | #include
9 | #include
10 | #include
11 | #include
12 | #include
13 | #include
14 | #include
15 | #include
16 | #include
17 | #include
18 | #include