You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Store the current font chain (with quote-delimited font names)
keymanweb.appliedFont=ff;
// Return the style string
returns;
Note that the function accomplishes two separate goals in the same function:
Prepares OSK key font formatting.
This quite clearly belongs here.
This currently does reference baseFont, though there's little reason the OSK can't do an independent, quick check rather than rely on this "semi-global". (In fact, relying on it hurts a goal referenced below - the "own module" bit.)
Prepares CSS font formatting for page inputs for browser-based KMW.
This... should be separate. There's no need for it to be here.
If we're planning to spin the OSK off as its own module (like, for cross-platform keyboard theming), this part should be left out as browser-Web-only.
Note: appliedFont is only used for this purpose. The OSK does not need access to this variable otherwise.
The text was updated successfully, but these errors were encountered:
As of the changes in #7343 and #7360, there are a couple of lingering references to old touch-alias code still found in kmwbase.ts:
keyman/web/source/kmwbase.ts
Lines 53 to 58 in 312b19c
As it stands,
baseFont
andappliedFont
are still in use - most prominently by the following methods:VisualKeyboard.appendStyleSheet()
VisualKeyboard.addFontStyle()
There's also some setup code to prepare
appliedFont
for use there, based on the value assigned during engine init tobaseFont
.For
VisualKeyboard.addFontStyle()
:keyman/web/source/osk/visualKeyboard.ts
Lines 1371 to 1414 in 312b19c
Note that the function accomplishes two separate goals in the same function:
baseFont
, though there's little reason the OSK can't do an independent, quick check rather than rely on this "semi-global". (In fact, relying on it hurts a goal referenced below - the "own module" bit.)appliedFont
is only used for this purpose. The OSK does not need access to this variable otherwise.The text was updated successfully, but these errors were encountered: