Skip to content

maitag/peote-text

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Peote Text - Glyph and Textrendering for peote-view

Installation:

haxelib git peote-text https://github.com/maitag/peote-text

FontProgram

Glyph

  • createGlyph(charcode:Int, x:Float, y:Float, ?glyphStyle:MyStyle, useMetric = false):Glyph

  • createGlyphAtBase(charcode:Int, x:Float, y:Float, ?glyphStyle:MyStyle):Glyph

  • glyphAdd(glyph:Glyph)

  • glyphRemove(glyph:Glyph)

  • glyphSet(glyph:Glyph, charcode:Int, x:Float, y:Float, ?glyphStyle:MyStyle, useMetric = false):Bool

  • glyphSetAtBase(glyph:Glyph, charcode:Int, x:Float, y:Float, ?glyphStyle:MyStyle):Bool

  • glyphSetChar(glyph:Glyph, charcode:Int, useMetric:Bool = false)

  • glyphSetStyle(glyph:Glyph, glyphStyle:MyStyle, useMetric = false)

  • glyphSetPosition(glyph:Glyph, x:Float, y:Float, useMetric = false)

  • glyphSetPositionAtBase(glyph:Glyph, x:Float, y:Float)

  • glyphSetXPosition(glyph:Glyph, x:Float, useMetric = false)

  • glyphGetXPosition(glyph:Glyph, useMetric = false)

  • glyphSetYPosition(glyph:Glyph, y:Float, useMetric = false)

  • glyphSetYPositionAtBase(glyph:Glyph, y:Float)

  • glyphGetYPosition(glyph:Glyph, useMetric = false):Float

  • glyphGetYPositionAtBase(glyph:Glyph):Float

  • glyphGetBaseline(glyph:Glyph):Float

  • glyphUpdate(glyph:Glyph)

  • updateAllGlyphes()

  • numberOfGlyphes():Int

