Versions in this module Expand all Collapse all v0 v0.0.2 Jun 26, 2022 Changes in this version + func IsRotatedScript(script Script) bool + func IsSpacelessScript(script Script) bool + func IsVerticalScript(script Script) bool v0.0.1 Jun 21, 2022 Changes in this version + const Adlam + const Arabic + const Armenian + const Avestan + const Balinese + const Bamum + const BassaVah + const Batak + const Bengali + const Bhaiksuki + const Bopomofo + const BottomToTop + const Brahmi + const Braille + const Buginese + const Buhid + const CanadianSyllabics + const Carian + const CaucasianAlbanian + const Chakma + const Cham + const Cherokee + const Chorasmian + const Coptic + const Cuneiform + const Cypriot + const Cyrillic + const Deseret + const Devanagari + const DirectionInvalid + const DivesAkuru + const Dogra + const Duployan + const EgyptianHieroglyphs + const Elbasan + const Elymaic + const Ethiopic + const FairyTales + const Georgian + const Glagolitic + const Gothic + const Grantha + const Greek + const Gujarati + const GunjalaGondi + const Gurmukhi + const Han + const Hangul + const HanifiRohingya + const Hanunoo + const Hebrew + const Hiragana + const ImperialAramaic + const InscriptionalPahlavi + const InscriptionalParthian + const Javanese + const Kaithi + const Kannada + const Katakana + const KayahLi + const Kharoshthi + const KhitanSmallScript + const Khmer + const Khojki + const Khudawadi + const Lao + const Latin + const LeftToRight + const Lepcha + const Limbu + const LinearA + const LinearB + const Lisu + const Lycian + const Lydian + const Mahajani + const Makasar + const Malayalam + const Mandaic + const Manichaean + const Marchen + const MasaramGondi + const Medefaidrin + const MeeteiMayek + const MendeKikakui + const MeroiticCursive + const MeroiticHieroglyphs + const Miao + const Modi + const Mongolian + const Mro + const Myanmar + const Nabataean + const Nandinagari + const NewTaiLue + const Newa + const Nko + const Nushu + const NyiakengPuachueHmong + const Ogham + const OlChiki + const OldItalic + const OldNorthArabian + const OldPermic + const OldPersian + const OldSogdian + const OldSouthArabian + const OldTurkic + const Oriya + const Osage + const Osmanya + const PahawhHmong + const Palmyrene + const PauCinHau + const PhagsPa + const Phoenician + const PsalterPahlavi + const Rejang + const RightToLeft + const Runic + const Samaritan + const Saurashtra + const ScriptCommon + const ScriptInherited + const ScriptInvalid + const ScriptUnknown + const Sharada + const Shavian + const Siddham + const Sinhala + const Sogdian + const SoraSompeng + const Soyombo + const Sundanese + const SylotiNagri + const Syriac + const Tagalog + const Tagbanwa + const TaiLe + const TaiTham + const TaiViet + const Takri + const Tamil + const Tangut + const Telugu + const Thaana + const Thai + const Tibetan + const Tifinagh + const Tirhuta + const TopToBottom + const Ugaritic + const Vai + const Wancho + const WarangCiti + const Yezidi + const Yi + const ZanabazarSquare + var ColonFactor = 2.0 + var CommaFactor = 1.25 + var DemeritsFitness = 100.0 + var DemeritsFlagged = 100.0 + var DemeritsLine = 10.0 + var FrenchSpacing = false + var HyphenPenalty = 50.0 + var Infinity = 1000.0 + var SemicolonFactor = 1.5 + var SentenceFactor = 3.0 + var SpaceShrink = 1.0 / 3.0 + var SpaceStretch = 1.0 / 2.0 + var Tolerance = 2.0 + func Bidi(text string) (string, []int) + func IsParagraphSeparator(r rune) bool + func LinebreakGlyphs(sfnt *font.SFNT, size float64, glyphs []Glyph, indent, width float64, ...) [][]Glyph + type Align int + const Centered + const Justified + const Left + const Right + type Breakpoint struct + Demerits float64 + Fitness int + Line int + Position int + Ratio float64 + W float64 + Width float64 + Y float64 + Z float64 + func Linebreak(items []Item, width float64, looseness int) []*Breakpoint + func (br *Breakpoint) String() string + type Breakpoints struct + func (list *Breakpoints) Has(b *Breakpoint) bool + func (list *Breakpoints) InsertBefore(b *Breakpoint, at *Breakpoint) + func (list *Breakpoints) Push(b *Breakpoint) + func (list *Breakpoints) Remove(b *Breakpoint) + func (list *Breakpoints) String() string + type Direction int + type Glyph struct + Cluster uint32 + ID uint16 + SFNT *font.SFNT + Size float64 + Text string + XAdvance int32 + XOffset int32 + YAdvance int32 + YOffset int32 + type Item struct + Flagged bool + Penalty float64 + Shrink float64 + Size int + Stretch float64 + Width float64 + func Box(width float64) Item + func Glue(width, stretch, shrink float64) Item + func GlyphsToItems(glyphs []Glyph, indent float64, align Align, vertical, mixed bool) []Item + func Penalty(width, penalty float64, flagged bool) Item + func (item Item) String() string + type Script uint32 + func (i Script) String() string + type ScriptItem struct + Text string + func ScriptItemizer(text string, curScript Script) []ScriptItem + type Shaper struct + func NewShaper(b []byte, _ int) (Shaper, error) + func NewShaperSFNT(sfnt *font.SFNT) (Shaper, error) + func (s Shaper) Destroy() + func (s Shaper) Shape(text string, ppem uint16, direction Direction, script Script, lang string, ...) []Glyph + type Type int + const BoxType + const GlueType + const PenaltyType + func (t Type) String() string