Feature request: Generate missing glyphs when pasting text

This would be really cool:
If I paste text which contains characters that are not in the font, Glyphs asked me whether to automatically create these glyphs for me, based on the missing Unicodes and the internal glyph name database. Voilà!

Nice idea; I like it.

I think this would get annoying for someone who often pastes in blocks of text that might not all be in a font. Which can happen often when working with complex scripts.

I think this could be a script. :slight_smile:

I’m with @DunwichTypeFounders on this one. You can separate the characters by spaces and paste it in the Generate Glyphs dialog.

You mean, using grep find & replace in a text editor? That seems quite a hassle.

To clarify the background of my request: I recently opened an old proof document in InDesign from a previous project, to re-use it for my new font, which does not have many characters yet. So, there is a small handful of pink (missing) characters in the font and I am looking for a convenient way to add them to my font in Glyphs.

Another problem: The following dialog “Some glyphs were already present in the font” gets so tall that I don’t even see the buttons at the bottom, they are off the screen. If I know that “Ignore Existing” means hitting the space bar then it works but this is not an elegant solution.

By the way, I understand what “Ignore Existing” and “Replace” does, but what is the result of pressing “OK”?

Select it, right click > Services > Unicodes to Glyph Names, done.

Edit: You still need to replace the slashes with spaces. But you can add an Automator service for just that.

Edit 2: Go to Automator, create a new Service, drag a Run AppleScript snippet into the right area, and insert this code into it:

on run {input, parameters}
	return replacetext(replacetext(input as text, "/", " "), "  ", " ")
end run

on replacetext(mytext, searchfor, replacewith)
	set oldDelims to AppleScript's text item delimiters
	set AppleScript's text item delimiters to {searchfor}
	set textlist to text items of mytext
	set AppleScript's text item delimiters to {replacewith}
	set mytext to textlist as text
	set AppleScript's text item delimiters to oldDelims
	return mytext
end replacetext

Then save it as Convert Slashes to Spaces or something like that. Now, you should be able to right click text anywhere and change slashes to spaces.

It doesn’t do anything. You are right, the wording is misleading.
Should be: [Ignore Existing] [Replace Existing] [Cancel]
What do you think?

Thanks for your help, Rainer! I will try the Applescript. Wouldn’t it save one step to make the script simply add spaces between the original Unicode characters? Then I could skip the Unicodes to Glyph Names step.

Sounds good!

Have fixed it.