It is currently Thu Apr 25, 2024 8:21 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 6 posts ] 
Author Message
 Post subject: Label Number(s) From Active Path Points (.py script)
PostPosted: Fri Sep 23, 2016 9:26 pm  (#1) 
Offline
Script Coder
User avatar

Joined: May 07, 2014
Posts: 3975
Location: Canada
Spawned from this post --> mahvin's descriptive post
I just found out that there's an .scm that does something similar.
But I already wrote this .py script so... here it is
Release #1:
Attachment:
label_number_from_path_points.zip [2.29 KiB]
Downloaded 230 times

Release #2: (Dead center numbers and size of numbers varies to fit nicely in circle, see comparison in post #2)
Attachment:
label_number_from_path_points (2).zip [2.53 KiB]
Downloaded 621 times

Available under <Image>/Python-Fu/Label Numbers From Active Path Points
Image

Available Options:
Image

Instructions:
Have an active path defining where you want the number labels to be
Image

Run Script, and you'll get 2 layers to work with (a Fill layer, and a Numbers layer so you can apply extra effects if you'd like).
Image

If you run script with Fill Circles and Write Numbers both turned off, you'll just get circular selections of your points.

I have to admit the .scm is better if you want to move your labels around after creation as each label is created on it's own separate layer. But I think the text fits nicer with .py script especially with double digits labels and if you want apply extra effects on numbers/fill layers you can.

Image

_________________
TinT


Share on Facebook Share on Twitter Share on Orkut Share on Digg Share on MySpace Share on Delicious Share on Technorati
Top
 Post subject: Re: Label Number(s) From Active Path Points (.py script)
PostPosted: Sat Sep 24, 2016 1:42 am  (#2) 
Offline
Script Coder
User avatar

Joined: May 07, 2014
Posts: 3975
Location: Canada
Comparison
Release 1
Image
Release 2 (Dead center numbers and size varies to fit nicely in circles, look at double digits numbers).
Image

_________________
TinT


Top
 Post subject: Re: Label Number(s) From Active Path Points (.py script)
PostPosted: Sat Sep 24, 2016 9:11 am  (#3) 
Offline
Global Moderator
User avatar

Joined: Oct 06, 2010
Posts: 4045
Ofnuts has a script that adds arrowheads to a path, and I use it all the time, except anyone who knows me and Lyle, we like to take the path of least resistance where GIMP is concerned (do something in the least amount of steps). Take a look at my picture here and see if you're shelf is ready for another Golden Wilbur.

Image

_________________
"In order to attain the impossible, one must attempt the absurd."
~ Miguel de Cervantes


Top
 Post subject: Re: Label Number(s) From Active Path Points (.py script)
PostPosted: Sat Sep 24, 2016 12:58 pm  (#4) 
Offline
Script Coder
User avatar

Joined: May 07, 2014
Posts: 3975
Location: Canada
I WANT Golden Wilbur :hehe

Check it here -->Label Arrows From Path Script

_________________
TinT


Top
 Post subject: Re: Label Number(s) From Active Path Points (.py script)
PostPosted: Tue Oct 04, 2016 4:27 am  (#5) 
Offline
GimpChat Member

Joined: Jun 16, 2016
Posts: 137
Hello,
it is possible to have create a separate layer for each number.
Then the script was even more flexible.

Regards Hardy111


Top
 Post subject: Re: Label Number(s) From Active Path Points (.py script)
PostPosted: Thu Mar 29, 2018 8:39 am  (#6) 
Offline
GimpChat Member

Joined: Nov 08, 2016
Posts: 45
label_number_from_path_points (2).zip

I get "An error occurred running python_fu_label_numbers_from_path_points".

RuntimeError: Procedure 'gimp-text-layer-new' has been called with value '(null)' for argument 'fontname' (#3, type gchararray). This value is out of range.

I just created a new image and created 3 points with the Path Tool. I took all the defaults.
Two layers were created, nothing in "Draw Numbers", 1 circle in "Draw Fill".

I realized after awhile, I had not selected a Font and there was no Default :-)

label_number_from_path_points and Label Arrows From Path Script are super helpful scripts. Thank you.

(Gimp 2.8.22)


Top
Post new topic Reply to topic  [ 6 posts ] 

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Attachment(s) Path: reduce the number of nodes while keeping the shape

9

No new posts Attachment(s) De-blurring a number plate

5

No new posts Attachment(s) Points of Interest Work Flow

1

No new posts Attachment(s) | Solved ] Move points on gradients

2

No new posts Convert a selection into an array of coordinates/points

2



* Login  



Powered by phpBB3 © phpBB Group