fontforge | Free font editor for Windows , Mac OS X and GNU+Linux | User Interface library
kandi X-RAY | fontforge Summary
kandi X-RAY | fontforge Summary
FontForge is a free (libre) font editor for Windows, Mac OS X and GNU+Linux. Use it to create, edit and convert fonts in OpenType, TrueType, UFO, CID-keyed, Multiple Master, and many other formats. designwithfontforge.com — font creation manual.
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
Currently covering the most popular Java, JavaScript and Python libraries. See a Sample of fontforge
fontforge Key Features
fontforge Examples and Code Snippets
RUN apt-get update \
&& apt-get install -y software-properties-common
RUN wget -q -O - https://dl-ssl.google.com/linux/linux_signing_key.pub | apt-key add -
RUN echo "deb [arch=amd64] http://dl.google.com/linux/chrome/deb/ stable
#!/usr/bin/env python
import fontforge as ff
import sys
args = sys.argv[1:]
if args[0] == '--help':
print("changeFontFamily ")
else:
font = args[0]
family = args[1]
newfont = args[2]
f = ff.open( font )
f.family
fontforge -lang=ff -c 'Open($1); SelectWorthOutputting(); foreach Export("svg"); endloop;' font.ttf
Community Discussions
Trending Discussions on fontforge
QUESTION
I'm working on a WOFF2 font using FontForge. All ligatures render correctly in Chrome, except those defined between θ and latin vowels which always appear as separate characters.
The ligatures are defined in the GSUB table with feature 'liga' and scripts "DFLT{dflt} latn{dflt} grek{dflt}". The ligatures render as expected in the Metrics preview in Fontforge, just not when compiled as WOFF2 and used in Chrome.
If I do nothing other than change the character θ to a latin character, the ligatures appear as expected, so my working theory is that the issue is due to the fact that θ is the only character defined by Unicode as being in the Greek range whereas all other ligatures are between characters defined as latin. Can anyone explain this behaviour or offer a solution?
One option is to replace the character θ with a latin character, but this breaks IPA support somewhat so is undesireable, so I would much rather find a method of allowing Chrome to recognise such ligatures (e.g. "θu").
...ANSWER
Answered 2022-Apr-05 at 12:31Having spoken to one of the developers at HarfBuzz, it turns out that this simply can't be done in Chrome because the text from different scripts will be separated into different runs before being passed to HB for rendering and thus such a ligature will never be triggered.
The solution for now will be to use T instead of θ.
QUESTION
In my Fontforge version fontforge 11:21 UTC 24-Sep-2017
under File > Execute script the FF button is disabled. Is it not possible any more to execute native legacy scripts from within FF?
ANSWER
Answered 2021-Mar-17 at 06:10That version is very out of date.
While the legacy scripting language is recommended against, it still works at least as of the 20th Anniversary Release, 20201107, and there's no plan to remove it (I'm one of the maintainers).
QUESTION
I am trying to figure out how the FreeType Library is calculating the FT_GlyphSlotRec_
's advance
variable. According to the comment blocks above this structure, this variable would be the same as the horiAdvance
variable further explained here, which is contained within the FT_Glyph_Metrics_
structure.
In any case, take the typical Arial narrow font as an example. It can be found in C:\Windows\Fonts\ARIALN.TTF. Uploading it to any of the web based TTF file editors (option 1, option 2), or using your own program that can interpret TTF files (fontforge, etc) you can see the Advance for the '!' character is clearly defined as 467.
I am running the following code and when I read FT_GlyphSlotRec_
's advance.x
value, I get a value of 1472. Obviously this is not the same as 467. Am I misinterpreting what this represents? Or am I using the FreeType library incorrectly?
I am retyping the code I used to get 1472 from a computer without internet, so please forgive me for any mundane syntax errors.
...ANSWER
Answered 2021-Feb-28 at 19:34As indicated on that Tutorial, Step 2 page you linked in your question, those metrics are usually reported for a 26.6 pixel format. You are modifying that by the way you're loading in the font. You can use the FT_LOAD_NO_SCALE to "[not] scale the loaded outline glyph but keep it in font units."
Your code generates a bitmap version of the glyph at the size you've requested at a default screen resolution of 72 dpi. The 1472 you're getting is the number of pixels * 64 used to draw the character in your bitmap. So, in this case, 1472 / 64 = 23 pixels, which would be the distance you would advance your draw cursor/pen point if you were drawing multiple characters into the same bitmap.
The 467 is in 1/2048th vector units. To make the conversion with a font_height of 100 pixels, it's: 467/2048 * 100 pixels, which is 22.8 pixels. Round to 23 pixels. Multiply by 64 to get 1472 1/64th pixels.
If you want to see it line up with the pixel value, set your font_height to 2048, then divide the resulting face->glyph->advance.x (29888) by 64, which will give 467.
The following script will give you the values you are looking for:
QUESTION
ANSWER
Answered 2021-Feb-16 at 20:02The output of the NumberFormatter is not U+00A0
, but 0xE2 0x80 0xAf
, or U+202F
- NARROW NO-BREAK SPACE which is most likely not supported by the font.
QUESTION
In the EB-Garamond github repository there's a makefile, which is supposed to generate the Garamond font files. Here are the first lines of the file:
...ANSWER
Answered 2021-Feb-06 at 16:05Simply make sure you have a version of the make
command line utility installed on your system, and then run make
.
QUESTION
I want remove unnecessary symbols from font «SFUI Text Regular». File size 104kb.
- FontForge
Tried use FontForge. Deleted ~50% symbols. Save font. Tried use on the website. Result: the file size has decreased (104kb > 35kb), but the letters are thinner than originally. (i am sure, that this is wasn't system font, it's same font, but thinner)
- Fonttools
Tried use fonttools, pyftsubset command.
...ANSWER
Answered 2021-Jan-29 at 09:15I tried few more programs and services for this.
FontCreator Pro helped decide problem. No specific settings. I just opened it, deleted characters, saved it.
QUESTION
I have a set of images named 32.png,..,126.png
of handwritten letters pertaining to the ASCII printable characters of the number in the filenames, and I intend to convert these into a font file, like .ttf
such that I can type (basic) latex letters with it.
After going through the documentation of project description and documentation of fonttools I have not yet been able to determine how to convert these images into a .ttf
font file in python.
It appears I could convert the .png
images into .svg
format as the fonttools is normally used for font vectors, but I did not find a method that outputs a font file. Hence I wike to ask:
How can I convert a set of images (either .png
or .svg
) into a .ttf
font in python?
- After installing fontforge on windows and adding the
../FontForgeBuilds/bin
folder to path, Anaconda does not recognize thefontforge
module as it throws error:
...
ModuleNotFoundError: No module named 'fontforge'
in a script that converts.svg
files into.ttf
files. The script namedsvgs2ttf
is called with command:python svgs2ttf.py examples/example.json
.
ANSWER
Answered 2020-Dec-11 at 15:36FontForge is not a python module but separate software. Hence, instead of calling FontForge from a python script, one can call python from a fontforge executable. Since I wanted to create the font in .ttf
format from a python script, I wrote an additional python script named execute.py
which executes a cmd
command that executes fontforge that executes the python svgs2ttf
script.
The execute.py
contains:
QUESTION
I have read and used the instruction given here to extract the individual glyphs of a font into separate svg files, but the files' names are not their unicode UTF-8 codes. The number of Glyphs is large and it would be difficult to rename them all by hand accordingly. Is there a way FontForge (or a similar free application online or on linux) can do this?
...ANSWER
Answered 2020-Aug-27 at 04:13Simply write "%u.svg", instead of "svg".
See the documentation here.
QUESTION
Is there a way to add a hidden info-text in FontForge? I think, I could need that sometimes.
I mean something like that:
Hint 1: I generate that text with a external graphic programm, not with FontForge itself; because that's my question how to do that.
Hint 2: The info text should be for own work, not for read out etc.
Hint 3: I mean info-text in the displayed area, not the comment function under 'glyph info'.
...ANSWER
Answered 2020-Aug-09 at 06:48As a FontForge developer, I guess the best way is to make a point with a really long name. A single floating point shouldn't mess anything up, especially if it's inside the bounds of the left and right bearings of the glyph.
So, go to «Point→Name Point». If you want multiline input, copy and paste from e.g. Notepad++.
I noticed that it seems to render multiple lines in the wrong place, which seems to be a minor bug (I'll open a bug for it done: №4420), but you can just move the point up, or use multiple points floating at the right side for multiple lines.
QUESTION
I had to do this basically on my Mac to get the required dependencies wired up locally for my package:
...ANSWER
Answered 2020-Jul-26 at 14:44It seems like you have at least three options (and you do not need docker):
Option 1: Run on Ubuntu and install with brewThe Ubuntu GitHub Runner already has linuxbrew installed (last bullet in the linked document).
You might encounter issues here, since this environment will not be completely compatible with your mac.
Option 2: Run on Ubuntu and install with aptFind the respective apt packages for the ones you currently install with brew, and install them normally with a run
directive.
This is probably the most suitable for you. If you want the CI environment to more closely resemble your personal environment, run on a mac runner instead of an ubuntu runner. These are the supported environments - you will probably want runs-on: macos-latest
. The software installed on the GitHub mac runner is listed here.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install fontforge
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page