Image MIME Reference
WMF
Windows Metafile
image/x-wmf
VS
X Bitmap (Legacy MIME Alias)
image/x-xbm
XBM
A complete technical comparison of Windows Metafile and X Bitmap (Legacy MIME Alias) — covering compression, feature support, browser compatibility, magic bytes, and when to choose each format.
Equal browser support
Feature Support
| Feature | WMF | XBM |
|---|---|---|
| Transparency (Alpha) | Yes | Yes |
| Animation Support | ✕ No | ✕ No |
| Progressive Loading | ✕ No | ✕ No |
| HDR Support | ✕ No | ✕ No |
| EXIF Metadata | ✕ No | ✕ No |
| ICC Color Profile | ✕ No | ✕ No |
Windows Metafile
image/x-wmf
Extension
.wmf.emf
Container
Windows GDI Metafile Command Stream
Compression
Uncompressed (Command Stream)
Algorithm
None
Color Depth
Varies based on GDI rendering engine
Developed by
Microsoft Corporation
Released
1990
Magic Bytes
D7 CD C6 9A (Aldus Placeable Metafile Header) or 01 00 09 00 (Standard WMF Header)
X Bitmap (Legacy MIME Alias)
image/x-xbm
Extension
.xbm
Container
C Source Code Header (.h)
Compression
Uncompressed (Source Code)
Algorithm
None
Color Depth
1-bit (Monochrome)
Developed by
MIT / X Consortium (X Window System)
Released
1988
Magic Bytes
23 64 65 66 69 6e 65 (ASCII '#define')
Browser Support Comparison
| Browser | WMF | XBM |
|---|---|---|
|
|
✕ | ✕ |
|
|
✕ | ✕ |
|
|
✕ | ✕ |
|
|
✕ | ✕ |
|
|
✓
|
✓
|
WMF
WMF Strengths
- Infinitely scalable vector format that remains remarkably compact for simple geometric illustrations and charts
- Historically served as a seamless conduit for copying and pasting vector graphics between disparate Windows applications via the system clipboard
Limitations
- Notoriously plagued by historic security vulnerabilities, making raw WMF parsing a vector for exploits in legacy software
- Completely obsolete and unsupported in modern web environments (browsers cannot render them)
- Strictly tied to the Windows GDI architecture, making cross-platform rendering inconsistent across Linux and macOS
XBM
XBM Strengths
- Can be compiled directly into C or C++ source code without needing an external file loader or binary asset manager
- Human-readable structure allows developers to inspect, edit, or hand-craft tiny icons directly within a text editor
- Extremely predictable and lightweight for 1-bit hardware displays and embedded systems
Limitations
- Strictly limited to 1-bit monochrome (black and white) graphics with no gray or color support
- Text-based C syntax creates massive file bloat compared to binary 1-bit formats like PBM
- Completely deprecated in modern web browsers and desktop GUI frameworks
When to choose which format
WMF
Use WMF when…
- Legacy Microsoft Office Clip Art and Icons
- Windows GDI Graphics Export
- Early Windows Desktop Publishing
XBM
Use XBM when…
- X Window System (X11) Cursors and Icons
- Embedded C/C++ Firmware UI Assets
- Early 1990s Unix Web Graphics