Patent ID: 8259091

Claim:
A handheld electronic device, comprising: a main body having a containing slot having an entrance, an end, and a sidewall connected between the entrance and the end; a first magnetic member disposed on the sidewall of the containing slot; and a stylus suitable for being inserted into the containing slot through the entrance, wherein the stylus comprises: a stylus body; and a second magnetic member disposed on the stylus body or embedded in the stylus body, wherein when the stylus is contained within the containing slot, the stylus is kept within the containing slot due to a magnetic attractive force generated between the first magnetic member and the second magnetic member, wherein when the stylus is contained within the containing slot, the first magnetic member is misaligned with the second magnetic member, such that a center of the first magnetic member corresponds to a position between a center of the second magnetic member and a tip of the stylus; one of the first magnetic member and the second magnetic member is a permanent magnet, and the other one of the first magnetic member and the second magnetic member is a permanent magnet or is composed of magnetic material; and the permanent magnet has an S pole and an N pole, and the S pole and the N pole are arranged along a pole direction substantially perpendicular to a longitudinal direction of the stylus.