Created
October 15, 2021 18:10
-
-
Save florianpircher/64b1636c232db28d180a58134b480ffd to your computer and use it in GitHub Desktop.
Double Combining Marks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##### Space ##### | |
## Horizontal Classes | |
#@H1 = [$[layer0.width > 0 AND layer0.width <= $classH1Max]]; | |
@H1 = [$[layer0.width > 0 AND layer0.width <= 432]]; | |
#@H3 = [$[layer0.width >= $classH3Min]]; | |
@H3 = [$[layer0.width >= 780]]; | |
## Vertical Classes | |
## | |
## -- 5 (ascender) | |
## -- 4 (upper cap height) | |
## -- 3 (lower cap height) | |
## -- 2 (upper mean line) | |
## -- 1 (lower mean line) | |
## -- 0 (descender) | |
## | |
## (012345) X = occupied, ? = occupied/empty, _ = empty | |
## | |
## (????X) | |
#@V5 = [$[layer0.maxY > $classV4Max]]; | |
@V5 = [$[layer0.maxY > 804]]; | |
## (???X__) | |
#@V3 = [$[layer0.maxY > $classV2Max AND layer0.maxY <= $classV3Max]]; | |
@V3 = [$[layer0.maxY > 564 AND layer0.maxY <= 660]]; | |
## (??X___) | |
#@V2 = [$[layer0.maxY <= $classV2Max AND layer0.maxY > 0]]; | |
@V2 = [$[layer0.maxY <= 564 AND layer0.maxY > 0]]; | |
## (X?????) | |
#@V0 = [$[layer0.minY <= $classV0Max]]; | |
@V0 = [$[layer0.minY <= -60]]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lookup kern_combining_double_mark_vertical_top { | |
lookupflag UseMarkFilteringSet @TopDoubleMark; | |
pos @V5 @TopDoubleMark' <0 $doubleMarkTopV5 0 0>; | |
pos @TopDoubleMark' <0 $doubleMarkTopV5 0 0> @V5; | |
pos @V2 @TopDoubleMark' <0 $doubleMarkTopV3 0 0> @V3; | |
pos @V3 @TopDoubleMark' <0 $doubleMarkTopV3 0 0> @V2; | |
pos @V3 @TopDoubleMark' <0 $doubleMarkTopV3 0 0> @V3; | |
pos @V2 @TopDoubleMark' <0 $doubleMarkTopV2 0 0> @V2; | |
} kern_combining_double_mark_vertical_top; | |
lookup kern_combining_double_mark_vertical_bottom { | |
lookupflag UseMarkFilteringSet @BottomDoubleMark; | |
pos @V0 @BottomDoubleMark' <0 $doubleMarkBottomV0 0 0>; | |
pos @BottomDoubleMark' <0 $doubleMarkBottomV0 0 0> @V0; | |
} kern_combining_double_mark_vertical_bottom; | |
# Separate top and bottom lookups so that cases with top and bottom double marks are also handled. | |
# The horizontal shift is the same for top and bottom marks, thus the feature code is the same and only the mark filtering set differs. | |
lookup kern_combining_double_mark_horizontal_top { | |
lookupflag UseMarkFilteringSet @TopDoubleMark; | |
pos @H1 @DoubleMark' <$doubleMarkShift13 0 0 0> @H3; | |
pos @H3 @DoubleMark' <${doubleMarkShift13*-1} 0 0 0> @H1; | |
ignore pos @H3 @DoubleMark' @H3; | |
pos @DoubleMark' <$doubleMarkShift23 0 0 0> @H3; | |
pos @H3 @DoubleMark' <${doubleMarkShift23*-1} 0 0 0>; | |
ignore pos @H1 @DoubleMark' @H1; | |
pos @H1 @DoubleMark' <$doubleMarkShift12 0 0 0>; | |
pos @DoubleMark' <${doubleMarkShift12*-1} 0 0 0> @H1; | |
} kern_combining_double_mark_horizontal_top; | |
lookup kern_combining_double_mark_horizontal_bottom { | |
lookupflag UseMarkFilteringSet @BottomDoubleMark; | |
pos @H1 @DoubleMark' <$doubleMarkShift13 0 0 0> @H3; | |
pos @H3 @DoubleMark' <${doubleMarkShift13*-1} 0 0 0> @H1; | |
ignore pos @H3 @DoubleMark' @H3; | |
pos @DoubleMark' <$doubleMarkShift23 0 0 0> @H3; | |
pos @H3 @DoubleMark' <${doubleMarkShift23*-1} 0 0 0>; | |
ignore pos @H1 @DoubleMark' @H1; | |
pos @H1 @DoubleMark' <$doubleMarkShift12 0 0 0>; | |
pos @DoubleMark' <${doubleMarkShift12*-1} 0 0 0> @H1; | |
} kern_combining_double_mark_horizontal_bottom; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment