I have this simple old plugin that is not working with modern versions of GIMP. I absolutely had this working in GIMP 2.x or whatever, but it is not working in GIMP 3.2. When running GIMP from the terminal, it prints out the error messages, and it seems that the issues with this plugin are mostly something to do with the manifest/metadata sort of info at the end of the script.
I have tried reading the documentation about plugins and making small edits to the script to resolve those errors, but I just cannot seem to get it to work. Can anyone help me edit this plugin in a way that makes it work with GIMP 3.2?
Another request is to add to the script to also add guides around the perimeter of the canvas. Which I assume should be simple, just adding something like
(gimp-image-add-vguide img 0)
(gimp-image-add-vguide img 100)
(gimp-image-add-hguide img 0)
(gimp-image-add-hguide img 100)
Original plugin script
;===============================================================
;== GIMP Add Guides Vertically and Horizontally @ 50% ==
;== Copyright (c) 2008 Gregory M. Ross ==
;===============================================================
(define (script-fu-crosshairs img drawable)
(let* ((ImageW (car (gimp-drawable-width drawable)))
(ImageH (car (gimp-drawable-height drawable)))
(Vert_Offset (car (gimp-drawable-offsets drawable)))
(Horz_Offset (cadr (gimp-drawable-offsets drawable)))
(Vert_50 (+ (* ImageW 0.5)Vert_Offset))
(Horz_50 (+ (* ImageH 0.5)Horz_Offset))
)
(gimp-image-undo-group-start img)
(gimp-image-add-vguide img Vert_50)
(gimp-image-add-hguide img Horz_50)
(gimp-image-undo-group-end img)
(gimp-displays-flush)))
(script-fu-register "script-fu-crosshairs"
"<Image>/Image/Guides/Crosshair Guides"
"Add Guides at 50% Horizontal and Vertical"
"Gregory M. Ross"
"Gregory M. Ross"
"March 2008"
""
SF-IMAGE "Image" 0
SF-DRAWABLE "Drawable" 0)



