元編程參考文件

單線字型

14 個節點

本頁內容 14

基線單位

函數

Baseline offset in raw Hershey units.

簽名
基線單位() -> 低精度數字
float BaselineUnit()

返回

結果低精度數字
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

大寫字母高度

函數

Font units from baseline to cap line.

簽名
大寫字母高度() -> 低精度數字
float CapHeight()

返回

結果低精度數字
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

字元

函數

Every character this face has a glyph for. The Hershey faces here cover ASCII 32-126.

簽名
字元(Stroke Font: Stroke Font) -> IReadOnlyCollection<Char>
IReadOnlyCollection<char> Characters(StrokeFont Stroke Font)

參數

名稱型別預設值說明
Stroke FontStroke Font—

返回

結果IReadOnlyCollection<Char>
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

是否連筆

函數

True for connected cursive faces, where glyphs are drawn to join up.

簽名
是否連筆(Stroke Font: Stroke Font) -> 真否
bool IsCursive(StrokeFont Stroke Font)

參數

名稱型別預設值說明
Stroke FontStroke Font—

返回

結果真否
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

字形

函數

The glyph for a character, or null if this face has none.

簽名
字形(Stroke Font: Stroke Font, C: Char) -> Stroke Glyph
StrokeGlyph Item(StrokeFont Stroke Font, char c)

參數

名稱型別預設值說明
Stroke FontStroke Font—
CChar—

返回

結果Stroke Glyph
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

名稱

函數

What this face is called.

簽名
名稱(Stroke Font: Stroke Font) -> 文字
string Name(StrokeFont Stroke Font)

參數

名稱型別預設值說明
Stroke FontStroke Font—

返回

結果文字
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

取得或使用後備字型

函數

The glyph for a character, falling back to this face's '?' and then to a blank of the space's width.

簽名
取得或使用後備字型 -> Stroke Glyph
    Stroke Font: Stroke Font
    C: Char
StrokeGlyph GetOrFallback(StrokeFont Stroke Font, char c)

參數

名稱型別預設值說明
Stroke FontStroke Font—
CChar—

返回

結果Stroke Glyph
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
事件 例程 狀態機狀態
宣告於
單線字型
所屬包
影像處理

按名稱取得

函數

One of the embedded faces by StrokeFont.Name, or null if no face carries that name.

簽名
按名稱取得(名稱: 文字) -> Stroke Font
StrokeFont ByName(string name)

參數

名稱型別預設值說明
名稱文字—

返回

結果Stroke Font

備註

Matched case-insensitively, so a caller that got the name out of a graph, a command line or a
settings file does not have to reproduce the capitalisation exactly.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

從檔案載入

函數

Reads a face from a `.jhf` file on disk, for the stroke and engraving faces this package does
not embed.

簽名
從檔案載入(路徑: 文字, 名稱: 文字, 連筆: 真否) -> Stroke Font
StrokeFont FromFile(
    string path,
    string name,
    bool cursive = false)

參數

名稱型別預設值說明
路徑文字—The `.jhf` file.
名稱文字—What to call the face; the file name without its extension when not given.
連筆真否FalseWhether the face's glyphs are drawn to join up.

返回

結果Stroke Font

備註

Latin-1 rather than UTF-8, for the reason the embedded loader uses it: the format encodes each
coordinate as one byte offset from 'R', and bytes above 0x7F are ordinary coordinates rather
than the start of a multi-byte sequence. Read as UTF-8 they become U+FFFD and the glyph
collapses.

所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

全部字型

函數

The three faces embedded in this package.

簽名
全部字型() -> IReadOnlyList<Stroke Font>
IReadOnlyList<StrokeFont> All()

返回

結果IReadOnlyList<Stroke Font>
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

印刷體

函數

Hershey Roman Simplex: unjoined print, which is what a plotter or an engraver usually wants.

簽名
印刷體() -> Stroke Font
StrokeFont Print()

返回

結果Stroke Font
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

手寫體

函數

Hershey Script: a light cursive hand, the one a handwriting animation usually wants.

簽名
手寫體() -> Stroke Font
StrokeFont Script()

返回

結果Stroke Font
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

複雜手寫體

函數

Hershey Script Complex: the same hand with more strokes per glyph, so a heavier, more formal one.

簽名
複雜手寫體() -> Stroke Font
StrokeFont ScriptComplex()

返回

結果Stroke Font
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理

解析字型

函數

Parses the text of a `.jhf` file into a face.

簽名
解析字型(名稱: 文字, 文字: 文字, 連筆: 真否) -> Stroke Font
StrokeFont Parse(string name, string text, bool cursive)

參數

名稱型別預設值說明
名稱文字—What to call the face.
文字文字—The file's contents, read as Latin-1.
連筆真否—Whether the face's glyphs are drawn to join up.

返回

結果Stroke Font
所屬發行版
元編程(教育版)元編程(專業版)
可用的圖種類
資料流 函數 事件 例程 藍圖 狀態機狀態
宣告於
單線字型
所屬包
影像處理