I think it's correct behaviour, not a bug. Your repeat signs are in the middle of a bar. I don't know if there's a rule in music theory for numbering bars when they are split like this. If not, NWC can't assume you want to do that, since others might prefer not to.
You can force a bar number change, though, by adding a hidden regular bar line, like so:
!NoteWorthyComposerClip(2.0,Single)
|Bar|Style:MasterRepeatClose
|Bar|Visibility:Never
|Bar|Style:MasterRepeatOpen
!NoteWorthyComposerClip-End
Bersyl91 is correct. If you paste the clip from the first post there are indeed 2 normal barlines labelled "2", with the back to back master repeats in between.
I reckon this is a bug.
NWC1 behaves differently. In that case, the back to back master repeat barlines get numbered as 3 and the surrounding ones are 2 and 4.
But if you turn off "exclude from bar count" for both repeat signs, you can get an extra count too, so it has to be done carefully.
I notice the print preview won't show Bar 1, so you don't get any numbering of bars on the print until you have a system wrap. This shouldn't be troublesome, unless you have a pickup bar. Then you can't tell whether or not is is numbered 0 or 1 after it's printed.
NWC does not include extra adjacent bar lines in the measure count, regardless of the setting of the exclude option. Only bar lines that have a musical duration separating them (notes or rests) are included in the count.
Where neither repeat is excluded from the bar count, you get the second half of the split bar counted as a new bar. I've attached a few illustrations - this is shown in <Song2>.
<Song4> is particularly interesting, and comes from this:
!NoteWorthyComposerClip(2.0,Single)
|Text|Text:"Anomaly - inserted a hidden bar line, excluded "|Font:StaffItalic|Pos:22
|Text|Text:"from count, between the repeats"|Font:StaffItalic|Pos:16
|Clef|Type:Treble
|Note|Dur:16th,Grace|Pos:5|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Grace|Pos:6|Opts:Stem=Down,Beam=End
|Note|Dur:8th|Pos:7|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#4,6|Opts:Stem=Down,Beam=End
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#2,4|Opts:Stem=Down,Beam=End
|Bar
|Note|Dur:4th|Pos:3
|Bar|Style:MasterRepeatClose|XBarCnt:Y
|Bar|XBarCnt:Y|Visibility:Never|Bar|Style:MasterRepeatOpen
|Dynamic|Style:mf|Pos:-8
|Note|Dur:8th,Staccato|Pos:3|Opts:Stem=Down,Beam=First
|Note|Dur:8th,Staccato|Pos:4|Opts:Stem=Down,Beam=End
|Bar
|Chord|Dur:8th,Staccato|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=End
|Note|Dur:16th,Slur|Pos:6|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Slur|Pos:5|Opts:Stem=Down,Beam
|Note|Dur:16th,Slur|Pos:4|Opts:Stem=Down,Beam
|Note|Dur:16th|Pos:3|Opts:Stem=Down,Beam=End
!NoteWorthyComposerClip-End
I admit being corrected.
About <SONG1>-The repeat open's bar bar would be the 8th-notes after it, and the the repeat close's bar would be nonexistent. This logic makes sense, as there would be no bar to count for the repeat open.
<SONG4> makes no sense to me, but it could be useful-see https://forum.noteworthycomposer.com/?topic=5827.msg38132#msg38132 (https://forum.noteworthycomposer.com/?topic=5827.msg38132#msg38132), fourth paragraph
Oops, one should be awake enough to spot these things...
Doesn't seem to matter what kind of barlines surround the hidden one, the phenomenon appears the same.
There IS something dodgy going on here though...
David's clip with the hidden barline:!NoteWorthyComposerClip(2.0,Single)
|Clef|Type:Treble
|Note|Dur:16th,Grace|Pos:5|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Grace|Pos:6|Opts:Stem=Down,Beam=End
|Note|Dur:8th|Pos:7|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#4,6|Opts:Stem=Down,Beam=End
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#2,4|Opts:Stem=Down,Beam=End
|Bar
|Note|Dur:4th|Pos:3
|Bar|Style:MasterRepeatClose|XBarCnt:Y
|Bar|XBarCnt:Y|Visibility:Never
|Bar|Style:MasterRepeatOpen
|Dynamic|Style:mf|Pos:-8
|Note|Dur:8th,Staccato|Pos:3|Opts:Stem=Down,Beam=First
|Note|Dur:8th,Staccato|Pos:4|Opts:Stem=Down,Beam=End
|Bar
|Chord|Dur:8th,Staccato|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=End
|Note|Dur:16th,Slur|Pos:6|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Slur|Pos:5|Opts:Stem=Down,Beam
|Note|Dur:16th,Slur|Pos:4|Opts:Stem=Down,Beam
|Note|Dur:16th|Pos:3|Opts:Stem=Down,Beam=End
!NoteWorthyComposerClip-End
The opening repeat is numbered "1"
Remove the exclusion from the closing repeat:!NoteWorthyComposerClip(2.0,Single)
|Clef|Type:Treble
|Note|Dur:16th,Grace|Pos:5|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Grace|Pos:6|Opts:Stem=Down,Beam=End
|Note|Dur:8th|Pos:7|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#4,6|Opts:Stem=Down,Beam=End
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#2,4|Opts:Stem=Down,Beam=End
|Bar
|Note|Dur:4th|Pos:3
|Bar|Style:MasterRepeatClose
|Bar|XBarCnt:Y|Visibility:Never
|Bar|Style:MasterRepeatOpen
|Dynamic|Style:mf|Pos:-8
|Note|Dur:8th,Staccato|Pos:3|Opts:Stem=Down,Beam=First
|Note|Dur:8th,Staccato|Pos:4|Opts:Stem=Down,Beam=End
|Bar
|Chord|Dur:8th,Staccato|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=End
|Note|Dur:16th,Slur|Pos:6|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Slur|Pos:5|Opts:Stem=Down,Beam
|Note|Dur:16th,Slur|Pos:4|Opts:Stem=Down,Beam
|Note|Dur:16th|Pos:3|Opts:Stem=Down,Beam=End
!NoteWorthyComposerClip-End
The opening repeat is numbered "2", as is the barline prior to the closing repeat.
Remove the exclusion from both the closing repeat and the hidden barline:!NoteWorthyComposerClip(2.0,Single)
|Clef|Type:Treble
|Note|Dur:16th,Grace|Pos:5|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Grace|Pos:6|Opts:Stem=Down,Beam=End
|Note|Dur:8th|Pos:7|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#4,6|Opts:Stem=Down,Beam=End
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#2,4|Opts:Stem=Down,Beam=End
|Bar
|Note|Dur:4th|Pos:3
|Bar|Style:MasterRepeatClose
|Bar|Visibility:Never
|Bar|Style:MasterRepeatOpen
|Dynamic|Style:mf|Pos:-8
|Note|Dur:8th,Staccato|Pos:3|Opts:Stem=Down,Beam=First
|Note|Dur:8th,Staccato|Pos:4|Opts:Stem=Down,Beam=End
|Bar
|Chord|Dur:8th,Staccato|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=End
|Note|Dur:16th,Slur|Pos:6|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Slur|Pos:5|Opts:Stem=Down,Beam
|Note|Dur:16th,Slur|Pos:4|Opts:Stem=Down,Beam
|Note|Dur:16th|Pos:3|Opts:Stem=Down,Beam=End
!NoteWorthyComposerClip-End
The opening repeat is numbered "3" (I would expect this)
This one is a beauty!!NoteWorthyComposerClip(2.0,Single)
|Clef|Type:Treble
|Note|Dur:16th,Grace|Pos:5|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Grace|Pos:6|Opts:Stem=Down,Beam=End
|Note|Dur:8th|Pos:7|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#4,6|Opts:Stem=Down,Beam=End
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:#2,4|Opts:Stem=Down,Beam=End
|Bar
|Note|Dur:4th|Pos:3
|Bar|Style:MasterRepeatClose|XBarCnt:Y
|Bar|XBarCnt:Y|Visibility:Never
|Bar|XBarCnt:Y|Visibility:Never
|Bar|Style:MasterRepeatOpen
|Dynamic|Style:mf|Pos:-8
|Note|Dur:8th,Staccato|Pos:3|Opts:Stem=Down,Beam=First
|Note|Dur:8th,Staccato|Pos:4|Opts:Stem=Down,Beam=End
|Bar
|Chord|Dur:8th,Staccato|Pos:3,5|Opts:Stem=Down,Beam=First
|Chord|Dur:8th|Pos:3,5|Opts:Stem=Down,Beam=End
|Note|Dur:16th,Slur|Pos:6|Opts:Stem=Down,Beam=First
|Note|Dur:16th,Slur|Pos:5|Opts:Stem=Down,Beam
|Note|Dur:16th,Slur|Pos:4|Opts:Stem=Down,Beam
|Note|Dur:16th|Pos:3|Opts:Stem=Down,Beam=End
!NoteWorthyComposerClip-End
The opening repeat is numbered 65536
Confirmed.
It would seem there's something special about the number 65536...googled it.
Apparently Microsoft Excel has problems with 65536, too:
http://support.microsoft.com/kb/120596 (http://support.microsoft.com/kb/120596)
Here's some more reading on 65536:
http://primes.utm.edu/curios/page.php/65536.html (http://primes.utm.edu/curios/page.php/65536.html)
Confirmed as a bug. The exclude option should not have any effect on a bar line that is already ignored in the measure count. This will be corrected.