Compare commits

..

1 Commits

Author SHA1 Message Date
agrynco a2b88f247c Release v0.6.42: use compact pinned checkbox beside history search 2026-11-04 20:38:36 +02:00
9 changed files with 26 additions and 28 deletions
+1 -1
View File
@@ -1,5 +1,5 @@
cmake_minimum_required(VERSION 3.24)
project(KSwitcher VERSION 0.6.41 LANGUAGES CXX RC)
project(KSwitcher VERSION 0.6.42 LANGUAGES CXX RC)
if(NOT WIN32)
message(FATAL_ERROR "KSwitcher uses native Windows APIs")
endif()
+2 -2
View File
@@ -720,9 +720,9 @@ Consecutive duplicates use SHA-256 fingerprints inside the encrypted history ind
Moving OCR isolates its temporary memory rather than reducing the combined processing peak. A controlled three-run comparison retained about 0.8 MiB less private RAM in the caller after recognition; combined peak RAM was about 55.6 MiB before and 56.6 MiB with the helper. Results depend on the image, OCR engine and system.
### Pinned history filter — v0.6.41
### Pinned history checkbox — v0.6.42
Use **Filter → All items / ★ Pinned only** beside the history search box to show all entries or only pinned entries. The text search applies within that filter. Unpinning an item removes it from the pinned view immediately. The filter and search are remembered after closing and reopening history. **Clear history…** still deletes the entire history after confirmation, including entries hidden by the filter.
Check **★ Pinned only** beside the history search box to show only pinned entries; uncheck it to show all entries. The checkbox sits on the left, immediately followed by the search box; its right edge stays aligned with the history list when resizing. The text search applies within that filter. Unpinning an item removes it from the pinned view immediately. The checkbox state and search are remembered after closing and reopening history. **Clear history…** still deletes the entire history after confirmation, including entries hidden by the filter.
### History process and clipboard memory — v0.6.40
Binary file not shown.
+7 -6
View File
@@ -1,15 +1,16 @@
# Latest Windows release
## v0.6.41 — 2026-11-04
## v0.6.42 — 2026-11-04
## Changes
- Added Filter → All items / ★ Pinned only beside the history search box.
- Search is restricted to the selected filter; Unpin immediately removes an entry from the pinned view.
- The filter and search are remembered across Esc and helper restarts. Older saved view state defaults to All items.
- Filtering occurs before content search and preview loading. History still exits its helper when closed; shortcuts and Clear history semantics are unchanged.
- Replaced the history filter dropdown with a one-click **★ Pinned only** checkbox. Checked shows pinned entries; unchecked shows all entries.
- The checkbox sits on the left, with the search field immediately alongside it. The search field keeps its right edge aligned with the history list when the window is resized.
- Existing filter state, search, Unpin behavior and persistence across Esc are preserved. No shortcut or default changed. Clear history still deletes every entry after confirmation, including hidden entries.
## Validation
A dedicated 500-entry integration suite verifies filtering, search intersection, unpinning the last match, returning to all items, persistence across helper restart, text/image paste, clipboard restoration and history helper shutdown. The installed development build was also checked visually. The v0.6.41 release candidate passed dictionary equivalence, 105 synchronization checks and 315 native checks. Its interactive input rerun could not obtain foreground/clipboard access in the current Windows session. The filter integration and visual checks passed before the version-only rebuild; they were not repeated successfully in the inaccessible session.
The dedicated 500-entry history integration suite verifies checkbox clicks, combined search/filter, removal after Unpin, remembered state after helper restart, text/image paste and helper shutdown. The compact layout was checked visually in the installed development build.
The release build also passed dictionary equivalence (140,939 words), 105 sync checks, 315 native checks, 561 input checks, screenshot UI/save/registration, 48 updater checks and updater progress UI.
## Upgrade
Choose **Update** in the tray menu. Legacy v0.3.0–v0.4.1 clients first receive the v0.4.2 compatibility bridge, then the current full release. v0.2.3 and earlier require manual installation.
+1 -1
View File
@@ -1 +1 @@
d367a27bb90895f6e33c41726beeb078edbd924aa96a59904de1c54804b23be9 KSwitcher-win-x64.zip
67cb67d4c08a8722fdd91bb513a9254d781cbee524d2e2eb39721251503b01c9 KSwitcher-win-x64.zip
+3 -3
View File
@@ -9,8 +9,8 @@ IDC_SCREENSHOT_PENCIL CURSOR "icons/lucide/pencil.cur"
1 RT_MANIFEST "app.manifest"
201 RCDATA "update.ps1"
1 VERSIONINFO
FILEVERSION 0,6,41,0
PRODUCTVERSION 0,6,41,0
FILEVERSION 0,6,42,0
PRODUCTVERSION 0,6,42,0
FILEOS VOS_NT_WINDOWS32
FILETYPE VFT_APP
BEGIN
@@ -20,7 +20,7 @@ BEGIN
BEGIN
VALUE "FileDescription", "KSwitcher — native keyboard and clipboard utility"
VALUE "ProductName", "KSwitcher"
VALUE "FileVersion", "0.6.41"
VALUE "FileVersion", "0.6.42"
END
END
BLOCK "VarFileInfo"
+8 -11
View File
@@ -514,7 +514,7 @@ void search(HWND w, HistoryView *v)
v->previewActive = std::make_shared<std::atomic<bool>>(true);
v->closed = false;
auto q = value(w, 101);
const bool pinnedOnly = SendDlgItemMessageW(w, 117, CB_GETCURSEL, 0, 0) == 1;
const bool pinnedOnly = SendDlgItemMessageW(w, 117, BM_GETCHECK, 0, 0) == BST_CHECKED;
auto generation = ++v->generation;
v->pending.clear();
auto *app = v->app;
@@ -740,7 +740,7 @@ LRESULT CALLBACK historyProc(HWND w, UINT msg, WPARAM wp, LPARAM lp)
case WM_COMMAND:
{
int id = LOWORD(wp);
if (id == 117 && HIWORD(wp) == CBN_SELCHANGE)
if (id == 117 && HIWORD(wp) == BN_CLICKED)
{
KillTimer(w, 1);
search(w, v);
@@ -918,7 +918,7 @@ LRESULT CALLBACK historyProc(HWND w, UINT msg, WPARAM wp, LPARAM lp)
int top = (int)SendDlgItemMessageW(w,102,LB_GETTOPINDEX,0,0);
v->rememberedTop = top >= 0 && top < (int)v->items.size() ? v->items[top].id : L"";
v->app->saveHistoryView(v->rememberedSelection, v->rememberedTop, value(w, 101),
SendDlgItemMessageW(w, 117, CB_GETCURSEL, 0, 0) == 1);
SendDlgItemMessageW(w, 117, BM_GETCHECK, 0, 0) == BST_CHECKED);
KillTimer(w, 1);
v->closed = true;
v->previewActive->store(false);
@@ -1745,14 +1745,11 @@ void showHistory(App &app, bool visible)
HWND w = makeWindow(app, L"KSwitcher.History", L"Clipboard history", historyProc, 760, 500);
app.historyWindow = w;
windowLayoutState(w)->history = true;
label(w, L"&Filter", 16, 12, 170);
auto filter = control(w, L"COMBOBOX", L"", WS_TABSTOP | CBS_DROPDOWNLIST | WS_VSCROLL,
117, 16, 38, 170, 100);
SendMessageW(filter, CB_ADDSTRING, 0, (LPARAM)L"All items");
SendMessageW(filter, CB_ADDSTRING, 0, (LPARAM)L"★ Pinned only");
SendMessageW(filter, CB_SETCURSEL, app.historyPinnedOnly ? 1 : 0, 0);
label(w, L"&Search clipboard history", 194, 12, 500);
edit(w, 101, 194, 38, 550);
auto filter = control(w, L"BUTTON", L"★ Pinned only", WS_TABSTOP | BS_AUTOCHECKBOX,
117, 16, 38, 112, 25);
SendMessageW(filter, BM_SETCHECK, app.historyPinnedOnly ? BST_CHECKED : BST_UNCHECKED, 0);
label(w, L"&Search clipboard history", 136, 12, 500);
edit(w, 101, 136, 38, 608);
auto list = control(w, L"LISTBOX", L"",
WS_TABSTOP | WS_VSCROLL | LBS_NOTIFY | LBS_NOINTEGRALHEIGHT | WS_BORDER |
LBS_OWNERDRAWFIXED | LBS_HASSTRINGS,
+1 -1
View File
@@ -2,7 +2,7 @@
#include "platform.h"
namespace ks
{
inline constexpr wchar_t AppVersion[] = L"0.6.41";
inline constexpr wchar_t AppVersion[] = L"0.6.42";
inline constexpr UINT UpdateMessage = WM_APP + 7;
inline constexpr UINT UpdateCheckIntervalMs = 6 * 60 * 60 * 1000;
inline constexpr UINT UpdateNotificationRetryMs = 5 * 60 * 1000;
+3 -3
View File
@@ -113,8 +113,8 @@ int main() {
until([&]{history.reload();return history.entries().front().pinned;},"resident pin mutation");
require(history.entries().front().id==textId,"pin preserves history identity");
auto filter=[&](HWND window,int index) {
send(GetDlgItem(window,117),CB_SETCURSEL,index);
send(window,WM_COMMAND,MAKEWPARAM(117,CBN_SELCHANGE),LPARAM(GetDlgItem(window,117)));
auto checkbox=GetDlgItem(window,117);
if(send(checkbox,BM_GETCHECK)!=(index ? BST_CHECKED : BST_UNCHECKED)) send(checkbox,BM_CLICK);
};
filter(w,1);
until([&]{return send(GetDlgItem(w,102),LB_GETCOUNT)==1;},"pinned filter hides unpinned entries");
@@ -129,7 +129,7 @@ int main() {
send(w,WM_COMMAND,112);
filter(w,1);
close(w);w=open();
require(send(GetDlgItem(w,117),CB_GETCURSEL)==1,"pinned filter survives helper restart");
require(send(GetDlgItem(w,117),BM_GETCHECK)==BST_CHECKED,"pinned checkbox survives helper restart");
wchar_t query[100]{};send(GetDlgItem(w,101),WM_GETTEXT,100,LPARAM(query));
require(std::wstring(query)==L"History fixture 498","search survives helper restart");
send(w,WM_COMMAND,114);