A person who, in the presence of a court, judge, or magistrate, assaults or threatens to assault another, or to commit an offense against another's property, or who contends with another with angry words to the disturbance of the peace may be ordered by the court, judge, or magistrate without warrant or other proof to give security as provided in this chapter and, if the person omits to do so, may be committed.