Skip to content

Commit

Permalink
Squashed merge from branch master 2489b88 to branch feature-issue171.
Browse files Browse the repository at this point in the history
  • Loading branch information
end2endzone committed Oct 11, 2024
1 parent bd042c7 commit ac172db
Show file tree
Hide file tree
Showing 58 changed files with 2,572 additions and 222 deletions.
4 changes: 4 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,17 @@ Changes for 0.10.0
* Fixed issue #31 : (twice) Error in logs for CContextMenu::GetCommandString()
* Fixed issue #109: Implement default and verbose logging.
* Fixed issue #110: Create a simple command line arguments debugging application.
* Fixed issue #148: Can't uninstall.
* Fixed issue #150: ico icon (that do not specifically force index=0) are not working.
* Fixed issue #157: Compilation fails on Github Action: `fatal error C1083: Cannot open include file: 'atlbase.h': No such file or directory`.
* Fixed issue #158: Compilation fails on Github Action: `CPack error : Problem running WiX.`.
* Fixed issue #159: Unit test fails on Github Actions: TestPlugins.testServices().
* Fixed issue #161: Create tools to help quickly find a system icon when creating a menu.
* Fixed issue #164: Fails to identify icon for HTML files.
* Fixed issue #167: Improve the quality and accuracy of icon's fileextension attribute resolution (Icon::ResolveFileExtensionIcon()).
* Fixed issue #171: New logo icon.
* Fixed issue #177: Execute a console program without showing a window.
* Fixed issue #178: Exec action should expose the created process id.


Changes for 0.9.0
Expand Down
4 changes: 4 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,7 @@ set(SHELLANYTHING_INSTALL_ROOT_DIR "/")
set(SHELLANYTHING_INSTALL_BIN_DIR "bin")
set(SHELLANYTHING_INSTALL_LIB_DIR "lib/shellanything-${SHELLANYTHING_VERSION}")
set(SHELLANYTHING_INSTALL_INCLUDE_DIR "include/shellanything-${SHELLANYTHING_VERSION}")
set(SHELLANYTHING_INSTALL_RESOURCE_DIR "resources")
set(SHELLANYTHING_INSTALL_CMAKE_DIR ${SHELLANYTHING_INSTALL_LIB_DIR}) # CMake files (*.cmake) should have the same destination as the library files. Some also prefers to use "cmake".
set(SHELLANYTHING_INSTALL_DOC_DIR "docs")

Expand Down Expand Up @@ -376,6 +377,9 @@ install(FILES ${CMAKE_SOURCE_DIR}/resources/register.bat
${CMAKE_SOURCE_DIR}/resources/unregister.bat
DESTINATION ${SHELLANYTHING_INSTALL_BIN_DIR})

# Resources
install(DIRECTORY "${CMAKE_SOURCE_DIR}/resources/Windows Icon Tables" DESTINATION ${SHELLANYTHING_INSTALL_RESOURCE_DIR})

