MarkMindCkm / obsidian-markmind

A mind map, outline for obsidian,It support mobile and desktop
770 stars 35 forks source link

Feature: Read existing PDF highlights #99

Open derekvan opened 2 years ago

derekvan commented 2 years ago

I have many PDF files with existing highlights that I would like to add to MarkMind mind maps. Would be great if you could add the ability to read these highlights so that I can copy them to the mind map as with the highlights made by mark mind itself.

derekvan commented 2 years ago

This is pretty exciting. I can't quite figure out how to do it though. I'm not sure how to get view the comments in the markdown file like is shown on the gif in the release notes. Could you document this in English? Thanks!

derekvan commented 2 years ago

So I have figured out how to replicate what is shown in the release notes. I'm noticing a key issue. If the highlights have "notes" attached to them, these notes aren't imported. Also, it seems like notes prevent the ability of being able to click on the highlight in the PDF and then paste the text into the mind map.

MarkMindCkm commented 2 years ago

This is pretty exciting. I can't quite figure out how to do it though. I'm not sure how to get view the comments in the markdown file like is shown on the gif in the release notes. Could you document this in English? Thanks!

update pdfjs and markmind

step

  1. use 'annotate-target' link a pdf in a new md file, the pdf has made many highlights by use other software , open to annotator mode
  2. in more options, you can find import pdf highlight menu , click it
  3. use original version pdf to replace highlight pdf , notice keep pdf name is same
grossherr commented 2 years ago

Hello there, this is unfortunately just partly working

View in Okular/PDF-Software

image

View in MarkMind PDF annotator

image

The extracted text is correct but the placement of the highlight isn't.

Also, there are a lot of annotations missing. It might be because they are of the type «underline», but obviously they should be imported too.

Just another example

View in Okular

image

View in MarkMind PDF annotator

image

This time it simply didn't import the highlights from page 1. The highlights on page 2 are located correctly, though.

Thank you for your efforts!

MarkMindCkm commented 2 years ago

Hello there, this is unfortunately just partly working

View in Okular/PDF-Software

image

View in MarkMind PDF annotator

image

The extracted text is correct but the placement of the highlight isn't.

Also, there are a lot of annotations missing. It might be because they are of the type «underline», but obviously they should be imported too.

Just another example

View in Okular

image

View in MarkMind PDF annotator

image

This time it simply didn't import the highlights from page 1. The highlights on page 2 are located correctly, though.

Thank you for your efforts!

Can you give me a pdf demo ?

grossherr commented 2 years ago

Here you go

vickers.pdf

note: it has something to do with the front matter, maybe because of the different page sizes, if I remove them, then the highlights are placed correctly

jcab018.pdf

note: no clue whatsoever why page 1 highlights aren't imported for this file

What to do about the underline highlights? I use them a lot, so being able to import them would be fantastic.