Grave and acute on the different levels

Get help with FontCreator here. Please do not post feature requests or bug reports here.
Post Reply
Niko
Posts: 14
Joined: Wed Nov 29, 2017 1:11 pm
Location: Russia, Ekaterinburg

Grave and acute on the different levels

Post by Niko » Thu Nov 30, 2017 8:52 pm

Hi, everybody!
I am creating my font and would like to make combining grave and acute accent on the different levels for uppercase and lowercase letters how that is made in the known fonts like “Times New Roman.” For example, if I type some text in MS Word using “Times New Roman” and enter “Alt + 0769” after the necessary letter that it has the acute, then the acute has the different levels depending on a case of the necessary letter.
As I understand, I need to use “OpenType Layout Features” in order to do such a thing, but that is a new thing for me.
I made the following simple script (see below), but it does not work. What am I doing wrong? Could anybody help me?

script cyrl {
feature MarkPositioning2;
}

script latn {
feature MarkPositioning1;
}

class @M2B_B_1 [uni0410 uni0415 uni0418 uni041E uni0423 uni042B uni042D-uni042F uni0430 uni0435 uni0438 uni043E uni0443 uni044B uni044D-uni044F];
class @M2B_B__A [A E I O U Y a e i o u y];

feature MarkPositioning2 mark {
lookup MarkToBase1;
}

feature MarkPositioning1 mark {
lookup MarkToBase2;
}

lookup MarkToBase1 {
anchor Anchor_1;
mark gravecomb -150 740;
pos uni0410 mark 350 760;
pos uni0415 mark 350 760;
pos uni0418 mark 350 760;
pos uni041E mark 350 760;
pos uni0423 mark 350 760;
pos uni042B mark 350 760;
pos uni042D mark 350 760;
pos uni042E mark 350 760;
pos uni042F mark 350 760;
pos uni0430 mark 200 540;
pos uni0435 mark 200 540;
pos uni0438 mark 200 540;
pos uni043E mark 200 540;
pos uni0443 mark 200 540;
pos uni044B mark 200 540;
pos uni044D mark 200 540;
pos uni044E mark 200 540;
pos uni044F mark 200 540;
anchor Anchor_1;
mark acutecomb -150 740;
pos uni0410 mark 350 760;
pos uni0415 mark 350 760;
pos uni0418 mark 350 760;
pos uni041E mark 350 760;
pos uni0423 mark 350 760;
pos uni042B mark 350 760;
pos uni042D mark 350 760;
pos uni042E mark 350 760;
pos uni042F mark 350 760;
pos uni0430 mark 200 540;
pos uni0435 mark 200 540;
pos uni0438 mark 200 540;
pos uni043E mark 200 540;
pos uni0443 mark 200 540;
pos uni044B mark 200 540;
pos uni044D mark 200 540;
pos uni044E mark 200 540;
pos uni044F mark 200 540;
}

lookup MarkToBase2 {
anchor Anchor_2;
mark gravecomb -150 780;
pos A mark 350 800;
pos E mark 350 800;
pos I mark 170 800;
pos O mark 350 800;
pos U mark 350 800;
pos Y mark 350 800;
pos a mark 200 500;
pos e mark 200 500;
pos i mark 120 670;
pos o mark 200 500;
pos u mark 200 500;
pos y mark 200 500;
anchor Anchor_2;
mark acutecomb -150 780;
pos A mark 350 800;
pos E mark 350 800;
pos I mark 170 800;
pos O mark 350 800;
pos U mark 350 800;
pos Y mark 350 800;
pos a mark 200 500;
pos e mark 200 500;
pos i mark 120 670;
pos o mark 200 500;
pos u mark 200 500;
pos y mark 200 500;
}

Bhikkhu Pesala
Top Typographer
Top Typographer
Posts: 7161
Joined: Tue Oct 29, 2002 5:28 am
Location: Seven Kings, London UK
Contact:

Re: Grave and acute on the different levels

Post by Bhikkhu Pesala » Thu Nov 30, 2017 9:29 pm

Why don't you use composites 0192 and 0224?

Àà
My FontsReviews: MainTypeFont CreatorHelpFC11.0 Pro + MT7.0 @ Win10 1709

Niko
Posts: 14
Joined: Wed Nov 29, 2017 1:11 pm
Location: Russia, Ekaterinburg

Re: Grave and acute on the different levels

Post by Niko » Thu Nov 30, 2017 9:43 pm

I am sorry. Maybe I have should placed this topic in “Type Design.” I did not notice before.
Bhikkhu Pesala wrote:
Thu Nov 30, 2017 9:29 pm
Why don't you use composites 0192 and 0224?

