Bug 215715 - Wrong numbering when importing photos
Summary: Wrong numbering when importing photos
Status: RESOLVED FIXED
Alias: None
Product: digikam
Classification: Applications
Component: AdvancedRename-Import (show other bugs)
Version: 1.0.0
Platform: Mandriva RPMs Linux
: NOR normal
Target Milestone: ---
Assignee: Digikam Developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-22 18:26 UTC by Frederic Gedin
Modified: 2017-08-17 17:39 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 1.0.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Frederic Gedin 2009-11-22 18:26:54 UTC
Version:           1.0.0-beta5 (using KDE 4.3.2)
OS:                Linux
Installed from:    Mandriva RPMs

When I want to import several pictures with customized names and sequence, the import tool remembers the initial sequence start even though I want to retart from 1.

For example, I have 20 pictures to import, 10 corresponding to prefix1, 10 to prefix2.

I make a first import with prefix1_## and I get pictures named prefix1_01, prefix1_02, ...., prefix1_10.

When making the second import after having changed the prefix and reinitialized the sequence numbering, the images names are prefix1_11, prefix2_12, ...., prefix2_20. Even the customization string prefix2_##[1] does not change the initial number. 

The only way I found to reinitialize the sequence was to close the import window and reopen it?
Comment 1 Andi Clemens 2009-11-22 18:39:31 UTC
Actually this is the normal behavior at the moment. For every downloaded image, the number is incremented. It is reset when the camera dialog is closed.
Most users want to select some images, download them, and then select a different set with a logical increased numbering.
We could think about that ###[1] actually forces the starting number, even if the internal counter already has been increased...
Comment 2 Frederic Gedin 2009-11-22 18:49:24 UTC
Andy

In that case, why not keeping the current behavior but actually reset the initial sequence number when it is specifically reset either using the numbering dialog box or using [1] ?

Regards

Frederic
Comment 3 Andi Clemens 2009-11-22 18:54:27 UTC
Yes, sure... right now I have to figure out how to do it :-)
The rename tool was designed to work in many places in digiKam, so it's API is rather simple... very simple :)
I will think about a way to force a reset...
Comment 4 Frederic Gedin 2009-11-22 22:13:29 UTC
Maybe can you provide the suggested sequence number in the corresponding field in the dialog box. If the user reset it to 1, then you just have to apply the change he made.

Frederic
Comment 5 Andi Clemens 2009-11-27 16:00:38 UTC
SVN commit 1055194 by aclemens:

Change the way the parser handles numbering. An internal counter is used to
number the images, with an additional startIndex parameter used by CameraUI to
set a different start than 1.

CameraUI increases the number / index while it has not been closed, which is a
good / normal behavior. So when you select three images, download them and
select different ones later on from the same camera device, the next index
will be 4.

Resetting this counter manually was not possible the way the rename parser
worked before.

Now the parser can be initialized with a ParseInformation object, that can have
a custom startIndex parameter.

BUG:215715

 M  +2 -1      NEWS  
 M  +12 -23    tests/advancedrenametest.cpp  
 M  +4 -3      utilities/advancedrename/advancedrenamedialog.cpp  
 M  +2 -0      utilities/advancedrename/advancedrenamedialog.h  
 M  +5 -0      utilities/advancedrename/advancedrenamewidget.cpp  
 M  +4 -2      utilities/advancedrename/advancedrenamewidget.h  
 M  +4 -3      utilities/advancedrename/common/parseinformation.h  
 M  +24 -4     utilities/advancedrename/common/parser.cpp  
 M  +3 -0      utilities/advancedrename/common/parser.h  
 M  +2 -2      utilities/advancedrename/parser/options/sequencenumberoption.cpp  
 M  +12 -7     utilities/cameragui/cameraiconview.cpp  
 M  +1 -1      utilities/cameragui/cameraiconview.h  
 M  +6 -6      utilities/cameragui/cameraui.cpp  
 M  +6 -3      utilities/cameragui/renamecustomizer.cpp  
 M  +1 -1      utilities/cameragui/renamecustomizer.h  
 M  +0 -3      utilities/queuemanager/queuelist.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1055194