Patent ID: 6984082

Claim:
A printing apparatus comprising: feeding means for feeding, in a predetermined feeding direction, a medium to be printed that has been supplied; light-emitting means for emitting light; and a light-receiving sensor for receiving light emitted by said light-emitting means, the printing apparatus being capable of detecting a change in an output value of said light-receiving sensor that is caused by said medium to be printed, which has been fed by said feeding means, blocking the light, which has been emitted by said light-emitting means, wherein, by moving said light-emitting means and said light-receiving sensor in a main scanning direction, the printing apparatus detects, at a plurality of positions, changes in said output value that are caused by an upper edge of said medium to be printed blocking said light, and based on a result of the detection, the printing apparatus obtains a position, in said feeding direction, of either one of a left edge or a right edge of said upper edge that is fed leading the other in said feeding direction.