An attempted overdose, even many years ago, would definitely have to be looked into very carefully by the AMEs before they granted a medical certificate. It is unfair that those who have suffered from depression in the past are stigmatised but the statistics show that if you have suffered once you are more likely to suffer again. There are of course lots of pilots who can and will suffer depression in the future, who hold a Class 1 now. It could be argued that if you have suffered depression before you will be safer than one who has not because you will know how to handle it if it crops up again.
There are two views, the old fashioned view says that if you have suffered a significant depression you can't be a pilot but things are changing. Personally, I have dropped my ambition to be a pilot, at least for the moment, because I have had M.E./Chronic Fatigue Syndome, which has gone on for a long time. Depression is a significant element of this illness.
The modern view says that if you can prove that the illness is behind you, there is no reason why you should not be granted a Class 1, and most airlines will accept a Class 1 medical as proof you are fit to fly without delving into your medical history.
BA on the other hand will look into your history but will not rule you out on the basis you have suffered depression, but will look at the case individually.
Good luck.