PrefUI // +hardenVerticalPunctuations.

This commit is contained in:
ShikiSuen 2022-08-27 23:33:22 +08:00
parent 504a1d70a8
commit ae22b62344
6 changed files with 26 additions and 1 deletions

View File

@ -27,6 +27,8 @@ struct suiPrefPaneDictionary: View {
forKey: UserDef.kUseFixecCandidateOrderOnSelection.rawValue)
@State private var selConsolidateContextOnCandidateSelection: Bool = UserDefaults.standard.bool(
forKey: UserDef.kConsolidateContextOnCandidateSelection.rawValue)
@State private var selHardenVerticalPunctuations: Bool = UserDefaults.standard.bool(
forKey: UserDef.kHardenVerticalPunctuations.rawValue)
private let contentMaxHeight: Double = 430
private let contentWidth: Double = {
@ -112,7 +114,8 @@ struct suiPrefPaneDictionary: View {
mgrPrefs.shouldAutoReloadUserDataFiles = selAutoReloadUserData
}
).controlSize(.small)
Divider()
}
Preferences.Section(title: "") {
Toggle(
LocalizedStringKey("Enable CNS11643 Support (2022-08-02)"),
isOn: $selEnableCNS11643.onChange {
@ -151,6 +154,18 @@ struct suiPrefPaneDictionary: View {
mgrPrefs.consolidateContextOnCandidateSelection = selConsolidateContextOnCandidateSelection
}
)
Toggle(
LocalizedStringKey("Harden vertical punctuations during vertical typing (not recommended)"),
isOn: $selHardenVerticalPunctuations.onChange {
mgrPrefs.hardenVerticalPunctuations = selHardenVerticalPunctuations
}
)
Text(
LocalizedStringKey(
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal."
)
)
.preferenceDescription().fixedSize(horizontal: false, vertical: true)
}
}
}

View File

@ -148,6 +148,8 @@
"for cycling pages" = "for cycling pages";
"General" = "General";
"Hanyu Pinyin with Numeral Intonation" = "Hanyu Pinyin with Numeral Intonation";
"Harden vertical punctuations during vertical typing (not recommended)" = "Harden vertical punctuations during vertical typing (not recommended)";
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal." = "⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal.";
"Horizontal" = "Horizontal";
"Hsu" = "Hsu";
"Hualuo Pinyin with Numeral Intonation" = "Hualuo Pinyin with Numeral Intonation";

View File

@ -148,6 +148,8 @@
"for cycling pages" = "for cycling pages";
"General" = "General";
"Hanyu Pinyin with Numeral Intonation" = "Hanyu Pinyin with Numeral Intonation";
"Harden vertical punctuations during vertical typing (not recommended)" = "Harden vertical punctuations during vertical typing (not recommended)";
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal." = "⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal.";
"Horizontal" = "Horizontal";
"Hsu" = "Hsu";
"Hualuo Pinyin with Numeral Intonation" = "Hualuo Pinyin with Numeral Intonation";

View File

@ -148,6 +148,8 @@
"for cycling pages" = "候補陳列ページ";
"General" = "全般設定";
"Hanyu Pinyin with Numeral Intonation" = "漢語弁音 (ローマ字+数字音調)";
"Harden vertical punctuations during vertical typing (not recommended)" = "縦書きの時に、引用符・括弧などを強制的に縦書き文字と変換する(不推奨)";
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal." = "⚠︎ 該当の組版用フォントには縦書き(引用符・括弧)変換機能が備えていない限り、この機能を使う甲斐がある。一旦使うと、入力した全ての引用符・括弧は永遠的に縦書きの様式になる。例え入力を受けているアプリ(例えばワープロソフとなど)の書写方向は横書きと変えたとしても、これらの入力済みの引用符・括弧は全て縦書きの見た目であり、削除してから入力し直す必要になる。";
"Horizontal" = "横型陳列";
"Hsu" = "許氏国音自然配列";
"Hualuo Pinyin with Numeral Intonation" = "中華ローマ弁音 (ローマ字+数字音調)";

View File

@ -148,6 +148,8 @@
"for cycling pages" = "轮替页面";
"General" = "通用设定";
"Hanyu Pinyin with Numeral Intonation" = "汉语拼音+数字标调";
"Harden vertical punctuations during vertical typing (not recommended)" = "在纵排书写时,强制转换标点为纵排形式(不推荐)";
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal." = "⚠︎ 该功能当且仅当目前的排版字型不支援纵排标点动态显示转义的情况下才有用。一旦使用了,所有敲出去的标点都会被永久转换为静态纵排标点:哪怕当前编辑器的排版模式已经改成横排,这些已经输入的标点也都还是纵排标点字符。";
"Horizontal" = "横向布局";
"Hsu" = "许氏国音自然排列";
"Hualuo Pinyin with Numeral Intonation" = "华罗拼音+数字标调";

View File

@ -148,6 +148,8 @@
"for cycling pages" = "輪替頁面";
"General" = "通用設定";
"Hanyu Pinyin with Numeral Intonation" = "漢語拼音+數字標調";
"Harden vertical punctuations during vertical typing (not recommended)" = "在縱排書寫時,強制轉換標點為縱排形式(不推薦)";
"⚠︎ This feature is useful ONLY WHEN the font you are using doesn't support dynamic vertical punctuations. However, typed vertical punctuations will always shown as vertical punctuations EVEN IF your editor has changed the typing direction to horizontal." = "⚠︎ 該功能當且僅當目前的排版字型不支援縱排標點動態顯示轉義的情況下才有用。一旦使用了,所有敲出去的標點都會被永久轉換為靜態縱排標點:哪怕當前編輯器的排版模式已經改成橫排,這些已經輸入的標點也都還是縱排標點字符。";
"Horizontal" = "橫向佈局";
"Hsu" = "許氏國音自然排列";
"Hualuo Pinyin with Numeral Intonation" = "華羅拼音+數字標調";