The wood molding around windows and doors—also known as casing—is often joined together with 45-degree miter joints. Unfortunately, window and door frames aren't always exactly square. The result: ill-fitting joints with noticeable gaps.
Next time you're trimming out a frame that's slightly out of square, miter-cut the top of the vertical piece of casing to 45 degrees and nail it in place. Be sure to leave a 1/4-inch reveal (of the window or door jamb) along the edge of the casing. Then, hold a second piece of casing to the top of the frame so it overlaps the miter on the first piece. Again, maintain a 1/4-inch reveal. Make two marks onto the second piece where it meets the mitered cut behind it. Connect the two marks and cut the matching miter.