Before you apply paint to the wood, the wall around your windows or the muntins (the narrow strips of wood that divide the windows into smaller panes), clean the surface of the glass with a window cleaner and dry completely.
Apply the masking tape that is specifically for painting along the edges of your window, between the wall and window panes on all sides of the window. If you are painting your walls, this will keep the paint from getting on your window panes, and if you are painting your windows, this will keep the paint from the window panes from getting on your walls.
Apply a layer of petroleum jelly onto the window glass for about 2 to 4 inches around the entire window. The petroleum jelly will not dry, which stops the paint from drying on the glass.
After you have painted your window panes or walls, let the paint dry completely.
Carefully remove the masking tape once the paint has dried. Take a dry cloth and wipe away the petroleum jelly that you applied to the glass. This will also remove any paint on the jelly. After wiping away the jelly, wash your window with glass cleaner.