Pre Merge pull request !97 from ShikiSuen/upd/2.3.0

This commit is contained in:
ShikiSuen 2022-08-31 15:03:17 +00:00 committed by Gitee
commit 0f74b459b7
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
44 changed files with 432 additions and 121 deletions

View File

@ -13,12 +13,14 @@ import Cocoa
private let kTargetBin = "vChewing"
private let kTargetType = "app"
private let kTargetBundle = "vChewing.app"
private let kTargetBundleWithComponents = "Library/Input%20Methods/vChewing.app"
private let urlDestinationPartial = FileManager.default.urls(
for: .inputMethodsDirectory, in: .userDomainMask
)[0]
private let urlTargetPartial = urlDestinationPartial.appendingPathComponent(kTargetBundle)
private let urlTargetFullBinPartial = urlTargetPartial.appendingPathComponent("Contents/MacOS/")
private let realHomeDir = URL(
fileURLWithFileSystemRepresentation: getpwuid(getuid()).pointee.pw_dir, isDirectory: true, relativeTo: nil
)
private let urlDestinationPartial = realHomeDir.appendingPathComponent("Library/Input Methods")
private let urlTargetPartial = realHomeDir.appendingPathComponent(kTargetBundleWithComponents)
private let urlTargetFullBinPartial = urlTargetPartial.appendingPathComponent("Contents/MacOS")
.appendingPathComponent(kTargetBin)
private let kDestinationPartial = urlDestinationPartial.path
@ -93,9 +95,9 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
window?.standardWindowButton(.zoomButton)?.isHidden = true
if FileManager.default.fileExists(
atPath: (kTargetPartialPath as NSString).expandingTildeInPath)
atPath: kTargetPartialPath)
{
let currentBundle = Bundle(path: (kTargetPartialPath as NSString).expandingTildeInPath)
let currentBundle = Bundle(path: kTargetPartialPath)
let shortVersion =
currentBundle?.infoDictionary?["CFBundleShortVersionString"] as? String
let currentVersion =
@ -136,15 +138,12 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
}
func removeThenInstallInputMethod() {
if FileManager.default.fileExists(
atPath: (kTargetPartialPath as NSString).expandingTildeInPath)
== false
{
installInputMethod(
previousExists: false, previousVersionNotFullyDeactivatedWarning: false
)
return
}
// if !FileManager.default.fileExists(atPath: kTargetPartialPath) {
// installInputMethod(
// previousExists: false, previousVersionNotFullyDeactivatedWarning: false
// )
// return
// }
let shouldWaitForTranslocationRemoval =
isAppBundleTranslocated(atPath: kTargetPartialPath)
@ -152,7 +151,7 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
//
do {
let sourceDir = (kDestinationPartial as NSString).expandingTildeInPath
let sourceDir = kDestinationPartial
let fileManager = FileManager.default
let fileURLString = String(format: "%@/%@", sourceDir, kTargetBundle)
let fileURL = URL(fileURLWithPath: fileURLString)
@ -216,8 +215,9 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
}
let cpTask = Process()
cpTask.launchPath = "/bin/cp"
print(kDestinationPartial)
cpTask.arguments = [
"-R", targetBundle, (kDestinationPartial as NSString).expandingTildeInPath,
"-R", targetBundle, kDestinationPartial,
]
cpTask.launch()
cpTask.waitUntilExit()
@ -231,7 +231,11 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
endAppWithDelay()
}
guard let imeBundle = Bundle(path: (kTargetPartialPath as NSString).expandingTildeInPath),
let imeURLInstalled = realHomeDir.appendingPathComponent("Library/Input Methods/vChewing.app")
_ = try? shell("/usr/bin/xattr -drs com.apple.quarantine \(kTargetPartialPath)")
guard let imeBundle = Bundle(url: imeURLInstalled),
let imeIdentifier = imeBundle.bundleIdentifier
else {
endAppWithDelay()
@ -343,6 +347,30 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
NSApp.terminate(self)
}
private func shell(_ command: String) throws -> String {
let task = Process()
let pipe = Pipe()
task.standardOutput = pipe
task.standardError = pipe
task.arguments = ["-c", command]
if #available(macOS 10.13, *) {
task.executableURL = URL(fileURLWithPath: "/bin/zsh")
} else {
task.launchPath = "/bin/zsh"
}
task.standardInput = nil
if #available(macOS 10.13, *) {
try task.run()
}
let data = pipe.fileHandleForReading.readDataToEndOfFile()
let output = String(data: data, encoding: .utf8)!
return output
}
// Determines if an app is translocated by Gatekeeper to a randomized path.
// See https://weblog.rogueamoeba.com/2016/06/29/sierra-and-gatekeeper-path-randomization/
// Originally written by Zonble Yang in Objective-C (MIT License).
@ -350,7 +378,7 @@ class AppDelegate: NSWindowController, NSApplicationDelegate {
func isAppBundleTranslocated(atPath bundlePath: String) -> Bool {
var entryCount = getfsstat(nil, 0, 0)
var entries: [statfs] = .init(repeating: .init(), count: Int(entryCount))
let absPath = (bundlePath as NSString).expandingTildeInPath.cString(using: .utf8)
let absPath = bundlePath.cString(using: .utf8)
entryCount = getfsstat(&entries, entryCount * Int32(MemoryLayout<statfs>.stride), MNT_NOWAIT)
for entry in entries.prefix(Int(entryCount)) {
let isMatch = withUnsafeBytes(of: entry.f_mntfromname) { mntFromName in

View File

@ -1,6 +1,6 @@
注意事项:
一、macOS 10.x-11.x 系统有 Bug、令该安装程式无法自动将安装目标设为当前使用者资料夹。如果您在 macOS 12 Monterey 之前的系统安装该输入法的话,请务必「手动」将安装目的地设为当前使用者资料夹。否则,当您今后(在升级系统之后)升级输入法的时候,可能会出现各种混乱情况。下述 sudo 指令会将任何安装到错误位置的档案全部移除。如果不用 sudo 的话,反而会将安装到正确位置的输入法档案给移除掉,所以请认真使用
sudo /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/MacOS/vChewing uninstall
一、macOS 10.x-11.x 系统有 Bug、令该安装程式无法自动将安装目标设为当前使用者资料夹。如果您在 macOS 12 Monterey 之前的系统安装该输入法的话,请务必「手动」将安装目的地设为当前使用者资料夹。否则,当您今后(在升级系统之后)升级输入法的时候,可能会出现各种混乱情况。下述 sudo 指令会将任何安装到错误位置的档案全部移除:
sudo bash /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/Resources/fixinstall.sh
二、安装完毕之后,如果输入法无法正常使用的话,请重新登入即可。

View File

@ -1,6 +1,6 @@
注意事項:
一、macOS 10.x-11.x 系統有 Bug、令該安裝程式無法自動將安裝目標設為當前使用者資料夾。如果您在 macOS 12 Monterey 之前的系統安裝該輸入法的話,請務必「手動」將安裝目的地設為當前使用者資料夾。否則,當您今後(在升級系統之後)升級輸入法的時候,可能會出現各種混亂情況。下述 sudo 指令會將任何安裝到錯誤位置的檔案全部移除。如果不用 sudo 的話,反而會將安裝到正確位置的輸入法檔案給移除掉,所以請認真使用
sudo /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/MacOS/vChewing uninstall
一、macOS 10.x-11.x 系統有 Bug、令該安裝程式無法自動將安裝目標設為當前使用者資料夾。如果您在 macOS 12 Monterey 之前的系統安裝該輸入法的話,請務必「手動」將安裝目的地設為當前使用者資料夾。否則,當您今後(在升級系統之後)升級輸入法的時候,可能會出現各種混亂情況。下述 sudo 指令會將任何安裝到錯誤位置的檔案全部移除:
sudo bash /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/Resources/fixinstall.sh
二、安裝完畢之後,如果輸入法無法正常使用的話,請重新登入即可。

View File

@ -1,6 +1,6 @@
Notice:
1. Due to a bug in macOS 10.x and 11.x, if you are trying to install this input method on macOS releases earlier than macOS 12 Monterey, PLEASE manually choose the install target to the user folder. Otherwise, there will be problems when you are trying to install this input method to later versions when your OS gets upgraded to macOS 12 Monterey or later. The following terminal command can solve such probelems by removing all incorrectly-installed files (must use sudo to avoid the removal of the correctly-installled files):
sudo /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/MacOS/vChewing uninstall
1. Due to a bug in macOS 10.x and 11.x, if you are trying to install this input method on macOS releases earlier than macOS 12 Monterey, PLEASE manually choose the install target to the user folder. Otherwise, there will be problems when you are trying to install this input method to later versions when your OS gets upgraded to macOS 12 Monterey or later. The following terminal command can solve such probelems by removing all incorrectly-installed files (must use sudo):
sudo bash /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/Resources/fixinstall.sh
2. Feel free to logout and re-login if the input method doesn't work after installation.

View File

@ -1,7 +1,6 @@
ご注意:
 macOS 12 Monterey 以前の OSmacOS 10.x-11.xのバグのため、macOS 10.x-11.x でインストールする場合、この入力アプリ必ずご自分でユーザーフォルダをインストール先と設定してください。然もないと、いずれ macOS 12 にアップデートし、この入力アプリのもっと新しいバージョンをインストールする時に、予測できない支障が生ずる恐れがあります。下記のターミナル指令を(必ず下記のまま sudo で)実行すれば、この様な支障を解決することができます:
sudo /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/MacOS/vChewing uninstall
⚠︎ 間違ったところへ実装したファイルだけは消されますが、もし sudo 使わずに実行すると、逆に正しく実装されたファイルは消されます。
sudo bash /Users/$(stat -f%Su /dev/console)/Library/Input\ Methods/vChewing.app/Contents/Resources/fixinstall.sh
● そして、インストール直後、入力アプリがうまく使えない場合、再ログインすれば済ませることです。

View File

@ -0,0 +1,101 @@
//
// Ref: https://stackoverflow.com/a/61695824
// License: https://creativecommons.org/licenses/by-sa/4.0/
//
import Cocoa
class BookmarkManager {
static let shared = BookmarkManager()
// Save bookmark for URL. Use this inside the NSOpenPanel `begin` closure
func saveBookmark(for url: URL) {
guard let bookmarkDic = getBookmarkData(url: url),
let bookmarkURL = getBookmarkURL()
else {
IME.prtDebugIntel("Error getting data or bookmarkURL")
return
}
if #available(macOS 10.13, *) {
do {
let data = try NSKeyedArchiver.archivedData(withRootObject: bookmarkDic, requiringSecureCoding: false)
try data.write(to: bookmarkURL)
IME.prtDebugIntel("Did save data to url")
} catch {
IME.prtDebugIntel("Couldn't save bookmarks")
}
}
}
// Load bookmarks when your app launch for example
func loadBookmarks() {
guard let url = getBookmarkURL() else {
return
}
if fileExists(url) {
do {
let fileData = try Data(contentsOf: url)
if let fileBookmarks = try NSKeyedUnarchiver.unarchiveTopLevelObjectWithData(fileData) as! [URL: Data]? {
for bookmark in fileBookmarks {
restoreBookmark(key: bookmark.key, value: bookmark.value)
}
}
} catch {
IME.prtDebugIntel("Couldn't load bookmarks")
}
}
}
private func restoreBookmark(key: URL, value: Data) {
let restoredUrl: URL?
var isStale = false
IME.prtDebugIntel("Restoring \(key)")
do {
restoredUrl = try URL(
resolvingBookmarkData: value, options: NSURL.BookmarkResolutionOptions.withSecurityScope, relativeTo: nil,
bookmarkDataIsStale: &isStale
)
} catch {
IME.prtDebugIntel("Error restoring bookmarks")
restoredUrl = nil
}
if let url = restoredUrl {
if isStale {
IME.prtDebugIntel("URL is stale")
} else {
if !url.startAccessingSecurityScopedResource() {
IME.prtDebugIntel("Couldn't access: \(url.path)")
}
}
}
}
private func getBookmarkData(url: URL) -> [URL: Data]? {
let data = try? url.bookmarkData(
options: NSURL.BookmarkCreationOptions.withSecurityScope, includingResourceValuesForKeys: nil, relativeTo: nil
)
if let data = data {
return [url: data]
}
return nil
}
private func getBookmarkURL() -> URL? {
let urls = FileManager.default.urls(for: .applicationSupportDirectory, in: .userDomainMask)
if let appSupportURL = urls.last {
let url = appSupportURL.appendingPathComponent("Bookmarks.dict")
return url
}
return nil
}
private func fileExists(_ url: URL) -> Bool {
var isDir = ObjCBool(false)
let exists = FileManager.default.fileExists(atPath: url.path, isDirectory: &isDir)
return exists
}
}

@ -1 +1 @@
Subproject commit 975d8b02cc1c87e83ac71adf9f937dd1cafaa1bb
Subproject commit 6bf8cdb5bfaf9a884b4317b2fa330e37fd9e1cf6

View File

@ -122,7 +122,7 @@ public class KeyHandler {
/// - Parameter key:
/// - Returns:
/// nil
func buildAssociatePhraseArray(withPair pair: Megrez.KeyValuePaired) -> [(String, String)] {
func buildAssociatePhraseArray(withPair pair: Megrez.Compositor.Candidate) -> [(String, String)] {
var arrResult: [(String, String)] = []
if currentLM.hasAssociatedPhrasesFor(pair: pair) {
arrResult = currentLM.associatedPhrasesFor(pair: pair).map { ("", $0) }

View File

@ -71,8 +71,8 @@ extension KeyHandler {
//
stateCallback(InputState.Empty())
// Shift
if input.isShiftHold {
// Shift
if input.isUpperCaseASCIILetterKey {
return false
}

View File

@ -150,7 +150,7 @@ extension KeyHandler {
/// - isTypingVertical:
/// - Returns:
func buildAssociatePhraseState(
withPair pair: Megrez.KeyValuePaired,
withPair pair: Megrez.Compositor.Candidate,
isTypingVertical: Bool
) -> InputState.AssociatedPhrases! {
//  Xcode

View File

@ -60,6 +60,11 @@ class ctlInputMethod: IMKInputController {
/// 調
func resetKeyHandler() {
//
if state is InputState.Inputting, mgrPrefs.trimUnfinishedReadingsOnCommit {
keyHandler.composer.clear()
handle(state: keyHandler.buildInputtingState)
}
if let state = state as? InputState.NotEmpty {
/// 調
handle(state: InputState.Committing(textToCommit: state.composingBufferConverted))
@ -128,7 +133,7 @@ class ctlInputMethod: IMKInputController {
/// - Parameter sender: 使
override func deactivateServer(_ sender: Any!) {
_ = sender //
handle(state: InputState.Empty())
resetKeyHandler() // Empty
handle(state: InputState.Deactivated())
}
@ -193,6 +198,9 @@ class ctlInputMethod: IMKInputController {
@objc(handleEvent:client:) override func handle(_ event: NSEvent!, client sender: Any!) -> Bool {
_ = sender //
// client()
if !(sender is IMKTextInput) { return false }
// NSEvent nilApple InputMethodKit
guard let event = event else { return false }
@ -264,6 +272,7 @@ class ctlInputMethod: IMKInputController {
override func commitComposition(_ sender: Any!) {
_ = sender //
resetKeyHandler()
// super.commitComposition(sender) //
}
///
@ -275,6 +284,14 @@ class ctlInputMethod: IMKInputController {
return state.committingBufferConverted
}
///
/// IMK Bug
override func inputControllerWillClose() {
//
resetKeyHandler()
super.inputControllerWillClose()
}
// MARK: - IMKCandidates
/// IMK

View File

@ -26,7 +26,16 @@ extension ctlInputMethod {
)
cursor -= 1
}
ctlInputMethod.tooltipController.show(tooltip: tooltip, at: lineHeightRect.origin)
var finalOrigin: NSPoint = lineHeightRect.origin
if isVerticalTyping {
finalOrigin = NSPoint(
x: lineHeightRect.origin.x + lineHeightRect.size.width + 4.0, y: lineHeightRect.origin.y - 4.0
)
ctlInputMethod.tooltipController.direction = .vertical
} else {
ctlInputMethod.tooltipController.direction = .horizontal
}
ctlInputMethod.tooltipController.show(tooltip: tooltip, at: finalOrigin)
}
func show(candidateWindowWith state: InputStateProtocol) {

View File

@ -130,7 +130,7 @@ extension ctlInputMethod {
ctlInputMethod.ctlCandidateCurrent.visible = false
ctlInputMethod.tooltipController.hide()
if let previous = previous as? InputState.NotEmpty {
commit(text: previous.composingBuffer)
commit(text: previous.committingBufferConverted)
}
clearInlineDisplay()
//
@ -145,7 +145,7 @@ extension ctlInputMethod {
if let previous = previous as? InputState.NotEmpty,
!(state is InputState.EmptyIgnoringPreviousState)
{
commit(text: previous.composingBuffer)
commit(text: previous.committingBufferConverted)
}
//
ctlInputMethod.ctlCandidateCurrent.visible = false

View File

@ -22,6 +22,9 @@ public enum InputMode: String {
public enum IME {
static let arrSupportedLocales = ["en", "zh-Hant", "zh-Hans", "ja"]
static let dlgOpenPath = NSOpenPanel()
public static let realHomeDir = URL(
fileURLWithFileSystemRepresentation: getpwuid(getuid()).pointee.pw_dir, isDirectory: true, relativeTo: nil
)
// MARK: - Bundle Identifier
@ -173,16 +176,23 @@ public enum IME {
return -1
}
let kTargetBin = "vChewing"
// v2.3.0 sudo
if isSudo {
print(
"vChewing binary does not support sudo-uninstall since v2.3.0. Please use the bundled uninstall.sh instead.\n\nIf you want to fix the installation (i.e. removing all incorrectly installed files outside of the current user folder), please use the bundled fixinstall.sh instead.\n\nIf you don't know how to proceed, please bring either the uninstall.sh / install.sh or the instruction article https://vchewing.github.io/UNINSTALL.html to Apple Support (support.apple.com) for help. Their senior advisors can understand these uninstall instructions."
)
return -1
}
let kTargetBundle = "/vChewing.app"
let pathLibrary =
isSudo
? "/Library"
: FileManager.default.urls(for: .libraryDirectory, in: .userDomainMask)[0].path
: IME.realHomeDir.appendingPathComponent("Library/").path
let pathIMELibrary =
isSudo
? "/Library/Input Methods"
: FileManager.default.urls(for: .inputMethodsDirectory, in: .userDomainMask)[0].path
: IME.realHomeDir.appendingPathComponent("Library/Input Methods/").path
let pathUnitKeyboardLayouts = "/Keyboard Layouts"
let arrKeyLayoutFiles = [
"/vChewing ETen.keylayout", "/vChewingKeyLayout.bundle", "/vChewing MiTAC.keylayout",
@ -203,15 +213,13 @@ public enum IME {
// symbol link
IME.trashTargetIfExists(mgrLangModel.dataFolderPath(isDefaultFolder: true))
IME.trashTargetIfExists(pathLibrary + "/Preferences/" + bundleID + ".plist") // App
IME.trashTargetIfExists(pathLibrary + "/Receipts/org.atelierInmu.vChewing.bom") // pkg
IME.trashTargetIfExists(pathLibrary + "/Receipts/org.atelierInmu.vChewing.plist") // pkg
}
if !IME.trashTargetIfExists(pathIMELibrary + kTargetBundle) { return -1 } // App
//
if selfKill {
let killTask = Process()
killTask.launchPath = "/usr/bin/killall"
killTask.arguments = ["-9", kTargetBin]
killTask.launch()
killTask.waitUntilExit()
NSApplication.shared.terminate(nil)
}
return 0
}

View File

@ -54,6 +54,7 @@ public enum UserDef: String, CaseIterable {
case kDisableShiftTogglingAlphanumericalMode = "DisableShiftTogglingAlphanumericalMode"
case kConsolidateContextOnCandidateSelection = "ConsolidateContextOnCandidateSelection"
case kHardenVerticalPunctuations = "HardenVerticalPunctuations"
case kTrimUnfinishedReadingsOnCommit = "TrimUnfinishedReadingsOnCommit"
case kUseIMKCandidateWindow = "UseIMKCandidateWindow"
case kHandleDefaultCandidateFontsByLangIdentifier = "HandleDefaultCandidateFontsByLangIdentifier"
@ -301,6 +302,9 @@ public enum mgrPrefs {
UserDefaults.standard.setDefault(
mgrPrefs.hardenVerticalPunctuations, forKey: UserDef.kHardenVerticalPunctuations.rawValue
)
UserDefaults.standard.setDefault(
mgrPrefs.trimUnfinishedReadingsOnCommit, forKey: UserDef.kTrimUnfinishedReadingsOnCommit.rawValue
)
// -----
@ -432,6 +436,9 @@ public enum mgrPrefs {
@UserDefault(key: UserDef.kHardenVerticalPunctuations.rawValue, defaultValue: false)
static var hardenVerticalPunctuations: Bool
@UserDefault(key: UserDef.kTrimUnfinishedReadingsOnCommit.rawValue, defaultValue: true)
static var trimUnfinishedReadingsOnCommit: Bool
// MARK: - Settings (Tier 2)
@UserDefault(key: UserDef.kUseIMKCandidateWindow.rawValue, defaultValue: false)

View File

@ -245,11 +245,11 @@ extension vChewing {
return !unigramsFor(key: key).isEmpty
}
public func associatedPhrasesFor(pair: Megrez.KeyValuePaired) -> [String] {
public func associatedPhrasesFor(pair: Megrez.Compositor.Candidate) -> [String] {
lmAssociates.valuesFor(pair: pair)
}
public func hasAssociatedPhrasesFor(pair: Megrez.KeyValuePaired) -> Bool {
public func hasAssociatedPhrasesFor(pair: Megrez.Compositor.Candidate) -> Bool {
lmAssociates.hasValuesFor(pair: pair)
}

View File

@ -173,7 +173,9 @@ class SymbolNode {
symbols:
"①②③④⑤⑥⑦⑧⑨⑩⑪⑫⑬⑭⑮⑯⑰⑱⑲⑳ⒶⒷⒸⒹⒺⒻⒼⒽⒾⒿⓀⓁⓂⓂ︎ⓃⓄⓅⓆⓇⓈⓉⓊⓋⓌⓍⓎⓏⓐⓑⓒⓓⓔⓕⓖⓗⓘⓙⓚⓛⓜⓝⓞⓟⓠⓡⓢⓣⓤⓥⓦⓧⓨⓩ⓪⓫⓬⓭⓮⓯⓰⓱⓲⓳⓴⓵⓶⓷⓸⓹⓺⓻⓼⓽⓾⓿❶❷❸❹❺❻❼❽❾❿➀➁➂➃➄➅➆➇➈➉➊➋➌➍➎➏➐➑➒➓🄰🄱🄲🄳🄴🄵🄶🄷🄸🄹🄺🄻🄼🄽🄾🄿🅀🅁🅂🅃🅄🅅🅆🅇🅈🅉🅐🅑🅒🅓🅔🅕🅖🅗🅘🅙🅚🅛🅜🅝🅞🅟🅠🅡🅢🅣🅤🅥🅦🅧🅨🅩🅰🅱🅲🅳🅴🅵🅶🅷🅸🅹🅺🅻🅼🅽🅾🅿︎🆀🆁🆂🆃🆄🆅🆆🆇🆈🆉"
),
SymbolNode(catBracketedASCII, symbols: "⑴⑵⑶⑷⑸⑹⑺⑻⑼⑽⑾⑿⒀⒁⒂⒃⒄⒅⒆⒇⒜⒝⒞⒟⒠⒡⒢⒣⒤⒥⒦⒧⒨⒩⒪⒫⒬⒭⒮⒯⒰⒱⒲⒳⒴⒵🄐🄑🄒🄓🄔🄕🄖🄗🄘🄙🄚🄛🄜🄝🄞🄟🄠🄡🄢🄣🄤🄥🄦🄧🄨🄩"),
SymbolNode(
catBracketedASCII, symbols: "⑴⑵⑶⑷⑸⑹⑺⑻⑼⑽⑾⑿⒀⒁⒂⒃⒄⒅⒆⒇⒜⒝⒞⒟⒠⒡⒢⒣⒤⒥⒦⒧⒨⒩⒪⒫⒬⒭⒮⒯⒰⒱⒲⒳⒴⒵🄐🄑🄒🄓🄔🄕🄖🄗🄘🄙🄚🄛🄜🄝🄞🄟🄠🄡🄢🄣🄤🄥🄦🄧🄨🄩"
),
SymbolNode(
catThai,
symbols: [

View File

@ -78,7 +78,7 @@ extension vChewing {
// This function will be implemented only if further hard-necessity comes.
}
public func valuesFor(pair: Megrez.KeyValuePaired) -> [String] {
public func valuesFor(pair: Megrez.Compositor.Candidate) -> [String] {
var pairs: [String] = []
if let arrRangeRecords: [(Range<String.Index>, Int)] = rangeMap[pair.toNGramKey] {
for (netaRange, index) in arrRangeRecords {
@ -98,7 +98,7 @@ extension vChewing {
return pairs.filter { set.insert($0).inserted }
}
public func hasValuesFor(pair: Megrez.KeyValuePaired) -> Bool {
public func hasValuesFor(pair: Megrez.Compositor.Candidate) -> Bool {
if rangeMap[pair.toNGramKey] != nil { return true }
return rangeMap[pair.value] != nil
}

View File

@ -319,8 +319,8 @@ extension vChewing.LMUserOverride {
//
let strCurrent = kvCurrent.key
var kvPrevious = Megrez.KeyValuePaired()
var kvAnterior = Megrez.KeyValuePaired()
var kvPrevious = Megrez.Compositor.Candidate()
var kvAnterior = Megrez.Compositor.Candidate()
var readingStack = ""
var trigramKey: String { "(\(kvAnterior.toNGramKey),\(kvPrevious.toNGramKey),\(strCurrent))" }
var result: String {

View File

@ -285,7 +285,9 @@ enum mgrLangModel {
/// - Parameter mode:
/// - Returns: URL
static func userOverrideModelDataURL(_ mode: InputMode) -> URL {
let fileName = (mode == InputMode.imeModeCHT) ? "override-model-data-cht.dat" : "override-model-data-chs.dat"
let fileName =
(mode == InputMode.imeModeCHT)
? "../vChewing_override-model-data-cht.dat" : "../vChewing_override-model-data-chs.dat"
return URL(fileURLWithPath: dataFolderPath(isDefaultFolder: true)).appendingPathComponent(fileName)
}
@ -354,7 +356,7 @@ enum mgrLangModel {
folderPath?.ensureTrailingSlash()
}
let isFolderWritable = FileManager.default.isWritableFile(atPath: folderPath ?? "")
// IME.prtDebugIntel("mgrLM: Exist: \(folderExist), IsFolder: \(isFolder.boolValue), isWritable: \(isFolderWritable)")
if ((folderExist && !isFolder.boolValue) || !folderExist) || !isFolderWritable {
return false
}
@ -423,6 +425,7 @@ enum mgrLangModel {
return userDictPathDefault
}
if mgrPrefs.ifSpecifiedUserDataPathExistsInPlist() {
BookmarkManager.shared.loadBookmarks()
if mgrLangModel.checkIfSpecifiedUserDataFolderValid(userDictPathSpecified) {
return userDictPathSpecified
} else {

View File

@ -72,14 +72,15 @@ struct suiPrefPaneDictionary: View {
if let window = ctlPrefUI.shared.controller.window {
IME.dlgOpenPath.beginSheetModal(for: window) { result in
if result == NSApplication.ModalResponse.OK {
if IME.dlgOpenPath.url != nil {
guard let url = IME.dlgOpenPath.url else { return }
// CommonDialog
//
var newPath = IME.dlgOpenPath.url!.path
var newPath = url.path
newPath.ensureTrailingSlash()
if mgrLangModel.checkIfSpecifiedUserDataFolderValid(newPath) {
mgrPrefs.userDataFolderSpecified = newPath
tbxUserDataPathSpecified = mgrPrefs.userDataFolderSpecified
BookmarkManager.shared.saveBookmark(for: url)
IME.initLangModels(userOnly: true)
(NSApplication.shared.delegate as! AppDelegate).updateStreamHelperPath()
} else {
@ -89,7 +90,6 @@ struct suiPrefPaneDictionary: View {
}
return
}
}
} else {
if !bolPreviousFolderValidity {
mgrPrefs.resetSpecifiedUserDataFolder()

View File

@ -41,6 +41,8 @@ struct suiPrefPaneExperience: View {
forKey: UserDef.kSpecifyIntonationKeyBehavior.rawValue)
@State private var selSpecifyShiftBackSpaceKeyBehavior = UserDefaults.standard.integer(
forKey: UserDef.kSpecifyShiftBackSpaceKeyBehavior.rawValue)
@State private var selTrimUnfinishedReadingsOnCommit = UserDefaults.standard.bool(
forKey: UserDef.kTrimUnfinishedReadingsOnCommit.rawValue)
private let contentMaxHeight: Double = 432
private let contentWidth: Double = {
@ -220,6 +222,12 @@ struct suiPrefPaneExperience: View {
mgrPrefs.keepReadingUponCompositionError = selKeepReadingUponCompositionError
}
)
Toggle(
LocalizedStringKey("Trim unfinished readings on commit"),
isOn: $selTrimUnfinishedReadingsOnCommit.onChange {
mgrPrefs.trimUnfinishedReadingsOnCommit = selTrimUnfinishedReadingsOnCommit
}
)
Toggle(
LocalizedStringKey("Emulating select-candidate-per-character mode"),
isOn: $selEnableSCPCTypingMode.onChange {

View File

@ -20,6 +20,11 @@ public class TooltipController: NSWindowController {
case prompt
}
public enum displayDirection {
case horizontal
case vertical
}
private var backgroundColor = NSColor.windowBackgroundColor
private var textColor = NSColor.windowBackgroundColor
private var messageTextField: NSTextField
@ -30,6 +35,8 @@ public class TooltipController: NSWindowController {
}
}
public var direction: displayDirection = .horizontal
public init() {
let contentRect = NSRect(x: 128.0, y: 128.0, width: 300.0, height: 20.0)
let styleMask: NSWindow.StyleMask = [.borderless, .nonactivatingPanel]
@ -157,6 +164,7 @@ public class TooltipController: NSWindowController {
var rect = attrString.boundingRect(
with: NSSize(width: 1600.0, height: 1600.0), options: .usesLineFragmentOrigin
)
rect.size.width += 10
messageTextField.frame = rect
window?.setFrame(rect, display: true)

View File

@ -11,7 +11,7 @@
import Cocoa
import InputMethodKit
let kConnectionName = "vChewing_1_Connection"
let kConnectionName = "org.atelierInmu.inputmethod.vChewing_Connection"
switch max(CommandLine.arguments.count - 1, 0) {
case 0: break

View File

@ -195,6 +195,7 @@
"Stop farting (when typed phonetic combination is invalid, etc.)" = "Stop farting (when typed phonetic combination is invalid, etc.)";
"This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later." = "This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later.";
"Traditional Chinese" = "Traditional Chinese";
"Trim unfinished readings on commit" = "Trim unfinished readings on commit";
"Type them into inline composition buffer" = "Type them into inline composition buffer";
"Typing Style:" = "Typing Style:";
"UI Language:" = "UI Language:";

View File

@ -90,7 +90,7 @@
</array>
</dict>
<key>InputMethodConnectionName</key>
<string>vChewing_1_Connection</string>
<string>org.atelierInmu.inputmethod.vChewing_Connection</string>
<key>InputMethodServerControllerClass</key>
<string>ctlInputMethod</string>
<key>InputMethodServerDelegateClass</key>

View File

@ -195,6 +195,7 @@
"Stop farting (when typed phonetic combination is invalid, etc.)" = "Stop farting (when typed phonetic combination is invalid, etc.)";
"This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later." = "This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later.";
"Traditional Chinese" = "Traditional Chinese";
"Trim unfinished readings on commit" = "Trim unfinished readings on commit";
"Type them into inline composition buffer" = "Type them into inline composition buffer";
"Typing Style:" = "Typing Style:";
"UI Language:" = "UI Language:";

View File

@ -195,6 +195,7 @@
"Stop farting (when typed phonetic combination is invalid, etc.)" = "マナーモード // 外すと入力間違った時に変な声が出る";
"This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later." = "これは Apple Bug Report #FB10978412 の臨時対策であり、macOS 12 からの macOS に効き、IMK 以外の候補陳列ウィンドウに作用する。Apple は macOS 11 からの macOS のために該当 Bug を修復すべきである。";
"Traditional Chinese" = "繁体中国語";
"Trim unfinished readings on commit" = "送り出す緩衝列内容から未完成な音読みを除く";
"Type them into inline composition buffer" = "入力緩衝列にローマ字入力";
"Typing Style:" = "入力習慣:";
"UI Language:" = "表示用言語:";

View File

@ -195,6 +195,7 @@
"Stop farting (when typed phonetic combination is invalid, etc.)" = "廉耻模式 // 取消勾选的话,敲错字时会有异音";
"This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later." = "该方法是 Apple Bug Report #FB10978412 的保守治疗方案,用来仅针对 macOS 12 开始的系统,且仅对非 IMK 选字窗起作用。Apple 应该对 macOS 11 开始的系统修复这个 Bug。";
"Traditional Chinese" = "繁体中文";
"Trim unfinished readings on commit" = "在递交时清理未完成拼写的读音";
"Type them into inline composition buffer" = "直接键入内文组字区";
"Typing Style:" = "输入风格:";
"UI Language:" = "介面语言:";

View File

@ -195,6 +195,7 @@
"Stop farting (when typed phonetic combination is invalid, etc.)" = "廉恥模式 // 取消勾選的話,敲錯字時會有異音";
"This only works since macOS 12 with non-IMK candidate window as an alternative wordaround of Apple Bug Report #FB10978412. Apple should patch that for macOS 11 and later." = "該方法是 Apple Bug Report #FB10978412 的保守治療方案,用來僅針對 macOS 12 開始的系統,且僅對非 IMK 選字窗起作用。Apple 應該對 macOS 11 開始的系統修復這個 Bug。";
"Traditional Chinese" = "繁體中文";
"Trim unfinished readings on commit" = "在遞交時清理未完成拼寫的讀音";
"Type them into inline composition buffer" = "直接鍵入內文組字區";
"Typing Style:" = "輸入風格:";
"UI Language:" = "介面語言:";

View File

@ -293,13 +293,14 @@ class ctlPrefWindow: NSWindowController {
IME.dlgOpenPath.beginSheetModal(for: window) { result in
if result == NSApplication.ModalResponse.OK {
if IME.dlgOpenPath.url != nil {
guard let url = IME.dlgOpenPath.url else { return }
// CommonDialog
//
var newPath = IME.dlgOpenPath.url!.path
var newPath = url.path
newPath.ensureTrailingSlash()
if mgrLangModel.checkIfSpecifiedUserDataFolderValid(newPath) {
mgrPrefs.userDataFolderSpecified = newPath
BookmarkManager.shared.saveBookmark(for: url)
IME.initLangModels(userOnly: true)
(NSApplication.shared.delegate as! AppDelegate).updateStreamHelperPath()
} else {
@ -309,7 +310,6 @@ class ctlPrefWindow: NSWindowController {
}
return
}
}
} else {
if !bolPreviousFolderValidity {
mgrPrefs.resetSpecifiedUserDataFolder()

View File

@ -266,10 +266,10 @@
</customSpacing>
</stackView>
<stackView distribution="fill" orientation="vertical" alignment="leading" spacing="9" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="VOm-nN-5IB">
<rect key="frame" x="410" y="30" width="386" height="282"/>
<rect key="frame" x="410" y="9" width="386" height="303"/>
<subviews>
<stackView distribution="fill" orientation="vertical" alignment="leading" spacing="7" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="s47-wG-vKA">
<rect key="frame" x="0.0" y="199" width="386" height="83"/>
<rect key="frame" x="0.0" y="220" width="386" height="83"/>
<subviews>
<textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="iCL-n8-VTP">
<rect key="frame" x="-2" y="68" width="323" height="15"/>
@ -319,7 +319,7 @@
</customSpacing>
</stackView>
<stackView distribution="fill" orientation="vertical" alignment="leading" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="NOW-jd-XBh">
<rect key="frame" x="0.0" y="129" width="386" height="61"/>
<rect key="frame" x="0.0" y="150" width="386" height="61"/>
<subviews>
<textField verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="J0f-Aw-dxC">
<rect key="frame" x="-2" y="46" width="336" height="15"/>
@ -365,10 +365,10 @@
</customSpacing>
</stackView>
<stackView distribution="fill" orientation="vertical" alignment="leading" spacing="6" horizontalStackHuggingPriority="249.99998474121094" verticalStackHuggingPriority="249.99998474121094" detachesHiddenViews="YES" translatesAutoresizingMaskIntoConstraints="NO" id="jxD-fv-UYx">
<rect key="frame" x="0.0" y="0.0" width="380" height="120"/>
<rect key="frame" x="0.0" y="0.0" width="380" height="141"/>
<subviews>
<button translatesAutoresizingMaskIntoConstraints="NO" id="109">
<rect key="frame" x="-1" y="104.5" width="285" height="16"/>
<rect key="frame" x="-1" y="125.5" width="285" height="16"/>
<buttonCell key="cell" type="check" title="Enable Space key for calling candidate window" bezelStyle="regularSquare" imagePosition="left" alignment="left" controlSize="small" state="on" inset="2" id="110">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -378,7 +378,7 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="bE0-Lq-Pj7">
<rect key="frame" x="-1" y="83.5" width="266" height="16"/>
<rect key="frame" x="-1" y="104.5" width="266" height="16"/>
<buttonCell key="cell" type="check" title="Use ESC key to clear the entire input buffer" bezelStyle="regularSquare" imagePosition="left" controlSize="small" state="on" inset="2" id="f2j-xD-4xK">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -388,7 +388,7 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="mzw-F2-aAQ">
<rect key="frame" x="-1" y="62.5" width="295" height="16"/>
<rect key="frame" x="-1" y="83.5" width="295" height="16"/>
<buttonCell key="cell" type="check" title="Emulating select-candidate-per-character mode" bezelStyle="regularSquare" imagePosition="left" controlSize="small" inset="2" id="ArK-Vk-OoT">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -398,7 +398,7 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="j8R-Hj-3dj">
<rect key="frame" x="-1" y="41.5" width="340" height="16"/>
<rect key="frame" x="-1" y="62.5" width="340" height="16"/>
<buttonCell key="cell" type="check" title="Automatically correct reading combinations when typing" bezelStyle="regularSquare" imagePosition="left" controlSize="small" inset="2" id="chkAutoCorrectReadingCombination">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -408,7 +408,7 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="6MM-WC-Mpd">
<rect key="frame" x="-1" y="20.5" width="381" height="16"/>
<rect key="frame" x="-1" y="41.5" width="381" height="16"/>
<buttonCell key="cell" type="check" title="Allow using Enter key to confirm associated candidate selection" bezelStyle="regularSquare" imagePosition="left" controlSize="small" inset="2" id="chkAlsoConfirmAssociatedCandidatesByEnter">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -418,7 +418,7 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="HaB-rc-AcW">
<rect key="frame" x="-1" y="-0.5" width="295" height="16"/>
<rect key="frame" x="-1" y="20.5" width="295" height="16"/>
<buttonCell key="cell" type="check" title="Allow backspace-editing miscomposed readings" bezelStyle="regularSquare" imagePosition="left" controlSize="small" inset="2" id="chkKeepReadingUponCompositionError">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
@ -427,6 +427,16 @@
<binding destination="32" name="value" keyPath="values.KeepReadingUponCompositionError" id="ddF-qg-jes"/>
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="xe6-Pu-3Fa">
<rect key="frame" x="-1" y="-0.5" width="223" height="16"/>
<buttonCell key="cell" type="check" title="Trim unfinished readings on commit" bezelStyle="regularSquare" imagePosition="left" controlSize="small" inset="2" id="tglTrimUnfinishedReadingsOnCommit">
<behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
<font key="font" metaFont="cellTitle"/>
</buttonCell>
<connections>
<binding destination="32" name="value" keyPath="values.TrimUnfinishedReadingsOnCommit" id="v0T-cw-dzA"/>
</connections>
</button>
</subviews>
<visibilityPriorities>
<integer value="1000"/>
@ -435,6 +445,7 @@
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
<integer value="1000"/>
</visibilityPriorities>
<customSpacing>
<real value="3.4028234663852886e+38"/>
@ -443,6 +454,7 @@
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
<real value="3.4028234663852886e+38"/>
</customSpacing>
</stackView>
</subviews>
@ -810,7 +822,7 @@
<rect key="frame" x="20" y="222" width="405" height="21"/>
<subviews>
<button wantsLayer="YES" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="MPN-np-SbT" userLabel="btnOpenFolderToSpecifyForUserData">
<rect key="frame" x="346" y="0.0" width="30" height="19"/>
<rect key="frame" x="346" y="0.0" width="30" height="21"/>
<constraints>
<constraint firstAttribute="height" constant="19" id="BjU-G3-RBx"/>
<constraint firstAttribute="width" constant="30" id="T0S-6A-QBe"/>
@ -824,7 +836,7 @@
</buttonCell>
</button>
<button wantsLayer="YES" verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="jXe-xz-9Sd" userLabel="btnOpenFolderToSpecifyForUserData">
<rect key="frame" x="375" y="0.0" width="30" height="19"/>
<rect key="frame" x="375" y="0.0" width="30" height="21"/>
<constraints>
<constraint firstAttribute="width" constant="30" id="k59-3x-inJ"/>
<constraint firstAttribute="height" constant="19" id="rUV-D4-dXJ"/>
@ -838,7 +850,7 @@
</connections>
</button>
<textField verticalHuggingPriority="750" horizontalCompressionResistancePriority="250" textCompletion="NO" translatesAutoresizingMaskIntoConstraints="NO" id="s7t-Kk-EPu">
<rect key="frame" x="0.0" y="0.0" width="347" height="21"/>
<rect key="frame" x="0.0" y="1" width="347" height="20"/>
<textFieldCell key="cell" controlSize="small" scrollable="YES" lineBreakMode="clipping" selectable="YES" allowsUndo="NO" borderStyle="border" baseWritingDirection="leftToRight" alignment="left" drawsBackground="YES" usesSingleLineMode="YES" id="REC-r4-T7m">
<font key="font" metaFont="cellTitle"/>
<color key="textColor" name="labelColor" catalog="System" colorSpace="catalog"/>

View File

@ -90,6 +90,7 @@
"s7u-Fm-dVg.title" = "Cycling Pages";
"shc-Nu-UsM.title" = "Show page buttons in candidate list";
"tglDevZoneIMKCandidate.title" = "Use IMK Candidate Window instead (will reboot the IME)";
"tglTrimUnfinishedReadingsOnCommit.title" = "Trim unfinished readings on commit";
"TXr-FF-ehw.title" = "Traditional Chinese";
"ueU-Rz-a1C.title" = "Choose the behavior of (Shift+)Tab key in the candidate window.";
"VdT-fw-7pQ.title" = "Debug Mode";

View File

@ -90,6 +90,7 @@
"s7u-Fm-dVg.title" = "ページ";
"shc-Nu-UsM.title" = "ページボタンを表示";
"tglDevZoneIMKCandidate.title" = "IMK 候補陳列ウィンドウを起用(入力アプリは自動的に再起動)";
"tglTrimUnfinishedReadingsOnCommit.title" = "送り出す緩衝列内容から未完成な音読みを除く";
"TXr-FF-ehw.title" = "繁体中国語";
"ueU-Rz-a1C.title" = "入力候補陳列での (Shift+)Tab キーの輪番切替対象をご指定ください。";
"VdT-fw-7pQ.title" = "欠陥辿着モード";

View File

@ -90,6 +90,7 @@
"s7u-Fm-dVg.title" = "轮替页面";
"shc-Nu-UsM.title" = "在选字窗内显示翻页按钮";
"tglDevZoneIMKCandidate.title" = "启用与 macOS 内建输入法相同的 IMK 选字窗(会自动重启输入法)";
"tglTrimUnfinishedReadingsOnCommit.title" = "在递交时清理未完成拼写的读音";
"TXr-FF-ehw.title" = "繁体中文";
"ueU-Rz-a1C.title" = "指定 (Shift+)Tab 热键在选字窗内的轮替操作对象。";
"VdT-fw-7pQ.title" = "侦错模式";

View File

@ -90,6 +90,7 @@
"s7u-Fm-dVg.title" = "輪替頁面";
"shc-Nu-UsM.title" = "在選字窗內顯示翻頁按鈕";
"tglDevZoneIMKCandidate.title" = "啟用與 macOS 內建輸入法相同的 IMK 選字窗(會自動重啟輸入法)";
"tglTrimUnfinishedReadingsOnCommit.title" = "在遞交時清理未完成拼寫的讀音";
"TXr-FF-ehw.title" = "繁體中文";
"ueU-Rz-a1C.title" = "指定 (Shift+)Tab 熱鍵在選字窗內的輪替操作對象。";
"VdT-fw-7pQ.title" = "偵錯模式";

View File

@ -3,9 +3,9 @@
<plist version="1.0">
<dict>
<key>CFBundleShortVersionString</key>
<string>2.2.0</string>
<string>2.3.0</string>
<key>CFBundleVersion</key>
<string>2201</string>
<string>2300</string>
<key>UpdateInfoEndpoint</key>
<string>https://gitee.com/vchewing/vChewing-macOS/raw/main/Update-Info.plist</string>
<key>UpdateInfoSite</key>

13
fixinstall.sh Normal file
View File

@ -0,0 +1,13 @@
#!/bin/sh
# Here's how to fix this input method, removing unnecessary files outside of the user directory:
sudo rm -rf /Library/Input\ Methods/vChewing.app
sudo rm -rf /Library/Keyboard\ Layouts/vChewingKeyLayout.bundle
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ MiTAC.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ IBM.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ FakeSeigyou.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ ETen.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ Dachen.keylayout
sudo rm -rf /Library/Receipts/org.atelierInmu.vChewing.bom
sudo rm -rf /Library/Receipts/org.atelierInmu.vChewing.plist

View File

@ -13,10 +13,13 @@ rm ~/Library/Keyboard\ Layouts/vChewing\ IBM.keylayout
rm ~/Library/Keyboard\ Layouts/vChewing\ FakeSeigyou.keylayout
rm ~/Library/Keyboard\ Layouts/vChewing\ ETen.keylayout
rm ~/Library/Keyboard\ Layouts/vChewing\ Dachen.keylayout
rm ~/Library/Receipts/org.atelierInmu.vChewing.bom
rm ~/Library/Receipts/org.atelierInmu.vChewing.plist
# Also user phrase folder:
# 原廠預設的使用者辭典目錄:
rm -rf ~/Library/Application\ Support/vChewing/
# 原廠預設的使用者辭典目錄不自動刪除了,讓使用者自己刪:
# rm -rf ~/Library/Application\ Support/vChewing/
# rm -rf /Users/shikisuen/Library/Containers/org.atelierInmu.inputmethod.vChewing/Data/Library/Application\ Support/vChewing/
# Also the IME configuration file:
# 輸入法偏好設定檔案:
@ -35,6 +38,8 @@ sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ IBM.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ FakeSeigyou.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ ETen.keylayout
sudo rm -rf /Library/Keyboard\ Layouts/vChewing\ Dachen.keylayout
sudo rm -rf /Library/Receipts/org.atelierInmu.vChewing.bom
sudo rm -rf /Library/Receipts/org.atelierInmu.vChewing.plist
# P.S.: The "vChewingKeyLayout.bundle" and keylayout files are deployed by the pkg installer. They are not hard-requirements for running vChewing, but providing extended on-screen keyboard for MiTAC, IBM, FakeSeigyou phonetic layouts.
# P.S.: 「vChewingKeyLayout.bundle」與 keylayout 檔案只會被 pkg 格式的安裝包安裝。這些檔案提供了除了大千傳統與倚天傳統以外的靜態注音排列的螢幕鍵盤支援。

22
vChewing.entitlements Normal file
View File

@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.security.app-sandbox</key>
<true/>
<key>com.apple.security.files.bookmarks.app-scope</key>
<true/>
<key>com.apple.security.files.user-selected.read-write</key>
<true/>
<key>com.apple.security.network.client</key>
<true/>
<key>com.apple.security.temporary-exception.files.home-relative-path.read-write</key>
<array>
<string>/</string>
</array>
<key>com.apple.security.temporary-exception.mach-register.global-name</key>
<string>org.atelierInmu.inputmethod.vChewing_Connection</string>
<key>com.apple.security.temporary-exception.shared-preference.read-only</key>
<string>org.atelierInmu.inputmethod.vChewing</string>
</dict>
</plist>

View File

@ -726,7 +726,7 @@
<key>USE_HFS+_COMPRESSION</key>
<false/>
<key>VERSION</key>
<string>2.2.0</string>
<string>2.3.0</string>
</dict>
<key>TYPE</key>
<integer>0</integer>

View File

@ -10,6 +10,7 @@
5B09307628B6FC3B0021F8C5 /* shortcuts.html in Resources */ = {isa = PBXBuildFile; fileRef = 5B09307828B6FC3B0021F8C5 /* shortcuts.html */; };
5B0AF8B527B2C8290096FE54 /* StringExtension.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B0AF8B427B2C8290096FE54 /* StringExtension.swift */; };
5B11328927B94CFB00E58451 /* AppleKeyboardConverter.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B11328827B94CFB00E58451 /* AppleKeyboardConverter.swift */; };
5B20430728BEE30900BFC6FD /* BookmarkManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B20430628BEE30900BFC6FD /* BookmarkManager.swift */; };
5B21176C287539BB000443A9 /* ctlInputMethod_HandleStates.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B21176B287539BB000443A9 /* ctlInputMethod_HandleStates.swift */; };
5B21176E28753B35000443A9 /* ctlInputMethod_HandleDisplay.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B21176D28753B35000443A9 /* ctlInputMethod_HandleDisplay.swift */; };
5B21177028753B9D000443A9 /* ctlInputMethod_Delegates.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B21176F28753B9D000443A9 /* ctlInputMethod_Delegates.swift */; };
@ -44,6 +45,7 @@
5B782EC4280C243C007276DE /* KeyHandler_HandleCandidate.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B782EC3280C243C007276DE /* KeyHandler_HandleCandidate.swift */; };
5B78EE0D28A562B4009456C1 /* suiPrefPaneDevZone.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B78EE0C28A562B4009456C1 /* suiPrefPaneDevZone.swift */; };
5B7BC4B027AFFBE800F66C24 /* frmPrefWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = 5B7BC4AE27AFFBE800F66C24 /* frmPrefWindow.xib */; };
5B7DA80328BF6BC600D7B2AD /* fixinstall.sh in Resources */ = {isa = PBXBuildFile; fileRef = 5B7DA80228BF6BBA00D7B2AD /* fixinstall.sh */; };
5B7F225D2808501000DDD3CB /* KeyHandler_HandleInput.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B7F225C2808501000DDD3CB /* KeyHandler_HandleInput.swift */; };
5B84579E2871AD2200C93B01 /* convdict.plist in Resources */ = {isa = PBXBuildFile; fileRef = 5B84579C2871AD2200C93B01 /* convdict.plist */; };
5B84579F2871AD2200C93B01 /* HotenkaChineseConverter.swift in Sources */ = {isa = PBXBuildFile; fileRef = 5B84579D2871AD2200C93B01 /* HotenkaChineseConverter.swift */; };
@ -217,6 +219,10 @@
5B18BA7227C7BD8B0056EB19 /* LICENSE.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = LICENSE.txt; sourceTree = "<group>"; };
5B18BA7327C7BD8C0056EB19 /* LICENSE-JPN.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = "LICENSE-JPN.txt"; sourceTree = "<group>"; };
5B18BA7427C7BD8C0056EB19 /* LICENSE-CHT.txt */ = {isa = PBXFileReference; lastKnownFileType = text; path = "LICENSE-CHT.txt"; sourceTree = "<group>"; };
5B20430628BEE30900BFC6FD /* BookmarkManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = BookmarkManager.swift; sourceTree = "<group>"; };
5B20430B28BEFC0C00BFC6FD /* vChewing.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = vChewing.entitlements; sourceTree = "<group>"; };
5B20430C28BEFC1200BFC6FD /* vChewingPhraseEditor.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = vChewingPhraseEditor.entitlements; sourceTree = "<group>"; };
5B20430D28BF279900BFC6FD /* vChewingInstaller.entitlements */ = {isa = PBXFileReference; lastKnownFileType = text.plist.entitlements; path = vChewingInstaller.entitlements; sourceTree = "<group>"; };
5B21176B287539BB000443A9 /* ctlInputMethod_HandleStates.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ctlInputMethod_HandleStates.swift; sourceTree = "<group>"; };
5B21176D28753B35000443A9 /* ctlInputMethod_HandleDisplay.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ctlInputMethod_HandleDisplay.swift; sourceTree = "<group>"; };
5B21176F28753B9D000443A9 /* ctlInputMethod_Delegates.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ctlInputMethod_Delegates.swift; sourceTree = "<group>"; };
@ -257,6 +263,7 @@
5B78EE0C28A562B4009456C1 /* suiPrefPaneDevZone.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = suiPrefPaneDevZone.swift; sourceTree = "<group>"; };
5B7BC4AF27AFFBE800F66C24 /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = Base; path = Base.lproj/frmPrefWindow.xib; sourceTree = "<group>"; };
5B7BC4B227AFFC0B00F66C24 /* en */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = en; path = en.lproj/frmPrefWindow.strings; sourceTree = "<group>"; };
5B7DA80228BF6BBA00D7B2AD /* fixinstall.sh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.script.sh; lineEnding = 0; path = fixinstall.sh; sourceTree = "<group>"; };
5B7F225C2808501000DDD3CB /* KeyHandler_HandleInput.swift */ = {isa = PBXFileReference; explicitFileType = sourcecode.swift; fileEncoding = 4; indentWidth = 2; lineEnding = 0; path = KeyHandler_HandleInput.swift; sourceTree = "<group>"; tabWidth = 2; usesTabs = 0; };
5B84579C2871AD2200C93B01 /* convdict.plist */ = {isa = PBXFileReference; lastKnownFileType = file.bplist; path = convdict.plist; sourceTree = "<group>"; };
5B84579D2871AD2200C93B01 /* HotenkaChineseConverter.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = HotenkaChineseConverter.swift; sourceTree = "<group>"; };
@ -413,6 +420,7 @@
5B18BA7527C7BF6D0056EB19 /* MiscRootFiles */ = {
isa = PBXGroup;
children = (
5B7DA80228BF6BBA00D7B2AD /* fixinstall.sh */,
5BC2652127E04B7B00700291 /* uninstall.sh */,
5BC447AB2865BEF500EDC323 /* AUTHORS */,
5BE8A8C4281EE65300197741 /* CONTRIBUTING.md */,
@ -427,6 +435,14 @@
name = MiscRootFiles;
sourceTree = "<group>";
};
5B20430528BEE2F300BFC6FD /* Sandbox */ = {
isa = PBXGroup;
children = (
5B20430628BEE30900BFC6FD /* BookmarkManager.swift */,
);
path = Sandbox;
sourceTree = "<group>";
};
5B2F2BB4286216A500B8557B /* vChewingTests */ = {
isa = PBXGroup;
children = (
@ -457,6 +473,7 @@
5B84579B2871AD2200C93B01 /* HotenkaChineseConverter */,
5B949BD72816DC4400D87B5D /* LineReader */,
5BA58644289BCFAC0077D02F /* Qwertyyb */,
5B20430528BEE2F300BFC6FD /* Sandbox */,
5BA9FCEA27FED652002DE248 /* SindreSorhus */,
5BA9FD8C28006BA7002DE248 /* VDKComboBox */,
);
@ -778,6 +795,9 @@
6A0D4E9215FC0CFA00ABF4B3 = {
isa = PBXGroup;
children = (
5B20430D28BF279900BFC6FD /* vChewingInstaller.entitlements */,
5B20430C28BEFC1200BFC6FD /* vChewingPhraseEditor.entitlements */,
5B20430B28BEFC0C00BFC6FD /* vChewing.entitlements */,
5BBD627827B6C4D900271480 /* Update-Info.plist */,
5B18BA7027C7BD8B0056EB19 /* Makefile */,
5B0C5EDE27C7D94C0078037C /* DataCompiler */,
@ -1045,6 +1065,7 @@
5BBBB77427AED70B0023B93A /* MenuIcon-SCVIM@2x.png in Resources */,
D4E33D8A27A838CF006DB1CF /* Localizable.strings in Resources */,
5BF9DA2828840E6200DBD48E /* template-exclusions.txt in Resources */,
5B7DA80328BF6BC600D7B2AD /* fixinstall.sh in Resources */,
5BDCBB2E27B4E67A00D0CC59 /* vChewingPhraseEditor.app in Resources */,
5BBBB76027AED54C0023B93A /* Fart.m4a in Resources */,
6A2E40F6253A69DA00D1AE1D /* Images.xcassets in Resources */,
@ -1242,6 +1263,7 @@
5B62A34927AE7CD900A19448 /* TooltipController.swift in Sources */,
5BA9FD4027FEF3C8002DE248 /* Localization.swift in Sources */,
5BAA8FBE282CAF380066C406 /* SyllableComposer.swift in Sources */,
5B20430728BEE30900BFC6FD /* BookmarkManager.swift in Sources */,
5BA9FD1327FEDB6B002DE248 /* suiPrefPaneDictionary.swift in Sources */,
5B2170E8289FACAD00BE7304 /* 5_Vertex.swift in Sources */,
5BBBB77A27AEDC690023B93A /* clsSFX.swift in Sources */,
@ -1449,7 +1471,7 @@
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_PREPROCESSOR_DEFINITIONS = (
@ -1459,7 +1481,7 @@
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewingTests;
@ -1488,13 +1510,13 @@
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
ENABLE_NS_ASSERTIONS = NO;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
GENERATE_INFOPLIST_FILE = YES;
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewingTests;
@ -1522,11 +1544,13 @@
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CODE_SIGN_ENTITLEMENTS = vChewingPhraseEditor.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
ENABLE_HARDENED_RUNTIME = YES;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_DYNAMIC_NO_PIC = NO;
GCC_PREPROCESSOR_DEFINITIONS = (
@ -1546,7 +1570,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewing.vChewingPhraseEditor;
@ -1572,11 +1596,13 @@
CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
CODE_SIGN_ENTITLEMENTS = vChewingPhraseEditor.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
ENABLE_HARDENED_RUNTIME = YES;
ENABLE_NS_ASSERTIONS = NO;
GCC_C_LANGUAGE_STANDARD = gnu11;
GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
@ -1592,7 +1618,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
MTL_ENABLE_DEBUG_INFO = NO;
MTL_FAST_MATH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewing.vChewingPhraseEditor;
@ -1704,13 +1730,15 @@
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_ENTITLEMENTS = vChewing.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
@ -1735,7 +1763,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
ONLY_ACTIVE_ARCH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.inputmethod.vChewing;
PRODUCT_NAME = "$(TARGET_NAME)";
@ -1761,13 +1789,15 @@
CLANG_WARN_OBJC_IMPLICIT_ATOMIC_PROPERTIES = YES;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_ENTITLEMENTS = vChewing.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_ASSET_PATHS = "";
DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
@ -1786,7 +1816,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.inputmethod.vChewing;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
@ -1806,12 +1836,14 @@
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_ENTITLEMENTS = vChewingInstaller.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_DYNAMIC_NO_PIC = NO;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
@ -1829,7 +1861,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
ONLY_ACTIVE_ARCH = YES;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewing.vChewingInstaller;
PRODUCT_NAME = "$(TARGET_NAME)";
@ -1848,12 +1880,14 @@
CLANG_ENABLE_OBJC_ARC = YES;
CLANG_ENABLE_OBJC_WEAK = YES;
CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
CODE_SIGN_ENTITLEMENTS = vChewingInstaller.entitlements;
CODE_SIGN_IDENTITY = "-";
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
CURRENT_PROJECT_VERSION = 2201;
CURRENT_PROJECT_VERSION = 2300;
DEAD_CODE_STRIPPING = YES;
DEVELOPMENT_TEAM = "";
ENABLE_HARDENED_RUNTIME = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_ENABLE_OBJC_EXCEPTIONS = YES;
GCC_TREAT_WARNINGS_AS_ERRORS = YES;
@ -1865,7 +1899,7 @@
"$(inherited)",
"@executable_path/../Frameworks",
);
MARKETING_VERSION = 2.2.0;
MARKETING_VERSION = 2.3.0;
PRODUCT_BUNDLE_IDENTIFIER = org.atelierInmu.vChewing.vChewingInstaller;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";

View File

@ -0,0 +1,14 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.security.files.bookmarks.app-scope</key>
<true/>
<key>com.apple.security.temporary-exception.files.home-relative-path.read-write</key>
<array>
<string>/Library/Input Methods/</string>
</array>
<key>com.apple.security.temporary-exception.shared-preference.read-write</key>
<string>org.atelierInmu.vChewing.vChewingInstaller</string>
</dict>
</plist>

View File

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>com.apple.security.app-sandbox</key>
<true/>
<key>com.apple.security.files.bookmarks.app-scope</key>
<true/>
<key>com.apple.security.files.user-selected.read-write</key>
<true/>
</dict>
</plist>