Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
cmap [2020/02/23 13:33]
christian [Mappings outside the codespace]
cmap [2020/02/23 13:45]
christian [Codespace problems]
Line 126: Line 126:
 ===== Monster from the wild ===== ===== Monster from the wild =====
  
 +CMaps are not well defined. Therefore, there are some interesting variations of them in the wild. Here is a small selection of some issues.
 +==== Codespace problems ====
  
-==== Mappings outside the codespace ====+=== Wrong code length ===
  
 <code postscript> <code postscript>
Line 147: Line 149:
 This can be seen often. These illegal mappings are collected into the ''#unmapped'' variable of a Mappings object. This can be seen often. These illegal mappings are collected into the ''#unmapped'' variable of a Mappings object.
  
-==== Wrong PostScript ====+=== Mappings outside the codespace ===
  
-using /find instead of /findresource +<code postscript> 
 +%... 
 +1 begincodespacerange 
 +<0001> <1004> 
 +endcodespacerange 
 +11 beginbfchar 
 +<0003> <00A0> 
 +<0005> <0022> 
 +<0008> <0025> 
 +<000F> <002C> 
 +<0010> <00AD> 
 +%... 
 +</code> 
 + 
 +Here, only the first mapping matches the code space. All others fall outside of it, because the second byte has to be between <00> and <04>
 + 
 +==== Wrong PostScript ====
  
-See [[postscript#exception_handling_example]]+On one occasion, I saw a CMap where the PostScript used a non-existing operator (''/find'' instead of ''/findresource''). See the [[postscript#exception_handling_example]] on the PostScript page.
 ==== Prevent copying ==== ==== Prevent copying ====
  
  • cmap.txt
  • Last modified: 2020/02/23 14:33
  • by christian