简体   繁体   English

QuickLook插件显示图像和一些信息

[英]QuickLook plugin displaying an image and some infos

我正在编写一个QuickLook插件,我想知道如何同时显示图像和有关该图像的一些信息,类似于http://www.code-line.com/software/sneakpeekphoto/

There is only one way to do so: Convert your content to an already supported one. 只有一种方法可以:将您的内容转换为已经支持的内容。 This means either PDF or HTML. 这意味着PDF或HTML。 There are two options you have: 您有两种选择:

  1. For static information you create a simple PDF preview by rendering a view into a PDF. 对于静态信息,您可以通过将视图渲染为PDF来创建简单的PDF预览。 (Use -dataWithPDFInsideRect: method of NSView ) (使用-dataWithPDFInsideRect: NSView方法)
  2. For dynamic information create a HTML page with links and so on. 对于动态信息,请创建包含链接的HTML页面等。 QuickLook will then show it. 然后QuickLook将显示它。 (I think this is also the way your example does it.) (我认为这也是你的例子的方式。)

We have not found a way to create complex previews on ur own and had to stick to one of the methods, too. 我们还没有找到一种方法来创建复杂的预览,并且必须坚持使用其中一种方法。 Keynote and Pages do the same -- they convert their presentations to multi-page PDF previews... Keynote和Pages也是如此 - 他们将演示文稿转换为多页PDF预览......

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

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM