As to the configuration in the diagram, it is allowed by 250.148(C):
(C) Metal Boxes. A connection shall be made between the
one or more equipment grounding conductors and a metal
box by means of a grounding screw that shall be used for
no other purpose, equipment listed for grounding, or a
listed grounding device.
However, what I would use instead here is called a "self-grounding" switch or outlet -- they have a spring clip on each of the yoke ears that ensures that the receptacle makes solid contact with the box even if the mounting screws loosen. This is explicitly allowed by NEC 250.146(B):
(B) Contact Devices or Yokes. Contact devices or yokes
designed and listed as self-grounding shall be permitted in
conjunction with the supporting screws to establish equipment bonding between the device yoke and flush-type boxes.
Note that using plain metal-to-metal contact between the yoke and box for yoke bonding is only allowed in surface mounted metal electrical boxes (i.e. a conduit box sitting on the garage wall), not on boxes that are mounted flush with the wall -- the verbiage in NEC 250.146(A) that allows metal-to-metal contact between an ordinary yoke and a box to bond the yoke only applies to surface mounted boxes:
(A) Surface-Mounted Box. Where the box is mounted on
the surface, direct metal-to-metal contact between the de
vice yoke and the box or a contact yoke or device that
complies with 250.146(B) shall be permitted to ground the
receptacle to the box. At least one of the insulating washers
shall be removed from receptacles that do not have a contact yoke or device that complies with 250.146(B) to ensure direct metal-to-metal contact. This provision shall not apply
to cover-mounted receptacles unless the box and cover
combination are listed as providing satisfactory ground
continuity between the box and the receptacle. A listed exposed work cover shall be permitted to be the grounding
and bonding means when (1) the device is attached to the
cover with at least two fasteners that are permanent (such
as a rivet) or have a thread locking or screw or nut locking
means and (2) when the cover mounting holes are located
on a flat non-raised portion of the cover.