Dolphin renaming functionality to include user choice in starting index number

Review Request #102328 - Created Aug. 15, 2011 and submitted

Information
Chirag Anand
kde-baseapps
Reviewers
kde-baseapps
ppenz
This patch applies to dolphin/src/views/renamedialog.cpp and
dolphin/src/views/renamedialog.h. It is built on the current master
branch of kde-baseapps repository.

It replaces the current renaming functionality of Dolphin for multiple
files. The functionality gives user a little more control over how to
rename their files. It asks the user for the starting point of the
sequence of number instead of starting it always from 1. Renaming 3
files by doing "FILE##.txt" gives us FILE01.txt, FILE02.txt, FILE03.txt.

If we have to rename these 3 files to FILE04.txt, FILE05.txt,
FILE06.txt, we need 6 files for the operation. We cannot rename files
starting from a random number. Also, we cannot rename file with
different extensions in a sequence. Though this patch does not yet solve
this problem, what it does is to give the user a choice to start the
sequence from wherever he/she wants it to.

I have used parenthesis '(', ')' instead of '#' as placeholder. For the
above example, we have to rename the files by doing FILE(04).txt and it
will rename the files as required.

  
Chirag Anand
Review request changed

Change Summary:

Added KIntSpinBox to the RenameDialog.

So that user can decide where to start the renaming sequence for multiple files. As taking '#' as the replacement string is proven to be stable, we just pass the value of the KIntSpinBox to the index variable.
Based on the discussion with Peter Penz on the kde-devel mailing list (SUB: [PATCH] Modified Dolphin multiple files renaming functionality)

Diff:

Revision 2 (+10 -3)

Show changes

Peter Penz
Thanks for the update, looks good! I've pushed your patch to master and only did a minor adjustment regarding the layout, so that the box is aligned beside the text.
Loading...