Machine screws originally had slotted heads due to practicality of manufacturing. Back in the early days, high-speed cold headers were years in the future. As a consequence, the drive recess of each screw had to be machined. The most practical driving recess was the slot, made with a slotting saw:
Those cheap sheet metal screws with the hex OD aren't meant to be driven with a screwdriver, even though the have a poor excuse for a slot.
Properly made slotted screws are a joy to use, I think. They have a nice look, too.
Modern screws are headed either hot or cold, just like bolts. Essentially, drawn wire enters the machine and is gripped by what will become the threaded portion of the screw. The heading die hits the protruding end of the wire and flows into the shape. The entire heading operation only takes a few 100ths of a second. After heading, the wire advances a set amount, equal to the length of the screw, and the screw blank is clipped off in preparation of heading the next screw.
Because modern screws are headed with a die, almost any shape that has form relief can be imparted on the head of the screw. It also means that modern slotted screws require the slot to have relief, to allow the die to be withdrawn from the newly formed head. This means the driver to mate with the slot must also be tapered.
Proper slotted screws are machined and the slot doesn't have a tapered side. Proper slotted screwdrivers have a blade of uniform thickness, which will
NOT cam out of the slot.
