Skip to content
Permalink
Browse files

Merge branch 'release/3.7.0-beta.3'

  • Loading branch information...
1024jp committed Jan 9, 2019
2 parents a242fa5 + d1e060b commit 050f6e664d9656d485ee3c69457f0e03998ec511
@@ -1,17 +1,8 @@
# ref. http://docs.travis-ci.com/user/languages/objective-c/
language: swift
osx_image: xcode10.1

language: objective-c
osx_image: xcode10

before_install:
- gem install xcpretty

script:
set -o pipefail &&
travis_retry
xcodebuild test
-workspace CotEditor.xcworkspace
-scheme CotEditor
CODE_SIGN_IDENTITY=""
CODE_SIGNING_REQUIRED=NO
| xcpretty
xcode_workspace: CotEditor.xcworkspace
xcode_scheme: CotEditor
xcode_destination: platform=macOS
xcode_sdk: macosx10.14
xcodebuild_args: CODE_SIGNING_REQUIRED=NO CODE_SIGN_IDENTITY="" CODE_SIGN_ENTITLEMENTS="" CODE_SIGNING_ALLOWED=YES ENABLE_HARDENED_RUNTIME=NO
@@ -2,6 +2,27 @@
Change Log
==========================

3.7.0-beta.3 (325)
--------------------------

### Improvements

- [beta] Support commenting-out/uncommenting in multi-cursor editing.
- [beta] Support `^T` and `fn+delete` (`^D`) shortcut in multi-cursor editing.


### Fixes

- [beta] Fix an issue where multiple cursors disappeared after (auto-)saving with “trim trailing whitespace on save” option.
- [beta] Fix an issue where the first cursor could disappear after some specific text editing.
- [beta] Fix an issue where auto-inserted tab did not expand to spaces on auto indent level adjustment.
- [beta] Fix multi-cursor behavior of deleting to the beginning of the visual line by `⌘⌫`.
- [beta] Fix multi-cursor movement when encountering a surrogate pair.
- [beta] Fix an issue where a selected range and an insertion point could overlap.
- [beta] Fix an issue where the appliation could rarely crash after moving cursors.



3.7.0-beta.2 (323)
--------------------------

@@ -314,8 +314,8 @@
2A6FD9E81D394F5900A59784 /* LayoutManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9E61D394F5900A59784 /* LayoutManager.swift */; };
2A6FD9EA1D3A819500A59784 /* EditorTextView+Commenting.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9E91D3A819500A59784 /* EditorTextView+Commenting.swift */; };
2A6FD9EB1D3A819500A59784 /* EditorTextView+Commenting.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9E91D3A819500A59784 /* EditorTextView+Commenting.swift */; };
2A6FD9ED1D3A85D700A59784 /* String+NSRange.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9EC1D3A85D700A59784 /* String+NSRange.swift */; };
2A6FD9EE1D3A85D700A59784 /* String+NSRange.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9EC1D3A85D700A59784 /* String+NSRange.swift */; };
2A6FD9ED1D3A85D700A59784 /* NSString.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9EC1D3A85D700A59784 /* NSString.swift */; };
2A6FD9EE1D3A85D700A59784 /* NSString.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9EC1D3A85D700A59784 /* NSString.swift */; };
2A6FD9F31D3ACEB500A59784 /* DefaultKey.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9F21D3ACEB500A59784 /* DefaultKey.swift */; };
2A6FD9F41D3ACEB500A59784 /* DefaultKey.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9F21D3ACEB500A59784 /* DefaultKey.swift */; };
2A6FD9F61D3AE29E00A59784 /* SyntaxStyle.swift in Sources */ = {isa = PBXBuildFile; fileRef = 2A6FD9F51D3AE29E00A59784 /* SyntaxStyle.swift */; };
@@ -1048,7 +1048,7 @@
2A6FD9DF1D393F9100A59784 /* SplitViewController.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SplitViewController.swift; sourceTree = "<group>"; };
2A6FD9E61D394F5900A59784 /* LayoutManager.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = LayoutManager.swift; sourceTree = "<group>"; };
2A6FD9E91D3A819500A59784 /* EditorTextView+Commenting.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "EditorTextView+Commenting.swift"; sourceTree = "<group>"; };
2A6FD9EC1D3A85D700A59784 /* String+NSRange.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = "String+NSRange.swift"; sourceTree = "<group>"; };
2A6FD9EC1D3A85D700A59784 /* NSString.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = NSString.swift; sourceTree = "<group>"; };
2A6FD9F21D3ACEB500A59784 /* DefaultKey.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = DefaultKey.swift; sourceTree = "<group>"; };
2A6FD9F51D3AE29E00A59784 /* SyntaxStyle.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = SyntaxStyle.swift; sourceTree = "<group>"; };
2A7135821CFFDC6600ADA555 /* FormattersTests.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = FormattersTests.swift; sourceTree = "<group>"; };
@@ -1756,7 +1756,6 @@
2AE73F3C2039A29300D8903B /* URL+ExtendedAttribute.swift */,
2A2792941D1DBDAC00F3FC5D /* String+Constants.swift */,
2AAD61FB1D2BD102008FE772 /* String+Additions.swift */,
2A6FD9EC1D3A85D700A59784 /* String+NSRange.swift */,
2AA761341D45634400031AAF /* String+Counting.swift */,
2A9BF3CA1D3842FA00E3D3E2 /* String+Normalization.swift */,
2A9BF3C61D38325200E3D3E2 /* String+JapaneseTransformation.swift */,
@@ -1766,6 +1765,7 @@
2AA761391D457BD500031AAF /* String+Indentation.swift */,
2A887A8F20FA1D19002BFA34 /* String+Localization.swift */,
2AEDB41E1D462EAB0020AD15 /* String+Sandboxing.swift */,
2A6FD9EC1D3A85D700A59784 /* NSString.swift */,
2AE3F3171D3F8A1F005B8724 /* NSAttributedString.swift */,
2AF1D85721B8D9250060BC04 /* NSRegularExpression+Additions.swift */,
2A9082EB1D325BEC00228F50 /* UserDefaults.swift */,
@@ -2845,7 +2845,7 @@
2A0BF8A91DD8E7F90088961B /* TextSizeTouchBar.swift in Sources */,
2A1814BC21CF8F3800602214 /* RegularExpressionSyntaxType+Color.swift in Sources */,
2A4714EA209717C90093E27F /* DispatchQueue+Throttle.swift in Sources */,
2A6FD9EE1D3A85D700A59784 /* String+NSRange.swift in Sources */,
2A6FD9EE1D3A85D700A59784 /* NSString.swift in Sources */,
2A91C31F1D1C3963007CF8BE /* PrintPaneController.swift in Sources */,
2AEC48341E641E4F00FB0F89 /* Snippet.swift in Sources */,
2A7646EC1D49035500350674 /* SettingFileManaging.swift in Sources */,
@@ -3251,7 +3251,7 @@
2AA4D3741D1AA0AC001D261D /* KeyBindingsViewController.swift in Sources */,
2A2948B12197FCE0001DCE1E /* ImageRadioButton.swift in Sources */,
2AACB1CD1D195ABD0073775B /* ShortcutKeyField.swift in Sources */,
2A6FD9ED1D3A85D700A59784 /* String+NSRange.swift in Sources */,
2A6FD9ED1D3A85D700A59784 /* NSString.swift in Sources */,
2A733E8920BBB4AC0090D7CB /* String+Case.swift in Sources */,
2AA79C7821CB7251005AD6AD /* PreferencesWindow.swift in Sources */,
2ACFE58B1D20730B0005233A /* FindPanelContentViewController.swift in Sources */,
@@ -28,6 +28,16 @@
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "2AC71DDE1BF0BDBC002E1434"
BuildableName = "Tests.xctest"
BlueprintName = "Tests"
ReferencedContainer = "container:CotEditor.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
@@ -1025,13 +1025,13 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>3.7.0-beta.2</string>
<string>3.7.0-beta.3</string>
<key>CFBundleSignature</key>
<string>cEd1</string>
<key>CFBundleSpokenName</key>
<string>Cot editor</string>
<key>CFBundleVersion</key>
<string>323</string>
<string>325</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationCategoryType</key>
@@ -1025,13 +1025,13 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>3.7.0-beta.2</string>
<string>3.7.0-beta.3</string>
<key>CFBundleSignature</key>
<string>cEd1</string>
<key>CFBundleSpokenName</key>
<string>Cot editor</string>
<key>CFBundleVersion</key>
<string>323</string>
<string>325</string>
<key>ITSAppUsesNonExemptEncryption</key>
<false/>
<key>LSApplicationCategoryType</key>
@@ -8,7 +8,7 @@
//
// ---------------------------------------------------------------------------
//
// © 2016-2018 1024jp
// © 2016-2019 1024jp
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -42,9 +42,9 @@ class DefaultKeys: RawRepresentable, Hashable, CustomStringConvertible {
}


