The graphic you've shown shows two AC voltages that add to give a positive voltage. However, one of them is greater than the other making the difference between the two a positive number. In the book the same phase shift is shown, but the voltages are equal in value which should give no difference between them and no voltage. Am I missing something?
The bottom source has 180 degrees phase shift but also opposite polarity, so it's the same as the top source. Think of the phase as "internal" to the signal generator within the source and the +/- polarity as an "output" polarity of the source.