Asking without being rude

I'm pan, but I haven't told that many people, but if I was in a relationship with another girl I wouldn't feel the need to hide it, I just feel uncomfortable "coming out". There's a girl I like who I have classes with and I want to ask if she's gay or otherwise into girls, but I don't really know how to without possibly offending her/coming out unintentionally