install(DIRECTORY ${CMAKE_SOURCE_DIR}/include/shellanything DESTINATION ${SHELLANYTHING_INSTALL_INCLUDE_DIR})
install(FILES ${SHELLANYTHING_EXPORT_HEADER}
${SHELLANYTHING_VERSION_HEADER}
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ The main features of ShellAnything are:
* Easily integrate any third party application with custom menus.
* Supports windows [keyboard mnemonics](https://en.wikipedia.org/wiki/Mnemonics_(keyboard)).

For more details about ShellAnything features, please refer to the [User Manual](UserManual.md).
**_For more details about ShellAnything features, please refer to the [User Manual](UserManual.md)._**



Expand Down
91 changes: 70 additions & 21 deletions UserManual.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ This manual includes a description of the system functionalities and capabilitie
* [Tools](#tools)
* [file_explorer_renew](#file_explorer_renew)
* [arguments.debugger](#argumentsdebugger)
* [Windows icons preview images](#windows-icons-preview-images)
* [Plugins](#plugins)
* [Plugin overview](#plugin-overview)
* [C API](#c-api)
Expand Down Expand Up @@ -685,16 +686,7 @@ For instance, the following icon definition uses the same icon as the clicked fi
<icon fileextension="${selection.filename.extension}" />
```


*_Hint_*: you can use Windows own icons to assign your &lt;icon&gt; with familiar Windows icons.
The following links shows a visual representation and the index of each icons:
* [Windows 7 icons in shell32.dll](https://help4windows.com/windows_7_shell32_dll.shtml)
* [Windows 7 icons in imageres.dll](https://help4windows.com/windows_7_imageres_dll.shtml)
* [Windows 8 icons in shell32.dll](https://help4windows.com/windows_8_shell32_dll.shtml)
* [Windows 8 icons in imageres.dll](https://help4windows.com/windows_8_imageres_dll.shtml)
* [Windows 10 icons in shell32.dll](https://help4windows.com/)
* [Windows 10 icons in imageres.dll](https://help4windows.com/)

*_Hint_*: Windows have a variety of built-in icons available. You can assign a Windows built-in icons to an &lt;icon&gt; to give a familiar Windows looks and feel to your menus. See the [Windows icons preview](#windows-icons-preview) section in Tools for more details.



Expand All @@ -714,6 +706,9 @@ The application support multiple types of actions. The list of each specific act

The &lt;exec&gt; element is used to launch an application. The &lt;exec&gt; element must be added under the &lt;actions&gt; element.

**Note:**
When a process is created, ShellAnything will set property `process.id` to the process id of the new launched application.

The &lt;exec&gt; elements have the following attributes:


Expand Down Expand Up @@ -762,7 +757,7 @@ For example, the following launch `cmd.exe` and list files and directories recur
```

**Note:**
It is recommanded to use the `wait` attribute with the `timeout` attribute. Without a _timeout_ value, ShellAnything will wait indefinitely until the launched process exits. This can result in system instability. If the launced process freezes, pauses or never exists, it will lock _ShellAnything_ and _File Explorer_.
It is recommanded to use the `wait` attribute with the `timeout` attribute. Without a _timeout_ value, ShellAnything will wait indefinitely until the launched process exits. This can result in system instability. If the launced process freezes, pauses or never exists, it will lock _ShellAnything_ and _File Explorer_ forever.

When combined with other elements, the `wait` attribute allows advanced use case.

Expand All @@ -781,6 +776,7 @@ Tell ShellAnything to wait until the search is complete before proceeding to the




#### timeout attribute: ####

The `timeout` attribute defines the maximum time to wait in seconds with the `wait` attribute. If the running process fails to exit before the _timeout_ value, a warning is logged and the next actions of the menu are not executed. The value must be numerical. The attribute is optional.
Expand All @@ -792,6 +788,34 @@ For example, the following launch `cmd.exe` and list files and directories recur



#### console attribute: ####

The `console` attribute defines how we should display the main window of the launched application. The attribute allow console applications to be launched without a console. The feature is particularly useful for running background tasks. The attribute must be set to a value that evaluates to `false` to enable the feature. See [istrue attribute](https://github.com/end2endzone/ShellAnything/blob/master/UserManual.md#istrue-attribute) or [isfalse attribute](https://github.com/end2endzone/ShellAnything/blob/master/UserManual.md#isfalse-attribute) logic for details. The attribute is optional.

For example, the following will launch ImageMagick `magick.exe` command line application to convert webp images to jpg :
```xml
<exec wait="true" console="off" path="${imagemagick.path}" arguments="&quot;${selection.path}&quot; &quot;${selection.filename.noext}.jpg&quot;" />
```
The conversion to JPEG format will be performed without showing a console and no window flickering will be visible.

**Note:**
* The _console_ attribute may also affects windowed applications and may hide their main graphical user interface.
* Users must be careful when launching background applications (hidden applications). A background application should not wait for user input or it may never complete/terminate gracefully. Background tasks can also cause system instability if the `wait` attribute is also set and the background process freezes, pauses or never exists because it will lock _ShellAnything_ and _File Explorer_ forever.



#### pid attribute: ####

The `pid` attribute defines the name of the property to set with the new launch process id.

For example, the following will sets the property `mspaint.process.id` to the process id of `mspaint.exe` :
```xml
<exec path="C:\Windows\System32\mspaint.exe" pid="mspaint.process.id" />
```

The target property is left untouched if the process cannot be launched.


#### verb attribute: ####

The `verb` attribute defines special directives on how to execute a file or launching the application. For example, the verb `open` or `edit` allows the user to open a document using the associated application. The attribute is optional.
Expand Down Expand Up @@ -1750,16 +1774,18 @@ The application defines a list of properties about the current runtime. The valu

The following table defines the list of fixed properties and their utility:

| Property | Description |
|-----------------------|----------------------------------------------------------|
| application.path | Matches the full path of the shell extension DLL. |
| application.directory | Matches the directory of the shell extension. |
| log.directory | Matches the directory where the logs are created. |
| config.directory | Matches the directory of the configuration files. |
| home.directory | Matches the home directory of the current user. |
| path.separator | Matches the `\` character. |
| line.separator | Matches the `\r\n` string. |
| newline | Matches the `\r\n` string. Same as `${line.separator}`. |
| Property | Description |
|-------------------------------|---------------------------------------------------------|
| application.path | Matches the full path of the shell extension DLL. |
| application.directory | Matches the directory of the shell extension. |
| application.install.directory | Matches the directory where ShellAnything is installed. |
| application.version | Matches ShellAnything current version. |
| log.directory | Matches the directory where the logs are created. |
| config.directory | Matches the directory of the configuration files. |
| home.directory | Matches the home directory of the current user. |
| path.separator | Matches the `\` character. |
| line.separator | Matches the `\r\n` string. |
| newline | Matches the `\r\n` string. Same as `${line.separator}`. |


Fixed properties are encoded in utf-8.
Expand Down Expand Up @@ -1873,6 +1899,29 @@ argv[33]=Ψψ
argv[34]=Ωω.
```



### Windows icons preview images ###

Windows have a variety of built-in icons available. You can assign a Windows built-in icons to an &lt;icon&gt; to give a familiar Windows looks and feel to your menus. ShellAnything has preview images of the icons in most Windows dll. It allows one to quickly identify the file and the index of a desired icon.

The following images show all icons within popular Windows dll files:

Microsoft Windows 10 Home:
* [shell32.dll](resources/Windows%20Icon%20Tables/Win%2010%20Home%20-%20shell32.dll%20icons.png)
* [imageres.dll](resources/Windows%20Icon%20Tables/Win%2010%20Home%20-%20imageres.dll%20icons.png)
* [ieframe.dll](resources/Windows%20Icon%20Tables/Win%2010%20Home%20-%20ieframe.dll%20icons.png)
* [netshell.dll](resources/Windows%20Icon%20Tables/Win%2010%20Home%20-%20netshell.dll%20icons.png)

Microsoft Windows 11 Pro:
* [shell32.dll](resources/Windows%20Icon%20Tables/Win%2011%20Pro%20-%20shell32.dll%20icons.png)
* [imageres.dll](resources/Windows%20Icon%20Tables/Win%2011%20Pro%20-%20imageres.dll%20icons.png)
* [ieframe.dll](resources/Windows%20Icon%20Tables/Win%2011%20Pro%20-%20ieframe.dll%20icons.png)
* [netshell.dll](resources/Windows%20Icon%20Tables/Win%2011%20Pro%20-%20netshell.dll%20icons.png)




# Plugins #


Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
@echo off
powershell -nologo -ExecutionPolicy Bypass -File "%~dpn0.ps1"
pause
Loading

0 comments on commit ac172db

Please sign in to comment.