The idea of transgender rights is not all that new. In many civilizations transgender, genderqueer, and in general gender minorities have been treated in certain specific ways. These customs may or may not have been codified into written laws but they can be seen as conventional laws or practices. However it is relatively new to our society and as such, there are no rules on how treat individuals who defy our gender norms and it seems that the law is struggling to keep up.
In the United Kingdom there has been a flurry of recent cases (here, here, and here) that all have to do with gender representation and how it affects sexual activity. Particularly, these cases revolve around issues of consent. These cases are important because they are setting the legal precedent for future cases, and unfortunately it seems that they are finding it to be a criminal offense to have sex with someone without disclosing your 'gender'.