Patent ID: 8817318

Claim:
A printer comprising: a retrieving unit that retrieves a file including document data; a controller comprising: a content acquiring unit that acquires information of a table of contents of the document data from the file; and an index image generating unit that generates an index image depicting the table of contents of the file based on the information of the table of contents; and a list printing unit that prints a list image containing the index image, the content acquiring unit comprising: a first determining unit that determines whether the file includes content data indicative of the table of contents of the document data; a second determining unit that determines whether the document data in the file includes a content page containing the table of contents; a third determining unit that determines whether the document data in the file includes data of a headline; a content data acquiring unit that is configured to acquire the content data from the file; a content page acquiring unit that is configured to acquire the content page from the document data; and a headline acquiring unit that is configured to acquire the data of the headline from the document data, wherein if the first determining unit determines that the file includes the content data, the content data acquiring unit acquires the content data and the index image generating unit generates the index image based on the content data, wherein if the first determining unit determines that the file does not include the content data and if the second determining unit determines that the document data contains the content page, the content page acquiring unit acquires the content page and the index image generating unit generates the index image based on the content page, and wherein if the first determining unit determines that the file does not include the content data, if the second determining unit determines that the document data does not contain the content page, and if the third determining unit determines that the document data includes data of the headline, the headline acquiring unit acquires the data of the headline from the document data and the index image generating unit generates the index image based on the headline.