Commit Graph

2977 Commits

Author SHA1 Message Date
Allan Odgaard
f0e6c33598 Introduce table cell view subclass to avoid expensive reload v2.0-alpha.9569 2014-09-30 00:49:09 +02:00
Allan Odgaard
6399a98d13 Use default control content font size for status bars
This does increase the status bar font from 11 to 12 points.
2014-09-30 00:03:44 +02:00
Allan Odgaard
5050bc9752 Hardcode small system font size as 11
This is because the small system font size is actually the tool tip font size which the user may increase (via the NSToolTipsFontSize defaults).
2014-09-30 00:02:42 +02:00
Allan Odgaard
2a3b18f2af Use message font as the control font 2014-09-30 00:01:16 +02:00
Allan Odgaard
39486e9c5f Use label font for color chooser in file browser context menu
This seems appropriate given that label font is used below toolbar icons and the tick marks on a slider. Here we use it below the available colors.
2014-09-29 23:47:30 +02:00
Allan Odgaard
d4a6948956 Change text view status bar layout constraints
We now center most things and baseline align text controls. Previously we would stretch all controls to full height which wouldn’t guarantee that e.g. pop-up buttons would properly align with the text fields.
2014-09-29 23:44:40 +02:00
Allan Odgaard
5b9580aa88 Remove unused code 2014-09-29 23:03:27 +02:00
Allan Odgaard
0dd97a738a Use message font for the status text in find window
We use it at its default size (13) since this is generally useful short text, I don’t think there is a reason to decrease the size.
2014-09-29 22:49:54 +02:00
Allan Odgaard
11de15ac54 Update fonts used for find in folder results
We now use the control content font as this seems to be meant for content shown in tables. We use the standard size (of 12 points) for the headings and set the result rows to use 11 point.

The number of matches is shown with the label font as that is semantically a small font used for placing labels next to things.
2014-09-29 22:41:54 +02:00
Allan Odgaard
2462bf8037 Use minimum tab size as tab bar’s intrinsic width
This way we can setup compression resistance to the required priority and thereby ensure that the tab bar fits at least one tab.
2014-09-29 18:23:34 +02:00
Allan Odgaard
d9e8a0fc5e Do not setup Y-centering constraint on tab overflow image
This image already has a fixed position so the centering is redundant and could even lead to ambiguous layout.
2014-09-29 18:23:33 +02:00
Allan Odgaard
1266129f0e Don’t layout any tabs when smaller than minimum tab item width 2014-09-29 18:23:33 +02:00
Allan Odgaard
c88b3e3611 Set “center tab labels” constraint below “fitting size” priority
This way when asking for a fitting size we get back the minimum size with all but the centering constraint met (and minimized).

In theory the compression resistance for the text field only need to be NSLayoutPriorityFittingSizeCompression+1 but for reasons I do not yet understand, we need to set it higher than NSLayoutPriorityDefaultLow, otherwise the fitting width will occasionally be 64.
2014-09-29 18:23:33 +02:00
Allan Odgaard
f079f8a917 Avoid redeclaration of “all views” dictionary 2014-09-29 16:21:05 +02:00
Allan Odgaard
d1dd666fbd Remove remains from cell-based find results outline view 2014-09-29 15:12:23 +02:00
Allan Odgaard
10e370319d Use system’s tool tip font for our custom tool tips 2014-09-29 13:47:32 +02:00
Allan Odgaard
a90acdcbe6 Use convenience methods to setup header/status bar backgrounds 2014-09-29 13:24:52 +02:00
Allan Odgaard
24bd3eee1d Let ProjectLayoutView setup height of file browser header 2014-09-29 13:03:45 +02:00
Allan Odgaard
b9ed2ac8ee Let ProjectLayoutView know about the file browser header view 2014-09-29 13:02:15 +02:00
Allan Odgaard
3052a2764b Don’t allow tab bar view to expand beyond its intrinsic height
This makes it easier to constrain other views to the height of the tab bar view, without the tab bar view growing to the height of the other view.
2014-09-29 13:02:15 +02:00
Allan Odgaard
6262e17159 Make file browser’s header view a public property
This allows users of the file browser to setup constraints involving the file browser header or change its (background) styling.
2014-09-29 13:02:15 +02:00
Allan Odgaard
d12e0976d6 Remove OakGradientView 2014-09-29 13:02:15 +02:00
Allan Odgaard
72837ca7ac Use OakBackgroundFillView instead of OakGradientView 2014-09-29 13:02:15 +02:00
Allan Odgaard
eb20fd8746 Add NSGradient support to OakBackgroundFillView 2014-09-29 13:02:15 +02:00
Allan Odgaard
65cfacd054 Fix issue with our tag property override and the 10.10 SDK
Until the 10.10 SDK we could use the compiler’s synthesized getter for our ‘tag’ property, but NSView.h in the 10.10 SDK declares ‘tag’ via the @property syntax and it is effectively unsupported to redeclare a readonly property as readwrite in a subclass (clang will not synthesize getter/setter methods in the subclass).
2014-09-28 14:31:42 +02:00
Allan Odgaard
05bd76ad0b Make “Restore Session” default for session restore dialog
Since disabling session restore will discard user data, it should not be default.
2014-09-27 13:06:31 +02:00
Allan Odgaard
244509586b Closing the overflow tab (via mouse) caused suboptimal relayout
When we close a tab with the mouse we “freeze” the layout rectangle of the tabs before the one closed, however, if this group contains non-visible tabs during close (as is mostly the case when showing the overflow button) then one of those would be made visible (since we closed a tab that took up space) and this new tab would be squeezed into the saved layout rectangle.
2014-09-27 13:02:46 +02:00
Allan Odgaard
94b7114a10 Remove old tab close button images (for non-modified tabs) 2014-09-27 12:04:56 +02:00
Allan Odgaard
6a7c42b775 Revert "Add “create tab” images from MMTabBarView"
This reverts commit 6a81bad1e4.
2014-09-27 12:04:56 +02:00
Allan Odgaard
923ee59534 Use NSImageNameAddTemplate image for “create new tab” button 2014-09-27 12:04:56 +02:00
Allan Odgaard
96c43146dc Remove redundant code 2014-09-27 12:04:05 +02:00
Allan Odgaard
bf73951ec9 Checkin release notes v2.0-alpha.9567 2014-09-26 23:18:48 +02:00
Allan Odgaard
e7bfe7b238 Fix reappearing regular expression error popover
If it was shown and dismissed, then it would show again the next time the text field content was changed (and the content was not a valid expression).
2014-09-26 23:10:24 +02:00
Allan Odgaard
e064491261 By default we no longer show the tab bar for a single document
Once we have two documents (in same window) we show the tab bar and never hides it again (to avoid content from jumping.
2014-09-26 23:10:24 +02:00
Allan Odgaard
5eb7ede829 Don’t ignore case changes on case-insensitive file systems 2014-09-26 23:10:24 +02:00
Allan Odgaard
89d2450c88 Reload tabs before changing selected tab index
This worked previously because selected tab was stored using an index and we were only changing it (before reload) when closing tabs, so the new index would be valid both before and after reload.

With the new OakTabBarView the index of selected tab is instantly converted into a reference to a tab item.
2014-09-26 23:10:24 +02:00
Allan Odgaard
cb463534b8 Make window key in actions that show file browser field editor
It is possible to bring up menus for inactive windows and e.g. select Rename or Duplicate.
2014-09-26 23:10:24 +02:00
Allan Odgaard
a983643fb8 Workaround for weak pointers to NSWindow crashing on 10.7 2014-09-26 23:10:24 +02:00
Ronald Wampler
a627991ac3 HOBrowserView: Avoid calling super on key events
This workaround is to avoid a couple of undesired behaviors in the `HTMLOutputWindow` when the web page implements keyboard commands such as Git → Browse Annotated File (Blame). Namely, when using the keyboard commands, we would always receive an NSBeep. Also, fixed an issue when these key commands may conflict with menu keys. See comment in the commit for details.
2014-09-26 23:10:24 +02:00
Allan Odgaard
13a3ac49ba Update OakTabBarView class to use an NSView per tab item 2014-09-26 23:10:24 +02:00
Allan Odgaard
baff543c47 Add OakTabItemView to be used in upcoming OakTabBarView 2014-09-26 23:10:23 +02:00
Allan Odgaard
6a81bad1e4 Add “create tab” images from MMTabBarView 2014-09-25 22:48:13 +02:00
Allan Odgaard
cba03ff594 Add tab images from Safari 2014-09-25 22:48:13 +02:00
Allan Odgaard
b7088bac3d Add OakRolloverButton 2014-09-25 22:48:13 +02:00
Allan Odgaard
7ebd14876c Introduce OakBackgroundFillView which replaces NSBox for dividers
This view has an active/inactive color or image. The latter is drawn as a pattern color (tiled image).
2014-09-25 19:33:17 +02:00
Allan Odgaard
e54a170eae NSBox is an implementation detail so use NSView instead 2014-09-25 19:33:17 +02:00
Allan Odgaard
1f06ac9ff4 Add identifier to OakTabBarViewDataSource 2014-09-25 19:33:16 +02:00
Allan Odgaard
cf3b830610 Make the ‘expanded’ property of OakTabBarView private 2014-09-20 13:47:30 +02:00
Allan Odgaard
bff8094976 Decrease minimum required width of document status bar 2014-09-19 11:40:29 +02:00
Allan Odgaard
da669a482c Update documentation reference in comment 2014-09-19 07:37:15 +02:00