Vanity and pride are different things, though the words are often used synonymously. A person may be proud without being vain. Pride relates more to our opinion of ourselves; vanity, to what we would have others think of us.
Jane AustenI read it [history] a little as a duty, but it tells me nothing that does not either vex or weary me. The quarrels of popes and kings, with wars or pestilences, in every page; the men all so good for nothing, and hardly any women at all — it is very tiresome: and yet I often think it odd that it should be so dull, for a great deal of it must be invention.
Jane Austen