Class names of an widget depends on the program itself, if the programmer specifies a class for that widget then only you can find it using the gtkInspector tool else there isn't any class to specify to start with.
Now if the class exists then follow the steps
- Open gtk inspector using
ctrl+shift+i
orctrl+shift+d
on the program window. - Using the inspect button on the top left corner select the widget that you want to get the style off.
- Navigate to the
Css Nodes
section from the dropdown menu on the objects tab. - Expand the hierchy and you'll find the class and id listed with more relevant information in sidebar.