| Previous | Next |
| DWRITE_E_ALREADYREGISTERED | DWRITE_E_CACHEVERSION |
DWRITE_E_CACHEFORMAT
The scope of DWRITE_E_CACHEFORMAT is DirectWrite font-cache compatibility. DirectWrite found font-cache data whose internal format is invalid or corrupt. Keep 0x88985007 beside the returning method because a wrapper can replace this distinction with a generic subsystem message.
Locate the first rejecting layer
When DWRITE_E_CACHEFORMAT is returned, font-cache data is derived state tied to a runtime format and version. Corrupt structure and incompatible version are distinct: one points to invalid stored bytes, while the other can follow servicing, rollback, deployment, or restoration of cache data from another image in the DWRITE_E_CACHEFORMAT path. For DWRITE_E_CACHEFORMAT, font files should not be removed merely because the cache is rejected.
For DWRITE_E_CACHEFORMAT, inspect the following boundary: font cache parsing and validation before cached glyph or font data can be trusted.
Misleading responses
CACHEVERSION means a structurally valid cache belongs to another DirectWrite version; CACHEFORMAT means the stored data itself cannot be accepted. For DWRITE_E_CACHEFORMAT, do not delete arbitrary font files when the failing object is the cache; distinguish cache regeneration from font removal.
Evidence that changes the diagnosis
| Record | Why it matters here |
|---|---|
| Cache file identity, size, timestamp, and owner service | Preserving cache file identity, size, timestamp, and owner service provides the evidence needed to test this distinction: cACHEVERSION means a structurally valid cache belongs to another DirectWrite version; CACHEFORMAT means the stored data itself cannot be accepted. |
| OS and DirectWrite build | For DWRITE_E_CACHEFORMAT, recording OS and DirectWrite build separates the DirectWrite font-cache compatibility boundary from a later wrapper symptom. |
| Font changes immediately before corruption | In DWRITE_E_CACHEFORMAT diagnostics, recording font changes immediately before corruption ties the HRESULT to the DirectWrite font-cache compatibility boundary rather than to the final visible failure. |
| Service and filesystem errors during cache write | Comparing service and filesystem errors during cache write shows whether DWRITE_E_CACHEFORMAT follows input, object state, or environment. |
Controlled reproduction
For DWRITE_E_CACHEFORMAT, preserve cache identity and servicing history, stop dependent components through supported means, and allow the installed runtime to regenerate derived data. When DWRITE_E_CACHEFORMAT is returned, verify reuse across subsequent starts so a deployment tool is not restoring the rejected cache.
- When DWRITE_E_CACHEFORMAT is returned, stop dependent applications before supported cache rebuild.
- Preserve a copy or hash for diagnosis when permitted in the DWRITE_E_CACHEFORMAT path.
- For DWRITE_E_CACHEFORMAT, validate filesystem and abrupt-shutdown history.
- When DWRITE_E_CACHEFORMAT is returned, confirm DirectWrite regenerates the cache and loads the same fonts.
Comparison tests
| Test | Interpretation | Hold constant |
|---|---|---|
| Same environment, reduced input | If DWRITE_E_CACHEFORMAT disappears with a smaller faithful case, complexity within DirectWrite font-cache compatibility is implicated. | For DWRITE_E_CACHEFORMAT, keep cache file identity, size, timestamp, and owner service fixed while simplifying font changes immediately before corruption. |
| Same input, fresh object generation | If DWRITE_E_CACHEFORMAT changes after rebuilding state, examine ownership across font loader, font file or cache reader, face construction, shaping or glyph operation, and caller fallback. | For DWRITE_E_CACHEFORMAT, place OS and DirectWrite build on the timeline of the last successful transition. |
| Same operation on a controlled second path | If DWRITE_E_CACHEFORMAT follows one environment, the failure is not explained by source data alone. | For DWRITE_E_CACHEFORMAT, compare OS build, DirectWrite version, font source, process architecture, locale, and rendering parameters while preserving service and filesystem errors during cache write. |
Closure criteria
A correction for DWRITE_E_CACHEFORMAT should let the operation at the DirectWrite font-cache compatibility boundary complete repeatedly under the original supported conditions. Repeat the control that begins with “Stop dependent applications before supported cache rebuild” and confirm that the following lifecycle step also succeeds. For DWRITE_E_CACHEFORMAT, keep the original failing sample and one deliberate negative case so fallback cannot be mistaken for repair.
Technical references
When DWRITE_E_CACHEFORMAT is returned, these references define the public API family, object model, or error list used to interpret this status.
- Microsoft: DirectWrite error codes.
- Microsoft: Introducing DirectWrite.
- Microsoft: DirectWrite font interfaces.
- Microsoft: Glyph image formats in DirectWrite.
Looking for a different code? Search another status or error code.