PageLine

  • createPageLine(chars:String, x:Float = 0.0, y:Float = 0.0, ?size:Null, ?offset:Null, ?glyphStyle:Null, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):PageLine

  • pageLineAdd (pageLine:PageLine)

  • pageLineRemove (pageLine:PageLine)

  • pageLineSet (pageLine:PageLine, chars:String, x:Float, ?y:Null, size:Float, offset:Float, ?glyphStyle:Null, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void)

  • pageLineSetStyle (pageLine:PageLine, x:Float, size:Float, offset:Float, glyphStyle:MyStyle, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):Float

  • pageLineSetPosition (pageLine:PageLine, x:Float, size:Float, offset:Float, xNew:Float, yNew:Float, ?offsetNew:Null, addRemoveGlyphes:Bool = true)

  • pageLineSetXPosition (pageLine:PageLine, x:Float, size:Float, offset:Float, xNew:Float, ?offsetNew:Null, addRemoveGlyphes:Bool = true)

  • pageLineSetYPosition (pageLine:PageLine, x:Float, size:Float, offset:Float, yNew:Float, ?offsetNew:Null, addRemoveGlyphes:Bool = true)

  • pageLineSetPositionSize(pageLine:PageLine, x:Float, size:Float, offset:Float, xNew:Float, yNew:Float, ?offsetNew:Null, addRemoveGlyphes:Bool = true)

  • pageLineSetSize (pageLine:PageLine, x:Float, size:Float, offset:Float, ?offsetNew:Null, addRemoveGlyphes:Bool = true)

  • pageLineSetOffset (pageLine:PageLine, x:Float, size:Float, offset:Float, offsetNew:Float, addRemoveGlyphes:Bool = true)

  • pageLineSetChar (pageLine:PageLine, x:Float, size:Float, offset:Float, charcode:Int, position:Int = 0, ?glyphStyle:MyStyle, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • pageLineSetChars (pageLine:PageLine, x:Float, size:Float, offset:Float, chars:String, position:Int = 0, ?glyphStyle:MyStyle, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float //TODO: pageLineReplaceChars(pageLine:PageLine, x:Float, size:Float, offset:Float, chars:String, from:Int, to:Int, ...)

  • pageLineInsertChar (pageLine:PageLine, x:Float, size:Float, offset:Float, charcode:Int, position:Int = 0, ?glyphStyle:MyStyle, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • pageLineInsertChars (pageLine:PageLine, x:Float, size:Float, offset:Float, chars:String, position:Int = 0, ?glyphStyle:MyStyle, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • pageLineAppendChars (pageLine:PageLine, x:Float, size:Float, offset:Float, chars:String, ?glyphStyle:MyStyle, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • pageLineDeleteChar (pageLine:PageLine, x:Float, size:Float, offset:Float, position:Int = 0 , addRemoveGlyphes:Bool = true):Float

  • pageLineDeleteChars (pageLine:PageLine, x:Float, size:Float, offset:Float, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):Float

  • pageLineCutChars (pageLine:PageLine, x:Float, size:Float, offset:Float, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):String

  • pageLineGetChars (pageLine:PageLine , from:Int = 0, ?to:Null):String

  • pageLineUpdate(pageLine:PageLine, ?from:Null, ?to:Null)

  • pageLineGetPositionAtChar(pageLine:PageLine, x:Float, offset:Float, position:Int):Float

  • pageLineGetCharAtPosition(pageLine:PageLine, x:Float, size:Float, offset:Float, xPosition:Float):Int

Line

  • createLine(chars:String, x:Float, y:Float, ?size:Null, ?offset:Null, ?glyphStyle:Null, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Line

  • lineAdd (line:Line)

  • lineRemove (line:Line)

  • lineSet (line:Line, chars:String, ?x:Null, ?y:Null, ?size:Null, ?offset:Null, ?glyphStyle:Null<$styleType>, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void)

  • lineSetStyle (line:Line, glyphStyle:$styleType, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):Float

  • lineSetPosition (line:Line, x:Float, y:Float, ?offset:Null, addRemoveGlyphes:Bool = true)

  • lineSetXPosition (line:Line, x:Float, ?offset:Null, addRemoveGlyphes:Bool = true)

  • lineSetYPosition (line:Line, y:Float, ?offset:Null, addRemoveGlyphes:Bool = true)

  • lineSetPositionSize(line:Line, x:Float, y:Float, size:Float, ?offset:Null, addRemoveGlyphes:Bool = true)

  • lineSetSize (line:Line, size:Float, ?offset:Null, addRemoveGlyphes:Bool = true)

  • lineSetOffset (line:Line, offset:Float, addRemoveGlyphes:Bool = true)

  • lineSetChar (line:Line, charcode:Int, position:Int = 0, ?glyphStyle:$styleType, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • lineSetChars (line:Line, chars:String, position:Int = 0, ?glyphStyle:$styleType, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float //TODO: lineReplaceChars(line:Line, chars:String, from:Int, to:Int, ...)

  • lineInsertChar (line:Line, charcode:Int, position:Int = 0, ?glyphStyle:$styleType, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • lineInsertChars (line:Line, chars:String, position:Int = 0, ?glyphStyle:$styleType, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • lineAppendChars (line:Line, chars:String, ?glyphStyle:$styleType, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Void):Float

  • lineDeleteChar (line:Line, position:Int = 0, addRemoveGlyphes:Bool = true):Float

  • lineDeleteChars (line:Line, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):Float

  • lineCutChars (line:Line, from:Int = 0, ?to:Null, addRemoveGlyphes:Bool = true):String

  • lineGetChars (line:Line, from:Int = 0, ?to:Null):String

  • lineUpdate (line:Line, ?from:Null, ?to:Null)

  • lineGetPositionAtChar(line:Line, position:Int):Float

  • lineGetCharAtPosition(line:Line, xPosition:Float):Int

Page

  • createPage(chars:String, x:Float, y:Float, ?width:Null, ?height:Null, ?xOffset:Null, ?yOffset:Null, glyphStyle:Null<$styleType> = null, ?onUnrecognizedChar:Int->Int->Int->Void):peote.text.Page<$styleType>

  • pageAdd(page:Page<$styleType>)

  • pageRemove(page:Page<$styleType>)

  • pageSet(page:Page<$styleType>, chars:String, ?x:Null, ?y:Null, ?width:Null, ?height:Null, ?xOffset:Null, ?yOffset:Null, ?glyphStyle:$styleType, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Int->Void)

  • pageAppendChars(page:Page<$styleType>, chars:String, ?glyphStyle:$styleType, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Int->Void):Float

  • pageSetStyle(page:Page<$styleType>, glyphStyle:$styleType, fromLine:Int = 0, fromPosition:Int = 0, ?toLine:Null, ?toPosition:Null, addRemoveGlyphes:Bool = true):Float

  • pageInsertChars(page:Page<$styleType>, chars:String, lineNumber:Int = 0, position:Int = 0 ?glyphStyle:$styleType, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true, ?onUnrecognizedChar:Int->Int->Int->Void)

  • pageTextWidthAfterExpand(page:Page<$styleType>, pageLine:PageLine<$styleType>)

  • pageIsLongestLine(page:Page<$styleType>, pageLine:PageLine<$styleType>):Bool

  • pageTextWidthAfterShrink(page:Page<$styleType>, pageLine:PageLine<$styleType>)

  • pageTextWidthAfterDelete(page:Page<$styleType>)

  • pageGetChars (page:Page<$styleType>, fromLine:Int = 0, fromChar:Int = 0, ?toLine:Null, ?toChar:Null):String

  • pageCutChars (page:Page<$styleType>, fromLine:Int = 0, fromChar:Int = 0, ?toLine:Null, ?toChar:Null):String

  • pageDeleteChars (page:Page<$styleType>, fromLine:Int, toLine:Int, fromChar:Int, toChar:Int, addRemoveGlyphes:Bool = true)

  • ----- TODO: ------

  • pageSetChars (page:Page<$styleType>, chars:String, fromLine:Int = 0, fromChar:Int = 0, ?toLine:Null, ?toChar:Null)

  • pageReplaceChars(page:Page<$styleType>, chars:String, fromLine:Int = 0, fromChar:Int = 0, ?toLine:Null, ?toChar:Null)

  • pageAddLinefeedAt (page:Page<$styleType>, ?pageLine:PageLine<$styleType>, lineNumber:Int, position:Int = 0, ?glyphStyle:$styleType, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true)

  • pageNewLinefeed (page:Page<$styleType>, ?pageLine:PageLine<$styleType>, lineNumber:Int, afterLine:Bool = true, ?glyphStyle:$styleType, ?defaultFontRange:Null, addRemoveGlyphes:Bool = true)

  • pageRemoveLinefeed(page:Page<$styleType>, ?pageLine:PageLine<$styleType>, lineNumber:Int, addRemoveGlyphes:Bool = true)

  • pageDeleteLine(page:Page<$styleType>, lineNumber:Int)

  • pageDeleteLines(page:Page<$styleType>, fromLineNumber:Int, toLineNumber:Int)

  • pageCutLine

  • pageCopyLine

// maybe better only setLineMetric() here ? public function pageSetLineSpace(page:Page<$styleType>, lineSpace:Float, fromLine:Int = 0, toLine:Null = null, addRemoveGlyphes:Bool = true)

  • pageSetPosition(page:Page<$styleType>, x:Float, y:Float, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetXPosition(page:Page<$styleType>, x:Float, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetYPosition(page:Page<$styleType>, y:Float, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetPositionSize(page:Page<$styleType>, x:Float, y:Float, width:Float, height:Float, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetSize(page:Page<$styleType>, width:Float, height:Float, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetOffset(page:Page<$styleType>, ?xOffset:Null, ?yOffset:Null, addRemoveGlyphes:Bool = true)

  • pageSetXOffset(page:Page<$styleType>, xOffset:Float, addRemoveGlyphes:Bool = true)

  • pageSetYOffset(page:Page<$styleType>, yOffset:Float, addRemoveGlyphes:Bool = true)

  • pageUpdate(page:Page<$styleType>, from:Null = null, to:Null = null)

  • pageGetPositionAtChar(page:Page<$styleType>, pageLine:PageLine<$styleType>, position:Int):Float

  • pageGetCharAtPosition(page:Page<$styleType>, pageLine:PageLine<$styleType>, xPosition:Float, intoVisibleRange:Bool = true):Int

  • pageGetLineAtPosition(page:Page<$styleType>, yPosition:Float):PageLine

  • pageGetLineAtPosition(page:Page<$styleType>, yPosition:Float, intoVisibleRange:Bool = true):Int


About

glyph, line and textrendering based on peote-view renderer

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages