I believe the princess realized that pig loves charlotte back when they're still kids
so, she chose to annul their engagement even though she actually(or used to) have feelings for him
because she can't stand it or because she wishes for his happiness more (whoa, tsundere drills. izz dat true!?)
well, in the end it goes however the author wants it to go