Beginning to excise internal linearization

This commit is contained in:
John Whitington 2014-10-01 14:59:25 +01:00
parent 5793a24e28
commit ccb78fc280
2 changed files with 9 additions and 9 deletions

View File

@ -1433,7 +1433,7 @@ let fast_write_split_pdfs enc printf splitlevel original_filename linearize pres
let name = name_of_spec printf marks main_pdf splitlevel spec number (stem original_filename) startpage endpage in
Pdf.remove_unreferenced pdf;
if sq then squeeze pdf;
Pdfwrite.pdf_to_file_options ~preserve_objstm ~generate_objstm:create_objstm linearize enc (not (enc = None)) pdf name)
Pdfwrite.pdf_to_file_options ~preserve_objstm ~generate_objstm:create_objstm false (*FIXLIN*) enc (not (enc = None)) pdf name)
(indx pagenums)
pagenums

View File

@ -1787,7 +1787,7 @@ let write_pdf mk_id pdf =
Pdfwrite.pdf_to_file_options
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize None mk_id pdf outname
false (*FIXLIN args.linearize*) None mk_id pdf outname
| Stdout ->
let pdf = Cpdf.recompress_pdf <| nobble pdf in
if args.squeeze then Cpdf.squeeze pdf;
@ -1795,7 +1795,7 @@ let write_pdf mk_id pdf =
Pdfwrite.pdf_to_channel
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize None mk_id pdf stdout;
false (*FIXLIN args.linearize*) None mk_id pdf stdout;
flush stdout (*r For Windows *)
let pdf_of_stdin user_pw owner_pw =
@ -2919,9 +2919,9 @@ let go () =
error "no output specified"
| File outname ->
let outname = writing_ok outname in
Pdfwrite.pdf_to_file_options args.linearize None args.makenewid pdf outname
Pdfwrite.pdf_to_file_options (*FIXLIN args.linearize*) false None args.makenewid pdf outname
| Stdout ->
Pdfwrite.pdf_to_channel args.linearize None args.makenewid pdf stdout;
Pdfwrite.pdf_to_channel (*FIXLIN args.linearize *) false None args.makenewid pdf stdout;
flush stdout
end
| Some Compress ->
@ -3099,13 +3099,13 @@ let go () =
Pdfwrite.pdf_to_file_options
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize None true pdf s
(*FIXLIN args.linearize*) false None true pdf s
| [(k, _, _, _, _) as input], Stdout ->
let pdf = get_pdf_from_input_kind input args.op k in
Pdfwrite.pdf_to_channel
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize None true pdf stdout;
(*FIXLIN args.linearize*) false None true pdf stdout;
flush stdout
| _ -> error "ChangeId: exactly one input file and output file required."
end
@ -3370,12 +3370,12 @@ let go () =
Pdfwrite.pdf_to_file_options
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize (Some encryption) args.makenewid pdf outname
(*FIXLIN args.linearize*)false (Some encryption) args.makenewid pdf outname
| Stdout ->
Pdfwrite.pdf_to_channel
~preserve_objstm:args.preserve_objstm
~generate_objstm:args.create_objstm
args.linearize (Some encryption) args.makenewid pdf stdout;
(*FIXLIN args.linearize*)false (Some encryption) args.makenewid pdf stdout;
flush stdout;
end
| Some Decrypt ->