printer 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. #------------------------------------------------------------------------------
  2. # $File: printer,v 1.29 2019/04/19 00:42:27 christos Exp $
  3. # printer: file(1) magic for printer-formatted files
  4. #
  5. # PostScript, updated by Daniel Quinlan (quinlan@yggdrasil.com)
  6. 0 string %! PostScript document text
  7. !:mime application/postscript
  8. !:apple ASPSTEXT
  9. >2 string PS-Adobe- conforming
  10. >>11 string >\0 DSC level %.3s
  11. >>>15 string EPS \b, type %s
  12. >>>15 string Query \b, type %s
  13. >>>15 string ExitServer \b, type %s
  14. >>>15 search/1000 %%LanguageLevel:\040
  15. >>>>&0 string >\0 \b, Level %s
  16. # Some PCs have the annoying habit of adding a ^D as a document separator
  17. 0 string \004%! PostScript document text
  18. !:mime application/postscript
  19. !:apple ASPSTEXT
  20. >3 string PS-Adobe- conforming
  21. >>12 string >\0 DSC level %.3s
  22. >>>16 string EPS \b, type %s
  23. >>>16 string Query \b, type %s
  24. >>>16 string ExitServer \b, type %s
  25. >>>16 search/1000 %%LanguageLevel:\040
  26. >>>>&0 string >\0 \b, Level %s
  27. 0 string \033%-12345X%!PS PostScript document
  28. # DOS EPS Binary File Header
  29. # From: Ed Sznyter <ews@Black.Market.NET>
  30. 0 belong 0xC5D0D3C6 DOS EPS Binary File
  31. >4 long >0 Postscript starts at byte %d
  32. >>8 long >0 length %d
  33. >>>12 long >0 Metafile starts at byte %d
  34. >>>>16 long >0 length %d
  35. >>>20 long >0 TIFF starts at byte %d
  36. >>>>24 long >0 length %d
  37. # Summary: Adobe's PostScript Printer Description File
  38. # Extension: .ppd
  39. # Reference: https://partners.adobe.com/public/developer/en/ps/5003.PPD_Spec_v4.3.pdf, Section 3.8
  40. # Submitted by: Yves Arrouye <arrouye@marin.fdn.fr>
  41. #
  42. 0 string *PPD-Adobe:\x20 PPD file
  43. >&0 string x \b, version %s
  44. # HP Printer Job Language
  45. 0 string \033%-12345X@PJL HP Printer Job Language data
  46. # HP Printer Job Language
  47. # The header found on Win95 HP plot files is the "Silliest Thing possible"
  48. # (TM)
  49. # Every driver puts the language at some random position, with random case
  50. # (LANGUAGE and Language)
  51. # For example the LaserJet 5L driver puts the "PJL ENTER LANGUAGE" in line 10
  52. # From: Uwe Bonnes <bon@elektron.ikp.physik.th-darmstadt.de>
  53. #
  54. 0 string \033%-12345X@PJL HP Printer Job Language data
  55. >&0 string >\0 %s
  56. >>&0 string >\0 %s
  57. >>>&0 string >\0 %s
  58. >>>>&0 string >\0 %s
  59. #>15 string \ ENTER\ LANGUAGE\ =
  60. #>31 string PostScript PostScript
  61. # From: Stefan Thurner <thurners@nicsys.de>
  62. 0 string \033%-12345X@PJL
  63. >&0 search/10000 %! PJL encapsulated PostScript document text
  64. # Rick Richardson <rickrich@gmail.com>
  65. # For Fuji-Xerox Printers - HBPL stands for Host Based Printer Language
  66. # For Oki Data Printers - HIPERC
  67. # For Konica Minolta Printers - LAVAFLOW
  68. # For Samsung Printers - QPDL
  69. # For HP Printers - ZJS stands for Zenographics ZJStream
  70. 0 string \033%-12345X@PJL HP Printer Job Language data
  71. >0 search/10000 @PJL\ ENTER\ LANGUAGE=HBPL - HBPL
  72. >0 search/10000 @PJL\ ENTER\ LANGUAGE=HIPERC - Oki Data HIPERC
  73. >0 search/10000 @PJL\ ENTER\ LANGUAGE=LAVAFLOW - Konica Minolta LAVAFLOW
  74. >0 search/10000 @PJL\ ENTER\ LANGUAGE=QPDL - Samsung QPDL
  75. >0 search/10000 @PJL\ ENTER\ LANGUAGE\ =\ QPDL - Samsung QPDL
  76. >0 search/10000 @PJL\ ENTER\ LANGUAGE=ZJS - HP ZJS
  77. # HP Printer Control Language, Daniel Quinlan (quinlan@yggdrasil.com)
  78. 0 string \033E\033 HP PCL printer data
  79. >3 string \&l0A - default page size
  80. >3 string \&l1A - US executive page size
  81. >3 string \&l2A - US letter page size
  82. >3 string \&l3A - US legal page size
  83. >3 string \&l26A - A4 page size
  84. >3 string \&l80A - Monarch envelope size
  85. >3 string \&l81A - No. 10 envelope size
  86. >3 string \&l90A - Intl. DL envelope size
  87. >3 string \&l91A - Intl. C5 envelope size
  88. >3 string \&l100A - Intl. B5 envelope size
  89. >3 string \&l-81A - No. 10 envelope size (landscape)
  90. >3 string \&l-90A - Intl. DL envelope size (landscape)
  91. # IMAGEN printer-ready files:
  92. 0 string @document( Imagen printer
  93. # this only works if "language xxx" is first item in Imagen header.
  94. >10 string language\ impress (imPRESS data)
  95. >10 string language\ daisy (daisywheel text)
  96. >10 string language\ diablo (daisywheel text)
  97. >10 string language\ printer (line printer emulation)
  98. >10 string language\ tektronix (Tektronix 4014 emulation)
  99. # Add any other languages that your Imagen uses - remember
  100. # to keep the word `text' if the file is human-readable.
  101. # [GRR 950115: missing "postscript" or "ultrascript" (whatever it was called)]
  102. #
  103. # Now magic for IMAGEN font files...
  104. 0 string Rast RST-format raster font data
  105. >45 string >0 face %s
  106. # From Jukka Ukkonen
  107. 0 string \033[K\002\0\0\017\033(a\001\0\001\033(g Canon Bubble Jet BJC formatted data
  108. # From <mike@flyn.org>
  109. # These are the /etc/magic entries to decode data sent to an Epson printer.
  110. 0 string \x1B\x40\x1B\x28\x52\x08\x00\x00REMOTE1P Epson Stylus Color 460 data
  111. #------------------------------------------------------------------------------
  112. # zenographics: file(1) magic for Zenographics ZjStream printer data
  113. # Rick Richardson <rickrich@gmail.com>
  114. 0 string JZJZ
  115. >0x12 string ZZ Zenographics ZjStream printer data (big-endian)
  116. 0 string ZJZJ
  117. >0x12 string ZZ Zenographics ZjStream printer data (little-endian)
  118. #------------------------------------------------------------------------------
  119. # Oak Technologies printer stream
  120. # Rick Richardson <rickrich@gmail.com>
  121. 0 string OAK
  122. >0x07 byte 0
  123. >0x0b byte 0 Oak Technologies printer stream
  124. # This would otherwise be recognized as PostScript - nick@debian.org
  125. 0 string %!VMF SunClock's Vector Map Format data
  126. #------------------------------------------------------------------------------
  127. # HP LaserJet 1000 series downloadable firmware file
  128. 0 string \xbe\xefABCDEFGH HP LaserJet 1000 series downloadable firmware
  129. # From: Paolo <oopla@users.sf.net>
  130. # Epson ESC/Page, ESC/PageColor
  131. 0 string \x1b\x01@EJL Epson ESC/Page language printer data