From CorelDRAW X4 a CDR file is a ZIP archive. Any
ZIP tool can list what is inside. The drawing itself is still a stream of
RIFF chunks, with the version character
E for X4, F for X5, G for X6 and so on. This page
follows what libcdr reads; the other members are named only as far as their names
show what they are.
Members
| Member | Holds |
|---|---|
content/riffData.cdr | The drawing as one RIFF stream. libcdr looks for it first. |
content/root.dat | The drawing as a RIFF stream whose chunks may keep their data in the files below. libcdr reads it when there is no riffData.cdr. |
content/dataFileList.dat | The names of the data files, one a line, separated by line feeds. |
content/data/ | The data files, under the names the list gives. |
color/profiles/rgb/, color/profiles/cmyk/ | Colour profiles; libcdr reads them for colour conversion. |
| a PNG with “thumbnail” in its name | The preview picture, in place of the DISP chunk of older files. |
metadata/ | Information about the drawing in XML. |
Chunks kept in data files
From X6 (version 1600), libcdr reads any chunk in the RIFF stream whose length is exactly 16 as a reference to data elsewhere, not as data of its own:
| Offset | Size | Field | Description |
|---|---|---|---|
0 | 4 | Data file | A line of content/dataFileList.dat, counting from 0. |
4 | 4 | Length | How many bytes of that file are the chunk’s data. |
8 | 4 | Offset | Where in the file they start. |
12 | 4 | Unknown | Not read by libcdr. |
The data found there is laid out as the chunk would be in a single stream: a
loda record, a trfd, a fill and so on.
In the explorer
The explorer shows the archive as a ZIP file, record by record, with the thumbnail and a table of the members. It reads the RIFF stream, follows the references into the data files and draws the pages. Opening the stream’s member shows its chunks as a file of their own, where the references appear as their four fields.