Fraction letter positioning ?

Hello,

Please forgive the subject title…I’m not sure how to describe what I’m hoping to achieve with my font.
I’m new to this so I do appreciate your thoughts on the following:

As in the image, essentially, I’d like to type some text (letters and/or numbers), and when a slash symbol is entered, have the remaining text positioned below.

Is there a simple way to do this?
Is there more than one approach, and if so, what would they be?

Many thanks
abc slash.PNG

There is a way to do this, but it is not what I would call simple. I have such a feature in my fonts to create complex fractions from both text and numbers. You can download my Pali Font and open it in FontCreator to inspect the code. It takes too long to explain it all here.

You will need:

  1. Superscript glyphs for A-Z
  2. Subscript glyphs for A-Z
  3. Super/subscript glyphs for any punctuation/symbols you wish to use in fractions, e.g. parentheses, plus, minus, divides, multiply, equal
  4. A fractions feature
  5. Contextual lookups
  6. Optionally, Standard fractions for ¼, ½, ¾ etc.


feature Fractions frac {
  lookup SlashToFraction;
  lookup NumbersToNumerators;
  lookup FractionContext;
  lookup StandardFractions;
}

Thank you for your reply.

I’m afraid your fractions approach is much too complex for my needs.

I tried using cursive attachments for the slash and the letters following it. It seems to work, at least as a web font. But it doesn’t quite work in my application. I’m not quite sure I’ve programmed the cursive script properly but will try experimenting more here.