If this is a domestic trip within Spain, you don't need to print your ticket! You can just show your ID plus your PDF ticket on your mobile device or show your locator number. You can find your locator on the ticket here:
However, if it is an international trip, you must have the printed ticket in your possession. Tickets on mobile devices will not be accepted!
Just remember, if you are crossing an international border, print your ticket!
Happy and safe travels :)