"Das Geschlecht der Richter."
'of' is often replaced with articles which change according to the object's case. 'der' = of the, here. The gender of the judge would be 'Das Geschlecht des Richters'. It's there, but hidden in the object's article, if this doesn't confuse you too much. Otherwise: Yes, we omitt it and use a grammatical case to express the same.
Why is "The gender of the judges" correct, but "The sex of the judges" is incorrect?
The genitive case was excluded from colloquial/informal German, and only still exists in the written language, nicht wahr? I think I read this once.
That's not completely true, in my opinion. It is often replaced with dative in informal, colloquial speech, but I think it also depends on your socilisation, education and personal preference. Also, there are situations – and they're not rare – where one would use formal language verbally, not only written. I, on my part, prefer the genetive. But of course, when talking to someone close without much pondering sentences, the dative slips through more often than I'd like. A friend of mine always corrects people who use dative instead of genetive, for example.