It is currently Fri Mar 29, 2024 4:36 am


All times are UTC - 5 hours [ DST ]



Post new topic Reply to topic  [ 44 posts ]  Go to page 1, 2, 3  Next
Author Message
 Post subject: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 20, 2019 1:53 pm  (#1) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
Wikipedia:
"Unicode is an industry standard computer that provides consistent coding, representation and handling of text expressed in most writing systems in the world.
The standard is maintained by the Unicode consortium, and from June 2018. The latest version, Unicode 11.0, contains a repertoire of 137439 characters including 146 modern and historical scripts, as well as many sets of symbols and emoji."


Inspired by Rich2005 in the post on Gimp-Forum.net:
https://www.gimp-forum.net/Thread-Polygonal-designs-and-intersections?pid=12402#pid12402

I tried to write a Python plugin that makes working with GIMP easier.
Because there are many ready-made shapes, we can use those we want (adding your own chosen shapes is not difficult).
In the GIMP menu: Filters -> Path -> Unicode to shape ...
Tested only for Windows, GIMP 2.10.5.
I invite You to test (and concrete changes proposals in the code ...)

Edit 2019-02-27: removed the old version of the plugin.
The current version in the # 12 post.


Attachments:
Plugin Unicode.png
Plugin Unicode.png [ 158.17 KiB | Viewed 12945 times ]
Example.png
Example.png [ 139.72 KiB | Viewed 12945 times ]

_________________
Image

Slava
Ukraini!


Last edited by MareroQ on Wed Feb 27, 2019 12:34 pm, edited 1 time in total.
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: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 20, 2019 2:22 pm  (#2) 
Offline
GimpChat Member
User avatar

Joined: Sep 27, 2016
Posts: 345
Location: Germany, BW
Thank you MareroQ.
Works fine on my Linux Mint 18.3/ GIMP 2.10.8 flatpak.

_________________
Regards
nelo

(Gimp 2.10 on Linux Mint MATE 20.1)


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 20, 2019 2:47 pm  (#3) 
Offline
GimpChat Member
User avatar

Joined: May 10, 2013
Posts: 1389
Location: FInland
That's nice, thanks for the plugin. Tried on 2.10.8 Win7 64, works okay.
Proposals?
How about automatic alignment to center of canvas?
Would be nice also if the list was in alphabetic order.
Or maybe even better if it was ordered alphabetically by the groups, but I guess it's easy to customize and create own list.

This is must:
https://en.wikipedia.org/wiki/Emoji#Unicode_blocks


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 20, 2019 4:24 pm  (#4) 
Offline
Script Coder
User avatar

Joined: Oct 25, 2010
Posts: 4726
Nidhogg wrote:
That's nice, thanks for the plugin. Tried on 2.10.8 Win7 64, works okay.
Proposals?
How about automatic alignment to center of canvas?
Would be nice also if the list was in alphabetic order.
Or maybe even better if it was ordered alphabetically by the groups, but I guess it's easy to customize and create own list.

This is must:
https://en.wikipedia.org/wiki/Emoji#Unicode_blocks


If you have the unicode blocks opened in your browser, you can just copy/paste the character in a Text layer:
Attachment:
Gimp-Emoji.png
Gimp-Emoji.png [ 42.89 KiB | Viewed 12904 times ]


... and then use text-to-path. You can even use them directly in my ofn-text-along-path script (here using the "Repeated" option):

Attachment:
T-A-P-Emojis.png
T-A-P-Emojis.png [ 73.82 KiB | Viewed 12904 times ]

_________________
Image


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 20, 2019 5:09 pm  (#5) 
Offline
GimpChat Member
User avatar

Joined: May 10, 2013
Posts: 1389
Location: FInland
Thanks for the tip Ofnuts, that's nifty. :bigthup


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Thu Feb 21, 2019 3:23 pm  (#6) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
Thank you all for testing.

@Nidhogg
One plugin for one group of characters is probably a good idea. :roll:

For the trial I added only one option - repeating the character in a row (Horizontally) or column (Vertical).
New shapes: Signs of Zodiac.

On the GIMP menu: Filters -> Path -> Unicode to shape -> Signs of Zodiac...

Edit 2019-02-27: removed the old version of the plugin.
The current version in the # 12 post.


Attachments:
Add new option-repeat  shape.jpg
Add new option-repeat shape.jpg [ 97.25 KiB | Viewed 12822 times ]

_________________
Image

Slava
Ukraini!


Last edited by MareroQ on Wed Feb 27, 2019 12:35 pm, edited 1 time in total.
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Feb 22, 2019 9:37 am  (#7) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
In the Unicode to shape V.03 (Final Release :geek ) added options " justification":

- Add "border" x = y (adds a margin from the top +X=0 and side edges +Y=0 of the image),
- Offset x (px),
- Offset y (px),
- Horizontal Spacing ("letter spacing") when repeating the shape,
- Vertical Spacing ("line spacing") when repeating the shape.

New shapes: Planets and I-CHING

On the GIMP menu:
Filters -> Path -> Unicode to shape -> Arrow,Card,Chess,Greek...
Filters -> Path -> Unicode to shape -> Planet and I-CHING..
Filters -> Path -> Unicode to shape -> Signs of Zodiac...

ps. Now a break in learning coding - I need to get to know the basics of Python better...

Edit 2019-02-27: removed the old version of the plugin.
The current version in the # 12 post.


Attachments:
Astrology.png
Astrology.png [ 733.23 KiB | Viewed 12777 times ]

_________________
Image

Slava
Ukraini!


Last edited by MareroQ on Wed Feb 27, 2019 12:37 pm, edited 1 time in total.
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Feb 22, 2019 12:41 pm  (#8) 
Offline
GimpChat Member
User avatar

Joined: May 10, 2013
Posts: 1389
Location: FInland
Thank you for the update. Good way to create some basic shapes and symbols fast without having to load a dingbat.
Especially with a favorites list, which I didn't manage to do yet.
But I stumbled upon a useful program called BabelMap.


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Sun Feb 24, 2019 12:27 pm  (#9) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
Hi Nidhogg.

Thanks for showing BabelMap.
It contains all the information you need - without having to use a web browser.


Attachments:
BabelMap.png
BabelMap.png [ 514.73 KiB | Viewed 12683 times ]

_________________
Image

Slava
Ukraini!
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Mon Feb 25, 2019 7:12 am  (#10) 
Offline
GimpChat Member
User avatar

Joined: Jul 24, 2018
Posts: 85
Location: Porto/ Matosinhos
Excellent Plug-in.. :clap
Can I change or add new shapes?
It is like ?


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Tue Feb 26, 2019 5:23 pm  (#11) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
@Leopardo-40

To add a new shape you need to edit the plugin (you need to know the appropriate symbol record in UNICODE and paste in the right places).
.................................................................................................................
I have a new solution (without editing the plugin code) using BabelMap (Windows only) or text from the selected font (but you need to know which font and keys to use).

Download BabelMap: http://www.babelstone.co.uk/Software/BabelMap.html

The new version (0.4 :hehe ) is ready for trial.
Explanation of use on discharges.

On the GIMP menu:
Filters -> Path -> Unicode to shape -> BabelMap (text) to GIMP ...


Edit 2019-02-27: removed the old version of the plugin.
The current version in the # 12 post.


Attachments:
BabeMap - create shape or text.png
BabeMap - create shape or text.png [ 514.73 KiB | Viewed 6586 times ]
BabelMap to Gimp - two posibility.png
BabelMap to Gimp - two posibility.png [ 784.38 KiB | Viewed 6586 times ]

_________________
Image

Slava
Ukraini!
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Wed Feb 27, 2019 12:43 pm  (#12) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
To the set added:
- script-fu "Symbol Display Rel 0.04" created by Graechan,
- a shortcut to call BabelMap.


Attachments:
Alternative possibilities.png
Alternative possibilities.png [ 748.41 KiB | Viewed 6378 times ]
Unicode_to_shape V 0.4.ZIP [17.73 KiB]
Downloaded 256 times

_________________
Image

Slava
Ukraini!
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Mar 01, 2019 8:21 am  (#13) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
Hey I see you have scrolling ability in your scm files. Is that gimp 2 10 you are using? And if so can you attach the scriptfu.exe file?

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Mar 01, 2019 9:32 am  (#14) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
Hi Rod.

I am currently using GIMP 2.10.5 on a 32 bit system (Windows Vista)..
Still (without any problems) I use the files: gimpfu.py and script-fu.exe made available here:
http://gimpchat.com/viewtopic.php?f=7&t=16090&start=10#p223540

_________________
Image

Slava
Ukraini!


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Mar 01, 2019 1:52 pm  (#15) 
Offline
GimpChat Member

Joined: Mar 04, 2011
Posts: 2414
For Windows 10 64 bit and Gimp 2.10.8 the modified script-fu.exe from viewtopic.php?p=146955#p146955 works.

file size should be 177,152 B

Gimp 2.10.8 now keeps the plugins in folders (political correctness) so move C:\Program Files\GIMP 2\lib\gimp\2.0\plug-ins\script-fu folder somewhere safe and replace with just the single script-fu.exe file.

I tried this a week or so ago in my Win10 VM and for some reason there were permissions issues - not able to move that folder out and had to mess with the security permissions. Just tried again without problems, so just something to look out for.

Working as of a few minutes ago before posting.

Image

_________________
Image


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Mon Mar 04, 2019 6:41 am  (#16) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
rich2005 wrote:
For Windows 10 64 bit and Gimp 2.10.8 the modified script-fu.exe from viewtopic.php?p=146955#p146955 works.

file size should be 177,152 B

Gimp 2.10.8 now keeps the plugins in folders (political correctness) so move C:\Program Files\GIMP 2\lib\gimp\2.0\plug-ins\script-fu folder somewhere safe and replace with just the single script-fu.exe file.

I tried this a week or so ago in my Win10 VM and for some reason there were permissions issues - not able to move that folder out and had to mess with the security permissions. Just tried again without problems, so just something to look out for.

Working as of a few minutes ago before posting.

[ Image ]

Thanks Rich. I'll give this version a try. I believe it's the same one I have already. So I'll move it where you say and try again.

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Thu Mar 07, 2019 10:50 am  (#17) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
Hah! I found that if i create a folder named script-fu and place the new executable in there and move it to my user/rod/appdata/roaming/gimp/gimp-2.10/plug-ins folder it works. Same with ml bevel reflect. You just have to name the folder the exact name as the executable without the exe extension.

Gimp seems to see this new folder/s when you restart. No need to remove anything at all from the programs plugins folder.

Image

Image

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Thu Mar 07, 2019 1:41 pm  (#18) 
Offline
GimpChat Member
User avatar

Joined: Jan 13, 2011
Posts: 2231
Location: Poland
@ Hi Rod.
I am happy about Your success - but which version works?
...........................................................
By the way some new shapes (but unfortunately not all can be displayed graphically in the menu - and I do not know why).


Attachments:
Star & Asterisk.png
Star & Asterisk.png [ 117.84 KiB | Viewed 6237 times ]
Signs differents.png
Signs differents.png [ 87.69 KiB | Viewed 6237 times ]
Add Unicode_to_shape V 0.4.ZIP [5.52 KiB]
Downloaded 223 times

_________________
Image

Slava
Ukraini!
Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Thu Mar 07, 2019 6:41 pm  (#19) 
Offline
GimpChat Member
User avatar

Joined: May 16, 2010
Posts: 14709
Location: USA
MareroQ wrote:
@ Hi Rod.
I am happy about Your success - but which version works?
...........................................................
By the way some new shapes (but unfortunately not all can be displayed graphically in the menu - and I do not know why).

I used the 64 bit version rich posted a link to.

_________________
Image
Edmund Burke nailed it when he said, "The only thing necessary for the triumph of evil is for good men to do nothing."


Top
 Post subject: Re: Plugin UNICODE to shapes and paths.py
PostPosted: Fri Mar 08, 2019 11:55 am  (#20) 
Offline
GimpChat Member
User avatar

Joined: May 10, 2013
Posts: 1389
Location: FInland
:tyspin MareroQ.
I modified the Run BabelMap & BabelMap to Gimp plugins for Linux Gucharmap.

Image


Top
Post new topic Reply to topic  [ 44 posts ]  Go to page 1, 2, 3  Next

All times are UTC - 5 hours [ DST ]


   Similar Topics   Replies 
No new posts Attachment(s) HN: Draw shape - Create paths draw shapes simultaneously and easily

31

No new posts Attachment(s) plugin for paths

24

No new posts Working with unicode filenames

0

No new posts Find and fill paths if closed, convert closed paths to transparent

1

No new posts Is there a 'shapes' tool ?

8



* Login  



Powered by phpBB3 © phpBB Group