Skip to main content

Crate libreoffice_pure

Crate libreoffice_pure 

Source
Expand description

High-level pure-Rust convenience helpers that mirror Clark’s current soffice --headless usage without relying on LibreOffice itself.

The Clark-focused surface in this crate is:

  • visual DOCX -> PDF
  • visual PPTX -> PDF
  • DOC -> DOCX
  • XLSX recalc with cached <v> patching
  • tracked-change acceptance for DOCX
  • generic convert_bytes / convert_bytes_auto
  • JSON recalc reports compatible with Clark’s existing recalc.py
  • direct DOCX/PPTX page rasterization to PNG/JPEG
  • Markdown extraction for DOCX/PPTX/XLSX
  • PDF -> TXT/MD/HTML via the native PDF reader

Structs§

RecalcCheckReport
RecalcErrorBucket

Functions§

accept_all_tracked_changes_docx_bytes
Walk every WordprocessingML part inside a DOCX, accept all common tracked revisions, then re-emit the package.
accept_tracked_changes_docx_bytesDeprecated
Back-compat alias; prefer accept_all_tracked_changes_docx_bytes.
base_convert_bytes
Convert a base-format byte stream from from to to.
calc_convert_bytes
Convert a calc-format byte stream from from to to.
convert_bytes
Convert any supported office-format byte stream from from to to.
convert_bytes_auto
Infer the source format from the byte payload itself and dispatch to convert_bytes.
convert_path_bytes
Infer the source format from path and dispatch to convert_bytes.
doc_to_docx_bytes
Convert a legacy binary .doc file (Word 97-2003) into a DOCX byte stream by extracting the piece-table text and re-emitting it.
docx_to_html_bytes
docx_to_jpeg_pages
Rasterize a DOCX document directly to JPEG pages at the requested DPI.
docx_to_md_bytes
Extract Markdown from an existing DOCX file using the native Writer importer.
docx_to_odt_bytes
docx_to_pdf_bytes
Convert a DOCX byte stream into a PDF using Writer’s native Rust layout/rendering path.
docx_to_png_pages
Rasterize a DOCX document directly to PNG pages at the requested DPI.
docx_to_txt_bytes
draw_convert_bytes
Convert a draw-format byte stream from from to to.
impress_convert_bytes
Convert an impress-format byte stream from from to to.
math_convert_bytes
Convert a math-format byte stream from from to to.
odp_to_pdf_bytes
odp_to_pptx_bytes
ods_to_csv_bytes
ods_to_pdf_bytes
ods_to_xlsx_bytes
odt_to_docx_bytes
odt_to_html_bytes
odt_to_pdf_bytes
pdf_to_html_bytes
pdf_to_md_bytes
pdf_to_txt_bytes
pptx_to_html_bytes
pptx_to_jpeg_pages
Rasterize a PPTX deck directly to JPEG slide images at the requested DPI.
pptx_to_md_bytes
Extract Markdown from an existing PPTX file using the native Impress importer.
pptx_to_odp_bytes
pptx_to_pdf_bytes
Convert a PPTX byte stream into a PDF using Impress’s native Rust renderer.
pptx_to_png_pages
Rasterize a PPTX deck directly to PNG slide images at the requested DPI.
pptx_to_svg_bytes
recalc_existing_xlsx_bytesDeprecated
Back-compat alias; prefer xlsx_recalc_bytes.
sniff_format_from_bytes
Infer a format from raw bytes.
sniff_format_from_path
Infer a format hint from a file path by looking at its extension.
writer_convert_bytes
Convert a writer-format byte stream from from to to.
xlsx_recalc_bytes
Re-evaluate every formula in an XLSX workbook and rewrite the cached <v> values inside the existing sheet XML. The result is a fresh XLSX byte stream with the same shape as the input, minus xl/calcChain.xml.
xlsx_recalc_check_json
Produce a Clark-shaped JSON report for an existing XLSX workbook.
xlsx_recalc_report
Produce the structured recalc report used by xlsx_recalc_check_json.
xlsx_to_csv_bytes
xlsx_to_html_bytes
xlsx_to_md_bytes
Extract Markdown from an existing XLSX file using the native Calc importer.
xlsx_to_ods_bytes
xlsx_to_pdf_bytes