Now think about how many times you've heard your teachers or fellow students speak up against people using homophobic language like that. Probably not all that often. Anti-gay insults are just one of the factors that can make a school unhealthy for these students.
Invisibility is another.
Beyond getting flak from their classmates, lgbt students are often shut out by the school's administration. Administrative silence when it comes to lesbian, gay, and bisexual issues hurts all students, not just those who aren't straight, because it sets up an environment where differences aren't things to be celebrated but things that have to be hidden. Many people have probably felt powerless to do something about homophobia at their school. Let the person making the remark know that homophobia is not acceptable. Get involved in or start your school's Gay-Straight Alliance.