简体   繁体   English

我们可以使用C,C ++或Java(任何语言)将PDF文件转换为HTML吗?

[英]Can we convert PDF files to HTML using C,C++,or Java (any language)?

I need to convert PDF files into HTML files (IOS platform) so that I can annotate the HTML page using Javascript. 我需要将PDF文件转换为HTML文件(IOS平台),以便我可以使用Javascript注释HTML页面。 I had some success in annotating HTML pages, so if I can convert PDF to HTML I can complete my task. 我在注释HTML页面方面取得了一些成功,所以如果我可以将PDF转换为HTML,我就可以完成我的任务。 How can I do the conversion? 我该如何进行转换?

Converting FROM PDF is generally Very Hard (at best). 转换FROM PDF通常很难(充其量)。

PDF contains drawing instructions. PDF包含绘图说明。 "Line from here to there", "these characters at these coordinates". “从这里到那里的线”,“这些坐标处的这些字符”。 There's usually no information about the logical meaning of these lines, characters, and images, though "Document Structure" is becoming more common. 虽然“文档结构”变得越来越普遍,但通常没有关于这些行,字符和图像的逻辑含义的信息。

Without "document structure" and "marked content" it is Very Hard to go from "a pile of lines and characters" to "a table with this information in these columns and rows". 如果没有“文档结构”和“标记内容”,很难从“一堆行和字符”转到“在这些列和行中包含此信息的表”。

Not impossible, just Very Hard. 并非不可能,只是很难。

And people who have worked on this problem aren't all that interested in sharing their code for free. 那些解决这个问题的人并不是都对免费共享代码感兴趣。

It will be hard to convert any pdf, some of them are too complicated for HTML. 转换任何pdf都很难,其中一些对于HTML来说太复杂了。

Take a look at libpoppler it has already pdf2html functions and it is open source, you can always extends it, so it fits yours requirements. 看看libpoppler它已经有pdf2html函数,它是开源的,你可以随时扩展它,所以它符合你的要求。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 LibreOffice UNO:设置样式(可以使用Java,VB,Python,C ++或使用UNO API的任何语言来提供) - LibreOffice UNO: Setting Styles (anwer can be provided in Java, VB, Python, C++, any language using UNO API) 在Java或C ++中将latex转换为html? - Convert latex to html in Java or C++? 我们可以使用任何语言编写Java虚拟机吗? - Can we write a java virtual machine using any language? 如何转换“ArrayList <ClassNod> “用Java编写成C ++程序语言? - How to convert an “ArrayList<ClassNod>” written in Java into a C++ program language? D转换器:有没有办法将D语言转换为java或C ++? - D converter: Is there a way to convert D language to java or C++? 如何领取一套<String>由C++ JNI中的java方法返回,我们可以将jobject转换为set<String> ? - How to receive a set<String> returned by java method in C++ JNI, can we Convert jobject to set<String>? 在任何情况下,Java 都能比 C++ 更快吗? - Can Java be faster C++ in any situation? 在Java中,我们可以使用javap disassembeler探索Java类方法。 如何在C ++中做同样的事情? - In java we can explore a java class, methods by using javap disassembeler. how to do the same in c++? 使用 Java 将 HTML 转换为 PDF - Convert HTML to PDF using Java 在Java中使用C ++“ .lib”文件 - Using c++ “.lib” files in java
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM