Hello everyone,
I recently modified the bibliography style to include icons for open/closed access.
My aim was to create something similar to what Wikipedia has in their References, since in my opinion, it is a lot nicer if I - as the reader - can see directly whether I can access the resource, or if other means are necessary. This was surprisingly easy to do, so I wanted to share a rough how-to if anyone else is interested. For a general introduction into customizing the Bibliography style, refer to https://texmacs.github.io/notes/docs/create-bibliography-style.html.
In the Bibliography, I added
;; Define the openaccess field and default value
(define (bib-format-openaccess x)
(let* ((oa (bib-field x "openaccess")))
(if (or (bib-null? oa) (equal? oa "false"))
`(image "logos/NoOpenAccess.png" 10pt "" "" "") ;; Image for non-open access
`(image "logos/OpenAccess.png" 10pt "" "" "")))) ;; Image for open access
and for e.g. the article I appended
(tm-define (bib-format-article n x)
(:mode bib-julius-one-num?)
`(concat ,(bib-format-bibitem n x)
,(bib-format-openaccess x) ;; Add openaccess icon
,(bib-label (list-ref x 2))
,(bib-new-block
...
In your project, there needs to be a logos
folder in the root directory, with the following two images:
OpenAccess.png
(both are CC0, and modified by me from here. Feel free to use them as you like.)
In your bibliography, there is a new entry that you need to add to your Resources: openaccess = {true},
(or openaccess = {false},
).
If it is not defined, it will default to the closed access icon.
I hope that this can help someone , feel free to ask questions/give suggestions.