hluk / copyq-commands

Useful commands for CopyQ clipboard manager.
331 stars 73 forks source link

Fix 'Clear Clipboard Tab' not working when there are pinned items #47

Closed zyw271828 closed 3 years ago

hluk commented 3 years ago

Thanks for the PR.

Couple of problems:

It would be probably better to add some better support for filtering items from scripts or add a new function to remove all rows when possible and skip the pinned rows.

hluk commented 3 years ago

It would be probably better to add some better support for filtering items from scripts or add a new function to remove all rows when possible and skip the pinned rows.

I've created https://github.com/hluk/CopyQ/pull/1746 which would allow among other things:

ItemSelection(tabName).selectRemovable().removeAll();

Comments are welcome.

zyw271828 commented 3 years ago

This will make writing scripts very convenient, thank you!

Actually, I think it would be better to make "Clear all" a built-in feature instead of a script function. The clipboard of Windows 10 provides this feature, and Windows 11 puts it in a more prominent position. Microsoft may think that the usage rate of this feature is high.

hluk commented 3 years ago

In the next release, there will be also a predefined command to Clear Current Tab (it will be possible to add it from the Command dialog).