That is true but it is way more complicated. A distinction can be drawn between moral rights and legal rights. A moral right means that a person is in a position to lay claim to something on the basis of the moral correctness of him having what he is asking for. His claim may or may not be backed up by the law. If it is, he has a legal right.
Legal rights are usually moral rights that are protected by law.
In the issue of when is death appropriate, both legal and moral rights apply. Historically, rights have been viewed as properties of individuals that need to be protected. This is a type of freedom because rights also includes a right of no interference. People are seen as individuals capable of making their own choices. When they make the wrong choices, is when the legal rights take over the individual rights and the law steps in.