I believe that the U.S. has traditionally been more in favour of gun ownership and opposed to gun control than other Western countries. Why is this? Did public opinion in the U.S. diverge from the rest of the West at some point, and if so, when?
It comes down to the 2nd Amendment to the Constitution:
A well regulated Militia, being necessary to the security of a free State, the right of the people to keep and bear Arms, shall not be infringed.
The phrase "shall not be infringed" has been the subject of a great deal of debate. What stands out is how forceful the wording is. If we compare it to its philosophical ancestor in the English Bill of Rights, the difference is fairly stark:
That the Subjects which are Protestants may have Arms for their Defence suitable to their Conditions and as allowed by Law.
First off, we've got the word subjects. This is in direct conflict with the American concept of citizens. The second thing that sticks out is that they may have arms.
The concept of a right to bear arms has its origins, and somewhat uniquely, in English Common Law. In the later Militia Act of 1662, Charles II stated that subjects could keep arms in accordance with "condition and decree." That definition was interpreted quite broadly, and Charles' supporters used it confiscate arms from revolutionaries and suspicious people.
A century later, William Blackstone wrote his Commentaries on the Laws of England, which framed the right in a more absolutist light:
In England, the people have been disarmed, generally, under the specious pretext of preserving the game: a never failing lure to bring over the landed aristocracy to support any measure, under that mask, though calculated for very different purposes. True it is, their bill of rights seems at first view to counteract this policy: but the right of bearing arms is confined to protestants, and the words suitable to their condition and degree, have been interpreted to authorise the prohibition of keeping a gun or other engine for the destruction of game, to any farmer, or inferior tradesman, or other person not qualified to kill game.
Blackstone went on to state the idea of an armed populace as a balance to government overreach:
[T]o vindicate these rights, when actually violated or attacked, the subjects of England are entitled, in the first place, to the regular administration and free course of justice in the courts of law; next, to the right of petitioning the king and parliament for redress of grievances; and, lastly, to the right of having and using arms for self-preservation and defence.
The drafters of the American Bill of Rights were well aware of Blackstone's work, and his ideas were applied when the right to bear arms was applied to the American Constitution. In 2008, the Supreme Court weighed the parameters of the 2nd Amendment in DC v. Heller.. Their opinion mentioned Blackstone's work more than 20 times.
I'm not aware of any other nation that has an enumerated right to bear arms. The closest such clause I know of is in the Cuban constitution:
When no other recourse is possible, all citizens have the right to struggle through all means, including armed struggle, against anyone who tries to overthrow the political, social and economic order established in this Constitution. [Chapter 1, Article 3]