Both options look ok to me, but I think I'm leaning towards considering it a bug in the numbering.
If this is considered a bug, then what impact does that have on the sectnum for the appendix title? Currently 'Appendix A' is stored in the 'appendix-number' attribute. Should it become the sectnum instead then? Seems to make more sense than having an empty sectnum like in my patch, but it does require special handling when deriving the sectnum for child sections to avoid 'Appendix A.1'.
The gap in the numbering that you suggested seems to make sense. As you said it's unlikely to occur, but when it does continuing the regular numbering where it left off seems the logical thing to do.
Just for completeness' sake I noticed that I forgot part of my patch. Here's the missing appendix_number function
def appendix_number
entry = Array === attributes[:attribute_entries] && attributes[:attribute_entries].find { |entry| entry.name == 'appendix-number' }
entry ? entry.value : nil
end
Free forum by Nabble | Edit this page |