fixing some window level problems