Lori,
I traveled around Sicily last year via public transportation.
As previously mentioned by jmauldinuu, buses are sometimes a better option on some routes.
If you share your itinerary, I can help you figure out which bus company services that route.
The Lonely Planet Guidebook was very helpful during my planning.
I took several buses and only 3 trains during my 3.5 weeks in Sicily. Trains were taken for the following routes: Palermo to Cefalù, Siracusa to Milazzo, and Milazzo to Acireale.
Here’s my trip report if you’re interested: My trip to Sicily- In Zoe’s memory...
Enjoy your trip!
Edited to add...
Regarding buying train tickets while in Sicily, I bought one at the train station and the others on my phone using the Trenitalia website (not the app).
The train ticket inspector does come around to check tickets with an electronic scanner.
Buying bus tickets was interesting...
I wanted to buy them in advance, at the bus stations, but was told to wait till the day of travel.
You can buy bus tickets at the bus station, a travel agency, or sometimes from the driver.