question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[feaLib] Behavior of using `language` without corresponding `languagesystem`

See original GitHub issue

Copy-paste from a secret project issue tracker:

Me: @moyogo Cosimo says you might know why feaLib doesn’t complain about using language without a languagesystem decl 😮

@moyogo: The Feature Syntax specification isn’t clear about this. It seems to be valid to have a script or language statement that doesn’t have a matching language system declaration present.

The language system statements are to define what applies by default. The script or language statements are to specify what script and language system a feature and lookups belong to.

If a script and language statement doesn’t have a matching language system then it never has the default features and only has the features where it is specifically called. A bit odd but there might be a corner case for it.

For example

language system DFLT dflt;
language system latn CAT;
language system latn ROM;

feature feat {
# Because there is no script or language this applies to all language systems declared above
# DFLT dft, latn CAT, latn ROM but not anything else;
sub one by two;

# This only applies to latn ENG.
script latn;
language ENG;
sub one by three;
} feat;

@anthrotype: what does makeotf do in this case?

Issue Analytics

  • State:open
  • Created 3 years ago
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
khaledhosnycommented, Feb 14, 2021

There is no issue here, languagesystem is some syntactic sugar and does not have to be used at all (makeotf will warn if no languagesystem was used, but it that is nonsense).

From one of my fonts:

languagesystem DFLT dflt;
languagesystem arab dflt;

feature locl {
  script latn;
    sub space by space.latn;
} locl;

...

Adding languagesystem latn dflt; makes no sense as I don’t want any feature under the latn script other than locl.

1reaction
punchcuttercommented, Feb 11, 2021

If you’re using the above code then it’s going to fail because you have language system instead of languagesystem.

Read more comments on GitHub >

github_iconTop Results From Across the Web

The power of language: How words shape people, culture
Even the slightest differences in language use can correspond with biased beliefs of the speakers, according to research.
Read more >
Introduction to OpenType Programming
Inside an OpenType font, rules are arranged into lookups, which are associated with features. Although the language we use to write OpenType code...
Read more >
3.1 Language and Meaning – Communication in the Real World
Our language system is primarily made up of symbols. ... Since the words we use do not have to correspond directly to a...
Read more >
Why language really is not a communication system - Frontiers
While most evolutionary scenarios for language see it as a communication system with consequences on the language-ready brain, ...
Read more >
Language system tags (OpenType 1.9) - Typography
Language System Language System Tag Corresponding ISO 639 IDs or other information Abaza 'ABA ' abq Abkhazian 'ABK ' abk Acholi 'ACH ' ach
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found