Feature to alpha-numeric ordinals

paulow's picture

Hi, again, wise-people. I want to know, in your opinion, what is the best open type feature to use with alpha-numeric ordinals (in fact, better say numeric-alphabetic ordinals). See the attached sample. I want to program a open type feature to use with this kind of gliph, where the first character is a arabic number, followed by a abreviation, like "1st", "2nd", "3rd"... But, I have two or three different kinds of each ordinal to program...

AttachmentSize
ordinals.png124.47 KB
Nick Shinn's picture

This works for English:

@ordn1: one.lnum two.lnum three.lnum one two three one.onum two.onum three.onum one.tnum two.tnum three.tnum

@ordn2: zero four five six seven eight nine zero.lnum four.lnum five.lnum six.lnum seven.lnum eight.lnum nine.lnum zero.onum four.onum five.onum six.onum seven.onum eight.onum nine.onum zero.tnum four.tnum five.tnum six.tnum seven.tnum eight.tnum nine.tnum

@ordn3: zero.lnum one.lnum two.lnum three.lnum four.lnum five.lnum six.lnum seven.lnum eight.lnum nine.lnum zero one two three four five six seven eight nine zero.onum one.onum two.onum three.onum four.onum five.onum six.onum seven.onum eight.onum nine.onum zero.tnum one.tnum two.tnum three.tnum four.tnum five.tnum six.tnum seven.tnum eight.tnum nine.tnum

[default = lining, proportional
lnum = lining, tabular
onum = oldstyle, proportional
tnum = oldstyle, tabular
These are my own abbreviations for class code names, probably not the most logical...]

feature ordn { # Ordinals
# Latin
ignore sub [one.lnum one one.onum one.tnum] [one.lnum one one.onum one.tnum] a';
sub @ordn3 a' by ordfeminine;
sub @ordn3 o' by ordmasculine;
sub @ordn3 period a' by ordfeminine;
sub @ordn3 period o' by ordmasculine;
sub [one.lnum one one.onum one.tnum] @ordn1 t' h by t.sups;
sub [one.lnum one one.onum one.tnum] @ordn1 t.sups h' by h.sups;
ignore sub [one.lnum one one.onum one.tnum] [one.lnum one one.onum one.tnum] s' t;
sub [one.lnum one one.onum one.tnum] s' t by s.sups;
sub [one.lnum one one.onum one.tnum] s.sups t' by t.sups;
ignore sub [one.lnum one one.onum one.tnum] [two.lnum two two.onum two.tnum] d';
sub [two.lnum two two.onum two.tnum] d' by d.sups;
ignore sub [one.lnum one one.onum one.tnum] [two.lnum two two.onum two.tnum] n' d;
sub [two.lnum two two.onum two.tnum] n' d by n.sups;
sub [two.lnum two two.onum two.tnum] n.sups d' by d.sups;
ignore sub [one.lnum one one.onum one.tnum] [three.lnum three three.onum three.tnum] d';
sub [three.lnum three three.onum three.tnum] d' by d.sups;
ignore sub [one.lnum one one.onum one.tnum] [three.lnum three three.onum three.tnum] r' d;
sub [three.lnum three three.onum three.tnum] r' d by r.sups;
sub [three.lnum three three.onum three.tnum] r.sups d' by d.sups;
sub @ordn2 t' h by t.sups;
sub @ordn2 t.sups h' by h.sups;
} ordn;

paulow's picture

Thanks, Nick. Taking a look, the programation seems very hard to do! But I will learn and use it, anyway, because I think this kind of resource is very interesting in a good font.

By the way, I appreciate the critics from the coleagues at Typophile about the aesthetic solutions to this font, Penabico. So, I create a new theme in the Calligraphic forum, at http://typophile.com/node/74385 - in the first post I need recomendations about the Thorn

best regards, and thanks, for all

Nick Shinn's picture

Yes, it is long-winded, but you have to do it this way in order to make the feature applicable in a Paragraph Style, and not have every letter made superscript, only those in "1st", "2nd", "3rd" etc., -- and also "11th", "12th", "13th" etc.

The benefit is that each instance of an ordinal doesn't have to be individually selected and styled.

Syndicate content Syndicate content