Until my Meganium, Furret, and Lapras found Shiny Leaves on their own by complete accident, I was totally clueless about them. After that, I got curious and looked them up and used a guide to match my Pokemon to their Shiny Leaf routes. Happiness seems to affect the Pokemon's ability to find Shiny Leaves and so my happiest Pokemon all found their Shiny Leaves super fast while my still-in-training Pokemon found theirs slower.
Related to that, I guess the star for the Trainer Card has to do with your friendship with your Pokemon - a way to reward you for having built a good strong relationship with your Pokemon.