var hashValue: Int {
func hash(into hasher: inout Hasher) {

return self.rawValue.hashValue
hasher.combine(self.rawValue)
}


@@ -9,7 +9,7 @@
// ---------------------------------------------------------------------------
//
// © 2004-2007 nakamuxu
// © 2014-2018 1024jp
// © 2014-2019 1024jp
//
// Licensed under the Apache License, Version 2.0 (the "License");
// you may not use this file except in compliance with the License.
@@ -82,7 +82,6 @@ final class Document: NSDocument, AdditionalDocumentPreparing, EncodingHolder {
private var fileData: Data?
private var shouldSaveXattr = true
private var autosaveIdentifier: String
private var isStab = true // not saved yet
@objc private dynamic var isExecutable = false // bind in save panel accessory view
private var lastSavedData: Data? // temporal data used only within saving process
@@ -313,8 +312,6 @@ final class Document: NSDocument, AdditionalDocumentPreparing, EncodingHolder {
// store file data in order to check the file content identity in `presentedItemDidChange()`
self.fileData = file.data

self.isStab = false

// use file attributes only if `fileURL` exists
// -> The passed-in `url` in this method can point to a file that isn't the real document file,
// for example on resuming an unsaved document.
@@ -458,7 +455,6 @@ final class Document: NSDocument, AdditionalDocumentPreparing, EncodingHolder {
case .saveOperation, .saveAsOperation, .saveToOperation:
self.analyzer.invalidateFileInfo()
ScriptManager.shared.dispatchEvent(documentSaved: self)
self.isStab = false
case .autosaveAsOperation, .autosaveElsewhereOperation, .autosaveInPlaceOperation: break
}
}
@@ -555,9 +551,8 @@ final class Document: NSDocument, AdditionalDocumentPreparing, EncodingHolder {
override func canClose(withDelegate delegate: Any, shouldClose shouldCloseSelector: Selector?, contextInfo: UnsafeMutableRawPointer?) {

var shouldClose = false

// disable save dialog if content is empty and not saved explicitly
if self.isStab, self.textStorage.string.isEmpty {
if (self.isDraft || self.fileURL == nil), self.textStorage.string.isEmpty {
self.updateChangeCount(.changeCleared)

// remove auto-saved file if exists

0 comments on commit 050f6e6

Please sign in to comment.
You can’t perform that action at this time.