I should hope that they can 'line up', at least there's the same number of dog teeth on both sides, not that there was any different types.
In order to allow for the hub outer track to slide over, the track and the gear dog teeth need to be sychronised.
When you shift gears, the action is something like this;-
The selector fork pushes up against the hub,
The hub outer track, held in place on it's detents, will slide on the mainshaft in the direction it's being pushed,
The inner track of the hub then puts pressure on the baulk ring,
The baulk ring then will 'bite' on to the cone on the gear and start to spin the gear (which free wheels on the mainshaft), at the same
speed as the hub, but some slippage can still occur between these parts, the ears on the baulk rings too encourage this action,
At the break away point where the force from the selector fork overcomes the detents, the dogs between the gear and the hub are fairly close to each other,
As the outer track breaks away, it tends to 'fling' in the backlash of the selector mechanism, and 'look' for engagement over the dogs of the gear,
To help with that engagement, the lead teeth length and angles of the outer track are varied ever so slightly between each other, this helps them align,
Finally, the outer track then snaps in to it's selected dentent and 'holds' gear.
This action firstly works best when the assembly is rotating. As there needs to be movement between the gear and hub, the ratio of the gear itself can come in to play here, with a smaller gear having less leverage on the Laygear and Drop Gears and Clutch Plate (as these parts too needs to move with the gear), and so will go in easier than a larger diameter gear. Also, when stationary, any rolling of the gear train to align the dogs is purely from the pressure on the selector fork alone. This is why 1st can be hard to select.