Update for CamlPDF inline image changes
This commit is contained in:
parent
332ff6c6b8
commit
76a0c23a5c
|
@ -194,7 +194,7 @@ let rec op_of_json = function
|
||||||
| `List [`String s; `String "Unknown"] -> O.Op_Unknown s
|
| `List [`String s; `String "Unknown"] -> O.Op_Unknown s
|
||||||
| `List [`String s; obj; `String "DP"] -> O.Op_DP (s, object_of_json obj)
|
| `List [`String s; obj; `String "DP"] -> O.Op_DP (s, object_of_json obj)
|
||||||
| `List [a; `String b; `String "InlineImage"] ->
|
| `List [a; `String b; `String "InlineImage"] ->
|
||||||
O.InlineImage (object_of_json a, Pdfio.bytes_of_string b)
|
O.InlineImage (object_of_json a, None, Pdfio.bytes_of_string b)
|
||||||
| `List torev ->
|
| `List torev ->
|
||||||
begin match rev torev with
|
begin match rev torev with
|
||||||
| `String "SCN"::ns -> O.Op_SCN (map opf (rev ns))
|
| `String "SCN"::ns -> O.Op_SCN (map opf (rev ns))
|
||||||
|
@ -452,7 +452,7 @@ let json_of_op utf8 pdf no_stream_data = function
|
||||||
`List (map (fun x -> mkfloat x) fs @ [`String s; `String "SCNName"])
|
`List (map (fun x -> mkfloat x) fs @ [`String s; `String "SCNName"])
|
||||||
| O.Op_scnName (s, fs) ->
|
| O.Op_scnName (s, fs) ->
|
||||||
`List (map (fun x -> mkfloat x) fs @ [`String s; `String "scnName"])
|
`List (map (fun x -> mkfloat x) fs @ [`String s; `String "scnName"])
|
||||||
| O.InlineImage (dict, data) ->
|
| O.InlineImage (dict, dp, data) ->
|
||||||
`List [json_of_object ~utf8 pdf (fun _ -> ()) ~no_stream_data ~parse_content:false dict; `String (Pdfio.string_of_bytes data); `String "InlineImage"]
|
`List [json_of_object ~utf8 pdf (fun _ -> ()) ~no_stream_data ~parse_content:false dict; `String (Pdfio.string_of_bytes data); `String "InlineImage"]
|
||||||
| O.Op_DP (s, obj) ->
|
| O.Op_DP (s, obj) ->
|
||||||
`List [`String s; json_of_object ~utf8 pdf (fun _ -> ()) ~no_stream_data ~parse_content:false obj; `String "DP"]
|
`List [`String s; json_of_object ~utf8 pdf (fun _ -> ()) ~no_stream_data ~parse_content:false obj; `String "DP"]
|
||||||
|
|
Loading…
Reference in New Issue