image-type-header-regexps
image-type-header-regexps is a variable defined in `
image.el
'.
Its value is shown
below.
- This variable may be risky if used as a file-local variable.
Documentation:
Alist of (REGEXP . IMAGE-TYPE) pairs used to auto-detect image types.
When the first bytes of an image file match REGEXP, it is assumed to
be of image type IMAGE-TYPE if IMAGE-TYPE is a symbol. If not a symbol,
IMAGE-TYPE must be a pair (PREDICATE . TYPE). PREDICATE is called
with one argument, a string containing the image data. If PREDICATE returns
a non-nil value, TYPE is the image's type.
Value:
(("\\`/[ \n
]*\\*.*XPM.\\*/" . xpm)
("\\`P[1-6]\\(?:\\(?:\\(?:#[^
\n]*[
\n]\\)?[[:space:]]\\)+\\(?:\\(?:#[^
\n]*[
\n]\\)?[0-9]\\)+\\)\\{2\\}" . pbm)
("\\`GIF8[79]a" . gif)
("\\`\211PNG
\n\n" . png)
("\\`[ \n
]*#define \\([a-z0-9_]+\\)_width [0-9]+\n#define \\1_height [0-9]+\n\\(#define \\1_x_hot [0-9]+\n#define \\1_y_hot [0-9]+\n\\)?static \\(unsigned \\)?char \\1_bits" . xbm)
("\\`\\(?:MM \\*\\|II\\* \\)" . tiff)
("\\`[ \n
]*%!PS" . postscript)
("\\`\377\330" . jpeg)
("\\(?:<\\?xml[
\n]+[^>]*>\\)?[
\n]*<\\(?:!--\\(?:[^-]\\|-[^-]\\)*-->[
\n]*<\\)*\\(?:!DOCTYPE[
\n]+[^>]*>[
\n]*<[
\n]*\\(?:!--\\(?:[^-]\\|-[^-]\\)*-->[
\n]*<\\)*\\)?[Ss][Vv][Gg]" . svg))