It's correct to omit constants from big O, but in the article W is a distinct input variable so the usage is valid. The size of the window W is bound by N, not a constant 26.
Normally for a search algorithm the size of the alphabet is assumed to be constant.