Default Open Type Features

Supplementary note

As this post has been moved from the thread in which it was posted and used to start a new thread, here is a link to that original thread.

http://forum.high-logic.com:9080/t/open-type-question/3825/1

William

10:52 am British Summer Time 23 May 2013

End of supplementary note


Previously I wrote, in a post timestamped as 20 May 2013 14:30, as follows.

Well, we know now that that was because the Default Template had been used.

I have now found the following web page.

http://www.high-logic.com/fontcreator/otlf/features.xml

There are various lists linked from that page, of which I quote three as those are the lists that produced the results mentioned in the text quoted above.

http://www.high-logic.com/fontcreator/otlf/clig.xml

That explains the following finding.

clig Contextual Ligatures ~N and ~n

http://www.high-logic.com/fontcreator/otlf/dlig.xml

That explains the following finding.

dlig Discretionary Ligatures LA

It also explains my puzzlement at finding LA but not LE.

http://www.high-logic.com/fontcreator/otlf/frac.xml

That does not, as it stands, having studied the font, explain the following finding.

frac Fractions / 1/2 1/4 3/4

However, maybe there is more in the code.

Could High-Logic consider publishing the code of the Default Template please? Or is it, in fact, already available in a file somewhere?

At my present stage of learning about OpenType I can include one type of special feature, for example, liga, yet I do not know how to put two or more types of special feature, for example liga, dlig and rlig, all into one script and in particular if there is a particular order for the various items that is either necessary or desirable.

As rand came up in the Scanahand forum, does FontCreator support rand please?

Is there a list of which features are supported please?

William Overington

23 May 2013

Split to a new topic.

You can find the default otlfd script in the FontCreator 7 installation folder. There, you can see how to combine multiple features in a single script.

I’m not sure how to use the rand

There’s a lot of information in the help file.

Try and see is often the best way to find out if something can be done.

Thank you.

I found a file named default.otlfd that I was able to open using WordPad.

Well, neither do I at present.

I think that I saw somewhere something about a syntax something like the following.

sub p → p, p1, p2, p3, p4

So, if for example, one had five glyphs of letter p then they would be used at random, where random might have a particular meaning.

I used to do some research using random numbers using the Pascal programming language and there was a feature to produce a new random number every time a particular function was called. However, there was also a feature whereby in a program one could, if one so chose, seed the random number generator with a seed number so that the same sequence of random numbers would be used every time that the program was run.

So, for example, one could run a program with one particular seed number value as many times as one wished and then one could change the seed number and run the program with that seed number as many times as one wished.

For example, in case any readers are interested to know why such techniques are used, random numbers used in that way are very useful for simulating heat conduction in irregularly shaped objects.

Returning to typography, the way that the random numbers are chosen could be important so that the document displays the same every time that one looks at it.

However, it is likely that the method of the choosing of the random numbers need not concern a font designer using the rand feature.

However, it would be interesting to know whether the method of the choosing of the random numbers is specified wholly in the font, wholly in an application program, or by the font making suggestions to the application program.

Thank you.

I remember having seen that page before, but I could not remember where to find it.

Indeed.

William

I found the following about the rand feature.

http://forum.fontlab.com/index.php?topic=2567.0

In particular it refers to the calt feature.

http://www.microsoft.com/typography/otspec/features_ae.htm#calt

William

I am wondering if a way to achieve a pseudo-random look using the features that we know are in FontCreator 7 and PagePlus X5 is to use whichever of liga or dlig, or both of them, that the font designer chooses and then to make glyphs that are ligatures in OpenType coding terms yet the glyphs do not actually have a join between the two or more characters in them so that they do not look like ligatures.

For example, there could be a p_a glyph that looks like an unconnected p and an unconnected a, yet in fact the tail of the p has a forward flourish on it that would be unsuitable for the basic letter p of the font because the basic letter p of the font might be needed just in front of a letter y.

William

I have now made a font that has both dlig and liga in one font.

In order to produce the code I opened the High-Logic default.otlfd file in Wordpad and saved a copy with a new name.

I then removed lots of code that seemed relevant only to parts other than the dlig and liga tables.

I then cut down the number of items in the dlig and liga tables and added an s_h glyph instead of an s_p glyph in the dlig table, simply because I had an sh ligature glyph available and I did not have an sp ligature glyph available. I added the d_a glyph to the liga table, so as to have a non-standard ligature in the testing. The idea being to produce some code that was not too long yet long enough to show more than one line for each type of entry.

Here is the code.

script latn { 
    feature DiscretionaryLigatures;
    feature Ligatures;
}

feature DiscretionaryLigatures dlig {
    lookup dligSub;
}  

lookup dligSub {
    sub c t -> c_t;
    sub s h -> s_h;
    sub s t -> s_t;
}

feature Ligatures liga {
    lookup ligaSub;
}

lookup ligaSub {
    sub f f i -> f_f_i;
    sub f f l -> f_f_l;
    sub f f -> f_f;
    sub f i -> fi;
    sub f j -> f_j;
    sub f l -> fl;
    sub d a -> d_a;
    sub longs t -> longs_t;
}

I tested the font in PagePlus X5 and it worked well.

William