RyotaUshio / obsidian-pdf-plus

PDF++: The most Obsidian-native PDF annotation, viewing & editing tool ever. Comes with optional Vim keybindings.
https://ryotaushio.github.io/obsidian-pdf-plus/
MIT License
810 stars 15 forks source link

[FR] Icons for custom copy formats #25

Closed N3C2L closed 9 months ago

N3C2L commented 9 months ago

Selecting a text with the marker > right click > add bookmark. When "add bookmark" is clicked from this context menu, it creates a special page link in the annotation file. Maybe this link is then named "Bookmark:" And after this word "Bookmark:" the user can name this bookmark, for example "Bookmark: Chapter 3".

RyotaUshio commented 9 months ago

Can you elaborate on your idea more? Do you want to have an easy way to copy & auto-paste a link that looks like [[file.pdf#page=...&selection=...|Bookmark: ]]?

If so, you can do that by defining your own custom copy format. https://github.com/RyotaUshio/obsidian-pdf-plus?tab=readme-ov-file#highly-customizable-copy-formats

In this case, the format would be something like

[[{{linktext}}|Bookmark: ]]

or if you have the "use [[wikilinks]]" option disabled,

[Bookmark: ]({{linktext}})
N3C2L commented 9 months ago

Thank you, this custom copy format option is very useful. Maybe you want to add "bookmark" as a custom format option in the settings for new users as a default setting when they install PDF++? So new users can use this option for bookmarks. But maybe another bookmark icon could be introduced left of the selected text. Like this icon instead of the text marker color: https://www.flaticon.com/free-icon/bookmark_786352 Maybe in the custom copy format setting new icons could be added for bookmark links or special links in the future for other custom copy formats?

RyotaUshio commented 9 months ago

add "bookmark" as a custom format option in the settings for new users as a default setting when they install PDF++

It seems to me that a custom format with a specific display text like "bookmark" is not a very common use case shared by most users. I'd like to keep the default minimalistic so I'm afraid I will not add this as default. However, providing a list of useful formats on the wiki page of this repository would be helpful.

in the custom copy format setting new icons could be added for bookmark links or special links in the future for other custom copy formats

This would be a wonderful addition that can be considered for a future release. Thanks for the idea!

RyotaUshio commented 9 months ago

Closing this as merged into #33.