That a direct contempt may be punished summarily, without written accusation against the person arraigned, but if the court or judge in chambers shall adjudge him guilty thereof a judgment shall be entered of record, in which shall be specified the conduct constituting such contempt, with a statement of whatever defense or extenuation the accused offered thereto, and the sentence of the court thereon.
K.S.A. 20-1203