Rainie3535 / sigil

Automatically exported from code.google.com/p/sigil
GNU General Public License v3.0
0 stars 0 forks source link

Bulk rename will stop if one name matches, context menu needs cleanup and warnings #1254

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

What steps will reproduce the problem?
1.Start with a file which has been previously renamed eg c01
2.Select a group which includes c01 as the first
3.Set the seed to C01

What is the expected output? What do you see instead?
All files rename per the seed. Blinks, but rename does not happen.
(selecting a file that does NOT match the seed, proceeds as expected)

What version of the product are you using? On what operating system?
5.01 on XP SP3

Original issue reported on code.google.com by dragonsc...@sonic.net on 9 Feb 2012 at 8:36

GoogleCodeExporter commented 9 years ago
Try this on 5.2.  It works for me.

Original comment by meme90...@gmail.com on 10 Feb 2012 at 8:37

GoogleCodeExporter commented 9 years ago
It still does this (see picture), failed to re-number
If I move down 1 section (and use c02) everything works as expected.
XP SP3

Original comment by dragonsc...@sonic.net on 10 Feb 2012 at 6:48

Attachments:

GoogleCodeExporter commented 9 years ago
BTW that was 5.2

Original comment by dragonsc...@sonic.net on 10 Feb 2012 at 6:49

GoogleCodeExporter commented 9 years ago
Yes, I see it now.  You gave c01 and C01 before which are different.  Thanks 
for the picture.

The issue is you are trying to rename to an existing file so Sigil aborts the 
renaming process.

I can look into allowing it to continue if the old/new names are the same.

The workaround for you is to just start with c02 on the second folder as you 
mentioned.

Original comment by meme90...@gmail.com on 10 Feb 2012 at 6:54

GoogleCodeExporter commented 9 years ago
Either that (case insensitive for windows users), or a warning 'Duplicate name' 
error, then abort the change for user rework :)

Original comment by dragonsc...@sonic.net on 10 Feb 2012 at 7:55

GoogleCodeExporter commented 9 years ago
Patch attached, against 0.5.2.  Ubuntu 11.10.   Needs checking under Windows.

If the old/new file names are identical, just continue.  Not tested on windows, 
but this should still allow you to rename from c01 to C01.  If we treat those 
as identical then you wouldn't be able to make all files the same case - 
assuming Windows allows you to rename in this way.

Also cleanup of code now that Rename/Rename Selected both use Rename in the 
context menu.

Original comment by meme90...@gmail.com on 11 Feb 2012 at 8:20

Attachments:

GoogleCodeExporter commented 9 years ago
Meme
The 'trick' to do a case change only, in windows is to do the rename with a 
additional/missing character, then do another with that 'fixed'
eg c01 ->C01x ->C01
This forces Windows to write the change to the directory table

Original comment by dragonsc...@sonic.net on 11 Feb 2012 at 2:58

GoogleCodeExporter commented 9 years ago
New patch uploaded to fix rename issue plus a number of other context menu 
issues:

- fix rename selected to handle when it includes renaming a file to the same 
name
- Add warning confirmation dialog when sorting, or merging all or selected 
files 
- Added Rename All and Merge All for completeness, and only show menu options 
when its appropriate
- Changed shortcut/tooltip for Merge to be on merge previous so its easily seen 
by users (still performs double duty as merge with previous and merge selected)
- Added text to Merge to more clearly explain what to do when you try to merge 
a new file that hasn't been saved yet (otherwise if you add a blank file and 
try to merge it, it fails with an invalid reason)

Ignored the windows rename issue since users can just rename twice themselves.

Original comment by meme90...@gmail.com on 16 Feb 2012 at 9:17

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by john@nachtimwald.com on 17 Feb 2012 at 12:22

GoogleCodeExporter commented 9 years ago

Original comment by daveheil...@gmail.com on 19 May 2012 at 3:20