typeset 0.1.0
縦書き・横書きの日本語組版ライブラリ(JLReq 水準、ラスタ / PDF / SVG)
読み取り中…
検索中…
一致する文字列を見つけられません
typeset::text::HyphenationDictionary クラス

言語ごとのパターン。TextStyle::language(BCP47)で引く。 完全一致 → 主言語("en-GB" なら "en")→ 既定の言語(setDefaultLanguage)の順に探す。 [詳解]

#include <typeset/text/hyphenation.hpp>

公開メンバ関数

HyphenatorforLanguage (const std::string &language)
 言語にパターンを足す(無ければ作る)。最初に足した言語が既定になる
 
const Hyphenatorfind (const std::string &language) const
 言語のパターン(無ければ既定の言語、それも無ければ nullptr)
 
void setDefaultLanguage (const std::string &language)
 見つからなかったときに使う言語(空で無効)
 
const std::string & defaultLanguage () const
 
bool empty () const
 

詳解

言語ごとのパターン。TextStyle::language(BCP47)で引く。 完全一致 → 主言語("en-GB" なら "en")→ 既定の言語(setDefaultLanguage)の順に探す。

既定の言語は「和文の文書に混ざる英単語」のためのもの。本文の言語が ja でも、欧文のハイフネーションは その言語のパターンで行いたい、という指定に使う(forLanguage() で最初に足した言語が自動で既定になる)

hyphenation.hpp63 行目に定義があります。

関数詳解

◆ forLanguage()

Hyphenator & typeset::text::HyphenationDictionary::forLanguage ( const std::string &  language)

言語にパターンを足す(無ければ作る)。最初に足した言語が既定になる

◆ find()

const Hyphenator * typeset::text::HyphenationDictionary::find ( const std::string &  language) const

言語のパターン(無ければ既定の言語、それも無ければ nullptr)

◆ setDefaultLanguage()

void typeset::text::HyphenationDictionary::setDefaultLanguage ( const std::string &  language)

見つからなかったときに使う言語(空で無効)

◆ defaultLanguage()

const std::string & typeset::text::HyphenationDictionary::defaultLanguage ( ) const
inline

hyphenation.hpp71 行目に定義があります。

◆ empty()

bool typeset::text::HyphenationDictionary::empty ( ) const
inline

hyphenation.hpp72 行目に定義があります。


このクラス詳解は次のファイルから抽出されました: