-
Notifications
You must be signed in to change notification settings - Fork 29
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
Questions concerning subscripts and superscripts in the PUA #135
Comments
And as always, thanks for a terrific font! |
Hi Anders! Thanks as always. Re (1) The earlier glyphs (UE8...) were added first; then the bigger set was added later as part of my contribution to https://github.com/stevengj/subsuper-proposal/. There's a loose 1:many relationship between the glyph designs and the Unicode points in the final font file: you can have the same glyph appearing in multiple places and in different positions and orientations, with many Unicode values. The PUA is unstructured, but there's probably no good reason to keep changing it... :) Re (2) The Unicode values won't change until there's a better place to put them. If Professor Johnson's proposal ever gets accepted (unlikely), and the Unicode Consortium designate some new permanent locations for them (unlikely), then they will of course move there - but they could be copied there and kept in their old locations as well, that's no extra work. Re (3) Can't rule it out! Although the differences between all these characters in subscript format might be difficult to distinguish at typical "coding" sizes. Re (4) I made a temporary change to access the Variational Selector glyphs locally but disabled it quickly afterwards, because the font shouldn't be breaking Unicode rules when released to users. Also, the Variational Selector mechanism is now being used to access Math script alternatives (#124), which can be in the next release, as soon as it's officially supported by the Glyphs fontmaker. If the official Variational Selector mechanism works well, we can see if a similar mechanism for subscripts can be added without any problems. Of course, should the Unicode Consortium choose the Variational Selectors mechanism to implement Professor Johnson's proposal (unlikely), that would be even better. Until then, some kind of macro or keyboard shortcut mechanism might work. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions! |
Perhaps my wish will not be forgotten whether this issue is closed or not, but as I said I would definitely love some superscripts and subscripts based on the glyphs for the Mathematical Alphanumeric Symbols. As I almost said in my original post (where I included some code points I do not use) from that block I mainly use 1D608–1D638, and those not-latin-looking greek letters that are in the range 1DE62–1D714—I think these best match with how the standard variants of these characters look in this font. |
Hi Anders - I’ll label this as enhancement so it stays open, but don’t know when it will happen. 😀 |
No expectations from my side! I am delighted by the already existing superscripts and subscripts! |
I would like to second interest in this - the orthogonality would work well within the tools I am constructing. I have found https://pypi.org/project/fonttools/ useful and might be able to prototype this in ttf. With permission, I could share an “extension font” (only the original glyphs and the PUA code points with scaled and translated instances to super/sub-script locations) with interested parties. My optimism here is that I was able edit the ttx xml with Emacs and convert back into a ttf font a single glyph that instances super and sub scripted 0s to represent a “byte value 0 hex digit pair”. I haven’t yet automated this nor done any scaling and translation in building a ttf combo glyph, so I can’t commit to a timeline. Let me know if this is of interest… |
Hi Daniel! According to the SIL licence, you don't need permission for anything, so you really can do what you like - the only real restriction is that you can't use the reserved name JuliaMono for any derivatives. "GesselMono" would be fine... :) One comment is that subscript and superscript glyphs are distinctly different glyphs, not transformed versions of others. So the top one here is scaled and moved, the bottom one is redrawn: |
Great! I'll put this somewhere on my todo list. When I'm ready to share, I'll create a repo including the Python scripts. I'll try to honor any recommendations for PUA placement, but the scripts will make it easy to relocate (names too, if you don't appreciate GesselTheGreatsMono as a font name). I do realize the subscripts are "tuned" for their smaller size - aside from tools limiting me to ttf fonts, this is the main reason I only offer to prototype the feature as the design work to do it properly is beyond me. |
As for (3) in my original post, I have toyed around with the idea of making alternative regular versions font, replacing all superscripts and subscripts with their counterparts from the their italic versions. Here is JuliaMono Light mathematical alphanumerics with superscripts from JuliaMono Light Italic (both v. 0.045): |
@anderslundstedt It’d be interesting to know if you could make use of a prototype? Creating a subset ttf font - containing only italic super/sub scripts - is straightforward with the Python fonttools package. If your toolset allows for control of fallback for missing glyphs, you could set the subset font as primary, the real font as fallback. |
My main use of JuliaMono is for typesetting mathematics. So far I have used a simple script doing: plain text → TeX source → PDF. The step from TeX to PDF uses XeLaTeX. I very quickly googled for the possibility of using a fallback font with XeLaTex. It does look possible, but perhaps it is not as straightforward as one would like. Any idea how much more difficult it would be to merge
with
|
I started hacking out a bash script that uses the fonttools Python package. |
Thanks! One small problem for my use case is that the italic glyphs for superscripts ‘a’, ‘g’ and ‘r’ do not match the glyphs from the Mathematical Alphanumerics Block I mainly use when typesetting mathematics. For ‘a’, ‘g’ and ‘r’ I use sans-serif italics─see https://en.wikipedia.org/wiki/Mathematical_Alphanumeric_Symbols ─since I think these best match the style of the rest of the JuliaMono typeface. (For the case of italic superscript r, it does not respect the “alternate r” stylistic set, so that may be considered a bug, probably to be added to #126. But then there are other similar bugs that my use case benefit from, such as that the superscripts of ‘γ’ all look much more like the sens-serif italic γ from the Mathematical Alphanumerics than they look like the regular γ.) In any case, I will have closer look at FontTools and also how fonts work to see if there are some convenient workarounds for my case. |
This issue has been open for 30 days with no activity. |
Looking through the PUA I found, to my great delight, lots of superscripts and subscripts. Some questions regarding these:
(1) Some code points are assigned identical (to my eyes, at least) glyphs. See picture below. What is the point with this?
(2) Is the code-point-to-character mapping for these considered stable? (What I mean is: could a future version of the font move or remove some or all of these subscripts and superscripts?
(3) Any chance of getting more superscripts and subscripts? A killer feature for math typesetting would be superscripts and subscripts for each character of the Mathematical Alphanumeric Symbols block. (When typesetting math, I mainly use the sans-serf italics for latin letters—code points 1D608–1D63B—and the italics for greek letters—code points 1D6E2–1D71B. So for me just those as superscripts and subscripts would be a killer feature.)
(4) In stevengj/subsuper-proposal#7 (comment) you demoed a way to input subscripts and superscripts using variational selectors. That never went into any release, right? If not, would you consider it?
The text was updated successfully, but these errors were encountered: