Can somebody point me to a piece of code in the display engine which is responsible for highlighting text upon selection? Or the general logic on what causes it to display in a different face than normal text?

Thanks.