Fix broken shape of tailed Cyrillic DJE (U+0452, #803).

This commit is contained in:
be5invis 2021-01-20 22:43:23 -08:00
parent 93bcacaa06
commit 971be9c1ad
5 changed files with 33 additions and 12 deletions

View file

@ -2,4 +2,5 @@
* Add diagonal-tailed variant of `f`, `i`, `j`, `k`, `l`, `q` and `t` (#795).
* Fix broken geometry of `K` and `%` under ultra-wide (#800).
* Add straight-bar AE (`Æ`), follows variant selector for `A` (#800).
* Refine the shape of Slab `S` and `s` to add serifs at both terminals (#800).
* Refine the shape of Slab `S` and `s` to add serifs at both terminals (#800).
* Fix broken shape of tailed Cyrillic DJE (`U+0452`, #803).

View file

@ -54,10 +54,16 @@ glyph-block Common-Derivatives : begin
local glyphDst : create-glyph dstGid dstUnicode : glyph-proc
include : Fn sourceGid null
local derivedGlyphIdMap : new Map
if glyphDst : foreach [gr : items-of : AnyDerivingCv.query glyphSrc] : begin
gr.set glyphDst [gr.amendName dstGid]
create-glyph [gr.amendName dstGid] : glyph-proc
include : Fn [gr.get glyphSrc] gr.tag
local relGidSrc : gr.get glyphSrc
if [derivedGlyphIdMap.get relGidSrc]
: then : gr.set glyphDst : derivedGlyphIdMap.get relGidSrc
: else : begin
local relGidDst : gr.amendName dstGid
create-glyph relGidDst : glyph-proc : include : Fn [gr.get glyphSrc] gr.tag
gr.set glyphDst relGidDst
derivedGlyphIdMap.set relGidSrc relGidDst
define [alias dstGid dstUnicode sourceGid] : begin
if [not dstGid] : throw : new Error "Target ID not specified"

View file

@ -10,6 +10,7 @@ glyph-block Letter-Cyrillic-Dje : begin
glyph-block-import CommonShapes
glyph-block-import Common-Derivatives
glyph-block-import Letter-Shared-Shapes : nShoulder
glyph-block-import Letter-Latin-Lower-H : HBarOverlay
create-glyph 'cyrl/Dje' 0x402 : glyph-proc
include : MarkSet.capital
@ -34,8 +35,6 @@ glyph-block Letter-Cyrillic-Dje : begin
if SLAB : begin
include : LeftwardBottomSerif left 0 SideJut
create-glyph 'cyrl/dje' 0x452 : glyph-proc
include : MarkSet.if
include : refer-glyph 'cyrl/tshe'
eject-contour 'serifRB'
include : VerticalHook (RightSB - HalfStroke * HVContrast) 0 (-Hook * 1.2) Hook
with-related-glyphs 'cyrl/dje' 0x452 'heng' : lambda [src sel] : glyph-proc
include [refer-glyph src] AS_BASE
include : HBarOverlay

View file

@ -96,12 +96,19 @@ glyph-block Letter-Latin-Lower-H : begin
eject-contour 'serifRB'
include : VerticalHook (RightSB - HalfStroke * HVContrast) 0 (-HookX) Hook
create-glyph 'heng' 0xA727 : glyph-proc
create-glyph 'heng.straight' : glyph-proc
include : MarkSet.if
include : refer-glyph "h.straight"
eject-contour 'serifRB'
include : VerticalHook (RightSB - HalfStroke * HVContrast) 0 (-HookX) Hook
create-glyph 'heng.motionSerifedStraight' : glyph-proc
include : MarkSet.if
include : refer-glyph "h.motionSerifedStraight"
eject-contour 'serifRB'
include : VerticalHook (RightSB - HalfStroke * HVContrast) 0 (-HookX) Hook
select-variant 'heng' 0xA727
turned 'turnh' 0x265 'h.straight' Middle (XH / 2) [MarkSet.p]
create-glyph 'hookturnh' 0x2AE : glyph-proc
@ -142,8 +149,8 @@ glyph-block Letter-Latin-Lower-H : begin
if SLAB : begin
include : LeftwardTopSerif (RightSB - Stroke * HVContrast) XH SideJut
with-related-glyphs 'hbar' 0x127 'h' : lambda [src sel] : glyph-proc
include [refer-glyph src] AS_BASE
glyph-block-export HBarOverlay
define [HBarOverlay] : glyph-proc
local barSpaceTop : CAP - [if SLAB Stroke 0]
local s : Math.min OverlayStroke (0.625 * (barSpaceTop - XH))
local xOverlayStart : mix SB 0 0.7
@ -158,6 +165,10 @@ glyph-block Letter-Latin-Lower-H : begin
corner (SB + HalfStroke * HVContrast) yOverlay
corner xOverlayEnd yOverlay
with-related-glyphs 'hbar' 0x127 'h' : lambda [src sel] : glyph-proc
include [refer-glyph src] AS_BASE
include : HBarOverlay
alias 'cyrl/tshe' 0x45B 'hbar'
glyph-block-import Letter-Blackboard : BBS BBD BBBarLeft

View file

@ -632,24 +632,28 @@ rank = 1
description = '`h` with straight ending'
selector.h = 'straight'
selector.hhooktop = 'straight'
selector.heng = 'straight'
[prime.h.variants.tailed]
rank = 2
description = '`h` with curly tailed ending'
selector.h = 'tailed'
selector.hhooktop = 'tailed'
selector.heng = 'straight'
[prime.h.variants.motion-serifed-straight]
rank = 3
description = '`h` with straight ending'
selector.h = 'motionSerifedStraight'
selector.hhooktop = 'straight'
selector.heng = 'motionSerifedStraight'
[prime.h.variants.motion-serifed-tailed]
rank = 4
description = '`h` with curly tailed ending'
selector.h = 'motionSerifedTailed'
selector.hhooktop = 'tailed'
selector.heng = 'motionSerifedStraight'