Zim

Comment 9 for bug 303657

Revision history for this message
milk2cups (milk2cups) wrote : Re: [Bug 303657] Re: natural sorting in the page index

On Wed, Mar 23, 2011 at 9:30 PM, Jaap Karssenberg
<email address hidden> wrote:
> On Wed, Mar 23, 2011 at 9:16 AM, milk2cups
> <email address hidden>wrote:
>
>> On Wed, Mar 23, 2011 at 5:09 AM, Lisa <email address hidden> wrote:
>> > Just a question: the natural sorting should be applied even when the
>> > numbers are in a different position, like at the beginning of the
>> > filename or in the middle?
>>
>> I suggest you only do the obvious ordering, and do nothing if the
>> situation becomes tricky.
>> i.e., part1, part2, ..., part10. but do not try too hard to figure out
>> the ordering of part1x and part_2aaa.
>>
>
> This can be easily achieved by splitting the name in numeric and non-numeric
> parts and then sort based on that list.

The problem is that you don't necessarily know what the user's intention is