• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
4

[Ann] A Monoline Text Drawing Script

Community Expert ,
Sep 12, 2010 Sep 12, 2010

Copy link to clipboard

Copied

Spurred into action by an ongoing discussion at Typophile: Technical Q: Monoline fonts, I decided to have a go at writing a Javascript. I'm pretty pleased with the result; perhaps it's of interest for the technical illustration drawers among you!

Enjoy.


Here is a link to the script I wrote for Illustrator CS4 (it might or might not work for any other version): monolinetext.v1.0.zip. It's a Javascript for Illustrator, and you can put it into the regular Illustrator Scripts folder to see it appear in the "Scripts" menu, or somewhere else (and you'd have to browse for it each time).

It shows a little tiny dialog (on which I spend most of the time) where you can enter a size in "points" (relative to the 29 units high Hershey characters) and enter some text. Use Shift+Enter to insert a 'Hard Return', or enter as much text as you want. The text is then drawn out in monoline characters in the center of the screen.

The script is intelligent, in that you can change a previously drawn text by simply selecting it and running the script. Note, however, that stuff like manual scaling and changed attributes (stroke width, color) will be lost. If that's important to you, I might look into it ...

It only supports a small subset of the Hershey Simplex set -- just ASCII, space up to tilde. (And it draws traditional K shapes.)

monolinetext.png

Views

54.2K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe
Community Expert ,
Feb 06, 2019 Feb 06, 2019

Copy link to clipboard

Copied

Hi Maria Teresa,

The line thickness is explicitly set to 0.5pt in the script in two places: line 290 and line 306. Both read now

p.strokeWidth = 0.5;

but you can change that 0.5 to any other value. The spacing between the characters is independent from this -- it's been a while but reading the script, I think the design units are times 29, and so each line segment coordinates need dividing by that number. To change the horizontal spacing only, change the "/29" in line 309 to a lower number, such as "25".

Changing that and the stroke width to 1pt makes the text display thicker and spaced further apart:

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 07, 2019 Feb 07, 2019

Copy link to clipboard

Copied

Hello Jongware,

Thank you for the helpful script.

I need to convert non-Latin languages into monolines. Is it possible to use or modify your script to accommodate Greek, Hebrew, or CJK languages?

Thanks.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Feb 08, 2019 Feb 08, 2019

Copy link to clipboard

Copied

Of course! It would take a lot of work, but-- sure.

The script does nothing special or "magic". It comes down to drawing x sets of lines (where x comes from the definition of each character) and then advance the cursor y units forward. The data for the characters I used come from the well-known Hershey fonts set.

For Greek, all you need to do is find suitable line definitions of characters and then add these to the script. For Hebrew, you also need to make the script recognize runs of Hebrew, so they can be set in RTL. For "CJK languages", again, you only need to find suitable line definitions. (Unless you want to add vertical text as well. But there is nothing in the script that would forbid this -- it's still very much possible.)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 03, 2019 Apr 03, 2019

Copy link to clipboard

Copied

Firstly, thank you so much for this script! It's amazing!

I was wondering; was there a way to adapt this to use a different typeface? Or to apply to a set of outlines? Thank you!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Apr 04, 2019 Apr 04, 2019

Copy link to clipboard

Copied

No, this script does not use a "typeface". The current line font comes courtesy of A.V. Hershey (Hershey fonts - Wikipedia), and that is a limited set. Although there are a few different designs -- serifed, sans, blackletter --, these are constructed by repeatedly drawing in the internal area to mimic a real "fill".

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 16, 2021 Feb 16, 2021

Copy link to clipboard

Copied

I just tried it in Illustrator 2021 and it works fine.

 

THANKS !

 

IMO, there is a great need for this tool, and the hability to use REAL single-line type. Technical illustrators, hobbyists (scrapbooking), art coders working with plotters, etc.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Oct 15, 2021 Oct 15, 2021

Copy link to clipboard

Copied

Hello, 

 

Is it possible to provide a step by step of how to set up and to use this script?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Oct 15, 2021 Oct 15, 2021

Copy link to clipboard

Copied

All the information you need is in the original post. Where are you getting stuck?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Jun 23, 2022 Jun 23, 2022

Copy link to clipboard

Copied

Is this still available? The link seems to be broken.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 23, 2022 Jun 23, 2022

Copy link to clipboard

Copied

Darrius,

 

unfortunately, Jongware passed away some time ago. Obviously, his website has been closed in the meantime.

 

I think (or hope) that today Jongware wouldn't mind to still share the script publicly.

 

I've uploaded it onto another server, so you can download it there:

 

Jongware – Monoline Text Script

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Mar 22, 2023 Mar 22, 2023

Copy link to clipboard

Copied

Thanks. Its working but don't understand which font is this script using.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Mar 22, 2023 Mar 22, 2023

Copy link to clipboard

Copied

LATEST

Naeem,

 

in his initial post Jongware mentioned that it's based on a subset of one of the Hershey fonts.

 

https://en.wikipedia.org/wiki/Hershey_fonts

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines