Note: this replaces the previous non Cocoa behaviour where the token field would grow height-wise with new tokens. This behaviour can still be useful, as seen in Apple Mail, but it will now require the user to subclass CPTokenField, override layoutSubview and set the frame size to the size of the scroll view's document view.
- Fixed _minimumFrameSize to take into account bezel and line break mode.
- Added test to show how sizeToFit was broken for multi-line labels in the old code.
- Added test to verify that behavior is correct for single-line labels.
Copying previous constants
Removing unnecessary constants
Borrowing initialization from my old implementation.
Refactoring the initialization method and adding setBackgroundColor: override.
Removing +initialize (no theming support yet) and -viewDidMoveToWindow (not sure why this was there?)
Implement the bulk of the new CPTabView
Adding delegate selectors. Don't think this is complete, though. What about when a user clicks on a segmented tab control?!
Adding delegate
Think I may have fixed the delegate blocking for selected segment control items
Adding tests. Fixing a bug by reverting to old way. Delegates still broken.
Cleaning up the test.
Resolving delegate issues (thanks Saikat!).
Switching tab appearance based on type enum. Updating tests to slightly test this.
Conflicts:
AppKit/CPTabView2.j
- Current theme blend is available via CPApplication -themeBlend.
- List of themes is available via CPApplication -themes.
- CPThemeBlend adds the following methods:
themes
themeNames
- CPTheme adds a number of methods to access theme attributes:
classNames
attributesForClass:
attributeNamesForClass:
attributeWithName:forClass: (was _attributeWithName:forClass:)
valueForAttributeWithName:forClass
valueForAttributeWithName:inState:forClass:
- _CPThemeAttribute -values was added to access the dictionary of attribute values.
- Theme browser application that demonstrates the API.
- In the course of making the test app, added the function CGInsetEqualToInset().
- The default box background color is now clear, that is what Cocoa does.
- Bezel drawing uses CPDrawTiledRects, obeys border width.
- CPDrawTiledRects/CPDrawColorTiledRects explicitly sets the line width and saves/restores the graphics state.
- Whitespace cleanup in CPBox.
- Checkbox and radio selected states would not show in the images. It turns out that the image and alternate image cannot be encoded->decoded->set without messing up the theme, and unfortunately the theme blending task (during a jake build) would do so. So for now this means that we cannot encode non-theme images with a button class, which is unlikely to happen.
- Since we cannot access themes in the NS classes, I went ahead and started to make some constants in a few control classes so that the values can be changed in one place and affect the theme and nib2cib.
- A formatter function can be passed to the CPLogRegister functions. If the given level already has a provider for the given level, the formatter will be replaced with the one passed to the register function.
- Added CPLogColorize function to make it easy for users to colorize messages.
- CPLogRegisterRange now checks for min <= max, and now correctly starts iterating from min.
- Moved colorization of log level to _CPFormatLogMessage.
- Whitespace cleanup.
- Implemented CGRectDivide/CPDivideRect.
- Implemented CPDrawTiledRects/CPDrawColorTiledRects.
- Removed CPDrawGrayBezel and CPDrawGroove, they were not being done in a Cocoa-compliant way, and the Cocoa way is not really useful right now.
- Moved border drawing code back to CPScrollView since CPDrawGrayBezel/CPDrawGroove are gone.
- Test app to do simple demo of the new functions.
- Removed trailing whitespace.
Fixed a bug in CPWindow where the didEndSelector was reset too early. This bug was visible only when trying to chain sheet alerts.
Fixed a local/instance variable conflict in AttachedSheet/AppController.j