<s>
In	O
computer	O
graphics	O
,	O
the	O
X	B-Operating_System
Window	I-Operating_System
System	I-Operating_System
used	O
X	B-Device
BitMap	I-Device
(	O
XBM	B-Device
)	O
,	O
a	O
plain	O
text	O
binary	B-Algorithm
image	I-Algorithm
format	O
,	O
for	O
storing	O
cursor	B-Application
and	O
icon	O
bitmaps	O
used	O
in	O
the	O
X	B-Operating_System
GUI	B-Application
.	O
</s>
<s>
The	O
XBM	B-Device
format	O
is	O
superseded	O
by	O
XPM	O
,	O
which	O
first	O
appeared	O
for	O
X11	B-Operating_System
in	O
1989	O
.	O
</s>
<s>
XBM	B-Device
files	O
differ	O
markedly	O
from	O
most	O
image	O
files	O
in	O
that	O
they	O
take	O
the	O
form	O
of	O
C	B-Language
source	O
files	O
.	O
</s>
<s>
This	O
means	O
that	O
they	O
can	O
be	O
compiled	O
directly	O
into	O
an	O
application	O
without	O
any	O
preprocessing	O
steps	O
,	O
but	O
it	O
also	O
makes	O
them	O
far	O
larger	O
than	O
their	O
raw	O
pixel	B-Algorithm
data	O
.	O
</s>
<s>
The	O
image	O
data	O
is	O
encoded	O
as	O
a	O
comma-separated	O
list	O
of	O
byte	O
values	O
,	O
each	O
written	O
in	O
the	O
C	B-Language
hexadecimal	O
notation	O
,	O
'	O
0x13	O
 '	O
for	O
example	O
,	O
so	O
that	O
multiple	O
ASCII	O
characters	O
are	O
used	O
to	O
express	O
a	O
single	O
byte	O
of	O
image	O
information	O
.	O
</s>
<s>
XBM	B-Device
data	O
consists	O
of	O
a	O
series	O
of	O
static	O
unsigned	O
char	O
arrays	B-Data_Structure
containing	O
the	O
monochrome	O
pixel	B-Algorithm
data	O
.	O
</s>
<s>
When	O
the	O
format	O
was	O
in	O
common	O
use	O
,	O
an	O
XBM	B-Device
typically	O
appeared	O
in	O
headers	B-General_Concept
(	O
.h	O
files	O
)	O
which	O
featured	O
one	O
array	O
per	O
image	O
stored	O
in	O
the	O
header	B-General_Concept
.	O
</s>
<s>
The	O
following	O
piece	O
of	O
C	B-Language
code	O
exemplifies	O
an	O
XBM	B-Device
file	O
:	O
</s>
<s>
In	O
place	O
of	O
the	O
usual	O
image-file-format	O
header	B-General_Concept
,	O
XBM	B-Device
files	O
has	O
two	O
or	O
four	O
#define	O
statements	O
.	O
</s>
<s>
The	O
first	O
two	O
#defines	O
specify	O
the	O
height	O
and	O
width	O
of	O
the	O
bitmap	O
in	O
pixels	B-Algorithm
.	O
</s>
<s>
(	O
In	O
the	O
case	O
of	O
bitmapped	O
cursors	B-Application
,	O
the	O
"	O
hotspot	O
"	O
refers	O
to	O
the	O
position	O
of	O
the	O
cursor	B-Application
"	O
point	O
"	O
,	O
generally	O
at	O
0	O
,	O
0	O
.	O
)	O
</s>
<s>
XBM	B-Device
image	O
data	O
consists	O
of	O
a	O
line	O
of	O
pixel	B-Algorithm
values	O
stored	O
in	O
a	O
static	O
array	O
.	O
</s>
<s>
Because	O
a	O
single	O
bit	O
represents	O
each	O
pixel	B-Algorithm
(	O
0	O
for	O
white	O
or	O
1	O
for	O
black	O
)	O
,	O
each	O
byte	O
in	O
the	O
array	O
contains	O
the	O
information	O
for	O
eight	O
pixels	B-Algorithm
,	O
with	O
the	O
upper	O
left	O
pixel	B-Algorithm
in	O
the	O
bitmap	O
represented	O
by	O
the	O
low	O
bit	O
of	O
the	O
first	O
byte	O
in	O
the	O
array	O
.	O
</s>
<s>
Some	O
web	B-Application
browsers	I-Application
support	O
displaying	O
XBM	B-Device
images	O
as	O
a	O
holdover	O
from	O
the	O
early	O
days	O
of	O
the	O
World	O
Wide	O
Web	O
,	O
when	O
XBM	B-Device
was	O
the	O
minimal	O
non-proprietary	O
image	O
file	O
format	O
.	O
</s>
<s>
The	O
Arena	B-Application
web	I-Application
browser	I-Application
had	O
full	O
support	O
since	O
version	O
0.3.34	O
(	O
25	O
July	O
1997	O
)	O
.	O
</s>
<s>
XBM	B-Device
support	O
was	O
removed	O
from	O
Internet	B-Application
Explorer	I-Application
6	I-Application
,	O
Mozilla	B-Protocol
Firefox	I-Protocol
3.6	I-Protocol
,	O
and	O
WebKit-based	O
browsers	B-Application
.	O
</s>
<s>
There	O
is	O
a	O
strong	O
indication	O
that	O
Chromium	B-Language
(	O
and	O
therefore	O
,	O
also	O
,	O
Google	B-Application
Chrome	I-Application
)	O
does	O
not	O
support	O
XBM	B-Device
.	O
</s>
<s>
Documentation	O
for	O
Opera	B-Application
2.12	O
and	O
6.0	O
indicates	O
that	O
XBM	B-Device
was	O
at	O
least	O
previously	O
supported	O
.	O
</s>
<s>
Some	O
image	O
viewers/converters	O
,	O
e.g.	O
,	O
XnView	B-Protocol
,	O
FFmpeg	B-Library
and	O
IrfanView	B-Protocol
,	O
support	O
XBM	B-Device
.	O
</s>
<s>
A	O
48×48	O
XBM	B-Device
can	O
be	O
converted	O
to	O
Ikon	O
and	O
eventually	O
X-Face	B-Application
with	O
Netpbm	B-Language
tools	O
.	O
</s>
<s>
Despite	O
having	O
been	O
superseded	O
by	O
the	O
XPM	O
format	O
,	O
XBM	B-Device
is	O
still	O
used	O
by	O
some	O
modern	O
but	O
lightweight	O
window	B-Application
managers	I-Application
like	O
Openbox	B-Language
to	O
define	O
simple	O
button	O
images	O
in	O
a	O
window	O
's	O
title	O
bar	O
,	O
such	O
as	O
the	O
iconify/minimize	O
,	O
restore	O
,	O
and	O
maximize	O
buttons	O
.	O
</s>
<s>
XBM	B-Device
is	O
also	O
used	O
in	O
embedded	O
processing	O
(	O
microControllers	O
)	O
to	O
display	O
Icons	O
used	O
in	O
GUIs	B-Application
.	O
</s>
<s>
ImageMagick	O
supports	O
converting	O
images	O
both	O
to	O
and	O
from	O
XBM	B-Device
.	O
</s>
<s>
GIMP	B-Application
may	O
be	O
used	O
to	O
create	O
or	O
modify	O
images	O
using	O
the	O
XBM	B-Device
format	O
,	O
and	O
also	O
supports	O
converting	O
images	O
to	O
and	O
from	O
the	O
XBM	B-Device
format	O
.	O
</s>
