implement the head bar