Àà
But that is more difficult during creating a font and typing some text in MS Word, and that increases a file size of a font.

Bhikkhu Pesala
Top Typographer
Top Typographer
Posts: 7161
Joined: Tue Oct 29, 2002 5:28 am
Location: Seven Kings, London UK
Contact:

Re: Grave and acute on the different levels

Post by Bhikkhu Pesala » Thu Nov 30, 2017 10:17 pm

Maybe I have should placed this topic in “Type Design.” I did not notice before.
I thought it was better in Support, but Type Design would be ideal if you want to discuss the best way to design fonts. There are many ways to approach the problem
Niko wrote:
Thu Nov 30, 2017 9:43 pm
But that is more difficult during creating a font and typing some text in MS Word, and that increases a file size of a font.
I wonder how those Germans, French, and Polish folk manage to type anything?

Typing combining accents after the base glyph is twice as much work, and the text won't be easily transferable to other fonts. Not all applications support OpenType, but all support composites.

I am sure that it can be done with anchors, but I have no experience of that method. Writing scripts involves more work than the fully automated completed composites feature, but designing a font that is difficult to type with is a complete waste of effort.

I use a customised Windows keyboard that type accented glyphs using dead keys. On the UK keyboard the grave accent ` is a dead key (top left below escape). Type àèìòù or ÀÈÌÒÙ etc., is very easy. Alt key combinations are hard to remember, and take multiple keystrokes to type. Word can also be customised to use shortcuts for inserting accented letters.
My FontsReviews: MainTypeFont CreatorHelpFC11.0 Pro + MT7.0 @ Win10 1709

Niko
Posts: 14
Joined: Wed Nov 29, 2017 1:11 pm
Location: Russia, Ekaterinburg

Re: Grave and acute on the different levels

Post by Niko » Fri Dec 01, 2017 5:22 am

Bhikkhu Pesala, thank you for your replies! I studied “Times New Roman” and found that it did not have the composites with the acute for my Russian Cyrillic letters, but it has some mark and base anchors for that glyphs and has some respective scripts in the OpenType Layout Features. Besides, the shortcuts on the keyboard (Alt + 0769 and 0301 + Alt + X) give the right acute with that letters in MS Word. I even opened and then exported the installed font “Times New Roman” without the Legacy 'kern' Table into the other file with the extension “OTF”. Then I deleted the installed font “Times New Roman” and installed my exported font. As a result, it works properly in MS Word anyway. Therefore, I made sure that FontCreator did everything right, and I did not :) Therefore, I would like to know how to do the acute and the grave accents with the help of anchors…

PJMiller
Top Typographer
Top Typographer
Posts: 568
Joined: Tue Jun 16, 2015 8:12 pm
Location: Sheffield, South Yorkshire
Contact:

Re: Grave and acute on the different levels

Post by PJMiller » Fri Dec 01, 2017 7:06 pm

Times New Roman has many of the composite characters which are in Unicode and it also has anchors which can be used to make up these same combinations and many other combinations.

The composites are used by many word processors and generated by many non-english keyboards.

Composite characters do not increase the size of the font by that much. They are a combination of two existing characters with offsets to position them relative to one another. The data which defines the character is not repeated.

A well designed font will have the composite characters necessary for its intended purpose and anchors for any combinations which are likely to be used.

Don't worry about the size of the font, hard disk sizes are still increasing and memory is still increasing in size. Moores law has slowed down in recent years but storage is still getting bigger. A large font file will not cause problems for most systems.

Hope this helps.

Niko
Posts: 14
Joined: Wed Nov 29, 2017 1:11 pm
Location: Russia, Ekaterinburg

Re: Grave and acute on the different levels

Post by Niko » Fri Dec 01, 2017 10:25 pm

I did it!
For everybody who is interested in it. As it turned out, the Latin subscrypt must contain the MarkToBase Items of all the other Code Pages.
My script should have begun like this:

script cyrl {
feature MarkPositioning2;
}

script latn {
feature MarkPositioning1;
}

class @M2B_B_1 [uni0410 uni0415 uni0418 uni041E uni0423 uni042B uni042D-uni042F uni0430 uni0435 uni0438 uni043E uni0443 uni044B uni044D-uni044F];
class @M2B_B__A [A E I O U Y a e i o u y];

feature MarkPositioning2 mark {
lookup MarkToBase1;
}

feature MarkPositioning1 mark {
lookup MarkToBase1; // This Item was added from the Cyrillic subscript.
lookup MarkToBase2;

}

Now my font works properly!

Post Reply

Who is online

Users browsing this forum: No registered users and 5 guests