Summary: | When changing dates, change date-based filename as well. | ||
---|---|---|---|
Product: | [Applications] digikam | Reporter: | Dotan Cohen <kde-2011.08> |
Component: | Metadata-Date | Assignee: | Digikam Developers <digikam-bugs-null> |
Status: | RESOLVED FIXED | ||
Severity: | wishlist | CC: | caulier.gilles, smit.meh |
Priority: | NOR | ||
Version: | 2.6.0 | ||
Target Milestone: | --- | ||
Platform: | Ubuntu | ||
OS: | Unspecified | ||
Latest Commit: | Version Fixed In: | 2.6.0 | |
Sentry Crash Report: | |||
Attachments: |
Example
Patch for bug 193874 |
Description
Dotan Cohen
2009-05-24 13:11:04 UTC
Dotan, This file still valid using 2.x serie ? Also, please give more information about, it's not enough clear... Gilles Caulier Created attachment 66835 [details]
Example
Yes, the RFE is still valid for Digikam 2.4.
If there is a file that is named 20111126T160302.jpg that has the timestamp 2011-11-26 16:03:02 then obviously the filename is used to record the date of the image, in addition to XMP, IPTC, or anything else. Therefore, when changing the time of the photo the filename should be an option to update as well. See attached screenshot.
Thanks!
Hi I am Smit, an aspiring GSoC applicant for the UPnP plugin, under Marcel. I was interested to solve this bug. As guided by Marcel, the advanced rename is implemented in /utilities/advancedrename and the "date and time adjust" is implemented as a kipi-plugin. Where can i find the kipi-plugin code? Can any developer please guide me on how to go about solving this? Smit Code is here : https://projects.kde.org/projects/extragear/graphics/kipi-plugins/repository/revisions/master/show/timeadjust Gilles Caulier Hi Gilles Thanks for pointing out the code. I tried to make ammends to it. As the user wants, i included a "Edit Filename" option in the list of exiting ones, and in the SlotOk(), i wrote another if condition, to do stuff when it is checked. I want to change the file name. However whatever function i use, i am unable to change it. I can change all the data related to image, say its comments, tags, etc. But not the name. Kindly go through the patch and comment. <a href="http://pastebin.com/AcdF4kdn"> patch </a> Smit You need to start an actual file rename operation on disk, not something which adjusts parameters on a structure in memory. I suggest to use KIO::move(). Regarding your code: Remove the toAscii(). Dont forget to find out the correct file suffix, see QFileInfo::suffix or completeSuffix(). Dont forget to handle a possible XMP sidecar file (current work in progress under bug 220545). For this and the KIO code, I suggest you have a look at digikam's dio.cpp Hi Gilles Kindly review the given patch. http://pastebin.com/ERRUtBtH This changed code works properly on the source code i downloaded on March 11. In that version, whenever i changed the file name with that option, upon clicking "Ok", it changed the filename, and was shown with the new name in the album view. But in the source-code i downloaded today, i.e. March 19, it still changes the fill name, but it is no more there in the album view inside digikam. Any suggestions? Hi Kindly note that, when i say the patch works in the 11th March's version of digikam, i mean that the file renaming portion works properly (as the sidecar implementation in kpmetadata was not done then). It renamed the file, and digikam automatically updated the view, with the renamed file. But it is not happening in the current source code. Instead, it is not showing the renamed file at all. Smit Smit, 1/ please post patch as attached file to this bugzilla entry, not as an external link 2/ to rename XMP sidecar file, please use KPMetadata::moveSidecar() static method that i just add today. 3/ revise you patch against current git/master implementation Thanks in advance Gilles Created attachment 69764 [details] Patch for bug 193874 Hi Gilles I have incorporated the changes you recommended in my patch. It is working properly on the latest source code. Kindly review it. Smit smit, Patch sound fine for me. Do you have an account to apply it on git/master ? Best Gilles Caulier Hi Gilles No I dont have an account to apply it on git/master. Can I use your name in "Who supports this request?" part of the application? Could you please guide me on how to get that? Smit Hi I am closing this bug. This commit solves it. https://projects.kde.org/projects/extragear/graphics/kipi-plugins/repository/revisions/3d7d8f30f1e9771dc1aab18b1b1a01b86883a946 Smit Smit, Note, use BUGS not BUG to close file automatically Use CCBUGS, not CCBUG to copy commit message in bugzilla entry Best Gilles Caulier |