Skip to content

Commit f7cc415

Browse files
committed
Add drag-to-snap areas for eighths (rxhanson#1708)
* Add drag-to-snap areas for eighths Adds compound snap area support for eighths (4x2 grid), following the same pattern as sixths. Can be enabled via terminal command or selected in the Snap Areas preferences tab. Terminal command: defaults write com.knollsoft.Rectangle eighthsSnapArea -bool true Particularly useful for ultra-wide monitors. * Remove unused terminal command and migration for eighths The snap area migration only runs for versions < 64, so the terminal command would not take effect on modern installs. Eighths snap areas are configurable directly in the Snap Areas preferences tab. * Add eighths image assets and shortcut recorders Add icon assets for all 8 eighth window positions and wire them up in WindowAction.image. Add shortcut recorders for eighths to the Extra Shortcuts popover in the General tab.
1 parent 42d8c5f commit f7cc415

24 files changed

Lines changed: 533 additions & 21 deletions

File tree

Rectangle.xcodeproj/project.pbxproj

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@
3131
9818E01228B59B64004AA524 /* ThirdsCompoundCalculation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9818E01128B59B64004AA524 /* ThirdsCompoundCalculation.swift */; };
3232
9818E01428B5A4FD004AA524 /* SixthsCompoundCalculation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9818E01328B5A4FD004AA524 /* SixthsCompoundCalculation.swift */; };
3333
9818E01828B63C48004AA524 /* FourthsCompoundCalculation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9818E01728B63C48004AA524 /* FourthsCompoundCalculation.swift */; };
34+
9818E01A28B63C49004AA524 /* EighthsCompoundCalculation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9818E01928B63C49004AA524 /* EighthsCompoundCalculation.swift */; };
3435
98192DDA270F606C00015E66 /* Debounce.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98192DD9270F606C00015E66 /* Debounce.swift */; };
3536
98192DDE2717201100015E66 /* ReverseAllManager.swift in Sources */ = {isa = PBXBuildFile; fileRef = 98192DDD2717201000015E66 /* ReverseAllManager.swift */; };
3637
981F27D12340E3E1006CD263 /* InternetAccessPolicy.plist in Resources */ = {isa = PBXBuildFile; fileRef = 981F27D02340E3E1006CD263 /* InternetAccessPolicy.plist */; };
@@ -209,6 +210,7 @@
209210
9818E01128B59B64004AA524 /* ThirdsCompoundCalculation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ThirdsCompoundCalculation.swift; sourceTree = "<group>"; };
210211
9818E01328B5A4FD004AA524 /* SixthsCompoundCalculation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = SixthsCompoundCalculation.swift; sourceTree = "<group>"; };
211212
9818E01728B63C48004AA524 /* FourthsCompoundCalculation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = FourthsCompoundCalculation.swift; sourceTree = "<group>"; };
213+
9818E01928B63C49004AA524 /* EighthsCompoundCalculation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = EighthsCompoundCalculation.swift; sourceTree = "<group>"; };
212214
98192DD9270F606C00015E66 /* Debounce.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Debounce.swift; sourceTree = "<group>"; };
213215
98192DDD2717201000015E66 /* ReverseAllManager.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = ReverseAllManager.swift; sourceTree = "<group>"; };
214216
981F27D02340E3E1006CD263 /* InternetAccessPolicy.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; path = InternetAccessPolicy.plist; sourceTree = "<group>"; };
@@ -378,6 +380,7 @@
378380
9818E00F28B59396004AA524 /* HalvesCompoundCalculation.swift */,
379381
9818E01128B59B64004AA524 /* ThirdsCompoundCalculation.swift */,
380382
9818E01728B63C48004AA524 /* FourthsCompoundCalculation.swift */,
383+
9818E01928B63C49004AA524 /* EighthsCompoundCalculation.swift */,
381384
9818E01328B5A4FD004AA524 /* SixthsCompoundCalculation.swift */,
382385
);
383386
path = CompoundSnapArea;
@@ -873,6 +876,7 @@
873876
9821402322B3886100ABFB3F /* CenterCalculation.swift in Sources */,
874877
98A009AB2512491300CFBF0C /* CenterHalfCalculation.swift in Sources */,
875878
9818E01828B63C48004AA524 /* FourthsCompoundCalculation.swift in Sources */,
879+
9818E01A28B63C49004AA524 /* EighthsCompoundCalculation.swift in Sources */,
876880
D0CFE33327A8CCB1004DA47B /* TopRightThirdCalculation.swift in Sources */,
877881
94E9B08E2C3B8D97004C7F41 /* MacTilingDefaults.swift in Sources */,
878882
9821403522B38A2B00ABFB3F /* UpperRightCalculation.swift in Sources */,
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "blEighthTemplate.png",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}
1.31 KB
Loading
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "brEighthTemplate.png",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}
1.31 KB
Loading
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "cblEighthTemplate.png",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}
1.32 KB
Loading
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "cbrEighthTemplate.png",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}
1.31 KB
Loading
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
{
2+
"images" : [
3+
{
4+
"filename" : "ctlEighthTemplate.png",
5+
"idiom" : "universal",
6+
"scale" : "1x"
7+
},
8+
{
9+
"idiom" : "universal",
10+
"scale" : "2x"
11+
},
12+
{
13+
"idiom" : "universal",
14+
"scale" : "3x"
15+
}
16+
],
17+
"info" : {
18+
"author" : "xcode",
19+
"version" : 1
20+
}
21+
}

0 commit comments

Comments
 (0)