Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Can I generate a custom build with substituted cedilla—comma below glyphs? #18

Open
bpj opened this issue Oct 1, 2023 · 1 comment

Comments

@bpj
Copy link

bpj commented Oct 1, 2023

I would like to build a font version which uses the glyph for ‹o̦›1 U+0326 COMBINING COMMA BELOW instead of the regular glyph for ‹o̧› U+0327 COMBINING CEDILLA for precomposed Latin letters with cedilla, primarily so that

  • ‹Ç› U+00C7 LATIN CAPITAL LETTER C WITH CEDILLA
  • ‹ç› U+00E7 LATIN SMALL LETTER C WITH CEDILLA
  • ‹Ş› U+015E LATIN CAPITAL LETTER S WITH CEDILLA
  • ‹ş› U+015F LATIN SMALL LETTER S WITH CEDILLA
  • ‹Ţ› U+0162 LATIN CAPITAL LETTER T WITH CEDILLA
  • ‹ţ› U+0163 LATIN SMALL LETTER T WITH CEDILLA
  • ‹Ḑ› U+1E10 LATIN CAPITAL LETTER D WITH CEDILLA
  • ‹ḑ› U+1E11 LATIN SMALL LETTER D WITH CEDILLA
  • ‹Ḩ› U+1E28 LATIN CAPITAL LETTER H WITH CEDILLA
  • ‹ḩ› U+1E29 LATIN SMALL LETTER H WITH CEDILLA

agree in style with

  • ‹Ģ› U+0122 LATIN CAPITAL LETTER G WITH CEDILLA
  • ‹ģ› U+0123 LATIN SMALL LETTER G WITH CEDILLA
  • ‹Ķ› U+0136 LATIN CAPITAL LETTER K WITH CEDILLA
  • ‹ķ› U+0137 LATIN SMALL LETTER K WITH CEDILLA
  • ‹Ļ› U+013B LATIN CAPITAL LETTER L WITH CEDILLA
  • ‹ļ› U+013C LATIN SMALL LETTER L WITH CEDILLA
  • ‹Ņ› U+0145 LATIN CAPITAL LETTER N WITH CEDILLA
  • ‹ņ› U+0146 LATIN SMALL LETTER N WITH CEDILLA
  • ‹Ŗ› U+0156 LATIN CAPITAL LETTER R WITH CEDILLA
  • ‹ŗ› U+0157 LATIN SMALL LETTER R WITH CEDILLA

I’m essentially hoping/assuming that precomposed glyphs with diacritics are/can be generated programmatically from base letters and combining diacritic glyphs, so that I merely need to replace the one combining glyph with the other and (re)build the precomposed glyphs.

I pretty much must replace U+0327 with U+0326 rather than the other way around because of U+0123 which effectively uses ‹o̒› U+0312 COMBINING TURNED COMMA ABOVE. That is also what will look best in my opinion.

I am aware of the existence of the precomposed

  • ‹Ș› U+0218 LATIN CAPITAL LETTER S WITH COMMA BELOW
  • ‹ș› U+0219 LATIN SMALL LETTER S WITH COMMA BELOW
  • ‹Ț› U+021A LATIN CAPITAL LETTER T WITH COMMA BELOW
  • ‹ț› U+021B LATIN SMALL LETTER T WITH COMMA BELOW

but I want to be able to just type ‹o̧› U+0327 COMBINING CEDILLA in my source2 and then just get the right look in the PDF/rendered HTML whether I apply an NFC normalization or not.

I am also aware that I can use teckit with XeLaTeX but I want to have the possibility to use LuaLaTeX, and above all I only want to change the glyphs, while the encoding should use U+0327, U+00C7 etc., i.e. the substitution should be presentational, not structural.

This is for a fictional language, and I fully understand if you find this too frivolous to waste any time on, but I would appreciate to learn if, and of course preferably also how, I can make a build with these substitutions without using a GUI tool like FontForge; I have cerebral palsy so frankly I’m absolutely hopeless as a GUI user! I suppose substituting the glyph of ‹o̦› U+0326 COMBINING COMMA BELOW for the glyph of ‹o̧› U+0327 COMBINING CEDILLA is trivial; the hard bit is or might be to substitute/(re)build the precomposed glyphs.

Finally I am aware of those other precomposed letters with cedilla:

  • ‹Ȩ› U+0228 LATIN CAPITAL LETTER E WITH CEDILLA
  • ‹ȩ› U+0229 LATIN SMALL LETTER E WITH CEDILLA
  • ‹Ḝ› U+1E1C LATIN CAPITAL LETTER E WITH CEDILLA AND BREVE
  • ‹ḝ› U+1E1D LATIN SMALL LETTER E WITH CEDILLA AND BREVE
  • ‹Ḉ› U+1E08 LATIN CAPITAL LETTER C WITH CEDILLA AND ACUTE
  • ‹ḉ› U+1E09 LATIN SMALL LETTER C WITH CEDILLA AND ACUTE

I don’t care about them at all as I do not need them; I would certainly be OK with substituting the cedilla in them too if that makes it easier to do the overall thing. Strictly speaking I don’t need ‹Ķ› U+0136 LATIN CAPITAL LETTER K WITH CEDILLA and ‹ķ› U+0137 LATIN SMALL LETTER K WITH CEDILLA either, but they already have the glyph I want by default so they are, I suppose, not part of the problem.

Last but not least apologies if this is not the right place to ask. I hope it is since this is, I think, about a customized build and the developers probably are the ones who know the build process best.

Thank you for your patience with this nonsense of mine!

Footnotes

  1. I use ‹o› U+006F LATIN SMALL LETTER O instead of ‹◌› U+25CC DOTTED CIRCLE as it seems like the font GitHub uses lacks a glyph for the latter.

  2. I’m using Vim with custom keymaps — basically ~/.XComppse the (superior) Vim way —, Pandoc with its extended Markdown, and then to PDF with XeLaTeX or LuaLaTeX. Web fonts/HTML are also on the horizon. The beauty of Pandoc is that you can generate both LaTeX and HTML from the same source! In this case I also need a Pandoc filter to inject some raw LaTeX markup for font commands and the like since Pandoc has no builtin provision for applying LaTeX commands to those Pandoc AST elements which become spans and divs when generating HTML.

@jvgaultney
Copy link
Contributor

Hi - The easiest solution for you would be to change your text to use U+0326 COMBINING COMMA BELOW instead of the cedilla. You don't need to use the precomposed combinations in Unicode - the OpenType code in the font will position the comma appropriately. The following are just the normal upper and lower case glyphs followed by U+0326:

image

If you did want the g-comma to place the comma above then you could just use U+0123 for that special combination.

There is another benefit to this: If you use this then your text will be able to be displayed with other fonts in different environments. For example, if you ever want to distribute your text as an ebook this would be important. If you hack the font, or create a custom build, then that font will be always needed - forever - to display your text correctly.

Custom builds are certainly possible, and allowed by the license (OFL), but requires significant setup and technical know-how. We have a website - SIL Font Development Guide - that explains how to modify and build the fonts yourself. We would not be able to create a custom build for you.

Hope that helps, Victor

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants