Skip to content

Commit 32dc672

Browse files
Refactor variable names to be like Xcode
1 parent 9dcc01e commit 32dc672

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

Sources/CodeEditTextView/TextView/TextView+Layout.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ extension TextView {
6565
var availableSize = scrollView?.contentSize ?? .zero
6666
availableSize.height -= (scrollView?.contentInsets.top ?? 0) + (scrollView?.contentInsets.bottom ?? 0)
6767

68-
let extraHeight = scrollPastEnd ? availableSize.height * scrollPastEndAmount : 0
68+
let extraHeight = overscroll ? availableSize.height * overscrollAmount : 0
6969
let newHeight = max(layoutManager.estimatedHeight() + extraHeight, availableSize.height)
7070
let newWidth = layoutManager.estimatedWidth()
7171

Sources/CodeEditTextView/TextView/TextView.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -108,16 +108,16 @@ public class TextView: NSView, NSTextContent {
108108
}
109109

110110
/// Determines if the text view should allow scrolling past the end of the document
111-
public var scrollPastEnd: Bool = true {
111+
public var overscroll: Bool = true {
112112
didSet {
113113
updateFrameIfNeeded()
114114
}
115115
}
116116

117117
/// The amount of extra space to add when scrolling past end is enabled, as a percentage of the viewport height
118-
public var scrollPastEndAmount: CGFloat = 0.5 {
118+
public var overscrollAmount: CGFloat = 0.5 {
119119
didSet {
120-
if scrollPastEnd {
120+
if overscroll {
121121
updateFrameIfNeeded()
122122
}
123123
}

0 commit comments

Comments
 (0)