@tiqian/engine 0.0.1 → 0.1.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/org/tiqian/clreq/AdjustmentStylePolicy.d.ts +11 -0
- package/dist/org/tiqian/clreq/AdjustmentStylePolicy.js +21 -0
- package/dist/org/tiqian/clreq/AutoSpaceMode.d.ts +16 -0
- package/dist/org/tiqian/clreq/AutoSpaceMode.js +17 -0
- package/dist/org/tiqian/clreq/AutoSpacePolicy.d.ts +13 -0
- package/dist/org/tiqian/clreq/AutoSpacePolicy.js +23 -0
- package/dist/org/tiqian/clreq/BopomofoParser.d.ts +10 -0
- package/dist/org/tiqian/clreq/BopomofoParser.js +46 -0
- package/dist/org/tiqian/clreq/BopomofoReading.d.ts +12 -0
- package/dist/org/tiqian/clreq/BopomofoReading.js +86 -0
- package/dist/org/tiqian/clreq/BopomofoTone.d.ts +28 -0
- package/dist/org/tiqian/clreq/BopomofoTone.js +26 -0
- package/dist/org/tiqian/clreq/CjkPunctuationGlyphPolicy.d.ts +16 -0
- package/dist/org/tiqian/clreq/CjkPunctuationGlyphPolicy.js +17 -0
- package/dist/org/tiqian/clreq/CjkPunctuationGlyphSubstitution.d.ts +8 -0
- package/dist/org/tiqian/clreq/CjkPunctuationGlyphSubstitution.js +25 -0
- package/dist/org/tiqian/clreq/ClreqProfile.d.ts +27 -0
- package/dist/org/tiqian/clreq/ClreqProfile.js +58 -0
- package/dist/org/tiqian/clreq/ClreqProfileResolver.d.ts +10 -0
- package/dist/org/tiqian/clreq/ClreqProfileResolver.js +13 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationAdvancePolicy.d.ts +7 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationAdvancePolicy.js +40 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationGlyphSubstitutor.d.ts +19 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationGlyphSubstitutor.js +93 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationPolicies.d.ts +26 -0
- package/dist/org/tiqian/clreq/ClreqPunctuationPolicies.js +137 -0
- package/dist/org/tiqian/clreq/ClreqRegion.d.ts +20 -0
- package/dist/org/tiqian/clreq/ClreqRegion.js +20 -0
- package/dist/org/tiqian/clreq/ClreqStrictness.d.ts +16 -0
- package/dist/org/tiqian/clreq/ClreqStrictness.js +17 -0
- package/dist/org/tiqian/clreq/GlueSide.d.ts +16 -0
- package/dist/org/tiqian/clreq/GlueSide.js +17 -0
- package/dist/org/tiqian/clreq/HangingPunctuationStyle.d.ts +12 -0
- package/dist/org/tiqian/clreq/HangingPunctuationStyle.js +14 -0
- package/dist/org/tiqian/clreq/InteriorPunctuationStyle.d.ts +12 -0
- package/dist/org/tiqian/clreq/InteriorPunctuationStyle.js +14 -0
- package/dist/org/tiqian/clreq/KinsokuLevel.d.ts +20 -0
- package/dist/org/tiqian/clreq/KinsokuLevel.js +20 -0
- package/dist/org/tiqian/clreq/KinsokuMode.d.ts +14 -0
- package/dist/org/tiqian/clreq/KinsokuMode.js +2 -0
- package/dist/org/tiqian/clreq/KinsokuModes.d.ts +11 -0
- package/dist/org/tiqian/clreq/KinsokuModes.js +71 -0
- package/dist/org/tiqian/clreq/LineAdjustmentStrategy.d.ts +16 -0
- package/dist/org/tiqian/clreq/LineAdjustmentStrategy.js +17 -0
- package/dist/org/tiqian/clreq/LineEndPunctuationStyle.d.ts +12 -0
- package/dist/org/tiqian/clreq/LineEndPunctuationStyle.js +14 -0
- package/dist/org/tiqian/clreq/NumberSymbolCohesion.d.ts +8 -0
- package/dist/org/tiqian/clreq/NumberSymbolCohesion.js +56 -0
- package/dist/org/tiqian/clreq/PunctuationClass.d.ts +44 -0
- package/dist/org/tiqian/clreq/PunctuationClass.js +38 -0
- package/dist/org/tiqian/clreq/PunctuationGluePlacement.d.ts +12 -0
- package/dist/org/tiqian/clreq/PunctuationGluePlacement.js +14 -0
- package/dist/org/tiqian/clreq/PunctuationGluePlacements.d.ts +9 -0
- package/dist/org/tiqian/clreq/PunctuationGluePlacements.js +49 -0
- package/dist/org/tiqian/clreq/PunctuationPolicy.d.ts +10 -0
- package/dist/org/tiqian/clreq/PunctuationPolicy.js +18 -0
- package/dist/org/tiqian/clreq/PunctuationWidthPolicy.d.ts +8 -0
- package/dist/org/tiqian/clreq/PunctuationWidthPolicy.js +16 -0
- package/dist/org/tiqian/clreq/ResolvedKinsoku.d.ts +12 -0
- package/dist/org/tiqian/clreq/ResolvedKinsoku.js +43 -0
- package/dist/org/tiqian/core/AccurateSum.d.ts +3 -0
- package/dist/org/tiqian/core/AccurateSum.js +9 -0
- package/dist/org/tiqian/core/AutoSpaceDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/AutoSpaceDecisionInfo.js +24 -0
- package/dist/org/tiqian/core/BopomofoDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/BopomofoDecisionInfo.js +32 -0
- package/dist/org/tiqian/core/BopomofoGlyphPlacement.d.ts +16 -0
- package/dist/org/tiqian/core/BopomofoGlyphPlacement.js +33 -0
- package/dist/org/tiqian/core/BopomofoGlyphRole.d.ts +16 -0
- package/dist/org/tiqian/core/BopomofoGlyphRole.js +17 -0
- package/dist/org/tiqian/core/BreakOpportunityDecisionInfo.d.ts +11 -0
- package/dist/org/tiqian/core/BreakOpportunityDecisionInfo.js +52 -0
- package/dist/org/tiqian/core/BuiltInLayoutProfiles.d.ts +4 -0
- package/dist/org/tiqian/core/BuiltInLayoutProfiles.js +5 -0
- package/dist/org/tiqian/core/Cluster.d.ts +13 -0
- package/dist/org/tiqian/core/Cluster.js +24 -0
- package/dist/org/tiqian/core/ClusterGeometryDecisionInfo.d.ts +21 -0
- package/dist/org/tiqian/core/ClusterGeometryDecisionInfo.js +40 -0
- package/dist/org/tiqian/core/ColorSpan.d.ts +8 -0
- package/dist/org/tiqian/core/ColorSpan.js +25 -0
- package/dist/org/tiqian/core/ContextualKinsokuDecisionInfo.d.ts +12 -0
- package/dist/org/tiqian/core/ContextualKinsokuDecisionInfo.js +47 -0
- package/dist/org/tiqian/core/DecorationDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/DecorationDecisionInfo.js +24 -0
- package/dist/org/tiqian/core/DecorationKind.d.ts +20 -0
- package/dist/org/tiqian/core/DecorationKind.js +20 -0
- package/dist/org/tiqian/core/DecorationSegmentInfo.d.ts +15 -0
- package/dist/org/tiqian/core/DecorationSegmentInfo.js +28 -0
- package/dist/org/tiqian/core/DecorationSpan.d.ts +10 -0
- package/dist/org/tiqian/core/DecorationSpan.js +36 -0
- package/dist/org/tiqian/core/EastAsianSpacingData.d.ts +4 -0
- package/dist/org/tiqian/core/EastAsianSpacingData.js +399 -0
- package/dist/org/tiqian/core/EastAsianSpacingEdges.d.ts +8 -0
- package/dist/org/tiqian/core/EastAsianSpacingEdges.js +14 -0
- package/dist/org/tiqian/core/EastAsianSpacingValue.d.ts +20 -0
- package/dist/org/tiqian/core/EastAsianSpacingValue.js +20 -0
- package/dist/org/tiqian/core/EmergencyTrackingEligibilityDecisionInfo.d.ts +9 -0
- package/dist/org/tiqian/core/EmergencyTrackingEligibilityDecisionInfo.js +29 -0
- package/dist/org/tiqian/core/FirstLineIndentDecisionInfo.d.ts +8 -0
- package/dist/org/tiqian/core/FirstLineIndentDecisionInfo.js +16 -0
- package/dist/org/tiqian/core/FittedLinePatternGeometry.d.ts +2 -0
- package/dist/org/tiqian/core/FittedLinePatternGeometry.js +84 -0
- package/dist/org/tiqian/core/FontDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/FontDecisionInfo.js +45 -0
- package/dist/org/tiqian/core/Glyph.d.ts +15 -0
- package/dist/org/tiqian/core/Glyph.js +30 -0
- package/dist/org/tiqian/core/GlyphRun.d.ts +11 -0
- package/dist/org/tiqian/core/GlyphRun.js +28 -0
- package/dist/org/tiqian/core/Ic.d.ts +7 -0
- package/dist/org/tiqian/core/Ic.js +17 -0
- package/dist/org/tiqian/core/IllegalStateException.d.ts +4 -0
- package/dist/org/tiqian/core/IllegalStateException.js +8 -0
- package/dist/org/tiqian/core/InlineAttachment.d.ts +12 -0
- package/dist/org/tiqian/core/InlineAttachment.js +14 -0
- package/dist/org/tiqian/core/InlineBoxDecisionInfo.d.ts +12 -0
- package/dist/org/tiqian/core/InlineBoxDecisionInfo.js +22 -0
- package/dist/org/tiqian/core/InlineBoxOuterSpacing.d.ts +12 -0
- package/dist/org/tiqian/core/InlineBoxOuterSpacing.js +14 -0
- package/dist/org/tiqian/core/InlineBoxSpan.d.ts +10 -0
- package/dist/org/tiqian/core/InlineBoxSpan.js +17 -0
- package/dist/org/tiqian/core/InlineObjectBoundaryAdjustment.d.ts +12 -0
- package/dist/org/tiqian/core/InlineObjectBoundaryAdjustment.js +31 -0
- package/dist/org/tiqian/core/InlineObjectDecisionInfo.d.ts +28 -0
- package/dist/org/tiqian/core/InlineObjectDecisionInfo.js +54 -0
- package/dist/org/tiqian/core/InlineObjectLineHeightDecisionInfo.d.ts +16 -0
- package/dist/org/tiqian/core/InlineObjectLineHeightDecisionInfo.js +57 -0
- package/dist/org/tiqian/core/InlineObjectPreferredStretch.d.ts +11 -0
- package/dist/org/tiqian/core/InlineObjectPreferredStretch.js +30 -0
- package/dist/org/tiqian/core/InlineObjectPreferredStretchKind.d.ts +16 -0
- package/dist/org/tiqian/core/InlineObjectPreferredStretchKind.js +17 -0
- package/dist/org/tiqian/core/InlineObjectPunctuationAttachmentDecisionInfo.d.ts +12 -0
- package/dist/org/tiqian/core/InlineObjectPunctuationAttachmentDecisionInfo.js +22 -0
- package/dist/org/tiqian/core/InlineObjectSpan.d.ts +13 -0
- package/dist/org/tiqian/core/InlineObjectSpan.js +22 -0
- package/dist/org/tiqian/core/IntRange.d.ts +12 -0
- package/dist/org/tiqian/core/IntRange.js +30 -0
- package/dist/org/tiqian/core/IntRangeFns.d.ts +2 -0
- package/dist/org/tiqian/core/IntRangeFns.js +4 -0
- package/dist/org/tiqian/core/JustificationAllocationInfo.d.ts +10 -0
- package/dist/org/tiqian/core/JustificationAllocationInfo.js +18 -0
- package/dist/org/tiqian/core/JustificationDecisionInfo.d.ts +10 -0
- package/dist/org/tiqian/core/JustificationDecisionInfo.js +21 -0
- package/dist/org/tiqian/core/KinsokuDecisionInfo.d.ts +8 -0
- package/dist/org/tiqian/core/KinsokuDecisionInfo.js +16 -0
- package/dist/org/tiqian/core/LastLineAlignment.d.ts +16 -0
- package/dist/org/tiqian/core/LastLineAlignment.js +17 -0
- package/dist/org/tiqian/core/LayoutConstraints.d.ts +7 -0
- package/dist/org/tiqian/core/LayoutConstraints.js +24 -0
- package/dist/org/tiqian/core/LayoutDebugInfo.d.ts +70 -0
- package/dist/org/tiqian/core/LayoutDebugInfo.js +205 -0
- package/dist/org/tiqian/core/LayoutInput.d.ts +22 -0
- package/dist/org/tiqian/core/LayoutInput.js +56 -0
- package/dist/org/tiqian/core/LayoutPaintBounds.d.ts +18 -0
- package/dist/org/tiqian/core/LayoutPaintBounds.js +131 -0
- package/dist/org/tiqian/core/LayoutProfileId.d.ts +6 -0
- package/dist/org/tiqian/core/LayoutProfileId.js +17 -0
- package/dist/org/tiqian/core/LayoutQueries.d.ts +121 -0
- package/dist/org/tiqian/core/LayoutQueries.js +1297 -0
- package/dist/org/tiqian/core/LayoutQueryFns.d.ts +27 -0
- package/dist/org/tiqian/core/LayoutQueryFns.js +65 -0
- package/dist/org/tiqian/core/LayoutResult.d.ts +16 -0
- package/dist/org/tiqian/core/LayoutResult.js +36 -0
- package/dist/org/tiqian/core/LayoutResultFns.d.ts +3 -0
- package/dist/org/tiqian/core/LayoutResultFns.js +5 -0
- package/dist/org/tiqian/core/LayoutResultLineFns.d.ts +4 -0
- package/dist/org/tiqian/core/LayoutResultLineFns.js +5 -0
- package/dist/org/tiqian/core/LayoutResultReplayIndex.d.ts +37 -0
- package/dist/org/tiqian/core/LayoutResultReplayIndex.js +379 -0
- package/dist/org/tiqian/core/LineBox.d.ts +23 -0
- package/dist/org/tiqian/core/LineBox.js +43 -0
- package/dist/org/tiqian/core/LineBreakPolicy.d.ts +8 -0
- package/dist/org/tiqian/core/LineBreakPolicy.js +11 -0
- package/dist/org/tiqian/core/LineBreakSpan.d.ts +10 -0
- package/dist/org/tiqian/core/LineBreakSpan.js +30 -0
- package/dist/org/tiqian/core/LineDebugInfo.d.ts +7 -0
- package/dist/org/tiqian/core/LineDebugInfo.js +18 -0
- package/dist/org/tiqian/core/LineDecisionInfo.d.ts +14 -0
- package/dist/org/tiqian/core/LineDecisionInfo.js +32 -0
- package/dist/org/tiqian/core/LineEdgeTrimDecisionInfo.d.ts +12 -0
- package/dist/org/tiqian/core/LineEdgeTrimDecisionInfo.js +22 -0
- package/dist/org/tiqian/core/LineEndReason.d.ts +16 -0
- package/dist/org/tiqian/core/LineEndReason.js +17 -0
- package/dist/org/tiqian/core/LineLengthGrid.d.ts +7 -0
- package/dist/org/tiqian/core/LineLengthGrid.js +12 -0
- package/dist/org/tiqian/core/LineLengthGridDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/LineLengthGridDecisionInfo.js +26 -0
- package/dist/org/tiqian/core/LineRepairAllocationInfo.d.ts +8 -0
- package/dist/org/tiqian/core/LineRepairAllocationInfo.js +14 -0
- package/dist/org/tiqian/core/LineRepairCandidateInfo.d.ts +16 -0
- package/dist/org/tiqian/core/LineRepairCandidateInfo.js +30 -0
- package/dist/org/tiqian/core/LineRepairDecisionInfo.d.ts +15 -0
- package/dist/org/tiqian/core/LineRepairDecisionInfo.js +31 -0
- package/dist/org/tiqian/core/LineSpacingDecisionInfo.d.ts +10 -0
- package/dist/org/tiqian/core/LineSpacingDecisionInfo.js +20 -0
- package/dist/org/tiqian/core/LinkAddressDisplay.d.ts +3 -0
- package/dist/org/tiqian/core/LinkAddressDisplay.js +12 -0
- package/dist/org/tiqian/core/MandatoryBreakDecisionInfo.d.ts +10 -0
- package/dist/org/tiqian/core/MandatoryBreakDecisionInfo.js +33 -0
- package/dist/org/tiqian/core/MaxLinesDecisionInfo.d.ts +8 -0
- package/dist/org/tiqian/core/MaxLinesDecisionInfo.js +25 -0
- package/dist/org/tiqian/core/MeasureAdaptiveFirstLineIndent.d.ts +8 -0
- package/dist/org/tiqian/core/MeasureAdaptiveFirstLineIndent.js +17 -0
- package/dist/org/tiqian/core/MetricDecisionInfo.d.ts +19 -0
- package/dist/org/tiqian/core/MetricDecisionInfo.js +36 -0
- package/dist/org/tiqian/core/ParagraphStyle.d.ts +22 -0
- package/dist/org/tiqian/core/ParagraphStyle.js +36 -0
- package/dist/org/tiqian/core/PositionedCluster.d.ts +22 -0
- package/dist/org/tiqian/core/PositionedCluster.js +52 -0
- package/dist/org/tiqian/core/PunctuationDecisionInfo.d.ts +29 -0
- package/dist/org/tiqian/core/PunctuationDecisionInfo.js +54 -0
- package/dist/org/tiqian/core/Rect.d.ts +12 -0
- package/dist/org/tiqian/core/Rect.js +28 -0
- package/dist/org/tiqian/core/RichTextBackgroundDrawStyle.d.ts +15 -0
- package/dist/org/tiqian/core/RichTextBackgroundDrawStyle.js +25 -0
- package/dist/org/tiqian/core/RichTextBackgroundMetricPolicy.d.ts +16 -0
- package/dist/org/tiqian/core/RichTextBackgroundMetricPolicy.js +17 -0
- package/dist/org/tiqian/core/RichTextBackgroundPaint.d.ts +19 -0
- package/dist/org/tiqian/core/RichTextBackgroundPaint.js +51 -0
- package/dist/org/tiqian/core/RichTextCornerRadii.d.ts +12 -0
- package/dist/org/tiqian/core/RichTextCornerRadii.js +28 -0
- package/dist/org/tiqian/core/RichTextLayoutProjection.d.ts +6 -0
- package/dist/org/tiqian/core/RichTextLayoutProjection.js +62 -0
- package/dist/org/tiqian/core/RichTextLinePattern.d.ts +24 -0
- package/dist/org/tiqian/core/RichTextLinePattern.js +46 -0
- package/dist/org/tiqian/core/RichTextLineSegment.d.ts +25 -0
- package/dist/org/tiqian/core/RichTextLineSegment.js +55 -0
- package/dist/org/tiqian/core/RichTextPaint.d.ts +17 -0
- package/dist/org/tiqian/core/RichTextPaint.js +64 -0
- package/dist/org/tiqian/core/RichTextProjectionFns.d.ts +7 -0
- package/dist/org/tiqian/core/RichTextProjectionFns.js +102 -0
- package/dist/org/tiqian/core/RichTextRole.d.ts +35 -0
- package/dist/org/tiqian/core/RichTextRole.js +57 -0
- package/dist/org/tiqian/core/RichTextSpan.d.ts +11 -0
- package/dist/org/tiqian/core/RichTextSpan.js +34 -0
- package/dist/org/tiqian/core/RoleOverrideInfo.d.ts +12 -0
- package/dist/org/tiqian/core/RoleOverrideInfo.js +41 -0
- package/dist/org/tiqian/core/RubyDecisionInfo.d.ts +20 -0
- package/dist/org/tiqian/core/RubyDecisionInfo.js +46 -0
- package/dist/org/tiqian/core/RubyKind.d.ts +12 -0
- package/dist/org/tiqian/core/RubyKind.js +14 -0
- package/dist/org/tiqian/core/RubyLineHeightDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/RubyLineHeightDecisionInfo.js +36 -0
- package/dist/org/tiqian/core/RubyLineHeightMode.d.ts +12 -0
- package/dist/org/tiqian/core/RubyLineHeightMode.js +14 -0
- package/dist/org/tiqian/core/RubySpan.d.ts +13 -0
- package/dist/org/tiqian/core/RubySpan.js +60 -0
- package/dist/org/tiqian/core/ShapingDecisionInfo.d.ts +21 -0
- package/dist/org/tiqian/core/ShapingDecisionInfo.js +40 -0
- package/dist/org/tiqian/core/Size.d.ts +6 -0
- package/dist/org/tiqian/core/Size.js +12 -0
- package/dist/org/tiqian/core/SourceBoundaryBias.d.ts +16 -0
- package/dist/org/tiqian/core/SourceBoundaryBias.js +17 -0
- package/dist/org/tiqian/core/SourceInteractionBoundaries.d.ts +29 -0
- package/dist/org/tiqian/core/SourceInteractionBoundaries.js +193 -0
- package/dist/org/tiqian/core/SpacingDecisionInfo.d.ts +13 -0
- package/dist/org/tiqian/core/SpacingDecisionInfo.js +24 -0
- package/dist/org/tiqian/core/TextRange.d.ts +11 -0
- package/dist/org/tiqian/core/TextRange.js +40 -0
- package/dist/org/tiqian/core/TextRangeError.d.ts +11 -0
- package/dist/org/tiqian/core/TextRangeError.js +2 -0
- package/dist/org/tiqian/core/TextSpan.d.ts +8 -0
- package/dist/org/tiqian/core/TextSpan.js +12 -0
- package/dist/org/tiqian/core/TextStyle.d.ts +12 -0
- package/dist/org/tiqian/core/TextStyle.js +28 -0
- package/dist/org/tiqian/core/TiqianIllegalArgumentException.d.ts +6 -0
- package/dist/org/tiqian/core/TiqianIllegalArgumentException.js +21 -0
- package/dist/org/tiqian/core/TiqianNoSuchElementException.d.ts +10 -0
- package/dist/org/tiqian/core/TiqianNoSuchElementException.js +16 -0
- package/dist/org/tiqian/core/TiqianTextContent.d.ts +12 -0
- package/dist/org/tiqian/core/TiqianTextContent.js +38 -0
- package/dist/org/tiqian/core/UnicodeCombiningMarkData.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeCombiningMarkData.js +109 -0
- package/dist/org/tiqian/core/UnicodeEastAsianSpacing.d.ts +16 -0
- package/dist/org/tiqian/core/UnicodeEastAsianSpacing.js +88 -0
- package/dist/org/tiqian/core/UnicodeEmojiModifierBaseData.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeEmojiModifierBaseData.js +35 -0
- package/dist/org/tiqian/core/UnicodeExtendedPictographicData.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeExtendedPictographicData.js +64 -0
- package/dist/org/tiqian/core/UnicodeNumber.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeNumber.js +14 -0
- package/dist/org/tiqian/core/UnicodeNumberData.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeNumberData.js +64 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidence.d.ts +16 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidence.js +17 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidenceClassifier.d.ts +7 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidenceClassifier.js +17 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidenceData.d.ts +4 -0
- package/dist/org/tiqian/core/UnicodeScriptEvidenceData.js +295 -0
- package/dist/org/tiqian/core/UnicodeWordCharacter.d.ts +6 -0
- package/dist/org/tiqian/core/UnicodeWordCharacter.js +17 -0
- package/dist/org/tiqian/core/UnicodeWordCharacterData.d.ts +3 -0
- package/dist/org/tiqian/core/UnicodeWordCharacterData.js +234 -0
- package/dist/org/tiqian/core/Units.d.ts +7 -0
- package/dist/org/tiqian/core/Units.js +11 -0
- package/dist/org/tiqian/core/WritingMode.d.ts +12 -0
- package/dist/org/tiqian/core/WritingMode.js +14 -0
- package/dist/org/tiqian/core/ZeroWidthBreakDecisionInfo.d.ts +10 -0
- package/dist/org/tiqian/core/ZeroWidthBreakDecisionInfo.js +33 -0
- package/dist/org/tiqian/font/BaselineClass.d.ts +24 -0
- package/dist/org/tiqian/font/BaselineClass.js +23 -0
- package/dist/org/tiqian/font/BaselinePolicy.d.ts +17 -0
- package/dist/org/tiqian/font/BaselinePolicy.js +18 -0
- package/dist/org/tiqian/font/CjkDashCapabilityPolicy.d.ts +4 -0
- package/dist/org/tiqian/font/CjkDashCapabilityPolicy.js +9 -0
- package/dist/org/tiqian/font/CjkFontRoleClassifier.d.ts +8 -0
- package/dist/org/tiqian/font/CjkFontRoleClassifier.js +43 -0
- package/dist/org/tiqian/font/FontMetricSource.d.ts +24 -0
- package/dist/org/tiqian/font/FontMetricSource.js +23 -0
- package/dist/org/tiqian/font/FontMetrics.d.ts +39 -0
- package/dist/org/tiqian/font/FontMetrics.js +106 -0
- package/dist/org/tiqian/font/FontMetricsPolicy.d.ts +21 -0
- package/dist/org/tiqian/font/FontMetricsPolicy.js +21 -0
- package/dist/org/tiqian/font/FontPolicy.d.ts +36 -0
- package/dist/org/tiqian/font/FontPolicy.js +157 -0
- package/dist/org/tiqian/font/FontRole.d.ts +29 -0
- package/dist/org/tiqian/font/FontRole.js +27 -0
- package/dist/org/tiqian/font/FontRoleContext.d.ts +13 -0
- package/dist/org/tiqian/font/FontRoleContext.js +28 -0
- package/dist/org/tiqian/font/InlineShapingStylePolicy.d.ts +4 -0
- package/dist/org/tiqian/font/InlineShapingStylePolicy.js +18 -0
- package/dist/org/tiqian/font/LayoutFontMetrics.d.ts +18 -0
- package/dist/org/tiqian/font/LayoutFontMetrics.js +29 -0
- package/dist/org/tiqian/font/MetricBox.d.ts +20 -0
- package/dist/org/tiqian/font/MetricBox.js +20 -0
- package/dist/org/tiqian/font/PreferCjkForAmbiguousPunctuationResolver.d.ts +10 -0
- package/dist/org/tiqian/font/PreferCjkForAmbiguousPunctuationResolver.js +30 -0
- package/dist/org/tiqian/font/PunctuationFontPolicy.d.ts +21 -0
- package/dist/org/tiqian/font/PunctuationFontPolicy.js +21 -0
- package/dist/org/tiqian/font/RawFontMetrics.d.ts +11 -0
- package/dist/org/tiqian/font/RawFontMetrics.js +23 -0
- package/dist/org/tiqian/font/UnicodeEmojiData.d.ts +3 -0
- package/dist/org/tiqian/font/UnicodeEmojiData.js +63 -0
- package/dist/org/tiqian/font/UnicodeEmojiPresentationData.d.ts +3 -0
- package/dist/org/tiqian/font/UnicodeEmojiPresentationData.js +46 -0
- package/dist/org/tiqian/font/UnicodeEmojiStyleVariationData.d.ts +3 -0
- package/dist/org/tiqian/font/UnicodeEmojiStyleVariationData.js +71 -0
- package/dist/org/tiqian/font/UnicodeSymbolData.d.ts +3 -0
- package/dist/org/tiqian/font/UnicodeSymbolData.js +88 -0
- package/dist/org/tiqian/layout/AnnotationGeometryStage.d.ts +57 -0
- package/dist/org/tiqian/layout/AnnotationGeometryStage.js +622 -0
- package/dist/org/tiqian/layout/AsciiPointMarkKinsokuTestSupport.d.ts +52 -0
- package/dist/org/tiqian/layout/AsciiPointMarkKinsokuTestSupport.js +209 -0
- package/dist/org/tiqian/layout/ClusterRoleResolution.d.ts +30 -0
- package/dist/org/tiqian/layout/ClusterRoleResolution.js +215 -0
- package/dist/org/tiqian/layout/ContextualDashEllipsisRoleResolver.d.ts +54 -0
- package/dist/org/tiqian/layout/ContextualDashEllipsisRoleResolver.js +326 -0
- package/dist/org/tiqian/layout/ContextualPunctuationDisplaySubstitution.d.ts +6 -0
- package/dist/org/tiqian/layout/ContextualPunctuationDisplaySubstitution.js +8 -0
- package/dist/org/tiqian/layout/ContextualQuoteRoleResolver.d.ts +51 -0
- package/dist/org/tiqian/layout/ContextualQuoteRoleResolver.js +305 -0
- package/dist/org/tiqian/layout/DefaultHyphenator.d.ts +4 -0
- package/dist/org/tiqian/layout/DefaultHyphenator.js +7 -0
- package/dist/org/tiqian/layout/Justifier.d.ts +64 -0
- package/dist/org/tiqian/layout/Justifier.js +474 -0
- package/dist/org/tiqian/layout/KinsokuRule.d.ts +15 -0
- package/dist/org/tiqian/layout/KinsokuRule.js +24 -0
- package/dist/org/tiqian/layout/LayoutDebugAssembly.d.ts +87 -0
- package/dist/org/tiqian/layout/LayoutDebugAssembly.js +371 -0
- package/dist/org/tiqian/layout/LineAdjustmentStage.d.ts +29 -0
- package/dist/org/tiqian/layout/LineAdjustmentStage.js +797 -0
- package/dist/org/tiqian/layout/LineBreakPlanningStage.d.ts +149 -0
- package/dist/org/tiqian/layout/LineBreakPlanningStage.js +769 -0
- package/dist/org/tiqian/layout/LineBreaker.d.ts +54 -0
- package/dist/org/tiqian/layout/LineBreaker.js +457 -0
- package/dist/org/tiqian/layout/LineGeometryStage.d.ts +63 -0
- package/dist/org/tiqian/layout/LineGeometryStage.js +344 -0
- package/dist/org/tiqian/layout/LineOptimization.d.ts +125 -0
- package/dist/org/tiqian/layout/LineOptimization.js +299 -0
- package/dist/org/tiqian/layout/LineRepair.d.ts +30 -0
- package/dist/org/tiqian/layout/LineRepair.js +471 -0
- package/dist/org/tiqian/layout/ParagraphDpLineBreaker.d.ts +80 -0
- package/dist/org/tiqian/layout/ParagraphDpLineBreaker.js +556 -0
- package/dist/org/tiqian/layout/ParagraphDpLineBreakerTestSupport.d.ts +23 -0
- package/dist/org/tiqian/layout/ParagraphDpLineBreakerTestSupport.js +135 -0
- package/dist/org/tiqian/layout/ParagraphLayoutEngine.d.ts +48 -0
- package/dist/org/tiqian/layout/ParagraphLayoutEngine.js +199 -0
- package/dist/org/tiqian/layout/ParagraphShapingStage.d.ts +63 -0
- package/dist/org/tiqian/layout/ParagraphShapingStage.js +1471 -0
- package/dist/org/tiqian/layout/PlanLowering.d.ts +10 -0
- package/dist/org/tiqian/layout/PlanLowering.js +329 -0
- package/dist/org/tiqian/layout/PreparedParagraph.d.ts +32 -0
- package/dist/org/tiqian/layout/PreparedParagraph.js +114 -0
- package/dist/org/tiqian/layout/ProgressiveBreakDecisions.d.ts +86 -0
- package/dist/org/tiqian/layout/ProgressiveBreakDecisions.js +415 -0
- package/dist/org/tiqian/layout/ProgressiveBreakTierPriority.d.ts +5 -0
- package/dist/org/tiqian/layout/ProgressiveBreakTierPriority.js +33 -0
- package/dist/org/tiqian/layout/PunctuationGeometryLedger.d.ts +92 -0
- package/dist/org/tiqian/layout/PunctuationGeometryLedger.js +617 -0
- package/dist/org/tiqian/layout/PunctuationGeometryStage.d.ts +73 -0
- package/dist/org/tiqian/layout/PunctuationGeometryStage.js +631 -0
- package/dist/org/tiqian/layout/PunctuationModel.d.ts +181 -0
- package/dist/org/tiqian/layout/PunctuationModel.js +414 -0
- package/dist/org/tiqian/layout/QuotePairAnalyzer.d.ts +63 -0
- package/dist/org/tiqian/layout/QuotePairAnalyzer.js +251 -0
- package/dist/org/tiqian/layout/UnicodePunctuationBoundaryResolver.d.ts +88 -0
- package/dist/org/tiqian/layout/UnicodePunctuationBoundaryResolver.js +495 -0
- package/dist/org/tiqian/layout/WidthIndependentAnnotationCache.d.ts +102 -0
- package/dist/org/tiqian/layout/WidthIndependentAnnotationCache.js +1207 -0
- package/dist/org/tiqian/linebreak/BreakKind.d.ts +20 -0
- package/dist/org/tiqian/linebreak/BreakKind.js +20 -0
- package/dist/org/tiqian/linebreak/BreakOpportunity.d.ts +19 -0
- package/dist/org/tiqian/linebreak/BreakOpportunity.js +64 -0
- package/dist/org/tiqian/linebreak/EnglishHyphenation.d.ts +5 -0
- package/dist/org/tiqian/linebreak/EnglishHyphenation.js +14 -0
- package/dist/org/tiqian/linebreak/EnglishHyphenationPatterns.d.ts +4 -0
- package/dist/org/tiqian/linebreak/EnglishHyphenationPatterns.js +4294 -0
- package/dist/org/tiqian/linebreak/Hyphenator.d.ts +17 -0
- package/dist/org/tiqian/linebreak/Hyphenator.js +24 -0
- package/dist/org/tiqian/linebreak/LiangHyphenator.d.ts +10 -0
- package/dist/org/tiqian/linebreak/LiangHyphenator.js +67 -0
- package/dist/org/tiqian/linebreak/LineBreakAnalyzer.d.ts +9 -0
- package/dist/org/tiqian/linebreak/LineBreakAnalyzer.js +23 -0
- package/dist/org/tiqian/linebreak/LineBreakFns.d.ts +2 -0
- package/dist/org/tiqian/linebreak/LineBreakFns.js +7 -0
- package/dist/org/tiqian/linebreak/ParseTexHyphenationPatterns.d.ts +7 -0
- package/dist/org/tiqian/linebreak/ParseTexHyphenationPatterns.js +108 -0
- package/dist/org/tiqian/linebreak/ParsedTexHyphenation.d.ts +6 -0
- package/dist/org/tiqian/linebreak/ParsedTexHyphenation.js +9 -0
- package/dist/org/tiqian/linebreak/UnicodePunctuationLineBreak.d.ts +63 -0
- package/dist/org/tiqian/linebreak/UnicodePunctuationLineBreak.js +103 -0
- package/dist/org/tiqian/linebreak/UnicodePunctuationLineBreakData.d.ts +3 -0
- package/dist/org/tiqian/linebreak/UnicodePunctuationLineBreakData.js +164 -0
- package/dist/org/tiqian/protocol/NamedError.d.ts +88 -0
- package/dist/org/tiqian/protocol/NamedError.js +71 -0
- package/dist/org/tiqian/protocol/NamedErrorNames.d.ts +5 -0
- package/dist/org/tiqian/protocol/NamedErrorNames.js +53 -0
- package/dist/org/tiqian/protocol/Plan.d.ts +101 -0
- package/dist/org/tiqian/protocol/Plan.js +10 -0
- package/dist/org/tiqian/protocol/PlanEndReason.d.ts +16 -0
- package/dist/org/tiqian/protocol/PlanEndReason.js +17 -0
- package/dist/org/tiqian/protocol/PlanJson.d.ts +10 -0
- package/dist/org/tiqian/protocol/PlanJson.js +442 -0
- package/dist/org/tiqian/protocol/PlanJsonNumber.d.ts +43 -0
- package/dist/org/tiqian/protocol/PlanJsonNumber.js +362 -0
- package/dist/org/tiqian/protocol/PlanPacked.d.ts +34 -0
- package/dist/org/tiqian/protocol/PlanPacked.js +1166 -0
- package/dist/org/tiqian/protocol/PlanSchema.d.ts +4 -0
- package/dist/org/tiqian/protocol/PlanSchema.js +5 -0
- package/dist/org/tiqian/protocol/PlanStyleDelta.d.ts +5 -0
- package/dist/org/tiqian/protocol/PlanStyleDelta.js +2 -0
- package/dist/org/tiqian/shaping/ReplayableFontBackend.d.ts +48 -0
- package/dist/org/tiqian/shaping/ReplayableFontBackend.js +97 -0
- package/dist/org/tiqian/shaping/TextShaper.d.ts +71 -0
- package/dist/org/tiqian/shaping/TextShaper.js +176 -0
- package/dist/org/tiqian/test/TestHelpers.d.ts +5 -0
- package/dist/org/tiqian/test/TestHelpers.js +27 -0
- package/dist/org/tiqian/test/trace/TestTrace.d.ts +6 -0
- package/dist/org/tiqian/test/trace/TestTrace.js +8 -0
- package/dist/org/tiqian/test/trace/TestTracePlatform.d.ts +6 -0
- package/dist/org/tiqian/test/trace/TestTracePlatform.js +78 -0
- package/dist/org/tiqian/test/trace/TestTraceRecorder.d.ts +9 -0
- package/dist/org/tiqian/test/trace/TestTraceRecorder.js +36 -0
- package/dist/org/tiqian/test/trace/TestTraceRender.d.ts +47 -0
- package/dist/org/tiqian/test/trace/TestTraceRender.js +690 -0
- package/dist/org/tiqian/test/trace/TestTraceStore.d.ts +18 -0
- package/dist/org/tiqian/test/trace/TestTraceStore.js +149 -0
- package/dist/org/tiqian/test/trace/TraceAssertionError.d.ts +5 -0
- package/dist/org/tiqian/test/trace/TraceAssertionError.js +2 -0
- package/dist/org/tiqian/test/trace/TraceAssertionException.d.ts +6 -0
- package/dist/org/tiqian/test/trace/TraceAssertionException.js +16 -0
- package/dist/org/tiqian/test/trace/TraceField.d.ts +5 -0
- package/dist/org/tiqian/test/trace/TraceField.js +10 -0
- package/dist/org/tiqian/test/trace/TraceFormat.d.ts +21 -0
- package/dist/org/tiqian/test/trace/TraceFormat.js +184 -0
- package/dist/org/tiqian/test/trace/TracedAssertions.d.ts +78 -0
- package/dist/org/tiqian/test/trace/TracedAssertions.js +749 -0
- package/dist/runtime.d.ts +96 -0
- package/dist/runtime.js +1612 -0
- package/dist/std/FsError.d.ts +48 -0
- package/dist/std/FsError.js +2 -0
- package/dist/std/FsException.d.ts +6 -0
- package/dist/std/FsException.js +45 -0
- package/dist/std/UStringException.d.ts +6 -0
- package/dist/std/UStringException.js +21 -0
- package/dist/std/UStringFault.d.ts +9 -0
- package/dist/std/UStringFault.js +2 -0
- package/package.json +22 -4
- package/README.md +0 -3
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
export class FontRoleContext {
|
|
3
|
+
locale;
|
|
4
|
+
regionHint;
|
|
5
|
+
constructor(locale = null, regionHint) {
|
|
6
|
+
regionHint = regionHint ?? null;
|
|
7
|
+
this.locale = locale ?? "zh-Hans";
|
|
8
|
+
this.regionHint = regionHint;
|
|
9
|
+
}
|
|
10
|
+
toString() {
|
|
11
|
+
return `FontRoleContext(locale=${this.locale}, regionHint=${this.regionHint})`;
|
|
12
|
+
}
|
|
13
|
+
}
|
|
14
|
+
export function compareFontRoleContext(a, b) {
|
|
15
|
+
if (a === b)
|
|
16
|
+
return 0;
|
|
17
|
+
if (a.locale !== b.locale)
|
|
18
|
+
return a.locale < b.locale ? -1 : 1;
|
|
19
|
+
if (a.regionHint === null && b.regionHint !== null)
|
|
20
|
+
return -1;
|
|
21
|
+
if (a.regionHint !== null && b.regionHint === null)
|
|
22
|
+
return 1;
|
|
23
|
+
if (a.regionHint !== null && b.regionHint !== null) {
|
|
24
|
+
if (a.regionHint !== b.regionHint)
|
|
25
|
+
return a.regionHint < b.regionHint ? -1 : 1;
|
|
26
|
+
}
|
|
27
|
+
return 0;
|
|
28
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
export class InlineShapingStylePolicy {
|
|
3
|
+
static unsupportedInlineShapingProperties = ["font-feature-settings", "font-variation-settings", "font-stretch", "font-kerning", "font-optical-sizing", "font-variant-ligatures", "font-variant-alternates", "font-variant-east-asian", "font-variant-caps", "font-variant-numeric", "font-variant-position", "font-language-override", "font-size-adjust", "word-spacing", "text-transform", "text-rendering"];
|
|
4
|
+
static firstDivergentProperty(elementValues, paragraphValues) {
|
|
5
|
+
let n = (elementValues.length < paragraphValues.length ? elementValues.length : paragraphValues.length);
|
|
6
|
+
if (n > InlineShapingStylePolicy.unsupportedInlineShapingProperties.length) {
|
|
7
|
+
n = InlineShapingStylePolicy.unsupportedInlineShapingProperties.length;
|
|
8
|
+
}
|
|
9
|
+
let i = 0;
|
|
10
|
+
while (i < n) {
|
|
11
|
+
if (elementValues[i] !== paragraphValues[i]) {
|
|
12
|
+
return InlineShapingStylePolicy.unsupportedInlineShapingProperties[i];
|
|
13
|
+
}
|
|
14
|
+
i++;
|
|
15
|
+
}
|
|
16
|
+
return null;
|
|
17
|
+
}
|
|
18
|
+
}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { BaselineClass } from "./BaselineClass.js";
|
|
2
|
+
import { type BaselinePolicy } from "./BaselinePolicy.js";
|
|
3
|
+
import { FontMetricSource } from "./FontMetricSource.js";
|
|
4
|
+
import { type FontMetricsPolicy } from "./FontMetricsPolicy.js";
|
|
5
|
+
import { MetricBox } from "./MetricBox.js";
|
|
6
|
+
export declare class LayoutFontMetrics {
|
|
7
|
+
readonly ascent: number;
|
|
8
|
+
readonly descent: number;
|
|
9
|
+
readonly baselineOffset: number;
|
|
10
|
+
readonly policy: FontMetricsPolicy;
|
|
11
|
+
readonly baselinePolicy: BaselinePolicy;
|
|
12
|
+
readonly baselineClass: BaselineClass;
|
|
13
|
+
readonly metricBox: MetricBox;
|
|
14
|
+
readonly source: FontMetricSource;
|
|
15
|
+
readonly reason: string;
|
|
16
|
+
constructor(ascent: number, descent: number, baselineOffset: number, policy: FontMetricsPolicy, baselinePolicy: BaselinePolicy, baselineClass?: BaselineClass | null, metricBox?: MetricBox | null, source?: FontMetricSource | null, reason?: string | null);
|
|
17
|
+
toString(): string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
import { BaselineClass } from "./BaselineClass.js";
|
|
3
|
+
import { FontMetricSource } from "./FontMetricSource.js";
|
|
4
|
+
import { MetricBox } from "./MetricBox.js";
|
|
5
|
+
export class LayoutFontMetrics {
|
|
6
|
+
ascent;
|
|
7
|
+
descent;
|
|
8
|
+
baselineOffset;
|
|
9
|
+
policy;
|
|
10
|
+
baselinePolicy;
|
|
11
|
+
baselineClass;
|
|
12
|
+
metricBox;
|
|
13
|
+
source;
|
|
14
|
+
reason;
|
|
15
|
+
constructor(ascent, descent, baselineOffset, policy, baselinePolicy, baselineClass = null, metricBox = null, source = null, reason = null) {
|
|
16
|
+
this.ascent = ascent;
|
|
17
|
+
this.descent = descent;
|
|
18
|
+
this.baselineOffset = baselineOffset;
|
|
19
|
+
this.policy = policy;
|
|
20
|
+
this.baselinePolicy = baselinePolicy;
|
|
21
|
+
this.baselineClass = baselineClass ?? BaselineClass.Roman;
|
|
22
|
+
this.metricBox = metricBox ?? MetricBox.RawFontBox;
|
|
23
|
+
this.source = source ?? FontMetricSource.RawTables;
|
|
24
|
+
this.reason = reason ?? "";
|
|
25
|
+
}
|
|
26
|
+
toString() {
|
|
27
|
+
return `LayoutFontMetrics(ascent=${this.ascent}, descent=${this.descent}, baselineOffset=${this.baselineOffset}, policy=${this.policy.kind}, baselinePolicy=${this.baselinePolicy.kind}, baselineClass=${this.baselineClass.kind}, metricBox=${this.metricBox.kind}, source=${this.source.kind}, reason=${this.reason})`;
|
|
28
|
+
}
|
|
29
|
+
}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
export interface RawFontBox {
|
|
2
|
+
readonly kind: "RawFontBox";
|
|
3
|
+
}
|
|
4
|
+
export interface IdeographicEmBox {
|
|
5
|
+
readonly kind: "IdeographicEmBox";
|
|
6
|
+
}
|
|
7
|
+
export interface IdeographicCharacterFace {
|
|
8
|
+
readonly kind: "IdeographicCharacterFace";
|
|
9
|
+
}
|
|
10
|
+
export interface SampledInkBox {
|
|
11
|
+
readonly kind: "SampledInkBox";
|
|
12
|
+
}
|
|
13
|
+
export type MetricBox = RawFontBox | IdeographicEmBox | IdeographicCharacterFace | SampledInkBox;
|
|
14
|
+
export declare const MetricBox: Readonly<{
|
|
15
|
+
RawFontBox: Readonly<RawFontBox>;
|
|
16
|
+
IdeographicEmBox: Readonly<IdeographicEmBox>;
|
|
17
|
+
IdeographicCharacterFace: Readonly<IdeographicCharacterFace>;
|
|
18
|
+
SampledInkBox: Readonly<SampledInkBox>;
|
|
19
|
+
}>;
|
|
20
|
+
export declare function compareMetricBox(a: MetricBox, b: MetricBox): number;
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
export const MetricBox = Object.freeze({
|
|
3
|
+
RawFontBox: Object.freeze({ kind: "RawFontBox" }),
|
|
4
|
+
IdeographicEmBox: Object.freeze({ kind: "IdeographicEmBox" }),
|
|
5
|
+
IdeographicCharacterFace: Object.freeze({ kind: "IdeographicCharacterFace" }),
|
|
6
|
+
SampledInkBox: Object.freeze({ kind: "SampledInkBox" })
|
|
7
|
+
});
|
|
8
|
+
export function compareMetricBox(a, b) {
|
|
9
|
+
if (a === b)
|
|
10
|
+
return 0;
|
|
11
|
+
if (a.kind === "RawFontBox")
|
|
12
|
+
return 0 - (b.kind === "RawFontBox" ? 0 : 0);
|
|
13
|
+
if (a.kind === "IdeographicEmBox")
|
|
14
|
+
return 1 - (b.kind === "IdeographicEmBox" ? 1 : 0);
|
|
15
|
+
if (a.kind === "IdeographicCharacterFace")
|
|
16
|
+
return 2 - (b.kind === "IdeographicCharacterFace" ? 2 : 0);
|
|
17
|
+
if (a.kind === "SampledInkBox")
|
|
18
|
+
return 3 - (b.kind === "SampledInkBox" ? 3 : 0);
|
|
19
|
+
return 0;
|
|
20
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type TextRange } from "./../core/TextRange.js";
|
|
2
|
+
import { type FallbackResolver, FontDecision, type FontRequest } from "./FontPolicy.js";
|
|
3
|
+
export declare class PreferCjkForAmbiguousPunctuationResolver implements FallbackResolver {
|
|
4
|
+
private readonly cjkFontKey;
|
|
5
|
+
private readonly latinFontKey;
|
|
6
|
+
private readonly symbolFontKey;
|
|
7
|
+
constructor(cjkFontKey?: string | null, latinFontKey?: string | null, symbolFontKey?: string | null);
|
|
8
|
+
resolve(_text: string, range: TextRange, request: FontRequest): FontDecision;
|
|
9
|
+
private static candidateFor;
|
|
10
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
import { FontCandidate, FontDecision } from "./FontPolicy.js";
|
|
3
|
+
export class PreferCjkForAmbiguousPunctuationResolver {
|
|
4
|
+
cjkFontKey;
|
|
5
|
+
latinFontKey;
|
|
6
|
+
symbolFontKey;
|
|
7
|
+
constructor(cjkFontKey = null, latinFontKey = null, symbolFontKey = null) {
|
|
8
|
+
this.cjkFontKey = cjkFontKey ?? "cjk-primary";
|
|
9
|
+
this.latinFontKey = latinFontKey ?? "latin-primary";
|
|
10
|
+
this.symbolFontKey = symbolFontKey ?? "symbol-fallback";
|
|
11
|
+
}
|
|
12
|
+
resolve(_text, range, request) {
|
|
13
|
+
const c = PreferCjkForAmbiguousPunctuationResolver.candidateFor(request, this.cjkFontKey, this.latinFontKey, this.symbolFontKey);
|
|
14
|
+
return new FontDecision(range, c, request.role, `PreferCjkForAmbiguousPunctuationResolver:${request.role.kind}`);
|
|
15
|
+
}
|
|
16
|
+
static candidateFor(request, cjkFontKey, latinFontKey, symbolFontKey) {
|
|
17
|
+
const role = request.role;
|
|
18
|
+
switch (role.kind) {
|
|
19
|
+
case "CjkText":
|
|
20
|
+
case "CjkPunctuation":
|
|
21
|
+
return new FontCandidate(cjkFontKey, (request.preferredFamilies.length === 0 ? cjkFontKey : request.preferredFamilies[0]), request.role);
|
|
22
|
+
case "LatinText":
|
|
23
|
+
return new FontCandidate(latinFontKey, latinFontKey, request.role);
|
|
24
|
+
case "Symbol":
|
|
25
|
+
case "Emoji":
|
|
26
|
+
case "Unknown":
|
|
27
|
+
return new FontCandidate(symbolFontKey, symbolFontKey, request.role);
|
|
28
|
+
}
|
|
29
|
+
}
|
|
30
|
+
}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
export interface PreferCjkForAmbiguousPunctuation {
|
|
2
|
+
readonly kind: "PreferCjkForAmbiguousPunctuation";
|
|
3
|
+
}
|
|
4
|
+
export interface PreferLatinForAscii {
|
|
5
|
+
readonly kind: "PreferLatinForAscii";
|
|
6
|
+
}
|
|
7
|
+
export interface PreserveRunFont {
|
|
8
|
+
readonly kind: "PreserveRunFont";
|
|
9
|
+
}
|
|
10
|
+
export interface CustomMap {
|
|
11
|
+
readonly kind: "CustomMap";
|
|
12
|
+
}
|
|
13
|
+
export type PunctuationFontPolicy = PreferCjkForAmbiguousPunctuation | PreferLatinForAscii | PreserveRunFont | CustomMap;
|
|
14
|
+
export declare const PunctuationFontPolicy: Readonly<{
|
|
15
|
+
PreferCjkForAmbiguousPunctuation: Readonly<PreferCjkForAmbiguousPunctuation>;
|
|
16
|
+
PreferLatinForAscii: Readonly<PreferLatinForAscii>;
|
|
17
|
+
PreserveRunFont: Readonly<PreserveRunFont>;
|
|
18
|
+
CustomMap: Readonly<CustomMap>;
|
|
19
|
+
}>;
|
|
20
|
+
export declare function comparePunctuationFontPolicy(a: PunctuationFontPolicy, b: PunctuationFontPolicy): number;
|
|
21
|
+
export declare const PUNCTUATION_FONT_POLICY_ALL: readonly (Readonly<PreferCjkForAmbiguousPunctuation> | Readonly<PreferLatinForAscii> | Readonly<PreserveRunFont> | Readonly<CustomMap>)[];
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
export const PunctuationFontPolicy = Object.freeze({
|
|
3
|
+
PreferCjkForAmbiguousPunctuation: Object.freeze({ kind: "PreferCjkForAmbiguousPunctuation" }),
|
|
4
|
+
PreferLatinForAscii: Object.freeze({ kind: "PreferLatinForAscii" }),
|
|
5
|
+
PreserveRunFont: Object.freeze({ kind: "PreserveRunFont" }),
|
|
6
|
+
CustomMap: Object.freeze({ kind: "CustomMap" })
|
|
7
|
+
});
|
|
8
|
+
export function comparePunctuationFontPolicy(a, b) {
|
|
9
|
+
if (a === b)
|
|
10
|
+
return 0;
|
|
11
|
+
if (a.kind === "PreferCjkForAmbiguousPunctuation")
|
|
12
|
+
return 0 - (b.kind === "PreferCjkForAmbiguousPunctuation" ? 0 : 0);
|
|
13
|
+
if (a.kind === "PreferLatinForAscii")
|
|
14
|
+
return 1 - (b.kind === "PreferLatinForAscii" ? 1 : 0);
|
|
15
|
+
if (a.kind === "PreserveRunFont")
|
|
16
|
+
return 2 - (b.kind === "PreserveRunFont" ? 2 : 0);
|
|
17
|
+
if (a.kind === "CustomMap")
|
|
18
|
+
return 3 - (b.kind === "CustomMap" ? 3 : 0);
|
|
19
|
+
return 0;
|
|
20
|
+
}
|
|
21
|
+
export const PUNCTUATION_FONT_POLICY_ALL = Object.freeze([PunctuationFontPolicy.PreferCjkForAmbiguousPunctuation, PunctuationFontPolicy.PreferLatinForAscii, PunctuationFontPolicy.PreserveRunFont, PunctuationFontPolicy.CustomMap]);
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { FontMetricSource } from "./FontMetricSource.js";
|
|
2
|
+
export declare class RawFontMetrics {
|
|
3
|
+
readonly ascent: number;
|
|
4
|
+
readonly descent: number;
|
|
5
|
+
readonly leading: number;
|
|
6
|
+
readonly source: FontMetricSource;
|
|
7
|
+
readonly typoAscent: number | null;
|
|
8
|
+
readonly typoDescent: number | null;
|
|
9
|
+
constructor(ascent: number, descent: number, leading?: number | null, source?: FontMetricSource | null, typoAscent?: number | null, typoDescent?: number | null);
|
|
10
|
+
toString(): string;
|
|
11
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
import { FontMetricSource } from "./FontMetricSource.js";
|
|
3
|
+
export class RawFontMetrics {
|
|
4
|
+
ascent;
|
|
5
|
+
descent;
|
|
6
|
+
leading;
|
|
7
|
+
source;
|
|
8
|
+
typoAscent;
|
|
9
|
+
typoDescent;
|
|
10
|
+
constructor(ascent, descent, leading = null, source = null, typoAscent, typoDescent) {
|
|
11
|
+
typoAscent = typoAscent ?? null;
|
|
12
|
+
typoDescent = typoDescent ?? null;
|
|
13
|
+
this.ascent = ascent;
|
|
14
|
+
this.descent = descent;
|
|
15
|
+
this.leading = leading ?? 0;
|
|
16
|
+
this.source = source ?? FontMetricSource.RawTables;
|
|
17
|
+
this.typoAscent = typoAscent;
|
|
18
|
+
this.typoDescent = typoDescent;
|
|
19
|
+
}
|
|
20
|
+
toString() {
|
|
21
|
+
return `RawFontMetrics(ascent=${this.ascent}, descent=${this.descent}, leading=${this.leading}, source=${this.source.kind}, typoAscent=${this.typoAscent}, typoDescent=${this.typoDescent})`;
|
|
22
|
+
}
|
|
23
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
const RANGES = new Int32Array([
|
|
3
|
+
0x23, 0x23, 0x2a, 0x2a, 0x30, 0x39, 0xa9, 0xa9,
|
|
4
|
+
0xae, 0xae, 0x203c, 0x203c, 0x2049, 0x2049, 0x2122, 0x2122,
|
|
5
|
+
0x2139, 0x2139, 0x2194, 0x2199, 0x21a9, 0x21aa, 0x231a, 0x231b,
|
|
6
|
+
0x2328, 0x2328, 0x23cf, 0x23cf, 0x23e9, 0x23f3, 0x23f8, 0x23fa,
|
|
7
|
+
0x24c2, 0x24c2, 0x25aa, 0x25ab, 0x25b6, 0x25b6, 0x25c0, 0x25c0,
|
|
8
|
+
0x25fb, 0x25fe, 0x2600, 0x2604, 0x260e, 0x260e, 0x2611, 0x2611,
|
|
9
|
+
0x2614, 0x2615, 0x2618, 0x2618, 0x261d, 0x261d, 0x2620, 0x2620,
|
|
10
|
+
0x2622, 0x2623, 0x2626, 0x2626, 0x262a, 0x262a, 0x262e, 0x262f,
|
|
11
|
+
0x2638, 0x263a, 0x2640, 0x2640, 0x2642, 0x2642, 0x2648, 0x2653,
|
|
12
|
+
0x265f, 0x2660, 0x2663, 0x2663, 0x2665, 0x2666, 0x2668, 0x2668,
|
|
13
|
+
0x267b, 0x267b, 0x267e, 0x267f, 0x2692, 0x2697, 0x2699, 0x2699,
|
|
14
|
+
0x269b, 0x269c, 0x26a0, 0x26a1, 0x26a7, 0x26a7, 0x26aa, 0x26ab,
|
|
15
|
+
0x26b0, 0x26b1, 0x26bd, 0x26be, 0x26c4, 0x26c5, 0x26c8, 0x26c8,
|
|
16
|
+
0x26ce, 0x26cf, 0x26d1, 0x26d1, 0x26d3, 0x26d4, 0x26e9, 0x26ea,
|
|
17
|
+
0x26f0, 0x26f5, 0x26f7, 0x26fa, 0x26fd, 0x26fd, 0x2702, 0x2702,
|
|
18
|
+
0x2705, 0x2705, 0x2708, 0x270d, 0x270f, 0x270f, 0x2712, 0x2712,
|
|
19
|
+
0x2714, 0x2714, 0x2716, 0x2716, 0x271d, 0x271d, 0x2721, 0x2721,
|
|
20
|
+
0x2728, 0x2728, 0x2733, 0x2734, 0x2744, 0x2744, 0x2747, 0x2747,
|
|
21
|
+
0x274c, 0x274c, 0x274e, 0x274e, 0x2753, 0x2755, 0x2757, 0x2757,
|
|
22
|
+
0x2763, 0x2764, 0x2795, 0x2797, 0x27a1, 0x27a1, 0x27b0, 0x27b0,
|
|
23
|
+
0x27bf, 0x27bf, 0x2934, 0x2935, 0x2b05, 0x2b07, 0x2b1b, 0x2b1c,
|
|
24
|
+
0x2b50, 0x2b50, 0x2b55, 0x2b55, 0x3030, 0x3030, 0x303d, 0x303d,
|
|
25
|
+
0x3297, 0x3297, 0x3299, 0x3299, 0x1f004, 0x1f004, 0x1f0cf, 0x1f0cf,
|
|
26
|
+
0x1f170, 0x1f171, 0x1f17e, 0x1f17f, 0x1f18e, 0x1f18e, 0x1f191, 0x1f19a,
|
|
27
|
+
0x1f1e6, 0x1f1ff, 0x1f201, 0x1f202, 0x1f21a, 0x1f21a, 0x1f22f, 0x1f22f,
|
|
28
|
+
0x1f232, 0x1f23a, 0x1f250, 0x1f251, 0x1f300, 0x1f321, 0x1f324, 0x1f393,
|
|
29
|
+
0x1f396, 0x1f397, 0x1f399, 0x1f39b, 0x1f39e, 0x1f3f0, 0x1f3f3, 0x1f3f5,
|
|
30
|
+
0x1f3f7, 0x1f4fd, 0x1f4ff, 0x1f53d, 0x1f549, 0x1f54e, 0x1f550, 0x1f567,
|
|
31
|
+
0x1f56f, 0x1f570, 0x1f573, 0x1f57a, 0x1f587, 0x1f587, 0x1f58a, 0x1f58d,
|
|
32
|
+
0x1f590, 0x1f590, 0x1f595, 0x1f596, 0x1f5a4, 0x1f5a5, 0x1f5a8, 0x1f5a8,
|
|
33
|
+
0x1f5b1, 0x1f5b2, 0x1f5bc, 0x1f5bc, 0x1f5c2, 0x1f5c4, 0x1f5d1, 0x1f5d3,
|
|
34
|
+
0x1f5dc, 0x1f5de, 0x1f5e1, 0x1f5e1, 0x1f5e3, 0x1f5e3, 0x1f5e8, 0x1f5e8,
|
|
35
|
+
0x1f5ef, 0x1f5ef, 0x1f5f3, 0x1f5f3, 0x1f5fa, 0x1f64f, 0x1f680, 0x1f6c5,
|
|
36
|
+
0x1f6cb, 0x1f6d2, 0x1f6d5, 0x1f6d8, 0x1f6dc, 0x1f6e5, 0x1f6e9, 0x1f6e9,
|
|
37
|
+
0x1f6eb, 0x1f6ec, 0x1f6f0, 0x1f6f0, 0x1f6f3, 0x1f6fc, 0x1f7e0, 0x1f7eb,
|
|
38
|
+
0x1f7f0, 0x1f7f0, 0x1f90c, 0x1f93a, 0x1f93c, 0x1f945, 0x1f947, 0x1f9ff,
|
|
39
|
+
0x1fa70, 0x1fa7c, 0x1fa80, 0x1fa8a, 0x1fa8e, 0x1fac6, 0x1fac8, 0x1fac8,
|
|
40
|
+
0x1facd, 0x1fadc, 0x1fadf, 0x1faea, 0x1faef, 0x1faf8
|
|
41
|
+
]);
|
|
42
|
+
export class UnicodeEmojiData {
|
|
43
|
+
static contains(codePoint) {
|
|
44
|
+
let l = 0;
|
|
45
|
+
let h = Math.trunc(RANGES.length >> 1) - 1;
|
|
46
|
+
while (l <= h) {
|
|
47
|
+
const m = l + h >> 1;
|
|
48
|
+
const b = m * 2;
|
|
49
|
+
if (codePoint < RANGES[b]) {
|
|
50
|
+
h = m - 1;
|
|
51
|
+
}
|
|
52
|
+
else {
|
|
53
|
+
if (codePoint > RANGES[b + 1]) {
|
|
54
|
+
l = m + 1;
|
|
55
|
+
}
|
|
56
|
+
else {
|
|
57
|
+
return true;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
}
|
|
61
|
+
return false;
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
const RANGES = new Int32Array([
|
|
3
|
+
0x231a, 0x231b, 0x23e9, 0x23ec, 0x23f0, 0x23f0, 0x23f3, 0x23f3,
|
|
4
|
+
0x25fd, 0x25fe, 0x2614, 0x2615, 0x2648, 0x2653, 0x267f, 0x267f,
|
|
5
|
+
0x2693, 0x2693, 0x26a1, 0x26a1, 0x26aa, 0x26ab, 0x26bd, 0x26be,
|
|
6
|
+
0x26c4, 0x26c5, 0x26ce, 0x26ce, 0x26d4, 0x26d4, 0x26ea, 0x26ea,
|
|
7
|
+
0x26f2, 0x26f3, 0x26f5, 0x26f5, 0x26fa, 0x26fa, 0x26fd, 0x26fd,
|
|
8
|
+
0x2705, 0x2705, 0x270a, 0x270b, 0x2728, 0x2728, 0x274c, 0x274c,
|
|
9
|
+
0x274e, 0x274e, 0x2753, 0x2755, 0x2757, 0x2757, 0x2795, 0x2797,
|
|
10
|
+
0x27b0, 0x27b0, 0x27bf, 0x27bf, 0x2b1b, 0x2b1c, 0x2b50, 0x2b50,
|
|
11
|
+
0x2b55, 0x2b55, 0x1f004, 0x1f004, 0x1f0cf, 0x1f0cf, 0x1f18e, 0x1f18e,
|
|
12
|
+
0x1f191, 0x1f19a, 0x1f1e6, 0x1f1ff, 0x1f201, 0x1f201, 0x1f21a, 0x1f21a,
|
|
13
|
+
0x1f22f, 0x1f22f, 0x1f232, 0x1f236, 0x1f238, 0x1f23a, 0x1f250, 0x1f251,
|
|
14
|
+
0x1f300, 0x1f320, 0x1f32d, 0x1f335, 0x1f337, 0x1f37c, 0x1f37e, 0x1f393,
|
|
15
|
+
0x1f3a0, 0x1f3ca, 0x1f3cf, 0x1f3d3, 0x1f3e0, 0x1f3f0, 0x1f3f4, 0x1f3f4,
|
|
16
|
+
0x1f3f8, 0x1f43e, 0x1f440, 0x1f440, 0x1f442, 0x1f4fc, 0x1f4ff, 0x1f53d,
|
|
17
|
+
0x1f54b, 0x1f54e, 0x1f550, 0x1f567, 0x1f57a, 0x1f57a, 0x1f595, 0x1f596,
|
|
18
|
+
0x1f5a4, 0x1f5a4, 0x1f5fb, 0x1f64f, 0x1f680, 0x1f6c5, 0x1f6cc, 0x1f6cc,
|
|
19
|
+
0x1f6d0, 0x1f6d2, 0x1f6d5, 0x1f6d8, 0x1f6dc, 0x1f6df, 0x1f6eb, 0x1f6ec,
|
|
20
|
+
0x1f6f4, 0x1f6fc, 0x1f7e0, 0x1f7eb, 0x1f7f0, 0x1f7f0, 0x1f90c, 0x1f93a,
|
|
21
|
+
0x1f93c, 0x1f945, 0x1f947, 0x1f9ff, 0x1fa70, 0x1fa7c, 0x1fa80, 0x1fa8a,
|
|
22
|
+
0x1fa8e, 0x1fac6, 0x1fac8, 0x1fac8, 0x1facd, 0x1fadc, 0x1fadf, 0x1faea,
|
|
23
|
+
0x1faef, 0x1faf8
|
|
24
|
+
]);
|
|
25
|
+
export class UnicodeEmojiPresentationData {
|
|
26
|
+
static contains(codePoint) {
|
|
27
|
+
let l = 0;
|
|
28
|
+
let h = Math.trunc(RANGES.length >> 1) - 1;
|
|
29
|
+
while (l <= h) {
|
|
30
|
+
const m = l + h >> 1;
|
|
31
|
+
const b = m * 2;
|
|
32
|
+
if (codePoint < RANGES[b]) {
|
|
33
|
+
h = m - 1;
|
|
34
|
+
}
|
|
35
|
+
else {
|
|
36
|
+
if (codePoint > RANGES[b + 1]) {
|
|
37
|
+
l = m + 1;
|
|
38
|
+
}
|
|
39
|
+
else {
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
return false;
|
|
45
|
+
}
|
|
46
|
+
}
|
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
const RANGES = new Int32Array([
|
|
3
|
+
0x23, 0x23, 0x2a, 0x2a, 0x30, 0x39, 0xa9, 0xa9,
|
|
4
|
+
0xae, 0xae, 0x203c, 0x203c, 0x2049, 0x2049, 0x2122, 0x2122,
|
|
5
|
+
0x2139, 0x2139, 0x2194, 0x2199, 0x21a9, 0x21aa, 0x231a, 0x231b,
|
|
6
|
+
0x2328, 0x2328, 0x23cf, 0x23cf, 0x23e9, 0x23f3, 0x23f8, 0x23fa,
|
|
7
|
+
0x24c2, 0x24c2, 0x25aa, 0x25ab, 0x25b6, 0x25b6, 0x25c0, 0x25c0,
|
|
8
|
+
0x25fb, 0x25fe, 0x2600, 0x2604, 0x260e, 0x260e, 0x2611, 0x2611,
|
|
9
|
+
0x2614, 0x2615, 0x2618, 0x2618, 0x261d, 0x261d, 0x2620, 0x2620,
|
|
10
|
+
0x2622, 0x2623, 0x2626, 0x2626, 0x262a, 0x262a, 0x262e, 0x262f,
|
|
11
|
+
0x2638, 0x263a, 0x2640, 0x2640, 0x2642, 0x2642, 0x2648, 0x2653,
|
|
12
|
+
0x265f, 0x2660, 0x2663, 0x2663, 0x2665, 0x2666, 0x2668, 0x2668,
|
|
13
|
+
0x267b, 0x267b, 0x267e, 0x267f, 0x2692, 0x2697, 0x2699, 0x2699,
|
|
14
|
+
0x269b, 0x269c, 0x26a0, 0x26a1, 0x26a7, 0x26a7, 0x26aa, 0x26ab,
|
|
15
|
+
0x26b0, 0x26b1, 0x26bd, 0x26be, 0x26c4, 0x26c5, 0x26c8, 0x26c8,
|
|
16
|
+
0x26ce, 0x26cf, 0x26d1, 0x26d1, 0x26d3, 0x26d4, 0x26e9, 0x26ea,
|
|
17
|
+
0x26f0, 0x26f5, 0x26f7, 0x26fa, 0x26fd, 0x26fd, 0x2702, 0x2702,
|
|
18
|
+
0x2705, 0x2705, 0x2708, 0x270d, 0x270f, 0x270f, 0x2712, 0x2712,
|
|
19
|
+
0x2714, 0x2714, 0x2716, 0x2716, 0x271d, 0x271d, 0x2721, 0x2721,
|
|
20
|
+
0x2728, 0x2728, 0x2733, 0x2734, 0x2744, 0x2744, 0x2747, 0x2747,
|
|
21
|
+
0x274c, 0x274c, 0x274e, 0x274e, 0x2753, 0x2755, 0x2757, 0x2757,
|
|
22
|
+
0x2763, 0x2764, 0x2795, 0x2797, 0x27a1, 0x27a1, 0x27b0, 0x27b0,
|
|
23
|
+
0x27bf, 0x27bf, 0x2934, 0x2935, 0x2b05, 0x2b07, 0x2b1b, 0x2b1c,
|
|
24
|
+
0x2b50, 0x2b50, 0x2b55, 0x2b55, 0x3030, 0x3030, 0x303d, 0x303d,
|
|
25
|
+
0x3297, 0x3297, 0x3299, 0x3299, 0x1f004, 0x1f004, 0x1f170, 0x1f171,
|
|
26
|
+
0x1f17e, 0x1f17f, 0x1f202, 0x1f202, 0x1f21a, 0x1f21a, 0x1f22f, 0x1f22f,
|
|
27
|
+
0x1f237, 0x1f237, 0x1f30d, 0x1f30f, 0x1f315, 0x1f315, 0x1f31c, 0x1f31c,
|
|
28
|
+
0x1f321, 0x1f321, 0x1f324, 0x1f32c, 0x1f336, 0x1f336, 0x1f378, 0x1f378,
|
|
29
|
+
0x1f37d, 0x1f37d, 0x1f393, 0x1f393, 0x1f396, 0x1f397, 0x1f399, 0x1f39b,
|
|
30
|
+
0x1f39e, 0x1f39f, 0x1f3a7, 0x1f3a7, 0x1f3ac, 0x1f3ae, 0x1f3c2, 0x1f3c2,
|
|
31
|
+
0x1f3c4, 0x1f3c4, 0x1f3c6, 0x1f3c6, 0x1f3ca, 0x1f3ce, 0x1f3d4, 0x1f3e0,
|
|
32
|
+
0x1f3ed, 0x1f3ed, 0x1f3f3, 0x1f3f3, 0x1f3f5, 0x1f3f5, 0x1f3f7, 0x1f3f7,
|
|
33
|
+
0x1f408, 0x1f408, 0x1f415, 0x1f415, 0x1f41f, 0x1f41f, 0x1f426, 0x1f426,
|
|
34
|
+
0x1f43f, 0x1f43f, 0x1f441, 0x1f442, 0x1f446, 0x1f449, 0x1f44d, 0x1f44e,
|
|
35
|
+
0x1f453, 0x1f453, 0x1f46a, 0x1f46a, 0x1f47d, 0x1f47d, 0x1f4a3, 0x1f4a3,
|
|
36
|
+
0x1f4b0, 0x1f4b0, 0x1f4b3, 0x1f4b3, 0x1f4bb, 0x1f4bb, 0x1f4bf, 0x1f4bf,
|
|
37
|
+
0x1f4cb, 0x1f4cb, 0x1f4da, 0x1f4da, 0x1f4df, 0x1f4df, 0x1f4e4, 0x1f4e6,
|
|
38
|
+
0x1f4ea, 0x1f4ed, 0x1f4f7, 0x1f4f7, 0x1f4f9, 0x1f4fb, 0x1f4fd, 0x1f4fd,
|
|
39
|
+
0x1f508, 0x1f508, 0x1f50d, 0x1f50d, 0x1f512, 0x1f513, 0x1f549, 0x1f54a,
|
|
40
|
+
0x1f550, 0x1f567, 0x1f56f, 0x1f570, 0x1f573, 0x1f579, 0x1f587, 0x1f587,
|
|
41
|
+
0x1f58a, 0x1f58d, 0x1f590, 0x1f590, 0x1f5a5, 0x1f5a5, 0x1f5a8, 0x1f5a8,
|
|
42
|
+
0x1f5b1, 0x1f5b2, 0x1f5bc, 0x1f5bc, 0x1f5c2, 0x1f5c4, 0x1f5d1, 0x1f5d3,
|
|
43
|
+
0x1f5dc, 0x1f5de, 0x1f5e1, 0x1f5e1, 0x1f5e3, 0x1f5e3, 0x1f5e8, 0x1f5e8,
|
|
44
|
+
0x1f5ef, 0x1f5ef, 0x1f5f3, 0x1f5f3, 0x1f5fa, 0x1f5fa, 0x1f610, 0x1f610,
|
|
45
|
+
0x1f687, 0x1f687, 0x1f68d, 0x1f68d, 0x1f691, 0x1f691, 0x1f694, 0x1f694,
|
|
46
|
+
0x1f698, 0x1f698, 0x1f6ad, 0x1f6ad, 0x1f6b2, 0x1f6b2, 0x1f6b9, 0x1f6ba,
|
|
47
|
+
0x1f6bc, 0x1f6bc, 0x1f6cb, 0x1f6cb, 0x1f6cd, 0x1f6cf, 0x1f6e0, 0x1f6e5,
|
|
48
|
+
0x1f6e9, 0x1f6e9, 0x1f6f0, 0x1f6f0, 0x1f6f3, 0x1f6f3
|
|
49
|
+
]);
|
|
50
|
+
export class UnicodeEmojiStyleVariationData {
|
|
51
|
+
static contains(codePoint) {
|
|
52
|
+
let l = 0;
|
|
53
|
+
let h = Math.trunc(RANGES.length >> 1) - 1;
|
|
54
|
+
while (l <= h) {
|
|
55
|
+
const m = l + h >> 1;
|
|
56
|
+
const b = m * 2;
|
|
57
|
+
if (codePoint < RANGES[b]) {
|
|
58
|
+
h = m - 1;
|
|
59
|
+
}
|
|
60
|
+
else {
|
|
61
|
+
if (codePoint > RANGES[b + 1]) {
|
|
62
|
+
l = m + 1;
|
|
63
|
+
}
|
|
64
|
+
else {
|
|
65
|
+
return true;
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
return false;
|
|
70
|
+
}
|
|
71
|
+
}
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
// Generated by the reflaxe TypeScript target. Do not edit.
|
|
2
|
+
const RANGES = new Int32Array([
|
|
3
|
+
0x24, 0x24, 0x2b, 0x2b, 0x3c, 0x3e, 0x5e, 0x5e,
|
|
4
|
+
0x60, 0x60, 0x7c, 0x7c, 0x7e, 0x7e, 0xa2, 0xa6,
|
|
5
|
+
0xa8, 0xa9, 0xac, 0xac, 0xae, 0xb1, 0xb4, 0xb4,
|
|
6
|
+
0xb8, 0xb8, 0xd7, 0xd7, 0xf7, 0xf7, 0x2c2, 0x2c5,
|
|
7
|
+
0x2d2, 0x2df, 0x2e5, 0x2eb, 0x2ed, 0x2ed, 0x2ef, 0x2ff,
|
|
8
|
+
0x375, 0x375, 0x384, 0x385, 0x3f6, 0x3f6, 0x482, 0x482,
|
|
9
|
+
0x58d, 0x58f, 0x606, 0x608, 0x60b, 0x60b, 0x60e, 0x60f,
|
|
10
|
+
0x6de, 0x6de, 0x6e9, 0x6e9, 0x6fd, 0x6fe, 0x7f6, 0x7f6,
|
|
11
|
+
0x7fe, 0x7ff, 0x888, 0x888, 0x9f2, 0x9f3, 0x9fa, 0x9fb,
|
|
12
|
+
0xaf1, 0xaf1, 0xb70, 0xb70, 0xbf3, 0xbfa, 0xc7f, 0xc7f,
|
|
13
|
+
0xd4f, 0xd4f, 0xd79, 0xd79, 0xe3f, 0xe3f, 0xf01, 0xf03,
|
|
14
|
+
0xf13, 0xf13, 0xf15, 0xf17, 0xf1a, 0xf1f, 0xf34, 0xf34,
|
|
15
|
+
0xf36, 0xf36, 0xf38, 0xf38, 0xfbe, 0xfc5, 0xfc7, 0xfcc,
|
|
16
|
+
0xfce, 0xfcf, 0xfd5, 0xfd8, 0x109e, 0x109f, 0x1390, 0x1399,
|
|
17
|
+
0x166d, 0x166d, 0x17db, 0x17db, 0x1940, 0x1940, 0x19de, 0x19ff,
|
|
18
|
+
0x1b61, 0x1b6a, 0x1b74, 0x1b7c, 0x1fbd, 0x1fbd, 0x1fbf, 0x1fc1,
|
|
19
|
+
0x1fcd, 0x1fcf, 0x1fdd, 0x1fdf, 0x1fed, 0x1fef, 0x1ffd, 0x1ffe,
|
|
20
|
+
0x2044, 0x2044, 0x2052, 0x2052, 0x207a, 0x207c, 0x208a, 0x208c,
|
|
21
|
+
0x20a0, 0x20c1, 0x2100, 0x2101, 0x2103, 0x2106, 0x2108, 0x2109,
|
|
22
|
+
0x2114, 0x2114, 0x2116, 0x2118, 0x211e, 0x2123, 0x2125, 0x2125,
|
|
23
|
+
0x2127, 0x2127, 0x2129, 0x2129, 0x212e, 0x212e, 0x213a, 0x213b,
|
|
24
|
+
0x2140, 0x2144, 0x214a, 0x214d, 0x214f, 0x214f, 0x218a, 0x218b,
|
|
25
|
+
0x2190, 0x2307, 0x230c, 0x2328, 0x232b, 0x2429, 0x2440, 0x244a,
|
|
26
|
+
0x249c, 0x24e9, 0x2500, 0x2767, 0x2794, 0x27c4, 0x27c7, 0x27e5,
|
|
27
|
+
0x27f0, 0x2982, 0x2999, 0x29d7, 0x29dc, 0x29fb, 0x29fe, 0x2b73,
|
|
28
|
+
0x2b76, 0x2bff, 0x2ce5, 0x2cea, 0x2e50, 0x2e51, 0x2e80, 0x2e99,
|
|
29
|
+
0x2e9b, 0x2ef3, 0x2f00, 0x2fd5, 0x2ff0, 0x2fff, 0x3004, 0x3004,
|
|
30
|
+
0x3012, 0x3013, 0x3020, 0x3020, 0x3036, 0x3037, 0x303e, 0x303f,
|
|
31
|
+
0x309b, 0x309c, 0x3190, 0x3191, 0x3196, 0x319f, 0x31c0, 0x31e5,
|
|
32
|
+
0x31ef, 0x31ef, 0x3200, 0x321e, 0x322a, 0x3247, 0x3250, 0x3250,
|
|
33
|
+
0x3260, 0x327f, 0x328a, 0x32b0, 0x32c0, 0x33ff, 0x4dc0, 0x4dff,
|
|
34
|
+
0xa490, 0xa4c6, 0xa700, 0xa716, 0xa720, 0xa721, 0xa789, 0xa78a,
|
|
35
|
+
0xa828, 0xa82b, 0xa836, 0xa839, 0xaa77, 0xaa79, 0xab5b, 0xab5b,
|
|
36
|
+
0xab6a, 0xab6b, 0xfb29, 0xfb29, 0xfbb2, 0xfbd2, 0xfd40, 0xfd4f,
|
|
37
|
+
0xfd90, 0xfd91, 0xfdc8, 0xfdcf, 0xfdfc, 0xfdff, 0xfe62, 0xfe62,
|
|
38
|
+
0xfe64, 0xfe66, 0xfe69, 0xfe69, 0xff04, 0xff04, 0xff0b, 0xff0b,
|
|
39
|
+
0xff1c, 0xff1e, 0xff3e, 0xff3e, 0xff40, 0xff40, 0xff5c, 0xff5c,
|
|
40
|
+
0xff5e, 0xff5e, 0xffe0, 0xffe6, 0xffe8, 0xffee, 0xfffc, 0xfffd,
|
|
41
|
+
0x10137, 0x1013f, 0x10179, 0x10189, 0x1018c, 0x1018e, 0x10190, 0x1019c,
|
|
42
|
+
0x101a0, 0x101a0, 0x101d0, 0x101fc, 0x10877, 0x10878, 0x10ac8, 0x10ac8,
|
|
43
|
+
0x10d8e, 0x10d8f, 0x10ed1, 0x10ed8, 0x1173f, 0x1173f, 0x11fd5, 0x11ff1,
|
|
44
|
+
0x16b3c, 0x16b3f, 0x16b45, 0x16b45, 0x1bc9c, 0x1bc9c, 0x1cc00, 0x1ccef,
|
|
45
|
+
0x1ccfa, 0x1ccfc, 0x1cd00, 0x1ceb3, 0x1ceba, 0x1ced0, 0x1cee0, 0x1cef0,
|
|
46
|
+
0x1cf50, 0x1cfc3, 0x1d000, 0x1d0f5, 0x1d100, 0x1d126, 0x1d129, 0x1d164,
|
|
47
|
+
0x1d16a, 0x1d16c, 0x1d183, 0x1d184, 0x1d18c, 0x1d1a9, 0x1d1ae, 0x1d1ea,
|
|
48
|
+
0x1d200, 0x1d241, 0x1d245, 0x1d245, 0x1d300, 0x1d356, 0x1d6c1, 0x1d6c1,
|
|
49
|
+
0x1d6db, 0x1d6db, 0x1d6fb, 0x1d6fb, 0x1d715, 0x1d715, 0x1d735, 0x1d735,
|
|
50
|
+
0x1d74f, 0x1d74f, 0x1d76f, 0x1d76f, 0x1d789, 0x1d789, 0x1d7a9, 0x1d7a9,
|
|
51
|
+
0x1d7c3, 0x1d7c3, 0x1d800, 0x1d9ff, 0x1da37, 0x1da3a, 0x1da6d, 0x1da74,
|
|
52
|
+
0x1da76, 0x1da83, 0x1da85, 0x1da86, 0x1e14f, 0x1e14f, 0x1e2ff, 0x1e2ff,
|
|
53
|
+
0x1ecac, 0x1ecac, 0x1ecb0, 0x1ecb0, 0x1ed2e, 0x1ed2e, 0x1eef0, 0x1eef1,
|
|
54
|
+
0x1f000, 0x1f02b, 0x1f030, 0x1f093, 0x1f0a0, 0x1f0ae, 0x1f0b1, 0x1f0bf,
|
|
55
|
+
0x1f0c1, 0x1f0cf, 0x1f0d1, 0x1f0f5, 0x1f10d, 0x1f1ad, 0x1f1e6, 0x1f202,
|
|
56
|
+
0x1f210, 0x1f23b, 0x1f240, 0x1f248, 0x1f250, 0x1f251, 0x1f260, 0x1f265,
|
|
57
|
+
0x1f300, 0x1f6d8, 0x1f6dc, 0x1f6ec, 0x1f6f0, 0x1f6fc, 0x1f700, 0x1f7d9,
|
|
58
|
+
0x1f7e0, 0x1f7eb, 0x1f7f0, 0x1f7f0, 0x1f800, 0x1f80b, 0x1f810, 0x1f847,
|
|
59
|
+
0x1f850, 0x1f859, 0x1f860, 0x1f887, 0x1f890, 0x1f8ad, 0x1f8b0, 0x1f8bb,
|
|
60
|
+
0x1f8c0, 0x1f8c1, 0x1f8d0, 0x1f8d8, 0x1f900, 0x1fa57, 0x1fa60, 0x1fa6d,
|
|
61
|
+
0x1fa70, 0x1fa7c, 0x1fa80, 0x1fa8a, 0x1fa8e, 0x1fac6, 0x1fac8, 0x1fac8,
|
|
62
|
+
0x1facd, 0x1fadc, 0x1fadf, 0x1faea, 0x1faef, 0x1faf8, 0x1fb00, 0x1fb92,
|
|
63
|
+
0x1fb94, 0x1fbef, 0x1fbfa, 0x1fbfa
|
|
64
|
+
]);
|
|
65
|
+
export class UnicodeSymbolData {
|
|
66
|
+
static contains(codePoint) {
|
|
67
|
+
let low = 0;
|
|
68
|
+
let high = Math.trunc(RANGES.length >> 1) - 1;
|
|
69
|
+
while (low <= high) {
|
|
70
|
+
const middle = low + high >> 1;
|
|
71
|
+
const base = middle * 2;
|
|
72
|
+
const start = RANGES[base];
|
|
73
|
+
const end = RANGES[base + 1];
|
|
74
|
+
if (codePoint < start) {
|
|
75
|
+
high = middle - 1;
|
|
76
|
+
}
|
|
77
|
+
else {
|
|
78
|
+
if (codePoint > end) {
|
|
79
|
+
low = middle + 1;
|
|
80
|
+
}
|
|
81
|
+
else {
|
|
82
|
+
return true;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
return false;
|
|
87
|
+
}
|
|
88
|
+
}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { type BopomofoTone } from "./../clreq/BopomofoTone.js";
|
|
2
|
+
import { BopomofoDecisionInfo } from "./../core/BopomofoDecisionInfo.js";
|
|
3
|
+
import { type Cluster } from "./../core/Cluster.js";
|
|
4
|
+
import { type ClusterGeometryDecisionInfo } from "./../core/ClusterGeometryDecisionInfo.js";
|
|
5
|
+
import { DecorationDecisionInfo } from "./../core/DecorationDecisionInfo.js";
|
|
6
|
+
import { DecorationSegmentInfo } from "./../core/DecorationSegmentInfo.js";
|
|
7
|
+
import { type DecorationSpan } from "./../core/DecorationSpan.js";
|
|
8
|
+
import { type Glyph } from "./../core/Glyph.js";
|
|
9
|
+
import { type InlineObjectDecisionInfo } from "./../core/InlineObjectDecisionInfo.js";
|
|
10
|
+
import { IntRange } from "./../core/IntRange.js";
|
|
11
|
+
import { type LineBox } from "./../core/LineBox.js";
|
|
12
|
+
import { RubyDecisionInfo } from "./../core/RubyDecisionInfo.js";
|
|
13
|
+
import { type RubySpan } from "./../core/RubySpan.js";
|
|
14
|
+
import { TextRange } from "./../core/TextRange.js";
|
|
15
|
+
import { TextStyle } from "./../core/TextStyle.js";
|
|
16
|
+
import { FontRole } from "./../font/FontRole.js";
|
|
17
|
+
import { type ClusterMetricDecision } from "./LineGeometryStage.js";
|
|
18
|
+
import { type ExplainableStubParagraphLayoutEngine } from "./ParagraphLayoutEngine.js";
|
|
19
|
+
import { SortedMapTable, SortedSetTable } from "../../../runtime.js";
|
|
20
|
+
export declare class RubyFontGeometry {
|
|
21
|
+
readonly width: number;
|
|
22
|
+
readonly ascent: number;
|
|
23
|
+
readonly descent: number;
|
|
24
|
+
readonly requiredExtent: number;
|
|
25
|
+
readonly glyphs: Glyph[];
|
|
26
|
+
constructor(width: number, ascent: number, descent: number, requiredExtent: number, glyphs: Glyph[]);
|
|
27
|
+
toString(): string;
|
|
28
|
+
}
|
|
29
|
+
export declare class AnnotationGeometryStageResult {
|
|
30
|
+
readonly inlineObjectDecisions: InlineObjectDecisionInfo[];
|
|
31
|
+
readonly decorationDecisions: DecorationDecisionInfo[];
|
|
32
|
+
readonly decorationSegments: DecorationSegmentInfo[];
|
|
33
|
+
readonly rubyDecisions: RubyDecisionInfo[];
|
|
34
|
+
readonly bopomofoDecisions: BopomofoDecisionInfo[];
|
|
35
|
+
constructor(inlineObjectDecisions: InlineObjectDecisionInfo[], decorationDecisions: DecorationDecisionInfo[], decorationSegments: DecorationSegmentInfo[], rubyDecisions: RubyDecisionInfo[], bopomofoDecisions: BopomofoDecisionInfo[]);
|
|
36
|
+
toString(): string;
|
|
37
|
+
}
|
|
38
|
+
export declare class IndexedDecorationSegment {
|
|
39
|
+
readonly index: number;
|
|
40
|
+
readonly seg: DecorationSegmentInfo;
|
|
41
|
+
constructor(index: number, seg: DecorationSegmentInfo);
|
|
42
|
+
}
|
|
43
|
+
export declare class AnnotationGeometryStage {
|
|
44
|
+
static computeDecorationDecisions(decorations: readonly DecorationSpan[], lineRanges: IntRange[], lineBoxes: LineBox[], finalClusters: Cluster[], clusterRoles: FontRole[], justifyDeltaByCluster: SortedMapTable<number, number>, rubySpreadByCluster: SortedMapTable<number, number>, metricDecisions: ClusterMetricDecision[], fontSize: number, emphasisDotGapEm: number): DecorationDecisionInfo[];
|
|
45
|
+
static shortenAdjacentInterlinearLines(segments: DecorationSegmentInfo[], fontSize: number): DecorationSegmentInfo[];
|
|
46
|
+
static computeDecorationSegments(decorations: readonly DecorationSpan[], lineRanges: IntRange[], lineBoxes: LineBox[], finalClusters: Cluster[], justifyDeltaByCluster: SortedMapTable<number, number>, geometryByRange: SortedMapTable<TextRange, ClusterGeometryDecisionInfo>, leadingGapRanges: SortedSetTable<TextRange>, trailingGapRanges: SortedSetTable<TextRange>, autoSpaceGapPx: number, fontSize: number): DecorationSegmentInfo[];
|
|
47
|
+
static computeRubyDecisions(rubySpans: RubySpan[], lineRanges: IntRange[], lineBoxes: LineBox[], finalClusters: Cluster[], naturalClusters: Cluster[], metricDecisions: ClusterMetricDecision[], rubyFontGeometryBySpan: SortedMapTable<RubySpan, RubyFontGeometry>, rubyStackGap: number, fallbackBaseAscent: number, rubyFontSize: number, rubyFontWeight: number, baseLocale: string): RubyDecisionInfo[];
|
|
48
|
+
static bopomofoSymbolRows(n: number, neutral: boolean): IntRange[];
|
|
49
|
+
static bopomofoNeutralRow(n: number): IntRange;
|
|
50
|
+
static bopomofoRegularToneRow(n: number): IntRange;
|
|
51
|
+
static bopomofoRuToneRow(n: number): IntRange;
|
|
52
|
+
static bopomofoToneGlyph(tone: BopomofoTone): string;
|
|
53
|
+
private static copyFontFamilies;
|
|
54
|
+
private static bopomofoBox;
|
|
55
|
+
private static bopomofoInkBounds;
|
|
56
|
+
static computeBopomofoDecisions(engine: ExplainableStubParagraphLayoutEngine, rubySpans: RubySpan[], lineRanges: IntRange[], lineBoxes: LineBox[], finalClusters: Cluster[], naturalClusters: Cluster[], baseAscent: number, baseDescent: number, fontSize: number, bopomofoFontWeightAt: (a0: number) => number, baseTextStyle: TextStyle): BopomofoDecisionInfo[];
|
|
57
|
+
}
|