Created attachment 169173 [details] Screenshot file not correct when title placeholder is included ## Bug Report for Spectacle - Filename Issue **SUMMARY** Spectacle generates incorrect filenames when using the `<title>` placeholder in the filename format with capture modes other than "Active Window". The filename omits seconds and truncates the window title. **STEPS TO REPRODUCE** 1. Configure the filename format in Spectacle to include the `<title>` placeholder (e.g., `Screenshot_A6213[<#>]_(<yyyy>-<MMMM>-<dd>)_[<hh>,<mm>,<ss>]__<title>`). 2. Open an application window, such as "Firefox". 3. Take a screenshot of the application window using any capture mode except "Active Window" (e.g., "Rectangular Region", "All Screens", "Current Screen"). You can use either a button or a hotkey to trigger the screenshot. **OBSERVED RESULT** The filename is generated incorrectly. For example, if the current time is 14:08:36 and the window title is "Firefox", the filename might become `14,08,<ss.jpg` instead of the expected `14,08,36__Firefox.jpg`. * The filename omits the seconds from the timestamp. * The filename truncates the window title. **EXPECTED RESULT** The filename should be generated according to the configured format, including: * The full timestamp with seconds (`<hh>,<mm>,<ss>`) * The captured window title (`<title>`) **SOFTWARE/OS VERSIONS** * **Operating System:** Arch Linux * **KDE Plasma Version:** 6.0.4 * **KDE Frameworks Version:** 6.1.0 * **Qt Version:** 6.7.0 * **Kernel Version:** 6.8.8-arch1-1-surface (64-bit) * **Graphics Platform:** Wayland **HARDWARE INFORMATION** * **Processors:** 8 × Intel® Core™ i7-8650U CPU @ 1.90GHz * **Memory:** 15.5 GiB of RAM * **Graphics Processor:** Mesa Intel® UHD Graphics 620 * **Manufacturer:** Microsoft Corporation * **Product Name:** Surface Book 2 * **System Version:** 124000000000000000000000D:0B:08K:1F:5C:10P:38 **ADDITIONAL INFORMATION** * This issue only occurs when using the `<title>` placeholder and taking screenshots with capture modes other than "Active Window". * Interestingly, even though the "Active Window" capture mode setting includes the `<title>` placeholder, it still generates correct filenames with the full timestamp. This suggests the issue might be related to how Spectacle interacts with the `<title>` placeholder when using specific capture methods. **Optional: Troubleshooting Steps (if any)** * Briefly describe any troubleshooting steps you've tried (e.g., reinstalling Spectacle, checking for configuration conflicts). **Full Story** 1. In KDE Plasma 5, I used the following filename format without issues: `Screenshot_A6213[%#]_(%Y%M%D)_[%H%m%S]__{%T}`. 2. After updating to KDE Plasma 6, I noticed Spectacle generated incorrect filenames with this format. 3. I learned that KDE Spectacle developers replaced the old `%` style placeholders with new `< >` style placeholders. 4. Following the new format guidelines, I tried using `Screenshot_A6213[<#>]_(<yyyy>-<MMMM>-<dd>)_[<hh>,<mm>,<ss>]__<title>`. 5. However, this format also resulted in incorrect filenames, like `Screenshot_A6213[2]_(2024-May-04)_[14,06,<ss-2.jpg`. 6. Initially, I thought the issue might be the filename length being too long. I tested with a shorter format (`<hh>,<mm>,<ss>__<title>`) but the problem persisted (filenames like `14,08,<ss.jpg`). 7. This led me to believe the problem was likely with the `<title>` placeholder itself. 8. To confirm this, I noticed that screenshots taken using the "Active Window" capture mode (which does use the `<title>` placeholder in its settings) generated correct filenames with the full timestamp (e.g., `Screenshot_A6213[1]_(2024-May-0
Created attachment 169174 [details] Even with a short filename format, if placeholder title is included, it's still produce incorrect filename
I think they're the same isse https://bugs.kde.org/show_bug.cgi?id=483320
*** This bug has been marked as a duplicate of bug 483320 ***