It's not defect. The problem happens if the bitmap is bigger than the window. By default the window needs to be at least 32 pixel bigger in width and height to avoid that. That's why it always says:
self.contents = Bitmap.new(width - 32, height - 32)
Just mess around with thos numbers and the window width/height itself and it will dissappear. BTW, for the one at the botton, you can just increase the NUMBER in this line:
@actor_command_window = Window_Command.new(NUMBER, ...)
It should be very similar in the CBS you are using. Basically increase that number by 32, 64, 96, etc. until the arrow is gone.