Revision: 15868
http://sourceforge.net/p/skim-app/code/15868
Author: hofman
Date: 2025-12-14 10:24:07 +0000 (Sun, 14 Dec 2025)
Log Message:
-----------
make search fields rounded on Tahoe
Modified Paths:
--------------
trunk/SKSearchFieldCell.m
Modified: trunk/SKSearchFieldCell.m
===================================================================
--- trunk/SKSearchFieldCell.m 2025-12-13 19:13:31 UTC (rev 15867)
+++ trunk/SKSearchFieldCell.m 2025-12-14 10:24:07 UTC (rev 15868)
@@ -42,6 +42,9 @@
- (void)drawWithFrame:(NSRect)cellFrame inView:(NSView *)controlView {
if (@available(macOS 11.0, *)) {
+ CGFloat r = 5.0;
+ if (@available(macOS 26.0, *))
+ r = 0.5 * NSHeight(cellFrame) - 1.0;
[NSGraphicsContext saveGraphicsState];
if ([[NSWorkspace sharedWorkspace]
accessibilityDisplayShouldIncreaseContrast]) {
[[NSColor controlTextColor] setStroke];
@@ -51,9 +54,9 @@
[[[NSColor controlTextColor] colorWithAlphaComponent:0.1]
setStroke];
} else {
[[[NSColor controlTextColor] colorWithAlphaComponent:0.05] set];
- [[NSBezierPath bezierPathWithRoundedRect:NSInsetRect(cellFrame,
1.0, 1.0) xRadius:5.0 yRadius:5.0] fill];
+ [[NSBezierPath bezierPathWithRoundedRect:NSInsetRect(cellFrame,
1.0, 1.0) xRadius:r yRadius:r] fill];
}
- [[NSBezierPath bezierPathWithRoundedRect:NSInsetRect(cellFrame, 1.5,
1.5) xRadius:4.5 yRadius:4.5] stroke];
+ [[NSBezierPath bezierPathWithRoundedRect:NSInsetRect(cellFrame, 1.5,
1.5) xRadius:r - 0.5 yRadius:r - 0.5] stroke];
[NSGraphicsContext restoreGraphicsState];
[self drawInteriorWithFrame:cellFrame inView:controlView];
} else {
This was sent by the SourceForge.net collaborative development platform, the
world's largest Open Source development site.
_______________________________________________
Skim-app-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/skim-app-commit