1. An image forming apparatus that includes recording heads, the recording heads ejecting recording liquids of a plurality of colors onto a recording medium, and performs multiple-color recording, the image forming apparatus comprising: a reference-patch forming unit that records a reference patch on the recording medium, the reference patch being formed by overlaying dot array patterns recorded with the recording liquids of different colors, the dot array patterns having no correlation therebetween; a detection-patch-group forming unit that records a detection patch group including detection patches on the recording medium, each of the detection patches being formed by overlaying dot array patterns recorded with the recording liquids of the different colors, the dot array patterns having a same cycle of regular dot array, the detection patches being allocated with different misregistration amounts of the dot array patterns; and a color-misregistration correcting unit that corrects color misregistration based on results of comparison between color tone of the reference patch and color tone of each of the detection patches of the detection patch group.