Gtk::StyleContext has methods for adding and removing a CSS class. Can I change the property of this class programmatically?
Yes, sort of; you can load another CSS file in the style context's CSS provider, that has different rules for that CSS class.
I suspect you might be asking about how to go into the rules directly and edit them programmatically; you can't do that.