├── .gitignore
├── .hgignore
├── BWToolkit.xcodeproj
├── TemplateIcon.icns
├── default.pbxuser
├── project.pbxproj
└── project.xcworkspace
│ └── contents.xcworkspacedata
└── BWToolkit
├── Artwork
├── ButtonBarPullDownArrow.pdf
├── TokenFieldArrow.tif
└── TokenFieldHighlightedArrow.tif
├── BWToolkit-Info.plist
├── BWToolkitMAS-Info.plist
├── Framework
├── Categories
│ ├── NSApplication+BWAdditions.h
│ ├── NSApplication+BWAdditions.m
│ ├── NSColor+BWAdditions.h
│ ├── NSColor+BWAdditions.m
│ ├── NSEvent+BWAdditions.h
│ ├── NSEvent+BWAdditions.m
│ ├── NSImage+BWAdditions.h
│ ├── NSImage+BWAdditions.m
│ ├── NSString+BWAdditions.h
│ ├── NSString+BWAdditions.m
│ ├── NSView+BWAdditions.h
│ ├── NSView+BWAdditions.m
│ ├── NSWindow+BWAdditions.h
│ └── NSWindow+BWAdditions.m
├── Classes
│ ├── BWToolkitFramework.h
│ ├── Bottom Bar
│ │ ├── BWAddMiniBottomBar.h
│ │ ├── BWAddMiniBottomBar.m
│ │ ├── BWAddRegularBottomBar.h
│ │ ├── BWAddRegularBottomBar.m
│ │ ├── BWAddSheetBottomBar.h
│ │ ├── BWAddSheetBottomBar.m
│ │ ├── BWAddSmallBottomBar.h
│ │ ├── BWAddSmallBottomBar.m
│ │ ├── BWRemoveBottomBar.h
│ │ └── BWRemoveBottomBar.m
│ ├── Button Bar
│ │ ├── BWAnchoredButton.h
│ │ ├── BWAnchoredButton.m
│ │ ├── BWAnchoredButtonBar.h
│ │ ├── BWAnchoredButtonBar.m
│ │ ├── BWAnchoredButtonCell.h
│ │ ├── BWAnchoredButtonCell.m
│ │ ├── BWAnchoredPopUpButton.h
│ │ ├── BWAnchoredPopUpButton.m
│ │ ├── BWAnchoredPopUpButtonCell.h
│ │ ├── BWAnchoredPopUpButtonCell.m
│ │ ├── BWUnanchoredButton.h
│ │ ├── BWUnanchoredButton.m
│ │ ├── BWUnanchoredButtonCell.h
│ │ ├── BWUnanchoredButtonCell.m
│ │ ├── BWUnanchoredButtonContainer.h
│ │ └── BWUnanchoredButtonContainer.m
│ ├── Gradient Box
│ │ ├── BWGradientBox.h
│ │ └── BWGradientBox.m
│ ├── Hyperlink Button
│ │ ├── BWHyperlinkButton.h
│ │ ├── BWHyperlinkButton.m
│ │ ├── BWHyperlinkButtonCell.h
│ │ └── BWHyperlinkButtonCell.m
│ ├── Inset Text Field
│ │ ├── BWInsetTextField.h
│ │ └── BWInsetTextField.m
│ ├── Selectable Toolbar
│ │ ├── BWSelectableToolbar.h
│ │ ├── BWSelectableToolbar.m
│ │ ├── BWSelectableToolbarHelper.h
│ │ └── BWSelectableToolbarHelper.m
│ ├── Sheet Controller
│ │ ├── BWSheetController.h
│ │ └── BWSheetController.m
│ ├── Split View
│ │ ├── BWCustomView.h
│ │ ├── BWCustomView.m
│ │ ├── BWSplitView.h
│ │ └── BWSplitView.m
│ ├── Styled Text Field
│ │ ├── BWStyledTextField.h
│ │ ├── BWStyledTextField.m
│ │ ├── BWStyledTextFieldCell.h
│ │ └── BWStyledTextFieldCell.m
│ ├── Textured Slider
│ │ ├── BWTexturedSlider.h
│ │ ├── BWTexturedSlider.m
│ │ ├── BWTexturedSliderCell.h
│ │ └── BWTexturedSliderCell.m
│ ├── Token Field
│ │ ├── BWTokenAttachmentCell.h
│ │ ├── BWTokenAttachmentCell.m
│ │ ├── BWTokenField.h
│ │ ├── BWTokenField.m
│ │ ├── BWTokenFieldCell.h
│ │ └── BWTokenFieldCell.m
│ ├── Toolbar Items
│ │ ├── BWToolbarItem.h
│ │ ├── BWToolbarItem.m
│ │ ├── BWToolbarShowColorsItem.h
│ │ ├── BWToolbarShowColorsItem.m
│ │ ├── BWToolbarShowFontsItem.h
│ │ └── BWToolbarShowFontsItem.m
│ └── Transparent Controls
│ │ ├── BWTransparentButton.h
│ │ ├── BWTransparentButton.m
│ │ ├── BWTransparentButtonCell.h
│ │ ├── BWTransparentButtonCell.m
│ │ ├── BWTransparentCheckbox.h
│ │ ├── BWTransparentCheckbox.m
│ │ ├── BWTransparentCheckboxCell.h
│ │ ├── BWTransparentCheckboxCell.m
│ │ ├── BWTransparentPopUpButton.h
│ │ ├── BWTransparentPopUpButton.m
│ │ ├── BWTransparentPopUpButtonCell.h
│ │ ├── BWTransparentPopUpButtonCell.m
│ │ ├── BWTransparentScrollView.h
│ │ ├── BWTransparentScrollView.m
│ │ ├── BWTransparentScroller.h
│ │ ├── BWTransparentScroller.m
│ │ ├── BWTransparentSlider.h
│ │ ├── BWTransparentSlider.m
│ │ ├── BWTransparentSliderCell.h
│ │ ├── BWTransparentSliderCell.m
│ │ ├── BWTransparentTableView.h
│ │ ├── BWTransparentTableView.m
│ │ ├── BWTransparentTableViewCell.h
│ │ ├── BWTransparentTableViewCell.m
│ │ ├── BWTransparentTextFieldCell.h
│ │ └── BWTransparentTextFieldCell.m
├── Graphics
│ ├── Button Bar
│ │ └── ButtonBarPullDownArrow.pdf
│ ├── Split View
│ │ ├── GradientSplitViewDimpleBitmap.tif
│ │ └── GradientSplitViewDimpleVector.pdf
│ ├── Textured Slider
│ │ ├── TexturedSliderPhotoLarge.tif
│ │ ├── TexturedSliderPhotoSmall.tif
│ │ ├── TexturedSliderSpeakerLoud.png
│ │ ├── TexturedSliderSpeakerQuiet.png
│ │ ├── TexturedSliderThumbN.tiff
│ │ ├── TexturedSliderThumbP.tiff
│ │ ├── TexturedSliderTrackFill.tiff
│ │ ├── TexturedSliderTrackLeft.tiff
│ │ └── TexturedSliderTrackRight.tiff
│ ├── Toolbar Items
│ │ ├── ToolbarItemColors.tiff
│ │ └── ToolbarItemFonts.tiff
│ └── Transparent Controls
│ │ ├── Button
│ │ ├── TransparentButtonFillN.tiff
│ │ ├── TransparentButtonFillP.tiff
│ │ ├── TransparentButtonLeftN.tiff
│ │ ├── TransparentButtonLeftP.tiff
│ │ ├── TransparentButtonRightN.tiff
│ │ └── TransparentButtonRightP.tiff
│ │ ├── Check Box
│ │ ├── TransparentCheckboxOffN.tiff
│ │ ├── TransparentCheckboxOffP.tiff
│ │ ├── TransparentCheckboxOnN.tiff
│ │ └── TransparentCheckboxOnP.tiff
│ │ ├── Pop Up
│ │ ├── TransparentPopUpFillN.tiff
│ │ ├── TransparentPopUpFillP.tiff
│ │ ├── TransparentPopUpLeftN.tiff
│ │ ├── TransparentPopUpLeftP.tiff
│ │ ├── TransparentPopUpPullDownRightN.tif
│ │ ├── TransparentPopUpPullDownRightP.tif
│ │ ├── TransparentPopUpRightN.tiff
│ │ └── TransparentPopUpRightP.tiff
│ │ ├── Scroller
│ │ ├── TransparentScrollerKnobBottom.tif
│ │ ├── TransparentScrollerKnobHorizontalFill.tif
│ │ ├── TransparentScrollerKnobLeft.tif
│ │ ├── TransparentScrollerKnobRight.tif
│ │ ├── TransparentScrollerKnobTop.tif
│ │ ├── TransparentScrollerKnobVerticalFill.tif
│ │ ├── TransparentScrollerSlotBottom.tif
│ │ ├── TransparentScrollerSlotHorizontalFill.tif
│ │ ├── TransparentScrollerSlotLeft.tif
│ │ ├── TransparentScrollerSlotRight.tif
│ │ ├── TransparentScrollerSlotTop.tif
│ │ └── TransparentScrollerSlotVerticalFill.tif
│ │ └── Slider
│ │ ├── TransparentSliderThumbN.tiff
│ │ ├── TransparentSliderThumbP.tiff
│ │ ├── TransparentSliderTrackFill.tiff
│ │ ├── TransparentSliderTrackLeft.tiff
│ │ ├── TransparentSliderTrackRight.tiff
│ │ ├── TransparentSliderTriangleThumbN.tiff
│ │ └── TransparentSliderTriangleThumbP.tiff
└── Private Cocoa Headers
│ ├── NSCustomView.h
│ ├── NSTokenAttachment.h
│ ├── NSTokenAttachmentCell.h
│ └── NSWindow-NSTimeMachineSupport.h
├── Info.plist
├── InfoPlist.strings
├── Plugin
├── Class Descriptions
│ ├── BWAddMiniBottomBar.classdescription
│ ├── BWAddRegularBottomBar.classdescription
│ ├── BWAddSheetBottomBar.classdescription
│ ├── BWAddSmallBottomBar.classdescription
│ ├── BWAnchoredButton.classdescription
│ ├── BWAnchoredButtonBar.classdescription
│ ├── BWAnchoredPopUpButton.classdescription
│ ├── BWCustomView.classdescription
│ ├── BWGradientBox.classdescription
│ ├── BWHyperlinkButton.classdescription
│ ├── BWHyperlinkButtonCell.classdescription
│ ├── BWInsetTextField.classdescription
│ ├── BWRemoveBottomBar.classdescription
│ ├── BWSelectableToolbar.classdescription
│ ├── BWSheetController.classdescription
│ ├── BWSplitView.classdescription
│ ├── BWStyledTextField.classdescription
│ ├── BWStyledTextFieldCell.classdescription
│ ├── BWTexturedSlider.classdescription
│ ├── BWTexturedSliderCell.classdescription
│ ├── BWTokenField.classdescription
│ ├── BWTokenFieldCell.classdescription
│ ├── BWToolbarItem.classdescription
│ ├── BWToolbarShowColorsItem.classdescription
│ ├── BWToolbarShowFontsItem.classdescription
│ ├── BWTransparentButton.classdescription
│ ├── BWTransparentButtonCell.classdescription
│ ├── BWTransparentCheckbox.classdescription
│ ├── BWTransparentCheckboxCell.classdescription
│ ├── BWTransparentPopUpButton.classdescription
│ ├── BWTransparentPopUpButtonCell.classdescription
│ ├── BWTransparentScrollView.classdescription
│ ├── BWTransparentScroller.classdescription
│ ├── BWTransparentSlider.classdescription
│ ├── BWTransparentSliderCell.classdescription
│ ├── BWTransparentTableView.classdescription
│ ├── BWTransparentTableViewCell.classdescription
│ └── BWTransparentTextFieldCell.classdescription
├── Classes
│ ├── BWAnchoredButtonBarInspector.h
│ ├── BWAnchoredButtonBarInspector.m
│ ├── BWGradientBoxInspector.h
│ ├── BWGradientBoxInspector.m
│ ├── BWGradientWell.h
│ ├── BWGradientWell.m
│ ├── BWGradientWellColorWell.h
│ ├── BWGradientWellColorWell.m
│ ├── BWHyperlinkButtonInspector.h
│ ├── BWHyperlinkButtonInspector.m
│ ├── BWSelectableToolbarInspector.h
│ ├── BWSelectableToolbarInspector.m
│ ├── BWSplitViewInspector.h
│ ├── BWSplitViewInspector.m
│ ├── BWSplitViewInspectorAutosizingButtonCell.h
│ ├── BWSplitViewInspectorAutosizingButtonCell.m
│ ├── BWSplitViewInspectorAutosizingView.h
│ ├── BWSplitViewInspectorAutosizingView.m
│ ├── BWStyledTextFieldInspector.h
│ ├── BWStyledTextFieldInspector.m
│ ├── BWTexturedSliderInspector.h
│ ├── BWTexturedSliderInspector.m
│ ├── BWToolbarItemInspector.h
│ ├── BWToolbarItemInspector.m
│ ├── BWToolkit.h
│ └── BWToolkit.m
├── Other Sources
│ ├── BWAddMiniBottomBarIntegration.m
│ ├── BWAddRegularBottomBarIntegration.m
│ ├── BWAddSheetBottomBarIntegration.m
│ ├── BWAddSmallBottomBarIntegration.m
│ ├── BWAnchoredButtonBarIntegration.m
│ ├── BWAnchoredButtonIntegration.m
│ ├── BWAnchoredPopUpButtonIntegration.m
│ ├── BWCustomViewIntegration.m
│ ├── BWGradientBoxIntegration.m
│ ├── BWHyperlinkButtonIntegration.m
│ ├── BWRemoveBottomBarIntegration.m
│ ├── BWSelectableToolbarIntegration.m
│ ├── BWSheetControllerIntegration.m
│ ├── BWSplitViewIntegration.m
│ ├── BWStyledTextFieldIntegration.m
│ ├── BWTexturedSliderIntegration.m
│ ├── BWToolbarItemIntegration.m
│ ├── BWToolkit_Prefix.pch
│ ├── BWTransparentButtonIntegration.m
│ ├── BWTransparentCheckboxIntegration.m
│ ├── BWTransparentPopUpButtonIntegration.m
│ ├── BWTransparentScrollViewIntegration.m
│ ├── BWTransparentSliderIntegration.m
│ ├── BWTransparentTableViewIntegration.m
│ ├── BWUnanchoredButtonContainerIntegration.m
│ └── BWUnanchoredButtonIntegration.m
└── Resources
│ ├── Inspectors
│ ├── BWAnchoredButtonBarInspector.xib
│ ├── BWGradientBoxInspector.xib
│ ├── BWHyperlinkButtonInspector.xib
│ ├── BWSelectableToolbarInspector.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWSplitViewInspector.xib
│ ├── BWStyledTextFieldInspector.xib
│ ├── BWTexturedSliderInspector.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWToolbarItemInspector.xib
│ └── Graphics
│ │ ├── Anchored Button Bar
│ │ ├── Inspector-ButtonBarMode1.tif
│ │ ├── Inspector-ButtonBarMode1Pressed.tif
│ │ ├── Inspector-ButtonBarMode2.tif
│ │ ├── Inspector-ButtonBarMode2Pressed.tif
│ │ ├── Inspector-ButtonBarMode3.tif
│ │ ├── Inspector-ButtonBarMode3Pressed.tif
│ │ └── Inspector-ButtonBarModeSelection.tif
│ │ ├── Gradient Well
│ │ └── GradientWellPattern.tif
│ │ └── Split View
│ │ ├── Inspector-SplitViewArrowBlueLeft.tif
│ │ ├── Inspector-SplitViewArrowBlueRight.tif
│ │ ├── Inspector-SplitViewArrowRedFill.tif
│ │ ├── Inspector-SplitViewArrowRedLeft.tif
│ │ ├── Inspector-SplitViewArrowRedRight.tif
│ │ └── Inspector-SplitViewBackground.tiff
│ ├── Libraries
│ ├── BWBottomBarLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWButtonBarLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWControllersLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWSplitViewLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWToolbarItemsLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── BWToolkitLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ └── BWTransparentControlsLibrary.nib
│ │ ├── designable.nib
│ │ └── keyedobjects.nib
│ ├── Library Thumbnails
│ ├── Library-AddMiniBottomBar.tif
│ ├── Library-AddRegularBottomBar.tif
│ ├── Library-AddSheetBottomBar.tif
│ ├── Library-AddSmallBottomBar.tif
│ ├── Library-AnchoredButton.tif
│ ├── Library-AnchoredButtonBar.tif
│ ├── Library-AnchoredPopUpButton.tif
│ ├── Library-CustomView.tif
│ ├── Library-GradientBox.tif
│ ├── Library-GradientSplitView.tif
│ ├── Library-HorizontalSplitView.tif
│ ├── Library-InsetTextField.tif
│ ├── Library-RemoveBottomBar.tif
│ ├── Library-SelectableToolbar.tif
│ ├── Library-SheetController.tif
│ ├── Library-ShowColors.tif
│ ├── Library-ShowFonts.tif
│ ├── Library-StyledTextField.tif
│ ├── Library-TexturedAddButton.tif
│ ├── Library-TexturedRemoveButton.tif
│ ├── Library-TexturedSlider.tif
│ ├── Library-TokenField.tif
│ ├── Library-ToolbarItem.tiff
│ ├── Library-TransparentButton.tif
│ ├── Library-TransparentCheckbox.tif
│ ├── Library-TransparentCheckboxCell.tif
│ ├── Library-TransparentLabel.tif
│ ├── Library-TransparentPopUpButton.tif
│ ├── Library-TransparentSlider.tif
│ ├── Library-TransparentTableView.tif
│ ├── Library-TransparentTextView.tif
│ └── Library-VerticalSplitView.tif
│ └── Private IB Classes
│ └── IBColor.h
└── Resources
├── License.rtf
└── Release Notes.rtf
/.gitignore:
--------------------------------------------------------------------------------
1 | DerivedData
--------------------------------------------------------------------------------
/.hgignore:
--------------------------------------------------------------------------------
1 | syntax: glob
2 |
3 | *.pbxuser
4 | *.mode1
5 | *.mode1v3
6 | *~.nib
7 | *~
8 | *.orig
9 | .DS_Store
10 |
--------------------------------------------------------------------------------
/BWToolkit.xcodeproj/TemplateIcon.icns:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit.xcodeproj/TemplateIcon.icns
--------------------------------------------------------------------------------
/BWToolkit.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/BWToolkit/Artwork/ButtonBarPullDownArrow.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Artwork/ButtonBarPullDownArrow.pdf
--------------------------------------------------------------------------------
/BWToolkit/Artwork/TokenFieldArrow.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Artwork/TokenFieldArrow.tif
--------------------------------------------------------------------------------
/BWToolkit/Artwork/TokenFieldHighlightedArrow.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Artwork/TokenFieldHighlightedArrow.tif
--------------------------------------------------------------------------------
/BWToolkit/BWToolkit-Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | English
7 | CFBundleExecutable
8 | BWToolkitFramework
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | BWTK
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleSignature
18 | ????
19 | CFBundleSupportedPlatforms
20 |
21 | MacOSX
22 |
23 | CFBundleVersion
24 | 1.2.5
25 | Mach-OLC_VERSION_MIN
26 | 10.6
27 | NSPrincipalClass
28 | BWToolkit
29 |
30 |
31 |
--------------------------------------------------------------------------------
/BWToolkit/BWToolkitMAS-Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | English
7 | CFBundleExecutable
8 | BWTKMAS
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | BWTKMAS
15 | CFBundlePackageType
16 | FMWK
17 | CFBundleSignature
18 | ????
19 | CFBundleSupportedPlatforms
20 |
21 | MacOSX
22 |
23 | CFBundleVersion
24 | 1.2.5
25 | Mach-OLC_VERSION_MIN
26 | 10.6
27 | NSPrincipalClass
28 | BWToolkit
29 |
30 |
31 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSApplication+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSApplication+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSApplication (BWAdditions)
12 |
13 | + (BOOL)bwIsOnLeopard;
14 |
15 | @end
16 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSApplication+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSApplication+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSApplication+BWAdditions.h"
10 |
11 | @implementation NSApplication (BWAdditions)
12 |
13 | + (BOOL)bwIsOnLeopard
14 | {
15 | SInt32 minorVersion, majorVersion;
16 | Gestalt(gestaltSystemVersionMajor, &majorVersion);
17 | Gestalt(gestaltSystemVersionMinor, &minorVersion);
18 | return majorVersion == 10 && minorVersion == 5;
19 | }
20 |
21 | @end
22 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSColor+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSColor+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSColor (BWAdditions)
12 |
13 | // Use this method to draw 1 px wide lines independent of scale factor. Handy for resolution independent drawing. Still needs some work - there are issues with drawing at the edges of views.
14 | - (void)bwDrawPixelThickLineAtPosition:(int)posInPixels withInset:(int)insetInPixels inRect:(NSRect)aRect inView:(NSView *)view horizontal:(BOOL)isHorizontal flip:(BOOL)shouldFlip;
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSColor+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSColor+PixelWideLines.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSColor+BWAdditions.h"
10 |
11 | @implementation NSColor (BWAdditions)
12 |
13 | // Use this method to draw 1 px wide lines independent of scale factor. Handy for resolution independent drawing. Still needs some work - there are issues with drawing at the edges of views.
14 | - (void)bwDrawPixelThickLineAtPosition:(int)posInPixels withInset:(int)insetInPixels inRect:(NSRect)aRect inView:(NSView *)view horizontal:(BOOL)isHorizontal flip:(BOOL)shouldFlip
15 | {
16 | // Convert the given rectangle from points to pixels
17 | aRect = [view convertRectToBase:aRect];
18 |
19 | // Round up the rect's values to integers
20 | aRect = NSIntegralRect(aRect);
21 |
22 | // Add or subtract 0.5 so the lines are drawn within pixel bounds
23 | if (isHorizontal)
24 | {
25 | if ([view isFlipped])
26 | aRect.origin.y -= 0.5;
27 | else
28 | aRect.origin.y += 0.5;
29 | }
30 | else
31 | {
32 | aRect.origin.x += 0.5;
33 | }
34 |
35 | NSSize sizeInPixels = aRect.size;
36 |
37 | // Convert the rect back to points for drawing
38 | aRect = [view convertRectFromBase:aRect];
39 |
40 | // Flip the position so it's at the other side of the rect
41 | if (shouldFlip)
42 | {
43 | if (isHorizontal)
44 | posInPixels = sizeInPixels.height - posInPixels - 1;
45 | else
46 | posInPixels = sizeInPixels.width - posInPixels - 1;
47 | }
48 |
49 | float posInPoints = posInPixels / [[NSScreen mainScreen] userSpaceScaleFactor];
50 | float insetInPoints = insetInPixels / [[NSScreen mainScreen] userSpaceScaleFactor];
51 |
52 | // Calculate line start and end points
53 | float startX, startY, endX, endY;
54 |
55 | if (isHorizontal)
56 | {
57 | startX = aRect.origin.x + insetInPoints;
58 | startY = aRect.origin.y + posInPoints;
59 | endX = aRect.origin.x + aRect.size.width - insetInPoints;
60 | endY = aRect.origin.y + posInPoints;
61 | }
62 | else
63 | {
64 | startX = aRect.origin.x + posInPoints;
65 | startY = aRect.origin.y + insetInPoints;
66 | endX = aRect.origin.x + posInPoints;
67 | endY = aRect.origin.y + aRect.size.height - insetInPoints;
68 | }
69 |
70 | // Draw line
71 | NSBezierPath *path = [NSBezierPath bezierPath];
72 | [path setLineWidth:0.0f];
73 | [path moveToPoint:NSMakePoint(startX,startY)];
74 | [path lineToPoint:NSMakePoint(endX,endY)];
75 | [self set];
76 | [path stroke];
77 | }
78 |
79 | @end
80 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSEvent+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSEvent+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSEvent (BWAdditions)
12 |
13 | + (BOOL)bwShiftKeyIsDown;
14 | + (BOOL)bwCommandKeyIsDown;
15 | + (BOOL)bwOptionKeyIsDown;
16 | + (BOOL)bwControlKeyIsDown;
17 | + (BOOL)bwCapsLockKeyIsDown;
18 |
19 | @end
20 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSEvent+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSEvent+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSEvent+BWAdditions.h"
10 |
11 | @implementation NSEvent (BWAdditions)
12 |
13 | + (BOOL)bwShiftKeyIsDown
14 | {
15 | if ([[NSApp currentEvent] modifierFlags] & NSShiftKeyMask)
16 | return YES;
17 |
18 | return NO;
19 | }
20 |
21 | + (BOOL)bwCommandKeyIsDown
22 | {
23 | if ([[NSApp currentEvent] modifierFlags] & NSCommandKeyMask)
24 | return YES;
25 |
26 | return NO;
27 | }
28 |
29 | + (BOOL)bwOptionKeyIsDown
30 | {
31 | if ([[NSApp currentEvent] modifierFlags] & NSAlternateKeyMask)
32 | return YES;
33 |
34 | return NO;
35 | }
36 |
37 | + (BOOL)bwControlKeyIsDown
38 | {
39 | if ([[NSApp currentEvent] modifierFlags] & NSControlKeyMask)
40 | return YES;
41 |
42 | return NO;
43 | }
44 |
45 | + (BOOL)bwCapsLockKeyIsDown
46 | {
47 | if ([[NSApp currentEvent] modifierFlags] & NSAlphaShiftKeyMask)
48 | return YES;
49 |
50 | return NO;
51 | }
52 |
53 | @end
54 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSImage+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSImage+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSImage (BWAdditions)
12 |
13 | // Draw a solid color over an image - taking into account alpha. Useful for coloring template images.
14 | - (NSImage *)bwTintedImageWithColor:(NSColor *)tint;
15 |
16 | // Rotate an image 90 degrees clockwise or counterclockwise
17 | - (NSImage *)bwRotateImage90DegreesClockwise:(BOOL)clockwise;
18 |
19 | @end
20 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSImage+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSImage+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSImage+BWAdditions.h"
10 |
11 | @implementation NSImage (BWAdditions)
12 |
13 | // Draw a solid color over an image - taking into account alpha. Useful for coloring template images.
14 |
15 | - (NSImage *)bwTintedImageWithColor:(NSColor *)tint
16 | {
17 | NSSize size = [self size];
18 | NSRect imageBounds = NSMakeRect(0, 0, size.width, size.height);
19 |
20 | NSImage *copiedImage = [self copy];
21 |
22 | [copiedImage lockFocus];
23 |
24 | [tint set];
25 | NSRectFillUsingOperation(imageBounds, NSCompositeSourceAtop);
26 |
27 | [copiedImage unlockFocus];
28 |
29 | return copiedImage;
30 | }
31 |
32 | // Rotate an image 90 degrees clockwise or counterclockwise
33 | // Code from http://swik.net/User:marc/Chipmunk+Ninja+Technical+Articles/Rotating+an+NSImage+object+in+Cocoa/zgha
34 |
35 | - (NSImage *)bwRotateImage90DegreesClockwise:(BOOL)clockwise
36 | {
37 | NSImage *existingImage = self;
38 | NSSize existingSize;
39 |
40 | /**
41 | * Get the size of the original image in its raw bitmap format.
42 | * The bestRepresentationForDevice: nil tells the NSImage to just
43 | * give us the raw image instead of it's wacky DPI-translated version.
44 | */
45 | existingSize.width = [[existingImage bestRepresentationForDevice:nil] pixelsWide];
46 | existingSize.height = [[existingImage bestRepresentationForDevice:nil] pixelsHigh];
47 |
48 | NSSize newSize = NSMakeSize(existingSize.height, existingSize.width);
49 | NSImage *rotatedImage = [[NSImage alloc] initWithSize:newSize];
50 |
51 | [rotatedImage lockFocus];
52 |
53 | /**
54 | * Apply the following transformations:
55 | *
56 | * - bring the rotation point to the centre of the image instead of
57 | * the default lower, left corner (0,0).
58 | * - rotate it by 90 degrees, either clock or counter clockwise.
59 | * - re-translate the rotated image back down to the lower left corner
60 | * so that it appears in the right place.
61 | */
62 | NSAffineTransform *rotateTF = [NSAffineTransform transform];
63 | NSPoint centerPoint = NSMakePoint(newSize.width / 2, newSize.height / 2);
64 |
65 | [rotateTF translateXBy: centerPoint.x yBy: centerPoint.y];
66 | [rotateTF rotateByDegrees: (clockwise) ? - 90 : 90];
67 | [rotateTF translateXBy: -centerPoint.y yBy: -centerPoint.x];
68 | [rotateTF concat];
69 |
70 | /**
71 | * We have to get the image representation to do its drawing directly,
72 | * because otherwise the stupid NSImage DPI thingie bites us in the butt
73 | * again.
74 | */
75 | NSRect r1 = NSMakeRect(0, 0, newSize.height, newSize.width);
76 | [[existingImage bestRepresentationForDevice:nil] drawInRect:r1];
77 |
78 | [rotatedImage unlockFocus];
79 |
80 | return rotatedImage;
81 | }
82 |
83 | @end
84 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSString+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSString (BWAdditions)
12 |
13 | + (NSString *)bwRandomUUID;
14 |
15 | @end
16 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSString+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSString+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSString+BWAdditions.h"
10 |
11 | @implementation NSString (BWAdditions)
12 |
13 | + (NSString *)bwRandomUUID
14 | {
15 | CFUUIDRef uuidObj = CFUUIDCreate(nil);
16 | NSString *newUUID = (NSString*)CFMakeCollectable(CFUUIDCreateString(nil, uuidObj));
17 | CFRelease(uuidObj);
18 |
19 | return [newUUID autorelease];
20 | }
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSView+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSView+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSView (BWAdditions)
12 |
13 | - (void)bwBringToFront;
14 |
15 | // Returns animator proxy and calls setWantsLayer:NO on the view when the animation completes
16 | - (id)bwAnimator;
17 |
18 | @end
19 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSView+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSView+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSView+BWAdditions.h"
10 |
11 | NSComparisonResult compareViews(id firstView, id secondView, id context);
12 | NSComparisonResult compareViews(id firstView, id secondView, id context)
13 | {
14 | if (firstView != context && secondView != context) {return NSOrderedSame;}
15 | else
16 | {
17 | if (firstView == context) {return NSOrderedDescending;}
18 | else {return NSOrderedAscending;}
19 | }
20 | }
21 |
22 | @interface NSView (BWPrivateAdditions)
23 | - (void)bwTurnOffLayer;
24 | @end
25 |
26 | @implementation NSView (BWAdditions)
27 |
28 | - (void)bwBringToFront
29 | {
30 | [[self superview] sortSubviewsUsingFunction:(NSComparisonResult (*)(id, id, void *))compareViews context:(__bridge void *)(self)];
31 | }
32 |
33 | - (id)bwAnimator
34 | {
35 | float duration = [[NSAnimationContext currentContext] duration];
36 | [self performSelector:@selector(bwTurnOffLayer) withObject:nil afterDelay:duration];
37 |
38 | return [self animator];
39 | }
40 |
41 | - (void)bwTurnOffLayer
42 | {
43 | [self setWantsLayer:NO];
44 | }
45 |
46 | @end
47 |
48 |
49 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSWindow+BWAdditions.h:
--------------------------------------------------------------------------------
1 | //
2 | // NSWindow+BWAdditions.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface NSWindow (BWAdditions)
12 |
13 | - (void)bwResizeToSize:(NSSize)newSize animate:(BOOL)animateFlag;
14 | - (BOOL)bwIsTextured;
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Categories/NSWindow+BWAdditions.m:
--------------------------------------------------------------------------------
1 | //
2 | // NSWindow+BWAdditions.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "NSWindow+BWAdditions.h"
10 |
11 | @implementation NSWindow (BWAdditions)
12 |
13 | - (void)bwResizeToSize:(NSSize)newSize animate:(BOOL)animateFlag
14 | {
15 | NSRect windowFrame;
16 | windowFrame.origin.x = [self frame].origin.x;
17 |
18 | if ([self isSheet])
19 | {
20 | float oldWidth = [self frame].size.width;
21 | float newWidth = newSize.width;
22 |
23 | float difference = oldWidth - newWidth;
24 |
25 | windowFrame.origin.x += difference / 2;
26 | }
27 |
28 | windowFrame.origin.y = [self frame].origin.y + [self frame].size.height - newSize.height;
29 | windowFrame.size.width = newSize.width;
30 | windowFrame.size.height = newSize.height;
31 |
32 | if (!NSIsEmptyRect(windowFrame))
33 | [self setFrame:windowFrame display:YES animate:animateFlag];
34 | }
35 |
36 | - (BOOL)bwIsTextured
37 | {
38 | return (([self styleMask] & NSTexturedBackgroundWindowMask) != 0);
39 | }
40 |
41 | @end
42 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/BWToolkitFramework.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolkitFramework.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | // This is a convenience header for importing the BWToolkit framework into your classes.
10 |
11 | #import "BWAnchoredButton.h"
12 | #import "BWAnchoredButtonBar.h"
13 | #import "BWAnchoredButtonCell.h"
14 | #import "BWAnchoredPopUpButton.h"
15 | #import "BWAnchoredPopUpButtonCell.h"
16 | #import "BWGradientBox.h"
17 | #import "BWHyperlinkButton.h"
18 | #import "BWHyperlinkButtonCell.h"
19 | #import "BWInsetTextField.h"
20 | #import "BWSelectableToolbar.h"
21 | #import "BWSheetController.h"
22 | #import "BWSplitView.h"
23 | #import "BWStyledTextField.h"
24 | #import "BWStyledTextFieldCell.h"
25 | #import "BWTexturedSlider.h"
26 | #import "BWTexturedSliderCell.h"
27 | #import "BWTokenAttachmentCell.h"
28 | #import "BWTokenField.h"
29 | #import "BWTokenFieldCell.h"
30 | #import "BWToolbarItem.h"
31 | #import "BWToolbarShowColorsItem.h"
32 | #import "BWToolbarShowFontsItem.h"
33 | #import "BWTransparentButton.h"
34 | #import "BWTransparentButtonCell.h"
35 | #import "BWTransparentCheckbox.h"
36 | #import "BWTransparentCheckboxCell.h"
37 | #import "BWTransparentPopUpButton.h"
38 | #import "BWTransparentPopUpButtonCell.h"
39 | #import "BWTransparentScroller.h"
40 | #import "BWTransparentScrollView.h"
41 | #import "BWTransparentSlider.h"
42 | #import "BWTransparentSliderCell.h"
43 | #import "BWTransparentTableView.h"
44 | #import "BWTransparentTableViewCell.h"
45 | #import "BWTransparentTextFieldCell.h"
46 | #import "BWUnanchoredButton.h"
47 | #import "BWUnanchoredButtonCell.h"
48 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddMiniBottomBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddMiniBottomBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAddMiniBottomBar : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddMiniBottomBar.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddMiniBottomBar.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAddMiniBottomBar.h"
10 | #import "NSWindow-NSTimeMachineSupport.h"
11 |
12 | @interface NSWindow (BWBBPrivate)
13 | - (void)setBottomCornerRounded:(BOOL)flag;
14 | @end
15 |
16 | @implementation BWAddMiniBottomBar
17 |
18 | - (id)initWithCoder:(NSCoder *)decoder;
19 | {
20 | if ((self = [super initWithCoder:decoder]) != nil)
21 | {
22 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)])
23 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
24 | }
25 | return self;
26 | }
27 |
28 | - (void)awakeFromNib
29 | {
30 | [[self window] setContentBorderThickness:16 forEdge:NSMinYEdge];
31 |
32 | // Private method
33 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
34 | [[self window] setBottomCornerRounded:NO];
35 | }
36 |
37 | - (void)drawRect:(NSRect)aRect
38 | {
39 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)] && [[self window] contentBorderThicknessForEdge:NSMinYEdge] == 0)
40 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
41 |
42 | if ([[self window] isSheet] && [[self window] respondsToSelector:@selector(setMovable:)])
43 | [[self window] setMovable:NO];
44 | }
45 |
46 | - (NSRect)bounds
47 | {
48 | return NSMakeRect(-10000,-10000,0,0);
49 | }
50 |
51 | @end
52 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddRegularBottomBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddRegularBottomBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAddRegularBottomBar : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddRegularBottomBar.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddRegularBottomBar.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAddRegularBottomBar.h"
10 | #import "NSWindow-NSTimeMachineSupport.h"
11 |
12 | @implementation BWAddRegularBottomBar
13 |
14 | - (id)initWithCoder:(NSCoder *)decoder;
15 | {
16 | if ((self = [super initWithCoder:decoder]) != nil)
17 | {
18 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)])
19 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
20 | }
21 | return self;
22 | }
23 |
24 | - (void)awakeFromNib
25 | {
26 | [[self window] setContentBorderThickness:34 forEdge:NSMinYEdge];
27 | }
28 |
29 | - (void)drawRect:(NSRect)aRect
30 | {
31 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)] && [[self window] contentBorderThicknessForEdge:NSMinYEdge] == 0)
32 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
33 |
34 | #ifndef APPSTORE
35 | if ([[self window] isSheet] && [[self window] respondsToSelector:@selector(setMovable:)])
36 | [[self window] setMovable:NO];
37 | #endif
38 | }
39 |
40 | - (NSRect)bounds
41 | {
42 | return NSMakeRect(-10000,-10000,0,0);
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddSheetBottomBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSheetBottomBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAddSheetBottomBar : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddSheetBottomBar.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSheetBottomBar.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAddSheetBottomBar.h"
10 | #import "NSWindow-NSTimeMachineSupport.h"
11 |
12 | @interface NSWindow (BWPrivate)
13 | - (void)setBottomCornerRounded:(BOOL)flag;
14 | @end
15 |
16 | @implementation BWAddSheetBottomBar
17 |
18 | - (id)initWithCoder:(NSCoder *)decoder;
19 | {
20 | if ((self = [super initWithCoder:decoder]) != nil)
21 | {
22 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)])
23 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
24 | }
25 | return self;
26 | }
27 |
28 | - (void)awakeFromNib
29 | {
30 | [[self window] setContentBorderThickness:40 forEdge:NSMinYEdge];
31 |
32 | // Private method
33 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
34 | [[self window] setBottomCornerRounded:NO];
35 | }
36 |
37 | - (void)drawRect:(NSRect)aRect
38 | {
39 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)] && [[self window] contentBorderThicknessForEdge:NSMinYEdge] == 0)
40 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
41 |
42 | if ([[self window] isSheet] && [[self window] respondsToSelector:@selector(setMovable:)])
43 | [[self window] setMovable:NO];
44 | }
45 |
46 | - (NSRect)bounds
47 | {
48 | return NSMakeRect(-10000,-10000,0,0);
49 | }
50 |
51 | @end
52 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddSmallBottomBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSmallBottomBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAddSmallBottomBar : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWAddSmallBottomBar.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSmallBottomBar.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAddSmallBottomBar.h"
10 | #import "NSWindow-NSTimeMachineSupport.h"
11 |
12 | @implementation BWAddSmallBottomBar
13 |
14 | - (id)initWithCoder:(NSCoder *)decoder;
15 | {
16 | if ((self = [super initWithCoder:decoder]) != nil)
17 | {
18 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)])
19 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
20 | }
21 | return self;
22 | }
23 |
24 | - (void)awakeFromNib
25 | {
26 | [[self window] setContentBorderThickness:24 forEdge:NSMinYEdge];
27 | }
28 |
29 | - (void)drawRect:(NSRect)aRect
30 | {
31 | if ([self respondsToSelector:@selector(ibDidAddToDesignableDocument:)] && [[self window] contentBorderThicknessForEdge:NSMinYEdge] == 0)
32 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
33 |
34 | #ifndef APPSTORE
35 | if ([[self window] isSheet] && [[self window] respondsToSelector:@selector(setMovable:)])
36 | [[self window] setMovable:NO];
37 | #endif
38 | }
39 |
40 | - (NSRect)bounds
41 | {
42 | return NSMakeRect(-10000,-10000,0,0);
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWRemoveBottomBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWRemoveBottomBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWRemoveBottomBar : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Bottom Bar/BWRemoveBottomBar.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWRemoveBottomBar.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWRemoveBottomBar.h"
10 |
11 | @implementation BWRemoveBottomBar
12 |
13 | - (NSRect)bounds
14 | {
15 | return NSMakeRect(-10000,-10000,0,0);
16 | }
17 |
18 | @end
19 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredButton : NSButton
12 | {
13 | BOOL isAtLeftEdgeOfBar;
14 | BOOL isAtRightEdgeOfBar;
15 | NSPoint topAndLeftInset;
16 | }
17 |
18 | @property BOOL isAtLeftEdgeOfBar;
19 | @property BOOL isAtRightEdgeOfBar;
20 |
21 | @end
22 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAnchoredButton.h"
10 | #import "BWAnchoredButtonBar.h"
11 | #import "NSView+BWAdditions.h"
12 |
13 | @implementation BWAnchoredButton
14 |
15 | @synthesize isAtLeftEdgeOfBar;
16 | @synthesize isAtRightEdgeOfBar;
17 |
18 | - (id)initWithCoder:(NSCoder *)decoder;
19 | {
20 | if ((self = [super initWithCoder:decoder]) != nil)
21 | {
22 | if ([BWAnchoredButtonBar wasBorderedBar])
23 | topAndLeftInset = NSMakePoint(0, 0);
24 | else
25 | topAndLeftInset = NSMakePoint(1, 1);
26 | }
27 | return self;
28 | }
29 |
30 | - (void)mouseDown:(NSEvent *)theEvent
31 | {
32 | [self bwBringToFront];
33 | [super mouseDown:theEvent];
34 | }
35 |
36 | - (NSRect)frame
37 | {
38 | NSRect frame = [super frame];
39 | frame.size.height = 24;
40 | return frame;
41 | }
42 |
43 | @end
44 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredButtonBar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonBar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredButtonBar : NSView
12 | {
13 | BOOL isResizable, isAtBottom, handleIsRightAligned;
14 | int selectedIndex;
15 | }
16 |
17 | @property (nonatomic) BOOL isResizable, isAtBottom, handleIsRightAligned;
18 | @property (nonatomic) int selectedIndex;
19 |
20 | // The mode of this bar with a resize handle makes use of some NSSplitView delegate methods. Use the splitViewDelegate for any custom delegate implementations
21 | // you'd like to provide.
22 | @property (assign) id splitViewDelegate;
23 |
24 | + (BOOL)wasBorderedBar;
25 |
26 | @end
27 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredButtonCell : NSButtonCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredPopUpButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredPopUpButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredPopUpButton : NSPopUpButton
12 | {
13 | BOOL isAtLeftEdgeOfBar;
14 | BOOL isAtRightEdgeOfBar;
15 | NSPoint topAndLeftInset;
16 | }
17 |
18 | @property BOOL isAtLeftEdgeOfBar;
19 | @property BOOL isAtRightEdgeOfBar;
20 |
21 | @end
22 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredPopUpButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredPopUpButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAnchoredPopUpButton.h"
10 | #import "BWAnchoredButtonBar.h"
11 | #import "NSView+BWAdditions.h"
12 |
13 | @implementation BWAnchoredPopUpButton
14 |
15 | @synthesize isAtLeftEdgeOfBar;
16 | @synthesize isAtRightEdgeOfBar;
17 |
18 | - (id)initWithCoder:(NSCoder *)decoder;
19 | {
20 | if ((self = [super initWithCoder:decoder]) != nil)
21 | {
22 | if ([BWAnchoredButtonBar wasBorderedBar])
23 | topAndLeftInset = NSMakePoint(0, 0);
24 | else
25 | topAndLeftInset = NSMakePoint(1, 1);
26 | }
27 | return self;
28 | }
29 |
30 | - (void)mouseDown:(NSEvent *)theEvent
31 | {
32 | [self bwBringToFront];
33 | [super mouseDown:theEvent];
34 | }
35 |
36 | - (NSRect)frame
37 | {
38 | NSRect frame = [super frame];
39 | frame.size.height = 24;
40 | return frame;
41 | }
42 |
43 | @end
44 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWAnchoredPopUpButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredPopUpButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredPopUpButtonCell : NSPopUpButtonCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWUnanchoredButton : NSButton
12 | {
13 | NSPoint topAndLeftInset;
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWUnanchoredButton.h"
10 | #import "BWAnchoredButtonBar.h"
11 | #import "NSView+BWAdditions.h"
12 |
13 | @implementation BWUnanchoredButton
14 |
15 | - (id)initWithCoder:(NSCoder *)decoder;
16 | {
17 | if ((self = [super initWithCoder:decoder]) != nil)
18 | {
19 | if ([BWAnchoredButtonBar wasBorderedBar])
20 | topAndLeftInset = NSMakePoint(0, 0);
21 | else
22 | topAndLeftInset = NSMakePoint(1, 1);
23 | }
24 | return self;
25 | }
26 |
27 | - (void)mouseDown:(NSEvent *)theEvent
28 | {
29 | [self bwBringToFront];
30 | [super mouseDown:theEvent];
31 | }
32 |
33 | - (NSRect)frame
34 | {
35 | NSRect frame = [super frame];
36 | frame.size.height = 22;
37 | return frame;
38 | }
39 |
40 | @end
41 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAnchoredButtonCell.h"
11 |
12 | @interface BWUnanchoredButtonCell : BWAnchoredButtonCell
13 | {
14 |
15 | }
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButtonCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWUnanchoredButtonCell.h"
10 | #import "BWUnanchoredButton.h"
11 | #import "NSColor+BWAdditions.h"
12 |
13 | static NSColor *fillStop1, *fillStop2, *fillStop3, *fillStop4;
14 | static NSColor *borderColor, *topBorderColor, *bottomInsetColor, *topInsetColor, *pressedColor;
15 | static NSGradient *fillGradient;
16 |
17 | @implementation BWUnanchoredButtonCell
18 |
19 | + (void)initialize;
20 | {
21 | fillStop1 = [[NSColor colorWithCalibratedWhite:(251.0f / 255.0f) alpha:1] retain];
22 | fillStop2 = [[NSColor colorWithCalibratedWhite:(251.0f / 255.0f) alpha:1] retain];
23 | fillStop3 = [[NSColor colorWithCalibratedWhite:(236.0f / 255.0f) alpha:1] retain];
24 | fillStop4 = [[NSColor colorWithCalibratedWhite:(243.0f / 255.0f) alpha:1] retain];
25 |
26 | fillGradient = [[NSGradient alloc] initWithColorsAndLocations:
27 | fillStop1, (CGFloat)0.0,
28 | fillStop2, (CGFloat)0.5,
29 | fillStop3, (CGFloat)0.5,
30 | fillStop4, (CGFloat)1.0,
31 | nil];
32 |
33 | topBorderColor = [[NSColor colorWithCalibratedWhite:(126.0f / 255.0f) alpha:1] retain];
34 | borderColor = [[NSColor colorWithCalibratedWhite:(151.0f / 255.0f) alpha:1] retain];
35 |
36 | topInsetColor = [[NSColor colorWithCalibratedWhite:(0.0f / 255.0f) alpha:0.08] retain];
37 | bottomInsetColor = [[NSColor colorWithCalibratedWhite:(255.0f / 255.0f) alpha:0.54] retain];
38 |
39 | pressedColor = [[NSColor colorWithCalibratedWhite:(0.0f / 255.0f) alpha:0.3] retain];
40 | }
41 |
42 | - (void)drawBezelWithFrame:(NSRect)cellFrame inView:(NSView *)controlView
43 | {
44 | [fillGradient drawInRect:NSInsetRect(cellFrame, 0, 2) angle:90];
45 |
46 | [topInsetColor bwDrawPixelThickLineAtPosition:0 withInset:0 inRect:cellFrame inView:[self controlView] horizontal:YES flip:NO];
47 | [topBorderColor bwDrawPixelThickLineAtPosition:1 withInset:0 inRect:cellFrame inView:[self controlView] horizontal:YES flip:NO];
48 | [borderColor bwDrawPixelThickLineAtPosition:1 withInset:0 inRect:cellFrame inView:[self controlView] horizontal:YES flip:YES];
49 | [bottomInsetColor bwDrawPixelThickLineAtPosition:0 withInset:0 inRect:cellFrame inView:[self controlView] horizontal:YES flip:YES];
50 |
51 | [borderColor bwDrawPixelThickLineAtPosition:0 withInset:2 inRect:cellFrame inView:[self controlView] horizontal:NO flip:YES];
52 | [borderColor bwDrawPixelThickLineAtPosition:0 withInset:2 inRect:cellFrame inView:[self controlView] horizontal:NO flip:NO];
53 | }
54 |
55 | - (NSRect)highlightRectForBounds:(NSRect)bounds
56 | {
57 | return NSInsetRect(bounds, 0, 1);
58 | }
59 |
60 | @end
61 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButtonContainer.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonContainer.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWUnanchoredButtonContainer : NSView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Button Bar/BWUnanchoredButtonContainer.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonContainer.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | // See the integration class
10 |
11 | #import "BWUnanchoredButtonContainer.h"
12 |
13 | @implementation BWUnanchoredButtonContainer
14 |
15 | - (void)awakeFromNib
16 | {
17 | for (NSView *subview in [self subviews])
18 | {
19 | [subview setFrameSize:NSMakeSize(subview.frame.size.width, 22)];
20 | }
21 | }
22 |
23 | @end
24 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Gradient Box/BWGradientBox.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientBox.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWGradientBox : NSView
12 | {
13 | NSColor *fillStartingColor, *fillEndingColor, *fillColor;
14 | NSColor *topBorderColor, *bottomBorderColor;
15 | float topInsetAlpha, bottomInsetAlpha;
16 |
17 | BOOL hasTopBorder, hasBottomBorder, hasGradient, hasFillColor;
18 | }
19 |
20 | @property (nonatomic, strong) NSColor *fillStartingColor, *fillEndingColor, *fillColor, *topBorderColor, *bottomBorderColor;
21 | @property float topInsetAlpha, bottomInsetAlpha;
22 | @property BOOL hasTopBorder, hasBottomBorder, hasGradient, hasFillColor;
23 |
24 | @end
25 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Hyperlink Button/BWHyperlinkButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWHyperlinkButton : NSButton
12 | {
13 | NSString *urlString;
14 | }
15 |
16 | @property (copy, nonatomic) NSString *urlString;
17 |
18 | @end
19 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Hyperlink Button/BWHyperlinkButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWHyperlinkButton.h"
10 | #import "BWHyperlinkButtonCell.h"
11 |
12 | @implementation BWHyperlinkButton
13 |
14 | @synthesize urlString;
15 |
16 | -(void)awakeFromNib
17 | {
18 | [self setTarget:self];
19 | [self setAction:@selector(openURLInBrowser:)];
20 | }
21 |
22 | - (id)initWithCoder:(NSCoder *)decoder
23 | {
24 | if ((self = [super initWithCoder:decoder]) != nil)
25 | {
26 | [self setUrlString:[decoder decodeObjectForKey:@"BWHBUrlString"]];
27 | }
28 | return self;
29 | }
30 |
31 | - (void)encodeWithCoder:(NSCoder *)coder
32 | {
33 | [super encodeWithCoder:coder];
34 |
35 | [coder encodeObject:[self urlString] forKey:@"BWHBUrlString"];
36 | }
37 |
38 | - (void)openURLInBrowser:(id)sender
39 | {
40 | if (![self respondsToSelector:@selector(ibDidAddToDesignableDocument:)])
41 | [[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:self.urlString]];
42 | }
43 |
44 | - (void)resetCursorRects
45 | {
46 | [self addCursorRect:[self bounds] cursor:[NSCursor pointingHandCursor]];
47 | }
48 |
49 | - (void)dealloc
50 | {
51 | [urlString release];
52 | [super dealloc];
53 | }
54 |
55 | @end
56 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Hyperlink Button/BWHyperlinkButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWHyperlinkButtonCell : NSButtonCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Hyperlink Button/BWHyperlinkButtonCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButtonCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWHyperlinkButtonCell.h"
10 |
11 | @interface NSCell (BWPrivate)
12 | - (NSDictionary *)_textAttributes;
13 | @end
14 |
15 | @implementation BWHyperlinkButtonCell
16 |
17 | - (NSDictionary *)_textAttributes
18 | {
19 | NSMutableDictionary *attributes = [[[NSMutableDictionary alloc] init] autorelease];
20 | [attributes addEntriesFromDictionary:[super _textAttributes]];
21 | [attributes setObject:[NSColor blueColor] forKey:NSForegroundColorAttributeName];
22 | [attributes setObject:[NSNumber numberWithInt:NSSingleUnderlineStyle] forKey:NSUnderlineStyleAttributeName];
23 |
24 | return attributes;
25 | }
26 |
27 | - (void)drawBezelWithFrame:(NSRect)frame inView:(NSView *)controlView
28 | {
29 |
30 | }
31 |
32 | - (void)setBordered:(BOOL)flag
33 | {
34 |
35 | }
36 |
37 | - (BOOL)isBordered
38 | {
39 | return YES;
40 | }
41 |
42 | @end
43 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Inset Text Field/BWInsetTextField.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWInsetTextField.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWInsetTextField : NSTextField
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Inset Text Field/BWInsetTextField.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWInsetTextField.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWInsetTextField.h"
10 |
11 | @implementation BWInsetTextField
12 |
13 | - (id)initWithCoder:(NSCoder *)decoder;
14 | {
15 | self = [super initWithCoder:decoder];
16 |
17 | if (self)
18 | {
19 | [[self cell] setBackgroundStyle:NSBackgroundStyleRaised];
20 | }
21 |
22 | return self;
23 | }
24 |
25 | @end
26 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Selectable Toolbar/BWSelectableToolbar.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbar.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @class BWSelectableToolbarHelper;
12 |
13 | // Notification that gets sent when a toolbar item has been clicked. You can get the button that was clicked by getting the object
14 | // for the key @"BWClickedItem" in the supplied userInfo dictionary.
15 | extern NSString * const BWSelectableToolbarItemClickedNotification;
16 |
17 | @interface BWSelectableToolbar : NSToolbar
18 | {
19 | BWSelectableToolbarHelper *helper;
20 | NSMutableArray *itemIdentifiers;
21 | NSMutableDictionary *itemsByIdentifier, *enabledByIdentifier;
22 | BOOL inIB;
23 |
24 | // For the IB inspector
25 | int selectedIndex;
26 | BOOL isPreferencesToolbar;
27 | }
28 |
29 | // Call one of these methods to set the active tab.
30 | - (void)setSelectedItemIdentifier:(NSString *)itemIdentifier; // Use if you want an action in the tabbed window to change the tab.
31 | - (void)setSelectedItemIdentifierWithoutAnimation:(NSString *)itemIdentifier; // Use if you want to show the window with a certain item selected.
32 |
33 | // Programmatically disable or enable a toolbar item.
34 | - (void)setEnabled:(BOOL)flag forIdentifier:(NSString *)itemIdentifier;
35 |
36 | @end
37 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Selectable Toolbar/BWSelectableToolbarHelper.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbarHelper.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWSelectableToolbarHelper : NSObject
12 | {
13 | NSMutableDictionary *contentViewsByIdentifier, *windowSizesByIdentifier;
14 | NSString *selectedIdentifier, *oldWindowTitle;
15 | NSSize initialIBWindowSize;
16 | BOOL isPreferencesToolbar;
17 | }
18 |
19 | @property (copy) NSMutableDictionary *contentViewsByIdentifier;
20 | @property (copy) NSMutableDictionary *windowSizesByIdentifier;
21 | @property (copy) NSString *selectedIdentifier;
22 | @property (copy) NSString *oldWindowTitle;
23 | @property (assign) NSSize initialIBWindowSize;
24 | @property (assign) BOOL isPreferencesToolbar;
25 |
26 | @end
27 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Selectable Toolbar/BWSelectableToolbarHelper.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbarHelper.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWSelectableToolbarHelper.h"
10 |
11 | @implementation BWSelectableToolbarHelper
12 |
13 | @synthesize contentViewsByIdentifier;
14 | @synthesize windowSizesByIdentifier;
15 | @synthesize selectedIdentifier;
16 | @synthesize oldWindowTitle;
17 | @synthesize initialIBWindowSize;
18 | @synthesize isPreferencesToolbar;
19 |
20 | - (id)init
21 | {
22 | if(self = [super init])
23 | {
24 | if (contentViewsByIdentifier == nil)
25 | contentViewsByIdentifier = [[NSMutableDictionary alloc] init];
26 |
27 | if (windowSizesByIdentifier == nil)
28 | windowSizesByIdentifier = [[NSMutableDictionary alloc] init];
29 |
30 | if (selectedIdentifier == nil)
31 | selectedIdentifier = [[NSString alloc] init];
32 |
33 | if (oldWindowTitle == nil)
34 | oldWindowTitle = [[NSString alloc] init];
35 | }
36 | return self;
37 | }
38 |
39 | - (id)initWithCoder:(NSCoder *)decoder;
40 | {
41 | if ((self = [super init]) != nil)
42 | {
43 | [self setContentViewsByIdentifier:[decoder decodeObjectForKey:@"BWSTHContentViewsByIdentifier"]];
44 |
45 | NSData *data = [decoder decodeObjectForKey:@"BWSTHWindowSizesByIdentifier"];
46 | [self setWindowSizesByIdentifier:[NSUnarchiver unarchiveObjectWithData:data]];
47 |
48 | [self setSelectedIdentifier:[decoder decodeObjectForKey:@"BWSTHSelectedIdentifier"]];
49 |
50 | [self setOldWindowTitle:[decoder decodeObjectForKey:@"BWSTHOldWindowTitle"]];
51 |
52 | [self setInitialIBWindowSize:[decoder decodeSizeForKey:@"BWSTHInitialIBWindowSize"]];
53 |
54 | [self setIsPreferencesToolbar:[decoder decodeBoolForKey:@"BWSTHIsPreferencesToolbar"]];
55 | }
56 | return self;
57 | }
58 |
59 | - (void)encodeWithCoder:(NSCoder*)coder
60 | {
61 | [coder encodeObject:[self contentViewsByIdentifier] forKey:@"BWSTHContentViewsByIdentifier"];
62 |
63 | NSData *data = [NSArchiver archivedDataWithRootObject:[self windowSizesByIdentifier]];
64 | [coder encodeObject:data forKey:@"BWSTHWindowSizesByIdentifier"];
65 |
66 | [coder encodeObject:[self selectedIdentifier] forKey:@"BWSTHSelectedIdentifier"];
67 |
68 | [coder encodeObject:[self oldWindowTitle] forKey:@"BWSTHOldWindowTitle"];
69 |
70 | [coder encodeSize:[self initialIBWindowSize] forKey:@"BWSTHInitialIBWindowSize"];
71 |
72 | [coder encodeBool:[self isPreferencesToolbar] forKey:@"BWSTHIsPreferencesToolbar"];
73 | }
74 |
75 | - (void)dealloc
76 | {
77 | [contentViewsByIdentifier release];
78 | [windowSizesByIdentifier release];
79 | [selectedIdentifier release];
80 | [oldWindowTitle release];
81 | [super dealloc];
82 | }
83 |
84 | @end
85 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Sheet Controller/BWSheetController.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSheetController.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWSheetController : NSObject
12 | {
13 | NSWindow *sheet;
14 | NSWindow *parentWindow;
15 | id delegate;
16 | }
17 |
18 | @property (nonatomic, retain) IBOutlet NSWindow *sheet, *parentWindow;
19 | @property (nonatomic, retain) IBOutlet id delegate;
20 |
21 | - (IBAction)openSheet:(id)sender;
22 | - (IBAction)closeSheet:(id)sender;
23 | - (IBAction)messageDelegateAndCloseSheet:(id)sender;
24 |
25 | // The optional delegate should implement the method:
26 | // - (BOOL)shouldCloseSheet:(id)sender
27 | // Return YES if you want the sheet to close after the button click, NO if it shouldn't close. The sender
28 | // object is the button that requested the close. This is helpful because in the event that there are multiple buttons
29 | // hooked up to the messageDelegateAndCloseSheet: method, you can distinguish which button called the method.
30 |
31 | @end
32 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Sheet Controller/BWSheetController.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSheetController.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWSheetController.h"
10 | #import "NSWindow-NSTimeMachineSupport.h"
11 |
12 | @implementation BWSheetController
13 |
14 | @synthesize parentWindow, sheet, delegate;
15 |
16 | - (void)awakeFromNib
17 | {
18 | // Hack so the sheet doesn't appear at launch in Cocoa Simulator (or in the actual app if "Visible at Launch" is checked)
19 | [sheet setAlphaValue:0];
20 | [sheet performSelector:@selector(orderOut:) withObject:nil afterDelay:0];
21 |
22 | // If the sheet has a toolbar or a bottom bar, make sure those elements can't move the window (private API)
23 | if ([sheet respondsToSelector:@selector(setMovable:)])
24 | [sheet setMovable:NO];
25 | }
26 |
27 | - (id)initWithCoder:(NSCoder *)decoder;
28 | {
29 | if ((self = [super init]) != nil)
30 | {
31 | NSWindowController *tempSheetController = [decoder decodeObjectForKey:@"BWSCSheet"];
32 | NSWindowController *tempParentWindowController = [decoder decodeObjectForKey:@"BWSCParentWindow"];
33 |
34 | sheet = [tempSheetController window];
35 | parentWindow = [tempParentWindowController window];
36 | }
37 | return self;
38 | }
39 |
40 | - (void)encodeWithCoder:(NSCoder*)coder
41 | {
42 | NSWindowController *tempSheetController = [[[NSWindowController alloc] initWithWindow:sheet] autorelease];
43 | NSWindowController *tempParentWindowController = [[[NSWindowController alloc] initWithWindow:parentWindow] autorelease];
44 |
45 | [coder encodeObject:tempSheetController forKey:@"BWSCSheet"];
46 | [coder encodeObject:tempParentWindowController forKey:@"BWSCParentWindow"];
47 | }
48 |
49 | - (IBAction)openSheet:(id)sender
50 | {
51 | [sheet setAlphaValue:1];
52 | [NSApp beginSheet:sheet modalForWindow:parentWindow modalDelegate:nil didEndSelector:nil contextInfo:nil];
53 | }
54 |
55 | - (IBAction)closeSheet:(id)sender
56 | {
57 | [sheet orderOut:nil];
58 | [NSApp endSheet:sheet];
59 | }
60 |
61 | - (IBAction)messageDelegateAndCloseSheet:(id)sender
62 | {
63 | if (delegate != nil && [delegate respondsToSelector:@selector(shouldCloseSheet:)])
64 | {
65 | if ([delegate performSelector:@selector(shouldCloseSheet:) withObject:sender])
66 | [self closeSheet:self];
67 | }
68 | else
69 | {
70 | [self closeSheet:self];
71 | }
72 | }
73 |
74 |
75 | @end
76 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Split View/BWCustomView.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientSplitViewSubview.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "NSCustomView.h"
11 |
12 | @interface BWCustomView : NSCustomView
13 | {
14 | BOOL isOnItsOwn;
15 | }
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Split View/BWSplitView.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSplitView.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com) and Fraser Kuyvenhoven.
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWSplitView : NSSplitView
12 | {
13 | NSColor *color;
14 | BOOL colorIsEnabled, checkboxIsEnabled, dividerCanCollapse, collapsibleSubviewCollapsed;
15 | NSMutableDictionary *minValues, *maxValues, *minUnits, *maxUnits;
16 | NSMutableDictionary *resizableSubviewPreferredProportion, *nonresizableSubviewPreferredSize;
17 | NSArray *stateForLastPreferredCalculations;
18 | int collapsiblePopupSelection;
19 | float uncollapsedSize;
20 |
21 | // Collapse button
22 | NSButton *toggleCollapseButton;
23 | BOOL isAnimating;
24 | }
25 |
26 | @property (nonatomic, strong) NSMutableDictionary *minValues, *maxValues, *minUnits, *maxUnits;
27 | @property (strong) NSMutableDictionary *resizableSubviewPreferredProportion, *nonresizableSubviewPreferredSize;
28 | @property (strong) NSArray *stateForLastPreferredCalculations;
29 | @property (strong) NSButton *toggleCollapseButton;
30 | @property (assign) id secondaryDelegate;
31 | @property (nonatomic) BOOL collapsibleSubviewCollapsed;
32 | @property int collapsiblePopupSelection;
33 | @property BOOL dividerCanCollapse;
34 |
35 | // The split view divider color
36 | @property (copy) NSColor *color;
37 |
38 | // Flag for whether a custom divider color is enabled. If not, the standard divider color is used.
39 | @property (nonatomic) BOOL colorIsEnabled;
40 |
41 | // Call this method to collapse or expand a subview configured as collapsible in the IB inspector.
42 | - (IBAction)toggleCollapse:(id)sender;
43 |
44 | @end
45 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Styled Text Field/BWStyledTextField.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextField.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWStyledTextField : NSTextField
12 | {
13 |
14 | }
15 |
16 | - (BOOL)hasGradient;
17 | - (void)setHasGradient:(BOOL)flag;
18 | - (NSColor *)startingColor;
19 | - (void)setStartingColor:(NSColor *)color;
20 | - (NSColor *)endingColor;
21 | - (void)setEndingColor:(NSColor *)color;
22 |
23 | - (NSColor *)solidColor;
24 | - (void)setSolidColor:(NSColor *)color;
25 |
26 | - (BOOL)hasShadow;
27 | - (void)setHasShadow:(BOOL)flag;
28 | - (BOOL)shadowIsBelow;
29 | - (void)setShadowIsBelow:(BOOL)flag;
30 | - (NSColor *)shadowColor;
31 | - (void)setShadowColor:(NSColor *)color;
32 |
33 | @end
34 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Styled Text Field/BWStyledTextField.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextField.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWStyledTextField.h"
10 |
11 | @implementation BWStyledTextField
12 |
13 | #pragma mark Shadow
14 |
15 | - (BOOL)hasShadow
16 | {
17 | return [[self cell] hasShadow];
18 | }
19 |
20 | - (void)setHasShadow:(BOOL)flag
21 | {
22 | [[self cell] setHasShadow:flag];
23 |
24 | [self setNeedsDisplay:YES];
25 | }
26 |
27 | - (BOOL)shadowIsBelow
28 | {
29 | return [[self cell] shadowIsBelow];
30 | }
31 |
32 | - (void)setShadowIsBelow:(BOOL)flag
33 | {
34 | [[self cell] setShadowIsBelow:flag];
35 |
36 | [self setNeedsDisplay:YES];
37 | }
38 |
39 | - (NSColor *)shadowColor
40 | {
41 | return (NSColor *)[[self cell] shadowColor];
42 | }
43 |
44 | - (void)setShadowColor:(NSColor *)color
45 | {
46 | [[self cell] setShadowColor:(__bridge CGColorRef)(color)];
47 |
48 | [self setNeedsDisplay:YES];
49 | }
50 |
51 | #pragma mark Fill
52 |
53 | - (BOOL)hasGradient
54 | {
55 | return [[self cell] hasGradient];
56 | }
57 |
58 | - (void)setHasGradient:(BOOL)flag
59 | {
60 | [[self cell] setHasGradient:flag];
61 |
62 | [self setNeedsDisplay:YES];
63 | }
64 |
65 | - (NSColor *)startingColor
66 | {
67 | return [[self cell] startingColor];
68 | }
69 |
70 | - (void)setStartingColor:(NSColor *)color
71 | {
72 | [[self cell] setStartingColor:color];
73 |
74 | [self setNeedsDisplay:YES];
75 | }
76 |
77 | - (NSColor *)endingColor
78 | {
79 | return [[self cell] endingColor];
80 | }
81 |
82 | - (void)setEndingColor:(NSColor *)color
83 | {
84 | [[self cell] setEndingColor:color];
85 |
86 | [self setNeedsDisplay:YES];
87 | }
88 |
89 | - (NSColor *)solidColor
90 | {
91 | return [[self cell] solidColor];
92 | }
93 |
94 | - (void)setSolidColor:(NSColor *)color
95 | {
96 | [[self cell] setSolidColor:color];
97 |
98 | [self setNeedsDisplay:YES];
99 | }
100 |
101 | @end
102 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Styled Text Field/BWStyledTextFieldCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextFieldCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWStyledTextFieldCell : NSTextFieldCell
12 | {
13 | BOOL shadowIsBelow, hasShadow, hasGradient;
14 | NSColor *shadowColor, *startingColor, *endingColor, *solidColor;
15 |
16 | NSShadow *shadow;
17 | NSMutableDictionary *previousAttributes;
18 | }
19 |
20 | @property (nonatomic) BOOL shadowIsBelow, hasShadow, hasGradient;
21 | @property (nonatomic, strong) NSColor *shadowColor, *startingColor, *endingColor, *solidColor;
22 |
23 | @end
24 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Textured Slider/BWTexturedSlider.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTexturedSlider.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTexturedSlider : NSSlider
12 | {
13 | int trackHeight, indicatorIndex;
14 | NSRect sliderCellRect;
15 | NSButton *minButton, *maxButton;
16 | }
17 |
18 | @property int indicatorIndex;
19 | @property (retain) NSButton *minButton;
20 | @property (retain) NSButton *maxButton;
21 |
22 | - (int)trackHeight;
23 | - (void)setTrackHeight:(int)newTrackHeight;
24 |
25 | @end
26 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Textured Slider/BWTexturedSliderCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTexturedSliderCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTexturedSliderCell : NSSliderCell
12 | {
13 | BOOL isPressed;
14 | int trackHeight;
15 | }
16 |
17 | @property int trackHeight;
18 |
19 | @end
20 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Token Field/BWTokenAttachmentCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTokenAttachmentCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "NSTokenAttachmentCell.h"
11 |
12 | @interface BWTokenAttachmentCell : NSTokenAttachmentCell
13 | {
14 |
15 | }
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Token Field/BWTokenField.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTokenField.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTokenField : NSTokenField
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Token Field/BWTokenField.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTokenField.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTokenField.h"
10 |
11 | @implementation BWTokenField
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Token Field/BWTokenFieldCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTokenFieldCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTokenFieldCell : NSTokenFieldCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Token Field/BWTokenFieldCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTokenFieldCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTokenFieldCell.h"
10 | #import "BWTokenAttachmentCell.h"
11 |
12 | @implementation BWTokenFieldCell
13 |
14 | - (id)setUpTokenAttachmentCell:(NSTokenAttachmentCell *)aCell forRepresentedObject:(id)anObj
15 | {
16 | BWTokenAttachmentCell *attachmentCell = [[BWTokenAttachmentCell alloc] initTextCell:[aCell stringValue]];
17 |
18 | [attachmentCell setRepresentedObject:anObj];
19 | [attachmentCell setAttachment:[aCell attachment]];
20 | [attachmentCell setControlSize:[self controlSize]];
21 | [attachmentCell setTextColor:[NSColor blackColor]];
22 | [attachmentCell setFont:[self font]];
23 |
24 | return [attachmentCell autorelease];
25 | }
26 |
27 | @end
28 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarItem.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarItem.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWToolbarItem : NSToolbarItem
12 | {
13 | NSString *identifierString;
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarItem.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarItem.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWToolbarItem.h"
10 | #import "NSString+BWAdditions.h"
11 |
12 | @interface BWToolbarItem ()
13 | @property (copy) NSString *identifierString;
14 | @end
15 |
16 | @interface NSToolbarItem (BWTIPrivate)
17 | - (void)_setItemIdentifier:(id)fp8;
18 | - (id)initWithCoder:(NSCoder *)coder;
19 | - (void)encodeWithCoder:(NSCoder*)coder;
20 | @end
21 |
22 | @implementation BWToolbarItem
23 |
24 | @synthesize identifierString;
25 |
26 | - (id)initWithCoder:(NSCoder *)coder
27 | {
28 | if ((self = [super initWithCoder:coder]) != nil)
29 | {
30 | [self setIdentifierString:[coder decodeObjectForKey:@"BWTIIdentifierString"]];
31 | }
32 | return self;
33 | }
34 |
35 | - (void)encodeWithCoder:(NSCoder*)coder
36 | {
37 | [super encodeWithCoder:coder];
38 |
39 | [coder encodeObject:[self identifierString] forKey:@"BWTIIdentifierString"];
40 | }
41 |
42 | - (void)setIdentifierString:(NSString *)aString
43 | {
44 | if (identifierString != aString)
45 | {
46 | [identifierString release];
47 | identifierString = [aString copy];
48 | }
49 |
50 | if (identifierString == nil || [identifierString isEqualToString:@""])
51 | [self _setItemIdentifier:[[NSString bwRandomUUID] retain]];
52 | else
53 | [self _setItemIdentifier:identifierString];
54 | }
55 |
56 | - (void)dealloc
57 | {
58 | [identifierString release];
59 | [super dealloc];
60 | }
61 |
62 | @end
63 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarShowColorsItem.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarShowColorsItem.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWToolbarShowColorsItem : NSToolbarItem
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarShowColorsItem.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarShowColorsItem.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWToolbarShowColorsItem.h"
10 |
11 | @implementation BWToolbarShowColorsItem
12 |
13 | - (NSImage *)image
14 | {
15 | NSBundle *bundle = [NSBundle bundleForClass:[BWToolbarShowColorsItem class]];
16 | NSImage *image = [[[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"ToolbarItemColors.tiff"]] autorelease];
17 |
18 | return image;
19 | }
20 |
21 | - (NSString *)itemIdentifier
22 | {
23 | return @"BWToolbarShowColorsItem";
24 | }
25 |
26 | - (NSString *)label
27 | {
28 | return @"Colors";
29 | }
30 |
31 | - (NSString *)paletteLabel
32 | {
33 | return @"Colors";
34 | }
35 |
36 | - (id)target
37 | {
38 | return [NSApplication sharedApplication];
39 | }
40 |
41 | - (SEL)action
42 | {
43 | return @selector(orderFrontColorPanel:);
44 | }
45 |
46 | - (NSString *)toolTip
47 | {
48 | return @"Show Color Panel";
49 | }
50 |
51 | @end
52 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarShowFontsItem.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarShowFontsItem.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWToolbarShowFontsItem : NSToolbarItem
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Toolbar Items/BWToolbarShowFontsItem.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarShowFontsItem.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWToolbarShowFontsItem.h"
10 |
11 | @implementation BWToolbarShowFontsItem
12 |
13 | - (NSImage *)image
14 | {
15 | NSBundle *bundle = [NSBundle bundleForClass:[BWToolbarShowFontsItem class]];
16 | NSImage *image = [[[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"ToolbarItemFonts.tiff"]] autorelease];
17 |
18 | return image;
19 | }
20 |
21 | - (NSString *)itemIdentifier
22 | {
23 | return @"BWToolbarShowFontsItem";
24 | }
25 |
26 | - (NSString *)label
27 | {
28 | return @"Fonts";
29 | }
30 |
31 | - (NSString *)paletteLabel
32 | {
33 | return @"Fonts";
34 | }
35 |
36 | - (id)target
37 | {
38 | return [NSApplication sharedApplication];
39 | }
40 |
41 | - (SEL)action
42 | {
43 | return @selector(orderFrontFontPanel:);
44 | }
45 |
46 | - (NSString *)toolTip
47 | {
48 | return @"Show Font Panel";
49 | }
50 |
51 | @end
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentButton : NSButton
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentButton.h"
10 |
11 | @implementation BWTransparentButton
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentButton.h"
11 |
12 | @interface BWTransparentButtonCell : NSButtonCell
13 | {
14 |
15 | }
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentButtonCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentButtonCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentButtonCell.h"
10 | #import "NSImage+BWAdditions.h"
11 |
12 | static NSImage *buttonLeftN, *buttonFillN, *buttonRightN, *buttonLeftP, *buttonFillP, *buttonRightP;
13 | static NSColor *disabledColor, *enabledColor;
14 |
15 | @interface NSCell (BWTBCPrivate)
16 | - (NSDictionary *)_textAttributes;
17 | @end
18 |
19 | @interface BWTransparentButtonCell (BWTBCPrivate)
20 | - (NSColor *)interiorColor;
21 | @end
22 |
23 | @implementation BWTransparentButtonCell
24 |
25 | + (void)initialize;
26 | {
27 | NSBundle *bundle = [NSBundle bundleForClass:[BWTransparentButtonCell class]];
28 |
29 | buttonLeftN = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonLeftN.tiff"]];
30 | buttonFillN = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonFillN.tiff"]];
31 | buttonRightN = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonRightN.tiff"]];
32 | buttonLeftP = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonLeftP.tiff"]];
33 | buttonFillP = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonFillP.tiff"]];
34 | buttonRightP = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"TransparentButtonRightP.tiff"]];
35 |
36 | enabledColor = [[NSColor whiteColor] retain];
37 | disabledColor = [[NSColor colorWithCalibratedWhite:0.6 alpha:1] retain];
38 | }
39 |
40 | - (void)drawBezelWithFrame:(NSRect)cellFrame inView:(NSView *)controlView
41 | {
42 | cellFrame.size.height = buttonFillN.size.height;
43 |
44 | if ([self isHighlighted])
45 | NSDrawThreePartImage(cellFrame, buttonLeftP, buttonFillP, buttonRightP, NO, NSCompositeSourceOver, 1, YES);
46 | else
47 | NSDrawThreePartImage(cellFrame, buttonLeftN, buttonFillN, buttonRightN, NO, NSCompositeSourceOver, 1, YES);
48 | }
49 |
50 | - (void)drawImage:(NSImage *)image withFrame:(NSRect)frame inView:(NSView *)controlView
51 | {
52 | frame.origin.y -= 2;
53 |
54 | if ([[image name] isEqualToString:@"NSActionTemplate"])
55 | [image setSize:NSMakeSize(10,10)];
56 |
57 | NSImage *newImage = image;
58 |
59 | if ([image isTemplate])
60 | newImage = [image bwTintedImageWithColor:[self interiorColor]];
61 |
62 | [super drawImage:newImage withFrame:frame inView:controlView];
63 | }
64 |
65 | - (NSRect)drawTitle:(NSAttributedString *)title withFrame:(NSRect)frame inView:(NSView *)controlView
66 | {
67 | frame.origin.y -= 4;
68 |
69 | return [super drawTitle:title withFrame:frame inView:controlView];
70 | }
71 |
72 | - (NSDictionary *)_textAttributes
73 | {
74 | NSMutableDictionary *attributes = [[[NSMutableDictionary alloc] init] autorelease];
75 | [attributes addEntriesFromDictionary:[super _textAttributes]];
76 | [attributes setObject:[NSFont systemFontOfSize:11] forKey:NSFontAttributeName];
77 | [attributes setObject:[self interiorColor] forKey:NSForegroundColorAttributeName];
78 |
79 | return attributes;
80 | }
81 |
82 | - (NSColor *)interiorColor
83 | {
84 | NSColor *interiorColor;
85 |
86 | if ([self isEnabled])
87 | interiorColor = enabledColor;
88 | else
89 | interiorColor = disabledColor;
90 |
91 | return interiorColor;
92 | }
93 |
94 | - (NSControlSize)controlSize
95 | {
96 | return NSSmallControlSize;
97 | }
98 |
99 | - (void)setControlSize:(NSControlSize)size
100 | {
101 |
102 | }
103 |
104 | @end
105 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentCheckbox.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentCheckbox.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentCheckbox : NSButton
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentCheckbox.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentCheckbox.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentCheckbox.h"
10 |
11 | @implementation BWTransparentCheckbox
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentCheckboxCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentCheckboxCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentCheckbox.h"
11 |
12 | @interface BWTransparentCheckboxCell : NSButtonCell
13 | {
14 |
15 | }
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentPopUpButton.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentPopUpButton.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentPopUpButton : NSPopUpButton
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentPopUpButton.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentPopUpButton.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentPopUpButton.h"
10 |
11 | @implementation BWTransparentPopUpButton
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentPopUpButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentPopUpButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentPopUpButtonCell : NSPopUpButtonCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentScrollView.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentScrollView.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentScrollView : NSScrollView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentScrollView.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentScrollView.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentScrollView.h"
10 | #import "BWTransparentScroller.h"
11 |
12 | @implementation BWTransparentScrollView
13 |
14 | - (id)initWithCoder:(NSCoder *)decoder;
15 | {
16 | if ((self = [super initWithCoder:decoder]) != nil)
17 | {
18 | if ([self respondsToSelector:@selector(ibTester)] == NO)
19 | [self setDrawsBackground:NO];
20 | }
21 | return self;
22 | }
23 |
24 | + (Class)_verticalScrollerClass
25 | {
26 | return [BWTransparentScroller class];
27 | }
28 |
29 | @end
30 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentScroller.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentScroller.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentScroller : NSScroller
12 | {
13 | BOOL isVertical;
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentSlider.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentSlider.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentSlider : NSSlider
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentSlider.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentSlider.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentSlider.h"
10 |
11 | @implementation BWTransparentSlider
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentSliderCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentSliderCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentSliderCell : NSSliderCell
12 | {
13 | BOOL isPressed;
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTableView.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTableView.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentTableView : NSTableView
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTableView.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTableView.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentTableView.h"
10 | #import "BWTransparentTableViewCell.h"
11 | #import "BWTransparentCheckboxCell.h"
12 |
13 | static NSColor *rowColor, *altRowColor, *highlightColor;
14 |
15 | @interface BWTransparentTableView (BWTTVPrivate)
16 | - (void)addObject:(id)object toParent:(id)parent;
17 | - (void)removeObject:(id)object;
18 | @end
19 |
20 | @implementation BWTransparentTableView
21 |
22 | + (void)initialize;
23 | {
24 | rowColor = [[NSColor colorWithCalibratedWhite:0.13 alpha:0.855] retain];
25 | altRowColor = [[NSColor colorWithCalibratedWhite:0.16 alpha:0.855] retain];
26 | highlightColor = [[NSColor colorWithCalibratedWhite:(75.0 / 255.0) alpha:0.855] retain];
27 | }
28 |
29 | - (void)addTableColumn:(NSTableColumn *)aColumn
30 | {
31 | [super addTableColumn:aColumn];
32 |
33 | if ([[[aColumn dataCell] className] isEqualToString:@"NSTextFieldCell"])
34 | {
35 | BWTransparentTableViewCell *cell = [[BWTransparentTableViewCell alloc] init];
36 |
37 | [self removeObject:[aColumn dataCell]];
38 | [aColumn setDataCell:cell];
39 | [self addObject:cell toParent:aColumn];
40 | }
41 | }
42 |
43 | + (Class)cellClass
44 | {
45 | return [BWTransparentTableViewCell class];
46 | }
47 |
48 | // We make this a no-op when there are no alt rows so that the background color is not drawn on top of the window
49 | - (void)drawBackgroundInClipRect:(NSRect)clipRect
50 | {
51 | if ([self usesAlternatingRowBackgroundColors])
52 | [super drawBackgroundInClipRect:clipRect];
53 | }
54 |
55 | // Color shown when a cell is edited
56 | - (NSColor *)backgroundColor
57 | {
58 | return rowColor;
59 | }
60 |
61 | - (NSArray *)_alternatingRowBackgroundColors
62 | {
63 | NSArray *colors = [NSArray arrayWithObjects:rowColor,altRowColor,nil];
64 |
65 | return colors;
66 | }
67 |
68 | - (NSColor *)_highlightColorForCell:(NSCell *)cell
69 | {
70 | return nil;
71 | }
72 |
73 | - (void)highlightSelectionInClipRect:(NSRect)theClipRect
74 | {
75 | NSRange aVisibleRowIndexes = [self rowsInRect:theClipRect];
76 | NSIndexSet * aSelectedRowIndexes = [self selectedRowIndexes];
77 | int aRow = aVisibleRowIndexes.location;
78 | int anEndRow = aRow + aVisibleRowIndexes.length;
79 |
80 | for (aRow; aRow < anEndRow; aRow++)
81 | {
82 | if([aSelectedRowIndexes containsIndex:aRow])
83 | {
84 | NSRect aRowRect = [self rectOfRow:aRow];
85 | aRowRect.size.height--;
86 |
87 | [NSGraphicsContext saveGraphicsState];
88 |
89 | [[NSGraphicsContext currentContext] setCompositingOperation:NSCompositeCopy];
90 |
91 | NSColor *startColor = [NSColor colorWithCalibratedWhite:(85.0 / 255.0) alpha:0.855];
92 | NSColor *endColor = [NSColor colorWithCalibratedWhite:(70.0 / 255.0) alpha:0.855];
93 |
94 | NSGradient *gradient = [[[NSGradient alloc] initWithStartingColor:startColor endingColor:endColor] autorelease];
95 |
96 | [gradient drawInRect:aRowRect angle:90];
97 |
98 | [NSGraphicsContext restoreGraphicsState];
99 | }
100 | }
101 | }
102 |
103 | @end
104 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTableViewCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTableViewCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentTableViewCell : NSTextFieldCell
12 | {
13 | BOOL mIsEditingOrSelecting;
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTableViewCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTableViewCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentTableViewCell.h"
10 |
11 | @implementation BWTransparentTableViewCell
12 |
13 | - (void)drawInteriorWithFrame:(NSRect)cellFrame inView:(NSView *)controlView
14 | {
15 | if (![[self title] isEqualToString:@""])
16 | {
17 | NSColor *textColor;
18 |
19 | if (!self.isHighlighted)
20 | textColor = [NSColor colorWithCalibratedWhite:(198.0f / 255.0f) alpha:1];
21 | else
22 | textColor = [NSColor whiteColor];
23 |
24 | NSMutableDictionary *attributes = [[[NSMutableDictionary alloc] init] autorelease];
25 | [attributes addEntriesFromDictionary:[[self attributedStringValue] attributesAtIndex:0 effectiveRange:NULL]];
26 | [attributes setObject:textColor forKey:NSForegroundColorAttributeName];
27 | [attributes setObject:[NSFont systemFontOfSize:11] forKey:NSFontAttributeName];
28 |
29 | NSMutableAttributedString *string = [[[NSMutableAttributedString alloc] initWithString:[self title] attributes:attributes] autorelease];
30 | [self setAttributedStringValue:string];
31 | }
32 |
33 | cellFrame.size.width -= 1;
34 | cellFrame.origin.x += 1;
35 | [super drawInteriorWithFrame:cellFrame inView:controlView];
36 | }
37 |
38 | #pragma mark RSVerticallyCenteredTextFieldCell
39 | // RSVerticallyCenteredTextFieldCell courtesy of Daniel Jalkut
40 | // http://www.red-sweater.com/blog/148/what-a-difference-a-cell-makes
41 |
42 | - (NSRect)drawingRectForBounds:(NSRect)theRect
43 | {
44 | // Get the parent's idea of where we should draw
45 | NSRect newRect = [super drawingRectForBounds:theRect];
46 |
47 | // When the text field is being
48 | // edited or selected, we have to turn off the magic because it screws up
49 | // the configuration of the field editor. We sneak around this by
50 | // intercepting selectWithFrame and editWithFrame and sneaking a
51 | // reduced, centered rect in at the last minute.
52 | if (mIsEditingOrSelecting == NO)
53 | {
54 | // Get our ideal size for current text
55 | NSSize textSize = [self cellSizeForBounds:theRect];
56 |
57 | // Center that in the proposed rect
58 | float heightDelta = newRect.size.height - textSize.height;
59 | if (heightDelta > 0)
60 | {
61 | newRect.size.height -= heightDelta;
62 | newRect.origin.y += (heightDelta / 2);
63 | }
64 | }
65 |
66 | return newRect;
67 | }
68 |
69 | - (void)selectWithFrame:(NSRect)aRect inView:(NSView *)controlView editor:(NSText *)textObj delegate:(id)anObject start:(NSInteger)selStart length:(NSInteger)selLength
70 | {
71 | aRect = [self drawingRectForBounds:aRect];
72 | mIsEditingOrSelecting = YES;
73 | [super selectWithFrame:aRect inView:controlView editor:textObj delegate:anObject start:selStart length:selLength];
74 | mIsEditingOrSelecting = NO;
75 | }
76 |
77 | - (void)editWithFrame:(NSRect)aRect inView:(NSView *)controlView editor:(NSText *)textObj delegate:(id)anObject event:(NSEvent *)theEvent
78 | {
79 | aRect = [self drawingRectForBounds:aRect];
80 | mIsEditingOrSelecting = YES;
81 | [super editWithFrame:aRect inView:controlView editor:textObj delegate:anObject event:theEvent];
82 | mIsEditingOrSelecting = NO;
83 | }
84 |
85 | @end
86 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTextFieldCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTextFieldCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTransparentTextFieldCell : NSTextFieldCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Classes/Transparent Controls/BWTransparentTextFieldCell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTextFieldCell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTransparentTextFieldCell.h"
10 | #import "NSApplication+BWAdditions.h"
11 |
12 | static NSShadow *textShadow;
13 |
14 | @interface NSCell (BWTTFCPrivate)
15 | - (NSDictionary *)_textAttributes;
16 | @end
17 |
18 | @implementation BWTransparentTextFieldCell
19 |
20 | + (void)initialize
21 | {
22 | textShadow = [[NSShadow alloc] init];
23 | [textShadow setShadowOffset:NSMakeSize(0,-1)];
24 | }
25 |
26 | - (NSDictionary *)_textAttributes
27 | {
28 | NSMutableDictionary *attributes = [[[NSMutableDictionary alloc] init] autorelease];
29 | [attributes addEntriesFromDictionary:[super _textAttributes]];
30 | [attributes setObject:[NSColor whiteColor] forKey:NSForegroundColorAttributeName];
31 |
32 | if ([NSApplication bwIsOnLeopard])
33 | [attributes setObject:[NSFont boldSystemFontOfSize:11] forKey:NSFontAttributeName];
34 | else
35 | [attributes setObject:[NSFont systemFontOfSize:11] forKey:NSFontAttributeName];
36 |
37 | [attributes setObject:textShadow forKey:NSShadowAttributeName];
38 |
39 | return attributes;
40 | }
41 |
42 | @end
43 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Button Bar/ButtonBarPullDownArrow.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Button Bar/ButtonBarPullDownArrow.pdf
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Split View/GradientSplitViewDimpleBitmap.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Split View/GradientSplitViewDimpleBitmap.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Split View/GradientSplitViewDimpleVector.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Split View/GradientSplitViewDimpleVector.pdf
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderPhotoLarge.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderPhotoLarge.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderPhotoSmall.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderPhotoSmall.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderSpeakerLoud.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderSpeakerLoud.png
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderSpeakerQuiet.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderSpeakerQuiet.png
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderThumbN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderThumbN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderThumbP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderThumbP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackFill.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackFill.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackLeft.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackLeft.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackRight.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Textured Slider/TexturedSliderTrackRight.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Toolbar Items/ToolbarItemColors.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Toolbar Items/ToolbarItemColors.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Toolbar Items/ToolbarItemFonts.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Toolbar Items/ToolbarItemFonts.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonFillN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonFillN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonFillP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonFillP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonLeftN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonLeftN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonLeftP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonLeftP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonRightN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonRightN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonRightP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Button/TransparentButtonRightP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOffN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOffN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOffP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOffP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOnN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOnN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOnP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Check Box/TransparentCheckboxOnP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpFillN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpFillN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpFillP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpFillP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpLeftN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpLeftN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpLeftP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpLeftP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpPullDownRightN.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpPullDownRightN.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpPullDownRightP.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpPullDownRightP.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpRightN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpRightN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpRightP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Pop Up/TransparentPopUpRightP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobBottom.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobBottom.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobHorizontalFill.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobHorizontalFill.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobLeft.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobLeft.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobRight.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobRight.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobTop.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobTop.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobVerticalFill.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerKnobVerticalFill.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotBottom.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotBottom.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotHorizontalFill.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotHorizontalFill.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotLeft.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotLeft.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotRight.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotRight.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotTop.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotTop.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotVerticalFill.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Scroller/TransparentScrollerSlotVerticalFill.tif
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderThumbN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderThumbN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderThumbP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderThumbP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackFill.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackFill.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackLeft.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackLeft.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackRight.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTrackRight.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTriangleThumbN.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTriangleThumbN.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTriangleThumbP.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Framework/Graphics/Transparent Controls/Slider/TransparentSliderTriangleThumbP.tiff
--------------------------------------------------------------------------------
/BWToolkit/Framework/Private Cocoa Headers/NSCustomView.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Generated by class-dump 3.1.2.
3 | *
4 | * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2007 by Steve Nygard.
5 | */
6 |
7 | #import
8 |
9 | @class NSString;
10 |
11 | @interface NSCustomView : NSView
12 | {
13 | NSString *className;
14 | NSView *view;
15 | id extension;
16 | }
17 |
18 | + (void)initialize;
19 | - (id)initWithFrame:(NSRect)fp8;
20 | - (void)dealloc;
21 | - (void)finalize;
22 | - (id)nibInstantiate;
23 | - (void)encodeWithCoder:(id)fp8;
24 | - (id)initWithCoder:(id)fp8;
25 |
26 | @end
27 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Private Cocoa Headers/NSTokenAttachment.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Generated by class-dump 3.1.2.
3 | *
4 | * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2007 by Steve Nygard.
5 | */
6 |
7 | #ifndef APPSTORE
8 |
9 | #import
10 |
11 | @interface NSTokenAttachment : NSTextAttachment
12 | {
13 | id _delegate;
14 | }
15 |
16 | - (id)initWithDelegate:(id)fp8;
17 | - (void)encodeWithCoder:(id)fp8;
18 | - (id)initWithCoder:(id)fp8;
19 | - (id)attachmentCell;
20 | - (id)delegate;
21 | - (void)setDelegate:(id)fp8;
22 |
23 | @end
24 |
25 | #endif
26 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Private Cocoa Headers/NSTokenAttachmentCell.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Generated by class-dump 3.1.2.
3 | *
4 | * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2007 by Steve Nygard.
5 | */
6 |
7 | #ifndef APPSTORE
8 |
9 | #import
10 |
11 | @interface NSTokenAttachmentCell : NSTextAttachmentCell
12 | {
13 | id _representedObject;
14 | id _textColor;
15 | id _reserved;
16 | struct {
17 | unsigned int _selected:1;
18 | unsigned int _edgeStyle:2;
19 | unsigned int _reserved:29;
20 | } _tacFlags;
21 | }
22 |
23 | + (void)initialize;
24 | - (id)initTextCell:(id)fp8;
25 | - (id)init;
26 | - (void)dealloc;
27 | - (id)representedObject;
28 | - (void)setRepresentedObject:(id)fp8;
29 | - (int)interiorBackgroundStyle;
30 | - (BOOL)_hasMenu;
31 | - (id)tokenForegroundColor;
32 | - (id)tokenBackgroundColor;
33 | - (id)textColor;
34 | - (void)setTextColor:(id)fp8;
35 | - (id)pullDownImage;
36 | - (id)menu;
37 | - (NSSize)cellSizeForBounds:(NSRect)fp8;
38 | - (NSSize)cellSize;
39 | - (NSRect)drawingRectForBounds:(NSRect)fp8;
40 | - (NSRect)titleRectForBounds:(NSRect)fp8;
41 | - (NSRect)cellFrameForTextContainer:(id)fp8 proposedLineFragment:(NSRect)fp12 glyphPosition:(NSPoint)fp28 characterIndex:(unsigned int)fp36;
42 | - (NSPoint)cellBaselineOffset;
43 | - (NSRect)pullDownRectForBounds:(NSRect)fp8;
44 | - (void)drawTokenWithFrame:(NSRect)fp8 inView:(id)fp24;
45 | - (void)drawInteriorWithFrame:(NSRect)fp8 inView:(id)fp24;
46 | - (void)drawWithFrame:(NSRect)fp8 inView:(id)fp24;
47 | - (void)drawWithFrame:(NSRect)fp8 inView:(id)fp24 characterIndex:(unsigned int)fp28 layoutManager:(id)fp32;
48 | - (void)encodeWithCoder:(id)fp8;
49 | - (id)initWithCoder:(id)fp8;
50 | - (BOOL)wantsToTrackMouseForEvent:(id)fp8 inRect:(NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32;
51 | - (BOOL)trackMouse:(id)fp8 inRect:(NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32 untilMouseUp:(BOOL)fp36;
52 |
53 | @end
54 |
55 | #endif
56 |
57 |
--------------------------------------------------------------------------------
/BWToolkit/Framework/Private Cocoa Headers/NSWindow-NSTimeMachineSupport.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Generated by class-dump 3.1.2.
3 | *
4 | * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2007 by Steve Nygard.
5 | */
6 |
7 | #ifndef APPSTORE
8 |
9 | #import
10 |
11 | @interface NSWindow (NSTimeMachineSupport)
12 | - (void)setTimeMachineDelegate:(id)fp8;
13 | - (id)timeMachineDelegate;
14 | - (void)setMovable:(BOOL)fp8;
15 | - (BOOL)isMovable;
16 | @end
17 |
18 | #endif
19 |
--------------------------------------------------------------------------------
/BWToolkit/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | English
7 | CFBundleExecutable
8 | ${EXECUTABLE_NAME}
9 | CFBundleIconFile
10 |
11 | CFBundleIdentifier
12 | $(PRODUCT_BUNDLE_IDENTIFIER)
13 | CFBundleInfoDictionaryVersion
14 | 6.0
15 | CFBundleName
16 | ${PRODUCT_NAME}
17 | CFBundlePackageType
18 | BNDL
19 | CFBundleShortVersionString
20 | 1.2.5
21 | CFBundleSignature
22 | ????
23 | CFBundleSupportedPlatforms
24 |
25 | MacOSX
26 |
27 | CFBundleVersion
28 | 1.2.5
29 | Mach-OLC_VERSION_MIN
30 | 10.6
31 | NSPrincipalClass
32 | BWToolkit
33 |
34 |
35 |
--------------------------------------------------------------------------------
/BWToolkit/InfoPlist.strings:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/InfoPlist.strings
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAddMiniBottomBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAddMiniBottomBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAddRegularBottomBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAddRegularBottomBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAddSheetBottomBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAddSheetBottomBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAddSmallBottomBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAddSmallBottomBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAnchoredButton.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAnchoredButton;
11 | SuperClass = NSButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAnchoredButtonBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAnchoredButtonBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWAnchoredPopUpButton.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWAnchoredPopUpButton;
11 | SuperClass = NSPopUpButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWCustomView.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWCustomView;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWGradientBox.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWGradientBox;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWHyperlinkButton.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWHyperlinkButton;
11 | SuperClass = NSButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWHyperlinkButtonCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWHyperlinkButtonCell;
11 | SuperClass = NSButtonCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWInsetTextField.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWInsetTextField;
11 | SuperClass = NSTextField;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWRemoveBottomBar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWRemoveBottomBar;
11 | SuperClass = NSView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWSelectableToolbar.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWSelectableToolbar;
11 | SuperClass = NSToolbar;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWSheetController.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | "openSheet:" = id;
4 | "closeSheet:" = id;
5 | "messageDelegateAndCloseSheet:" = id;
6 | };
7 | Outlets = {
8 | sheet = NSWindow;
9 | parentWindow = NSWindow;
10 | delegate = id;
11 | };
12 | ClassName = BWSheetController;
13 | SuperClass = NSObject;
14 | }
15 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWSplitView.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions =
3 | {
4 | "toggleCollapse:" = id;
5 | };
6 | Outlets =
7 | {
8 | };
9 | ClassName = BWSplitView;
10 | SuperClass = NSSplitView;
11 | }
12 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWStyledTextField.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWStyledTextField;
11 | SuperClass = NSTextField;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWStyledTextFieldCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWStyledTextFieldCell;
11 | SuperClass = NSTextFieldCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTexturedSlider.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTexturedSlider;
11 | SuperClass = NSSlider;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTexturedSliderCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTexturedSliderCell;
11 | SuperClass = NSSliderCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTokenField.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTokenField;
11 | SuperClass = NSTokenField;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTokenFieldCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTokenFieldCell;
11 | SuperClass = NSTokenFieldCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWToolbarItem.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWToolbarItem;
11 | SuperClass = NSToolbarItem;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWToolbarShowColorsItem.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWToolbarShowColorsItem;
11 | SuperClass = NSToolbarItem;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWToolbarShowFontsItem.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWToolbarShowFontsItem;
11 | SuperClass = NSToolbarItem;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentButton.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentButton;
11 | SuperClass = NSButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentButtonCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentButtonCell;
11 | SuperClass = NSButtonCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentCheckbox.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentCheckbox;
11 | SuperClass = NSButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentCheckboxCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentCheckboxCell;
11 | SuperClass = NSButtonCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentPopUpButton.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentPopUpButton;
11 | SuperClass = NSPopUpButton;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentPopUpButtonCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentPopUpButtonCell;
11 | SuperClass = NSPopUpButtonCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentScrollView.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentScrollView;
11 | SuperClass = NSScrollView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentScroller.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentScroller;
11 | SuperClass = NSScroller;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentSlider.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentSlider;
11 | SuperClass = NSSlider;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentSliderCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentSliderCell;
11 | SuperClass = NSSliderCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentTableView.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentTableView;
11 | SuperClass = NSTableView;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentTableViewCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentTableViewCell;
11 | SuperClass = NSTextFieldCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Class Descriptions/BWTransparentTextFieldCell.classdescription:
--------------------------------------------------------------------------------
1 | {
2 | Actions = {
3 | // Define action descriptions here, for example
4 | // "myAction:" = id;
5 | };
6 | Outlets = {
7 | // Define outlet descriptions here, for example
8 | // myOutlet = NSView;
9 | };
10 | ClassName = BWTransparentTextFieldCell;
11 | SuperClass = NSTextFieldCell;
12 | }
13 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWAnchoredButtonBarInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonBarViewInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWAnchoredButtonBarInspector : IBInspector
12 | {
13 | IBOutlet NSMatrix *matrix;
14 | IBOutlet NSImageView *selectionView;
15 | IBOutlet NSView *contentView;
16 |
17 | BOOL isAnimating;
18 | }
19 |
20 | - (IBAction)selectMode1:(id)sender;
21 | - (IBAction)selectMode2:(id)sender;
22 | - (IBAction)selectMode3:(id)sender;
23 | - (void)selectMode:(int)modeIndex withAnimation:(BOOL)shouldAnimate;
24 |
25 | @end
26 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWAnchoredButtonBarInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonBarViewInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWAnchoredButtonBarInspector.h"
10 | #import "BWAnchoredButtonBar.h"
11 |
12 | @implementation BWAnchoredButtonBarInspector
13 |
14 | - (NSString *)viewNibName
15 | {
16 | return @"BWAnchoredButtonBarInspector";
17 | }
18 |
19 | - (void)refresh
20 | {
21 | [super refresh];
22 |
23 | if ([[self inspectedObjects] count] > 0 && !isAnimating)
24 | {
25 | BWAnchoredButtonBar *inspectedButtonBar = [[self inspectedObjects] lastObject];
26 |
27 | if ([inspectedButtonBar selectedIndex] == 0)
28 | [self selectMode:1 withAnimation:NO];
29 | else if ([inspectedButtonBar selectedIndex] == 1)
30 | [self selectMode:2 withAnimation:NO];
31 | else
32 | [self selectMode:3 withAnimation:NO];
33 | }
34 | }
35 |
36 | - (IBAction)selectMode1:(id)sender
37 | {
38 | [self selectMode:1 withAnimation:YES];
39 | }
40 |
41 | - (IBAction)selectMode2:(id)sender
42 | {
43 | [self selectMode:2 withAnimation:YES];
44 | }
45 |
46 | - (IBAction)selectMode3:(id)sender
47 | {
48 | [self selectMode:3 withAnimation:YES];
49 | }
50 |
51 | - (void)selectMode:(int)modeIndex withAnimation:(BOOL)shouldAnimate
52 | {
53 | float xOrigin;
54 |
55 | if (modeIndex == 1)
56 | xOrigin = roundf(matrix.frame.origin.x-1);
57 | else if (modeIndex == 2)
58 | xOrigin = roundf(matrix.frame.origin.x + NSWidth(matrix.frame) / matrix.numberOfColumns);
59 | else
60 | xOrigin = roundf(NSMaxX(matrix.frame) - NSWidth(matrix.frame) / matrix.numberOfColumns + matrix.numberOfColumns - 1);
61 |
62 | if (shouldAnimate)
63 | {
64 | float deltaX = fabsf(xOrigin - selectionView.frame.origin.x);
65 | float doubleSpaceMultiplier = 1;
66 |
67 | if (deltaX > 65)
68 | doubleSpaceMultiplier = 1.5;
69 |
70 | float duration = 0.1*doubleSpaceMultiplier;
71 |
72 | isAnimating = YES;
73 |
74 | [NSAnimationContext beginGrouping];
75 | [[NSAnimationContext currentContext] setDuration:(duration)];
76 | [[selectionView animator] setFrameOrigin:NSMakePoint(xOrigin,selectionView.frame.origin.y)];
77 | [NSAnimationContext endGrouping];
78 |
79 | [self performSelector:@selector(selectionAnimationDidEnd) withObject:nil afterDelay:duration];
80 | }
81 | else
82 | {
83 | [selectionView setFrameOrigin:NSMakePoint(xOrigin,selectionView.frame.origin.y)];
84 | }
85 | }
86 |
87 | - (void)selectionAnimationDidEnd
88 | {
89 | isAnimating = NO;
90 | }
91 |
92 | @end
93 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientBoxInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientBoxInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWGradientBox.h"
11 | #import "BWGradientWell.h"
12 |
13 | @interface BWGradientBoxInspector : IBInspector
14 | {
15 | BWGradientBox *box;
16 | int fillPopupSelection;
17 |
18 | BWGradientWell *gradientWell;
19 | NSColorWell *colorWell;
20 | NSView *wellContainer;
21 | float largeViewHeight, smallViewHeight;
22 | }
23 |
24 | @property (nonatomic, retain) IBOutlet BWGradientWell *gradientWell;
25 | @property (nonatomic, retain) IBOutlet NSColorWell *colorWell;
26 | @property (nonatomic, retain) IBOutlet NSView *wellContainer;
27 | @property int fillPopupSelection;
28 |
29 | @end
30 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientBoxInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientBoxInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWGradientBoxInspector.h"
10 | #import "NSEvent+BWAdditions.h"
11 | #import "NSView+BWAdditions.h"
12 |
13 | static float heightDelta = 33;
14 | static float animationDuration = 0.1;
15 |
16 | @interface BWGradientBoxInspector (BWGBIPrivate)
17 | - (void)updateWellVisibility;
18 | @end
19 |
20 | @implementation BWGradientBoxInspector
21 |
22 | @synthesize fillPopupSelection, gradientWell, colorWell, wellContainer;
23 |
24 | - (void)awakeFromNib
25 | {
26 | [super awakeFromNib];
27 |
28 | largeViewHeight = [[self view] frame].size.height;
29 | smallViewHeight = largeViewHeight - heightDelta;
30 | }
31 |
32 | - (NSString *)viewNibName
33 | {
34 | return @"BWGradientBoxInspector";
35 | }
36 |
37 | - (void)refresh
38 | {
39 | [super refresh];
40 |
41 | box = [[self inspectedObjects] objectAtIndex:0];
42 | [self updateWellVisibility];
43 |
44 | // Update the popup selections in case of an undo operation
45 | if ([box hasGradient])
46 | [self setFillPopupSelection:2];
47 | else if ([box hasFillColor])
48 | [self setFillPopupSelection:1];
49 | else
50 | [self setFillPopupSelection:0];
51 |
52 | }
53 |
54 | + (BOOL)supportsMultipleObjectInspection
55 | {
56 | return NO;
57 | }
58 |
59 | - (void)setFillPopupSelection:(int)anInt
60 | {
61 | fillPopupSelection = anInt;
62 |
63 | if (fillPopupSelection == 0)
64 | {
65 | [box setHasGradient:NO];
66 | [box setHasFillColor:NO];
67 | }
68 | else if (fillPopupSelection == 1)
69 | {
70 | [box setHasGradient:NO];
71 | [box setHasFillColor:YES];
72 | [gradientWell setHidden:YES];
73 | [colorWell setHidden:NO];
74 | [colorWell setEnabled:YES];
75 | }
76 | else
77 | {
78 | [box setHasGradient:YES];
79 | [box setHasFillColor:NO];
80 | [gradientWell setHidden:NO];
81 | [colorWell setHidden:YES];
82 | [colorWell setEnabled:NO];
83 | }
84 | }
85 |
86 | - (void)updateWellVisibility
87 | {
88 | BOOL willCollapse;
89 | NSRect targetFrame = [[self view] frame];
90 | float viewHeight = [[self view] frame].size.height;
91 |
92 | if ((int)viewHeight == (int)largeViewHeight && ![box hasGradient] && ![box hasFillColor])
93 | willCollapse = YES;
94 | else if ((int)viewHeight == (int)smallViewHeight && ([box hasGradient] || [box hasFillColor]))
95 | willCollapse = NO;
96 | else
97 | return;
98 |
99 | targetFrame.size.height = willCollapse ? smallViewHeight : largeViewHeight;
100 | float alpha = willCollapse ? 0 : 1;
101 | float duration = [NSEvent bwShiftKeyIsDown] ? animationDuration * 10 : animationDuration;
102 |
103 | [NSAnimationContext beginGrouping];
104 | [[NSAnimationContext currentContext] setDuration:duration];
105 | [[wellContainer bwAnimator] setAlphaValue:alpha];
106 | [[[self view] bwAnimator] setFrame:targetFrame];
107 | [NSAnimationContext endGrouping];
108 | }
109 |
110 | @end
111 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientWell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientWell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWGradientWell : NSView
12 | {
13 | NSColorWell *startingColorWell, *endingColorWell;
14 | }
15 |
16 | @property (nonatomic, retain) IBOutlet NSColorWell *startingColorWell, *endingColorWell;
17 |
18 | @end
19 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientWell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientWell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWGradientWell.h"
10 |
11 | static NSColor *borderColor;
12 | static NSImage *pattern;
13 |
14 | @implementation BWGradientWell
15 |
16 | @synthesize startingColorWell, endingColorWell;
17 |
18 | + (void)initialize
19 | {
20 | borderColor = [[NSColor colorWithCalibratedWhite:(121.0 / 255.0) alpha:1] retain];
21 |
22 | NSBundle *bundle = [NSBundle bundleForClass:[BWGradientWell class]];
23 | pattern = [[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"GradientWellPattern.tif"]];
24 | }
25 |
26 | - (void)drawRect:(NSRect)rect
27 | {
28 | NSRect insetRect = NSInsetRect(self.bounds, 2, 2);
29 |
30 | [pattern drawAtPoint:insetRect.origin fromRect:NSZeroRect operation:NSCompositeSourceOver fraction:1];
31 |
32 | NSGradient *gradient = [[NSGradient alloc] initWithStartingColor:[startingColorWell color] endingColor:[endingColorWell color]];
33 | [gradient drawInRect:insetRect angle:0];
34 | [gradient release];
35 |
36 | [borderColor set];
37 | NSFrameRect(self.bounds);
38 | }
39 |
40 | @end
41 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientWellColorWell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientWellColorWell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWGradientWell.h"
11 |
12 | @interface BWGradientWellColorWell : NSColorWell
13 | {
14 | BWGradientWell *gradientWell;
15 | }
16 |
17 | @property (nonatomic, retain) IBOutlet BWGradientWell *gradientWell;
18 |
19 | @end
20 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWGradientWellColorWell.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientWellColorWell.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWGradientWellColorWell.h"
10 |
11 | static NSColor *borderColor;
12 | static float bezelThickness = 2;
13 |
14 | @implementation BWGradientWellColorWell
15 |
16 | @synthesize gradientWell;
17 |
18 | + (void)initialize
19 | {
20 | borderColor = [[NSColor colorWithCalibratedWhite:(66.0 / 255.0) alpha:1] retain];
21 | }
22 |
23 | - (void)drawRect:(NSRect)rect
24 | {
25 | [super drawRect:rect];
26 |
27 | [borderColor set];
28 | NSFrameRect(self.bounds);
29 |
30 | [borderColor drawSwatchInRect:NSInsetRect(self.bounds, bezelThickness + 1, bezelThickness + 1)];
31 |
32 | [[self color] drawSwatchInRect:NSInsetRect(self.bounds, bezelThickness + 2, bezelThickness + 2)];
33 | }
34 |
35 | - (void)setColor:(NSColor *)color
36 | {
37 | [gradientWell setNeedsDisplay:YES];
38 |
39 | [super setColor:color];
40 | }
41 |
42 | @end
43 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWHyperlinkButtonInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButtonInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWHyperlinkButtonInspector : IBInspector
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWHyperlinkButtonInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButtonInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWHyperlinkButtonInspector.h"
10 |
11 | @implementation BWHyperlinkButtonInspector
12 |
13 | - (NSString *)viewNibName
14 | {
15 | return @"BWHyperlinkButtonInspector";
16 | }
17 |
18 | - (void)refresh
19 | {
20 | [super refresh];
21 | }
22 |
23 | @end
24 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWSelectableToolbarInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbarInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWSelectableToolbarInspector : IBInspector
12 | {
13 | }
14 | @end
15 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWSelectableToolbarInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbarInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWSelectableToolbarInspector.h"
10 |
11 | @implementation BWSelectableToolbarInspector
12 |
13 | - (NSString *)viewNibName {
14 | return @"BWSelectableToolbarInspector";
15 | }
16 |
17 | - (void)refresh {
18 | // Synchronize your inspector's content view with the currently selected objects
19 | [super refresh];
20 | }
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWSplitViewInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSplitViewInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWSplitView.h"
11 | #import "BWSplitViewInspectorAutosizingView.h"
12 |
13 | @interface BWSplitViewInspector : IBInspector
14 | {
15 | IBOutlet NSTextField *maxField, *minField, *maxLabel, *minLabel;
16 | IBOutlet NSButton *dividerCheckbox;
17 | IBOutlet BWSplitViewInspectorAutosizingView *autosizingView;
18 |
19 | int subviewPopupSelection, minUnitPopupSelection, maxUnitPopupSelection;
20 | NSMutableArray *subviewPopupContent, *collapsiblePopupContent;
21 |
22 | BWSplitView *splitView;
23 | BOOL dividerCheckboxCollapsed;
24 | }
25 |
26 | @property int subviewPopupSelection, minUnitPopupSelection, maxUnitPopupSelection;
27 | @property (copy) NSMutableArray *subviewPopupContent, *collapsiblePopupContent;
28 | @property (retain) BWSplitView *splitView;
29 | @property BOOL dividerCheckboxCollapsed;
30 |
31 | @end
32 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWSplitViewInspectorAutosizingButtonCell.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSplitViewInspectorAutosizingButtonCell.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWSplitViewInspectorAutosizingButtonCell : NSButtonCell
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWSplitViewInspectorAutosizingView.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWSplitViewInspectorAutosizingView.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWSplitView.h"
11 |
12 | @interface BWSplitViewInspectorAutosizingView : NSView
13 | {
14 | NSMutableArray *buttons;
15 | BWSplitView *splitView;
16 | }
17 |
18 | @property (retain) BWSplitView *splitView;
19 |
20 | - (void)layoutButtons;
21 | - (BOOL)isVertical;
22 |
23 | @end
24 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWStyledTextFieldInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextFieldInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWStyledTextField.h"
11 |
12 | @interface BWStyledTextFieldInspector : IBInspector
13 | {
14 | BWStyledTextField *textField;
15 | int shadowPositionPopupSelection, fillPopupSelection;
16 | }
17 |
18 | @property int shadowPositionPopupSelection, fillPopupSelection;
19 |
20 | @end
21 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWStyledTextFieldInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextFieldInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWStyledTextFieldInspector.h"
10 |
11 | @implementation BWStyledTextFieldInspector
12 |
13 | @synthesize shadowPositionPopupSelection, fillPopupSelection;
14 |
15 | - (NSString *)viewNibName
16 | {
17 | return @"BWStyledTextFieldInspector";
18 | }
19 |
20 | - (void)refresh
21 | {
22 | [super refresh];
23 |
24 | textField = [[self inspectedObjects] objectAtIndex:0];
25 |
26 | // Update the popup selections in case of an undo operation
27 | if (![textField hasShadow])
28 | {
29 | [self setShadowPositionPopupSelection:0];
30 | }
31 | else
32 | {
33 | if ([textField shadowIsBelow])
34 | [self setShadowPositionPopupSelection:3];
35 | else
36 | [self setShadowPositionPopupSelection:2];
37 | }
38 |
39 | if ([textField hasGradient])
40 | [self setFillPopupSelection:1];
41 | else
42 | [self setFillPopupSelection:0];
43 | }
44 |
45 | + (BOOL)supportsMultipleObjectInspection
46 | {
47 | return NO;
48 | }
49 |
50 | - (void)setFillPopupSelection:(int)anInt
51 | {
52 | fillPopupSelection = anInt;
53 |
54 | if (fillPopupSelection == 0)
55 | [textField setHasGradient:NO];
56 | else
57 | [textField setHasGradient:YES];
58 | }
59 |
60 | - (void)setShadowPositionPopupSelection:(int)anInt
61 | {
62 | shadowPositionPopupSelection = anInt;
63 |
64 | if (shadowPositionPopupSelection == 2)
65 | {
66 | [textField setHasShadow:YES];
67 | [textField setShadowIsBelow:NO];
68 | }
69 | else if (shadowPositionPopupSelection == 3)
70 | {
71 | [textField setHasShadow:YES];
72 | [textField setShadowIsBelow:YES];
73 | }
74 | else
75 | {
76 | [textField setHasShadow:NO];
77 | }
78 | }
79 |
80 | @end
81 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWTexturedSliderInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWControlsInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWTexturedSliderInspector : IBInspector
12 | {
13 | }
14 | @end
15 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWTexturedSliderInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWControlsInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWTexturedSliderInspector.h"
10 |
11 | @implementation BWTexturedSliderInspector
12 |
13 | - (NSString *)viewNibName {
14 | return @"BWTexturedSliderInspector";
15 | }
16 |
17 | - (void)refresh {
18 | // Synchronize your inspector's content view with the currently selected objects.
19 | [super refresh];
20 | }
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWToolbarItemInspector.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarItemInspector.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWToolbarItemInspector : IBInspector
12 | {
13 |
14 | }
15 |
16 | @end
17 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWToolbarItemInspector.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarItemInspector.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWToolbarItemInspector.h"
10 |
11 | @implementation BWToolbarItemInspector
12 |
13 | - (NSString *)viewNibName {
14 | return @"BWToolbarItemInspector";
15 | }
16 |
17 | - (void)refresh {
18 | // Synchronize your inspector's content view with the currently selected objects
19 | [super refresh];
20 | }
21 |
22 | @end
23 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWToolkit.h:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolkit.h
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 |
11 | @interface BWToolkit : IBPlugin {
12 |
13 | }
14 |
15 | @end
16 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Classes/BWToolkit.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolkit.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import "BWToolkit.h"
10 |
11 | @implementation BWToolkit
12 | - (NSArray *)libraryNibNames {
13 | return [NSArray arrayWithObjects:@"BWSplitViewLibrary",@"BWControllersLibrary",@"BWToolbarItemsLibrary",@"BWBottomBarLibrary",@"BWToolkitLibrary",@"BWTransparentControlsLibrary",@"BWButtonBarLibrary",nil];
14 | }
15 |
16 | - (NSArray *)requiredFrameworks {
17 | return [NSArray arrayWithObjects:[NSBundle bundleWithIdentifier:@"com.brandonwalkin.BWToolkitFramework"], nil];
18 | }
19 |
20 | - (NSString *)label
21 | {
22 | return @"BWToolkit";
23 | }
24 |
25 | @end
26 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAddMiniBottomBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddMiniBottomBarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAddSmallBottomBar.h"
11 | #import "BWAddRegularBottomBar.h"
12 | #import "BWAddMiniBottomBar.h"
13 | #import "BWAddSheetBottomBar.h"
14 | #import "NSWindow+BWAdditions.h"
15 |
16 | @interface NSWindow (BWBBPrivate)
17 | - (void)setBottomCornerRounded:(BOOL)flag;
18 | @end
19 |
20 | @implementation BWAddMiniBottomBar ( BWAddMiniBottomBarIntegration )
21 |
22 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
23 | {
24 | [super ibDidAddToDesignableDocument:document];
25 |
26 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
27 | [self performSelector:@selector(removeOtherBottomBarViewsInDocument:) withObject:document afterDelay:0];
28 | }
29 |
30 | - (void)addBottomBar
31 | {
32 | if ([[self window] bwIsTextured] == NO)
33 | {
34 | [[self window] setContentBorderThickness:16 forEdge:NSMinYEdge];
35 |
36 | // Private method
37 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
38 | [[self window] setBottomCornerRounded:NO];
39 | }
40 | }
41 |
42 | - (void)removeOtherBottomBarViewsInDocument:(IBDocument *)document
43 | {
44 | NSArray *subviews = [[[self window] contentView] subviews];
45 |
46 | int i;
47 | for (i = 0; i < [subviews count]; i++)
48 | {
49 | NSView *view = [subviews objectAtIndex:i];
50 | if (view != self && ([view isKindOfClass:[BWAddRegularBottomBar class]] || [view isKindOfClass:[BWAddSmallBottomBar class]] || [view isKindOfClass:[BWAddMiniBottomBar class]] || [view isKindOfClass:[BWAddSheetBottomBar class]]))
51 | {
52 | [document removeObject:view];
53 | [view removeFromSuperview];
54 | }
55 | }
56 | }
57 |
58 | @end
59 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAddRegularBottomBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddRegularBottomBarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAddSmallBottomBar.h"
11 | #import "BWAddRegularBottomBar.h"
12 | #import "BWAddMiniBottomBar.h"
13 | #import "BWAddSheetBottomBar.h"
14 | #import "NSWindow+BWAdditions.h"
15 |
16 | @interface NSWindow (BWBBPrivate)
17 | - (void)setBottomCornerRounded:(BOOL)flag;
18 | @end
19 |
20 | @implementation BWAddRegularBottomBar ( BWAddRegularBottomBarIntegration )
21 |
22 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
23 | {
24 | [super ibDidAddToDesignableDocument:document];
25 |
26 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
27 | [self performSelector:@selector(removeOtherBottomBarViewsInDocument:) withObject:document afterDelay:0];
28 | }
29 |
30 | - (void)addBottomBar
31 | {
32 | if ([[self window] bwIsTextured] == NO)
33 | {
34 | [[self window] setContentBorderThickness:34 forEdge:NSMinYEdge];
35 |
36 | // Private method
37 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
38 | [[self window] setBottomCornerRounded:YES];
39 | }
40 | }
41 |
42 | - (void)removeOtherBottomBarViewsInDocument:(IBDocument *)document
43 | {
44 | NSArray *subviews = [[[self window] contentView] subviews];
45 |
46 | int i;
47 | for (i = 0; i < [subviews count]; i++)
48 | {
49 | NSView *view = [subviews objectAtIndex:i];
50 | if (view != self && ([view isKindOfClass:[BWAddRegularBottomBar class]] || [view isKindOfClass:[BWAddSmallBottomBar class]] || [view isKindOfClass:[BWAddMiniBottomBar class]] || [view isKindOfClass:[BWAddSheetBottomBar class]]))
51 | {
52 | [document removeObject:view];
53 | [view removeFromSuperview];
54 | }
55 | }
56 | }
57 |
58 | @end
59 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAddSheetBottomBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSheetBottomBarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAddSmallBottomBar.h"
11 | #import "BWAddRegularBottomBar.h"
12 | #import "BWAddMiniBottomBar.h"
13 | #import "BWAddSheetBottomBar.h"
14 | #import "NSWindow+BWAdditions.h"
15 |
16 | @interface NSWindow (BWBBPrivate)
17 | - (void)setBottomCornerRounded:(BOOL)flag;
18 | @end
19 |
20 | @implementation BWAddSheetBottomBar ( BWAddSheetBottomBarIntegration )
21 |
22 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
23 | {
24 | [super ibDidAddToDesignableDocument:document];
25 |
26 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
27 | [self performSelector:@selector(removeOtherBottomBarViewsInDocument:) withObject:document afterDelay:0];
28 | }
29 |
30 | - (void)addBottomBar
31 | {
32 | if ([[self window] bwIsTextured] == NO)
33 | {
34 | [[self window] setContentBorderThickness:40 forEdge:NSMinYEdge];
35 |
36 | // Private method
37 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
38 | [[self window] setBottomCornerRounded:NO];
39 | }
40 | }
41 |
42 | - (void)removeOtherBottomBarViewsInDocument:(IBDocument *)document
43 | {
44 | NSArray *subviews = [[[self window] contentView] subviews];
45 |
46 | int i;
47 | for (i = 0; i < [subviews count]; i++)
48 | {
49 | NSView *view = [subviews objectAtIndex:i];
50 | if (view != self && ([view isKindOfClass:[BWAddRegularBottomBar class]] || [view isKindOfClass:[BWAddSmallBottomBar class]] || [view isKindOfClass:[BWAddMiniBottomBar class]] || [view isKindOfClass:[BWAddSheetBottomBar class]]))
51 | {
52 | [document removeObject:view];
53 | [view removeFromSuperview];
54 | }
55 | }
56 | }
57 |
58 | @end
59 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAddSmallBottomBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAddSmallBottomBarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAddSmallBottomBar.h"
11 | #import "BWAddRegularBottomBar.h"
12 | #import "BWAddMiniBottomBar.h"
13 | #import "BWAddSheetBottomBar.h"
14 | #import "NSWindow+BWAdditions.h"
15 |
16 | @interface NSWindow (BWBBPrivate)
17 | - (void)setBottomCornerRounded:(BOOL)flag;
18 | @end
19 |
20 | @implementation BWAddSmallBottomBar ( BWAddSmallBottomBarIntegration )
21 |
22 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
23 | {
24 | [super ibDidAddToDesignableDocument:document];
25 |
26 | [self performSelector:@selector(addBottomBar) withObject:nil afterDelay:0];
27 | [self performSelector:@selector(removeOtherBottomBarViewsInDocument:) withObject:document afterDelay:0];
28 | }
29 |
30 | - (void)addBottomBar
31 | {
32 | if ([[self window] bwIsTextured] == NO)
33 | {
34 | [[self window] setContentBorderThickness:24 forEdge:NSMinYEdge];
35 |
36 | // Private method
37 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
38 | [[self window] setBottomCornerRounded:YES];
39 | }
40 | }
41 |
42 | - (void)removeOtherBottomBarViewsInDocument:(IBDocument *)document
43 | {
44 | NSArray *subviews = [[[self window] contentView] subviews];
45 |
46 | int i;
47 | for (i = 0; i < [subviews count]; i++)
48 | {
49 | NSView *view = [subviews objectAtIndex:i];
50 | if (view != self && ([view isKindOfClass:[BWAddRegularBottomBar class]] || [view isKindOfClass:[BWAddSmallBottomBar class]] || [view isKindOfClass:[BWAddMiniBottomBar class]] || [view isKindOfClass:[BWAddSheetBottomBar class]]))
51 | {
52 | [document removeObject:view];
53 | [view removeFromSuperview];
54 | }
55 | }
56 | }
57 |
58 |
59 | @end
60 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAnchoredButtonBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonBarViewIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAnchoredButtonBar.h"
11 | #import "BWAnchoredButtonBarInspector.h"
12 |
13 |
14 | @implementation BWAnchoredButtonBar ( BWAnchoredButtonBarIntegration )
15 |
16 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths {
17 | [super ibPopulateKeyPaths:keyPaths];
18 |
19 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"selectedIndex", nil]];
20 | }
21 |
22 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes {
23 | [super ibPopulateAttributeInspectorClasses:classes];
24 |
25 | [classes addObject:[BWAnchoredButtonBarInspector class]];
26 | }
27 |
28 | - (NSArray *)ibDefaultChildren
29 | {
30 | return [self subviews];
31 | }
32 |
33 | - (NSView *)ibDesignableContentView
34 | {
35 | return self;
36 | }
37 |
38 | - (NSSize)ibMinimumSize
39 | {
40 | NSSize minSize = NSZeroSize;
41 |
42 | if (isAtBottom)
43 | minSize.height = 23;
44 | else
45 | minSize.height = 24;
46 |
47 | return minSize;
48 | }
49 |
50 | - (NSSize)ibMaximumSize
51 | {
52 | NSSize maxSize;
53 | maxSize.width = 100000;
54 |
55 | if (isAtBottom)
56 | maxSize.height = 23;
57 | else
58 | maxSize.height = 24;
59 |
60 | return maxSize;
61 | }
62 |
63 |
64 | @end
65 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAnchoredButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredButtonIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAnchoredButton.h"
11 |
12 | @implementation BWAnchoredButton ( BWAnchoredButtonIntegration )
13 |
14 | - (NSSize)ibMinimumSize
15 | {
16 | return NSMakeSize(0,24);
17 | }
18 |
19 | - (NSSize)ibMaximumSize
20 | {
21 | return NSMakeSize(100000,24);
22 | }
23 |
24 | - (IBInset)ibLayoutInset
25 | {
26 | IBInset inset;
27 | inset.bottom = 0;
28 | inset.right = 0;
29 | inset.top = topAndLeftInset.x;
30 | inset.left = topAndLeftInset.y;
31 |
32 | return inset;
33 | }
34 |
35 | - (NSInteger)ibBaselineCount
36 | {
37 | return 1;
38 | }
39 |
40 | - (CGFloat)ibBaselineAtIndex:(NSInteger)index
41 | {
42 | return 16;
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWAnchoredPopUpButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWAnchoredPopUpButtonIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWAnchoredPopUpButton.h"
11 |
12 | @implementation BWAnchoredPopUpButton ( BWAnchoredPopUpButtonIntegration )
13 |
14 | - (NSSize)ibMinimumSize
15 | {
16 | return NSMakeSize(0,24);
17 | }
18 |
19 | - (NSSize)ibMaximumSize
20 | {
21 | return NSMakeSize(100000,24);
22 | }
23 |
24 | - (IBInset)ibLayoutInset
25 | {
26 | IBInset inset;
27 | inset.bottom = 0;
28 | inset.right = 0;
29 | inset.top = topAndLeftInset.x;
30 | inset.left = topAndLeftInset.y;
31 |
32 | return inset;
33 | }
34 |
35 | - (NSInteger)ibBaselineCount
36 | {
37 | return 1;
38 | }
39 |
40 | - (CGFloat)ibBaselineAtIndex:(NSInteger)index
41 | {
42 | return 16;
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWCustomViewIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientSplitViewSubviewIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWCustomView.h"
11 | #import "IBColor.h"
12 |
13 | @implementation BWCustomView ( BWCustomViewIntegration )
14 |
15 | - (NSView *)ibDesignableContentView
16 | {
17 | return self;
18 | }
19 |
20 | - (NSColor *)containerCustomViewBackgroundColor
21 | {
22 | return [IBColor containerCustomViewBackgroundColor];
23 | }
24 |
25 | - (NSColor *)childlessCustomViewBackgroundColor
26 | {
27 | return [IBColor childlessCustomViewBackgroundColor];
28 | }
29 |
30 | - (NSColor *)customViewDarkTexturedBorderColor
31 | {
32 | return [IBColor customViewDarkTexturedBorderColor];
33 | }
34 |
35 | - (NSColor *)customViewDarkBorderColor
36 | {
37 | return [IBColor customViewDarkBorderColor];
38 | }
39 |
40 | - (NSColor *)customViewLightBorderColor
41 | {
42 | return [IBColor customViewLightBorderColor];
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWGradientBoxIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWGradientBoxIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWGradientBox.h"
11 | #import "BWGradientBoxInspector.h"
12 |
13 | @implementation BWGradientBox (BWGradientBoxIntegration)
14 |
15 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths
16 | {
17 | [super ibPopulateKeyPaths:keyPaths];
18 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"topBorderColor", @"bottomBorderColor", @"fillStartingColor", @"fillEndingColor",
19 | @"fillColor", @"topInsetAlpha", @"bottomInsetAlpha", @"hasTopBorder", @"hasBottomBorder", @"hasGradient", @"hasFillColor", nil]];
20 | }
21 |
22 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes
23 | {
24 | [super ibPopulateAttributeInspectorClasses:classes];
25 |
26 | [classes addObject:[BWGradientBoxInspector class]];
27 | }
28 |
29 | - (NSView *)ibDesignableContentView
30 | {
31 | return self;
32 | }
33 |
34 | @end
35 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWHyperlinkButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWHyperlinkButtonIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWHyperlinkButton.h"
11 | #import "BWHyperlinkButtonInspector.h"
12 |
13 | @implementation BWHyperlinkButton (BWHyperlinkButtonIntegration)
14 |
15 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths
16 | {
17 | [super ibPopulateKeyPaths:keyPaths];
18 |
19 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"urlString", nil]];
20 | }
21 |
22 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes
23 | {
24 | [super ibPopulateAttributeInspectorClasses:classes];
25 |
26 | [classes addObject:[BWHyperlinkButtonInspector class]];
27 | }
28 |
29 | @end
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWRemoveBottomBarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWRemoveBottomBarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWRemoveBottomBar.h"
11 | #import "BWAddSmallBottomBar.h"
12 | #import "BWAddRegularBottomBar.h"
13 | #import "BWAddMiniBottomBar.h"
14 | #import "BWAddSheetBottomBar.h"
15 | #import "NSWindow+BWAdditions.h"
16 |
17 | @interface NSWindow (BWBBPrivate)
18 | - (void)setBottomCornerRounded:(BOOL)flag;
19 | @end
20 |
21 | @implementation BWRemoveBottomBar (BWRemoveBottomBarIntegration)
22 |
23 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
24 | {
25 | [super ibDidAddToDesignableDocument:document];
26 |
27 | // Remove the window's bottom bar
28 | [self performSelector:@selector(removeBottomBar) withObject:nil afterDelay:0];
29 |
30 | // Clean up
31 | [self performSelector:@selector(removeOtherBottomBarViewsInDocument:) withObject:document afterDelay:0];
32 | [self performSelector:@selector(removeSelfInDocument:) withObject:document afterDelay:0];
33 | }
34 |
35 | - (void)removeBottomBar
36 | {
37 | if ([[self window] bwIsTextured] == NO)
38 | {
39 | [[self window] setContentBorderThickness:0 forEdge:NSMinYEdge];
40 |
41 | // Private method
42 | if ([[self window] respondsToSelector:@selector(setBottomCornerRounded:)])
43 | [[self window] setBottomCornerRounded:NO];
44 | }
45 | }
46 |
47 | - (void)removeOtherBottomBarViewsInDocument:(IBDocument *)document
48 | {
49 | NSArray *subviews = [[[self window] contentView] subviews];
50 |
51 | int i;
52 | for (i = 0; i < [subviews count]; i++)
53 | {
54 | NSView *view = [subviews objectAtIndex:i];
55 | if (view != self && ([view isKindOfClass:[BWAddRegularBottomBar class]] || [view isKindOfClass:[BWAddSmallBottomBar class]] || [view isKindOfClass:[BWAddMiniBottomBar class]] || [view isKindOfClass:[BWAddSheetBottomBar class]]))
56 | {
57 | [document removeObject:view];
58 | [view removeFromSuperview];
59 | }
60 | }
61 | }
62 |
63 | - (void)removeSelfInDocument:(IBDocument *)document
64 | {
65 | [document removeObject:self];
66 | [self removeFromSuperview];
67 | }
68 |
69 | @end
70 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWSelectableToolbarIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSelectableToolbarIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWSelectableToolbar.h"
11 | #import "BWSelectableToolbarInspector.h"
12 | #import "BWSelectableToolbarHelper.h"
13 |
14 | @interface NSToolbar (BWSTIntPrivate)
15 | - (void)ibDocument:(id)fp8 willStartSimulatorWithContext:(id)fp12;
16 | @end
17 |
18 | @interface BWSelectableToolbar (BWSTIntPrivate)
19 | - (id)parentOfObject:(id)anObj;
20 | - (void)setDocumentToolbar:(BWSelectableToolbar *)obj;
21 | @end
22 |
23 | @interface IBDocument (BWSTIntPrivate)
24 | + (id)currentIBFrameworkVersion;
25 | @end
26 |
27 | @implementation BWSelectableToolbar ( BWSelectableToolbarIntegration )
28 |
29 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths {
30 | [super ibPopulateKeyPaths:keyPaths];
31 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"isPreferencesToolbar",nil]];
32 | }
33 |
34 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes {
35 | [super ibPopulateAttributeInspectorClasses:classes];
36 | [classes addObject:[BWSelectableToolbarInspector class]];
37 | }
38 |
39 | // Display a modal warning just before the simulator is launched - this incompatibility will hopefully be fixed in a future version of this plugin
40 | - (void)ibDocument:(id)fp8 willStartSimulatorWithContext:(id)fp12
41 | {
42 | [super ibDocument:fp8 willStartSimulatorWithContext:fp12];
43 |
44 | // Simulating seems to work fine in IB 3.1.1 (672) so we won't show the alert if the user is running that version
45 | if ([[IBDocument currentIBFrameworkVersion] intValue] != 672)
46 | {
47 | NSAlert *alert = [NSAlert alertWithMessageText:@"Toolbar not compatible with simulator" defaultButton:@"OK" alternateButton:nil otherButton:nil informativeTextWithFormat:@"The selectable toolbar is not yet compatible with the IB simulator. Quit the simulator and revert to the last saved document. Sorry for the inconvenience."];
48 | [alert runModal];
49 | }
50 | }
51 |
52 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
53 | {
54 | [super ibDidAddToDesignableDocument:document];
55 |
56 | [self setDocumentToolbar:self];
57 |
58 | helper = [[BWSelectableToolbarHelper alloc] init];
59 | [document addObject:helper toParent:[self parentOfObject:self]];
60 | }
61 |
62 | - (void)addObject:(id)object toParent:(id)parent
63 | {
64 | IBDocument *document = [IBDocument documentForObject:parent];
65 |
66 | [document addObject:object toParent:parent];
67 | }
68 |
69 | - (void)moveObject:(id)object toParent:(id)parent
70 | {
71 | IBDocument *document = [IBDocument documentForObject:object];
72 |
73 | [document moveObject:object toParent:parent];
74 | }
75 |
76 | - (void)removeObject:(id)object
77 | {
78 | IBDocument *document = [IBDocument documentForObject:object];
79 |
80 | [document removeObject:object];
81 | }
82 |
83 | - (NSArray *)objectsforDocumentObject:(id)anObj
84 | {
85 | IBDocument *document = [IBDocument documentForObject:anObj];
86 |
87 | return [[document objects] retain];
88 | }
89 |
90 | - (id)parentOfObject:(id)anObj
91 | {
92 | IBDocument *document = [IBDocument documentForObject:anObj];
93 |
94 | return [[document parentOfObject:anObj] retain];
95 | }
96 |
97 | - (NSArray *)childrenOfObject:(id)object
98 | {
99 | IBDocument *document = [IBDocument documentForObject:object];
100 |
101 | return [document childrenOfObject:object];
102 | }
103 |
104 | @end
105 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWSheetControllerIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSheetControllerIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWSheetController.h"
11 |
12 | @implementation BWSheetController ( BWSheetControllerIntegration )
13 |
14 | - (NSImage *)ibDefaultImage
15 | {
16 | NSBundle *bundle = [NSBundle bundleForClass:[BWSheetController class]];
17 |
18 | NSImage *image = [[[NSImage alloc] initWithContentsOfFile:[bundle pathForImageResource:@"Library-SheetController.tif"]] autorelease];
19 |
20 | return image;
21 | }
22 |
23 | @end
24 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWSplitViewIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWSplitViewIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWSplitView.h"
11 | #import "BWSplitViewInspector.h"
12 |
13 | @implementation BWSplitView ( BWSplitViewIntegration )
14 |
15 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths {
16 | [super ibPopulateKeyPaths:keyPaths];
17 |
18 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"color",@"colorIsEnabled",@"dividerCanCollapse",@"collapsiblePopupSelection",@"minValues",@"maxValues",@"minUnits",@"maxUnits",nil]];
19 | }
20 |
21 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes {
22 | [super ibPopulateAttributeInspectorClasses:classes];
23 |
24 | [classes addObject:[BWSplitViewInspector class]];
25 | }
26 |
27 | - (void)ibDidAddToDesignableDocument:(IBDocument *)document
28 | {
29 | [super ibDidAddToDesignableDocument:document];
30 | }
31 |
32 | @end
33 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWStyledTextFieldIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWStyledTextFieldIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWStyledTextField.h"
11 | #import "BWStyledTextFieldInspector.h"
12 |
13 | @implementation BWStyledTextField (BWStyledTextFieldIntegration)
14 |
15 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths
16 | {
17 | [super ibPopulateKeyPaths:keyPaths];
18 |
19 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"shadowIsBelow", @"hasShadow", @"shadowColor", @"startingColor", @"endingColor", @"hasGradient", @"solidColor", nil]];
20 | }
21 |
22 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes
23 | {
24 | [super ibPopulateAttributeInspectorClasses:classes];
25 |
26 | [classes addObject:[BWStyledTextFieldInspector class]];
27 | }
28 |
29 | @end
30 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTexturedSliderIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWControlsView.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTexturedSlider.h"
11 | #import "BWTexturedSliderInspector.h"
12 |
13 |
14 | @implementation BWTexturedSlider ( BWTexturedSliderIntegration )
15 |
16 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths {
17 | [super ibPopulateKeyPaths:keyPaths];
18 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"trackHeight",@"indicatorIndex",nil]];
19 | }
20 |
21 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes {
22 | [super ibPopulateAttributeInspectorClasses:classes];
23 | [classes addObject:[BWTexturedSliderInspector class]];
24 | }
25 |
26 | - (IBInset)ibLayoutInset
27 | {
28 | IBInset inset;
29 |
30 | if ([self trackHeight] == 0)
31 | {
32 | inset.top = 4;
33 | inset.bottom = 5;
34 | }
35 | else
36 | {
37 | inset.top = 5;
38 | inset.bottom = 4;
39 | }
40 |
41 | if ([self indicatorIndex] == 0)
42 | {
43 | inset.right = 4;
44 | inset.left = 5;
45 | }
46 | else if ([self indicatorIndex] == 2)
47 | {
48 | inset.bottom = 3;
49 | inset.right = 5;
50 | inset.left = 13;
51 | }
52 | else if ([self indicatorIndex] == 3)
53 | {
54 | inset.right = 12;
55 | inset.left = 18;
56 | }
57 | else
58 | {
59 | inset.right = 0;
60 | inset.left = 0;
61 | }
62 |
63 | return inset;
64 | }
65 |
66 | @end
67 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWToolbarItemIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWToolbarItemIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWToolbarItem.h"
11 | #import "BWToolbarItemInspector.h"
12 |
13 | @implementation BWToolbarItem ( BWToolbarItemIntegration )
14 |
15 | - (void)ibPopulateKeyPaths:(NSMutableDictionary *)keyPaths {
16 | [super ibPopulateKeyPaths:keyPaths];
17 |
18 | [[keyPaths objectForKey:IBAttributeKeyPaths] addObjectsFromArray:[NSArray arrayWithObjects:@"identifierString", nil]];
19 | }
20 |
21 | - (void)ibPopulateAttributeInspectorClasses:(NSMutableArray *)classes {
22 | [super ibPopulateAttributeInspectorClasses:classes];
23 |
24 | [classes addObject:[BWToolbarItemInspector class]];
25 | }
26 |
27 | @end
28 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWToolkit_Prefix.pch:
--------------------------------------------------------------------------------
1 | //
2 | // Prefix header for all source files of the 'BWToolkit' target in the 'BWToolkit' project.
3 | //
4 |
5 | #ifdef __OBJC__
6 | #import
7 | #import
8 | #endif
9 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentButtonIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentButton.h"
11 |
12 | @implementation BWTransparentButton ( BWTransparentButtonIntegration )
13 |
14 | - (IBInset)ibLayoutInset
15 | {
16 | IBInset inset;
17 | inset.top = 10;
18 | inset.bottom = 0;
19 | inset.left = 1;
20 | inset.right = 1;
21 |
22 | return inset;
23 | }
24 |
25 | - (NSInteger)ibBaselineCount
26 | {
27 | return 1;
28 | }
29 |
30 | - (CGFloat)ibBaselineAtIndex:(NSInteger)index
31 | {
32 | return 13;
33 | }
34 |
35 | @end
36 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentCheckboxIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentCheckBoxIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentCheckbox.h"
11 |
12 | @implementation BWTransparentCheckbox ( BWTransparentCheckboxIntegration )
13 |
14 | - (NSSize)ibMinimumSize
15 | {
16 | return NSMakeSize(0,18);
17 | }
18 |
19 | - (NSSize)ibMaximumSize
20 | {
21 | return NSMakeSize(100000,18);
22 | }
23 |
24 | - (IBInset)ibLayoutInset
25 | {
26 | IBInset inset;
27 | inset.top = 3;
28 | inset.bottom = 3;
29 | inset.left = 2;
30 | inset.right = 0;
31 |
32 | return inset;
33 | }
34 |
35 | @end
36 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentPopUpButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentPopUpIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentPopUpButton.h"
11 |
12 | @implementation BWTransparentPopUpButton ( BWTransparentPopUpButtonIntegration )
13 |
14 | - (IBInset)ibLayoutInset
15 | {
16 | IBInset inset;
17 | inset.top = 4;
18 | inset.bottom = 0;
19 | inset.left = 1;
20 | inset.right = 1;
21 |
22 | return inset;
23 | }
24 |
25 | - (NSInteger)ibBaselineCount
26 | {
27 | return 1;
28 | }
29 |
30 | - (CGFloat)ibBaselineAtIndex:(NSInteger)index
31 | {
32 | return 13;
33 | }
34 |
35 | @end
36 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentScrollViewIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentScrollViewIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentScrollView.h"
11 |
12 | @implementation BWTransparentScrollView ( BWTransparentScrollViewIntegration )
13 |
14 | - (IBInset)ibLayoutInset
15 | {
16 | IBInset inset;
17 | inset.top = 0;
18 | inset.bottom = 0;
19 | inset.left = -1;
20 | inset.right = -1;
21 |
22 | return inset;
23 | }
24 |
25 | - (void)ibTester
26 | {
27 | }
28 |
29 | @end
30 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentSliderIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentSliderIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentSlider.h"
11 |
12 |
13 | @implementation BWTransparentSlider ( BWTransparentSliderIntegration )
14 |
15 | - (IBInset)ibLayoutInset
16 | {
17 | IBInset inset;
18 |
19 | inset.left = 2;
20 | inset.top = 2;
21 | inset.bottom = 3;
22 |
23 | if ([self numberOfTickMarks] == 0)
24 | {
25 | inset.right = 3;
26 | }
27 | else
28 | {
29 | inset.right = 2;
30 | }
31 |
32 | return inset;
33 | }
34 |
35 | @end
36 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWTransparentTableViewIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWTransparentTableViewIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWTransparentTableView.h"
11 |
12 | @implementation BWTransparentTableView ( BWTransparentTableViewIntegration )
13 |
14 | - (void)addObject:(id)object toParent:(id)parent
15 | {
16 | IBDocument *document = [IBDocument documentForObject:parent];
17 |
18 | [document addObject:object toParent:parent];
19 | }
20 |
21 | - (void)removeObject:(id)object
22 | {
23 | IBDocument *document = [IBDocument documentForObject:object];
24 |
25 | [document removeObject:object];
26 | }
27 |
28 | - (void)ibTester
29 | {
30 | }
31 |
32 | @end
33 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWUnanchoredButtonContainerIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonContainerIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWUnanchoredButtonContainer.h"
11 | #import "BWUnanchoredButton.h"
12 |
13 | @implementation BWUnanchoredButtonContainer ( BWUnanchoredButtonContainerIntegration )
14 |
15 | - (NSSize)ibMinimumSize
16 | {
17 | return NSMakeSize(45,22);
18 | }
19 |
20 | - (NSSize)ibMaximumSize
21 | {
22 | return NSMakeSize(45,22);
23 | }
24 |
25 | - (BOOL)ibIsChildInitiallySelectable:(id)child
26 | {
27 | return NO;
28 | }
29 |
30 | - (NSArray *)ibDefaultChildren
31 | {
32 | return [self subviews];
33 | }
34 |
35 | - (NSView *)ibDesignableContentView
36 | {
37 | return self;
38 | }
39 |
40 | - (IBInset)ibLayoutInset
41 | {
42 | IBInset inset;
43 |
44 | inset.left = 0;
45 | inset.top = 1;
46 | inset.bottom = 1;
47 | inset.right = 0;
48 |
49 | return inset;
50 | }
51 |
52 | @end
53 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Other Sources/BWUnanchoredButtonIntegration.m:
--------------------------------------------------------------------------------
1 | //
2 | // BWUnanchoredButtonIntegration.m
3 | // BWToolkit
4 | //
5 | // Created by Brandon Walkin (www.brandonwalkin.com)
6 | // All code is provided under the New BSD license.
7 | //
8 |
9 | #import
10 | #import "BWUnanchoredButton.h"
11 |
12 | @implementation BWUnanchoredButton ( BWUnanchoredButtonIntegration )
13 |
14 | - (NSSize)ibMinimumSize
15 | {
16 | return NSMakeSize(0,22);
17 | }
18 |
19 | - (NSSize)ibMaximumSize
20 | {
21 | return NSMakeSize(100000,22);
22 | }
23 |
24 | - (IBInset)ibLayoutInset
25 | {
26 | IBInset inset;
27 | inset.bottom = 1;
28 | inset.right = 0;
29 | inset.top = 1;
30 | inset.left = 0;
31 |
32 | return inset;
33 | }
34 |
35 | - (NSInteger)ibBaselineCount
36 | {
37 | return 1;
38 | }
39 |
40 | - (CGFloat)ibBaselineAtIndex:(NSInteger)index
41 | {
42 | return 15;
43 | }
44 |
45 | @end
46 |
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/BWSelectableToolbarInspector.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/BWSelectableToolbarInspector.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/BWTexturedSliderInspector.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/BWTexturedSliderInspector.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode1.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode1.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode1Pressed.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode1Pressed.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode2.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode2.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode2Pressed.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode2Pressed.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode3.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode3.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode3Pressed.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarMode3Pressed.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarModeSelection.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Anchored Button Bar/Inspector-ButtonBarModeSelection.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Gradient Well/GradientWellPattern.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Gradient Well/GradientWellPattern.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowBlueLeft.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowBlueLeft.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowBlueRight.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowBlueRight.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedFill.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedFill.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedLeft.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedLeft.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedRight.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewArrowRedRight.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewBackground.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Inspectors/Graphics/Split View/Inspector-SplitViewBackground.tiff
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWBottomBarLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWBottomBarLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWButtonBarLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWButtonBarLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWControllersLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWControllersLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWSplitViewLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWSplitViewLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWToolbarItemsLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWToolbarItemsLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWToolkitLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWToolkitLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Libraries/BWTransparentControlsLibrary.nib/keyedobjects.nib:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Libraries/BWTransparentControlsLibrary.nib/keyedobjects.nib
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddMiniBottomBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddMiniBottomBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddRegularBottomBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddRegularBottomBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddSheetBottomBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddSheetBottomBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddSmallBottomBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AddSmallBottomBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredButtonBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredButtonBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredPopUpButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-AnchoredPopUpButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-CustomView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-CustomView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-GradientBox.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-GradientBox.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-GradientSplitView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-GradientSplitView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-HorizontalSplitView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-HorizontalSplitView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-InsetTextField.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-InsetTextField.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-RemoveBottomBar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-RemoveBottomBar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-SelectableToolbar.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-SelectableToolbar.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-SheetController.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-SheetController.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ShowColors.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ShowColors.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ShowFonts.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ShowFonts.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-StyledTextField.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-StyledTextField.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedAddButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedAddButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedRemoveButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedRemoveButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedSlider.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TexturedSlider.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TokenField.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TokenField.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ToolbarItem.tiff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-ToolbarItem.tiff
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentCheckbox.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentCheckbox.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentCheckboxCell.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentCheckboxCell.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentLabel.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentLabel.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentPopUpButton.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentPopUpButton.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentSlider.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentSlider.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentTableView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentTableView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentTextView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-TransparentTextView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Library Thumbnails/Library-VerticalSplitView.tif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/glebd/bwtoolkit/c357bccfaf827b5c1762efd46b0d3ece0d2d1d73/BWToolkit/Plugin/Resources/Library Thumbnails/Library-VerticalSplitView.tif
--------------------------------------------------------------------------------
/BWToolkit/Plugin/Resources/Private IB Classes/IBColor.h:
--------------------------------------------------------------------------------
1 | /*
2 | * Generated by class-dump 3.1.2.
3 | *
4 | * class-dump is Copyright (C) 1997-1998, 2000-2001, 2004-2007 by Steve Nygard.
5 | */
6 |
7 | //#import "NSColor.h"
8 |
9 | @interface IBColor : NSColor
10 | {
11 | }
12 |
13 | + (void)setPreferredColor:(id)fp8 forName:(id)fp12;
14 | + (id)preferredColorForName:(id)fp8;
15 | + (id)bandSelectionBodyColor;
16 | + (id)viewSelectionColor;
17 | + (id)bandSelectionBorderColor;
18 | + (id)dragInsertionIndicatorColor;
19 | + (id)dragInsertionIndicatorFillColor;
20 | + (id)layoutRectColor;
21 | + (id)baselineColor;
22 | + (id)layoutInfoColor;
23 | + (id)boundsInfoColor;
24 | + (id)customViewColor;
25 | + (id)missingImageColor;
26 | + (id)connectionLineStrokeColor;
27 | + (id)connectionLineFillColor;
28 | + (id)connectionLineShadowColor;
29 | + (id)targetIdentifierColor;
30 | + (id)liveLayoutGuideColor;
31 | + (id)layoutGuideLabelFillColor;
32 | + (id)layoutGuideLabelFrameColor;
33 | + (id)notesBackgroundColor;
34 | + (id)paletteBackgroundColor;
35 | + (id)paletteTitleFillColor;
36 | + (id)paletteTitleColor;
37 | + (id)paletteTextColor;
38 | + (id)inspectorGearBackgroundColor;
39 | + (id)inspectorModeLightGradientColor;
40 | + (id)inspectorModeDarkGradientColor;
41 | + (id)inspectorSliceLightGradientColor;
42 | + (id)inspectorSliceDarkGradientColor;
43 | + (id)inspectorSliceBorderColor;
44 | + (id)inspectorSliceToneColor;
45 | + (id)inspectorModeSelectionToneColor;
46 | + (id)inspectorModePressedToneColor;
47 | + (id)inspectorModeSeparatorColor;
48 | + (id)slateScrollerBackgroundColor;
49 | + (id)slateScrollerKnobColor;
50 | + (id)slateScrollerTrackedKnobColor;
51 | + (id)slateScrollerTrackColor;
52 | + (id)slateScrollerButtonFillColor;
53 | + (id)slateScrollerButtonIconColor;
54 | + (id)slateScrollerButtonPressedIconColor;
55 | + (id)slateScrollerButtonDisabledIconColor;
56 | + (id)slateScrollerButtonDisabledFillColor;
57 | + (id)slateScrollerButtonPressedFillColor;
58 | + (id)connectionSliceTitleFillColor;
59 | + (id)menuDropTargetIndicatorColor;
60 | + (id)menuDarkDropTargetIndicatorColor;
61 | + (id)menuLightDropTargetIndicatorColor;
62 | + (id)slatePaletteButtonPressedColor;
63 | + (id)slateElementViewBackgroundColor;
64 | + (id)slateElementViewHighlightColor;
65 | + (id)slateElementViewPressedColor;
66 | + (id)slateElementViewSelectedColor;
67 | + (id)slateElementViewTextColor;
68 | + (id)slateLabelHighlightColor;
69 | + (id)paletteChooserOutlineColor;
70 | + (id)paletteChooserPressedColor;
71 | + (id)paletteChooserHighlightColor;
72 | + (id)containerCustomViewBackgroundColor;
73 | + (id)childlessCustomViewBackgroundColor;
74 | + (id)childlessCustomViewTextColor;
75 | + (id)containerCustomViewTextColor;
76 | + (id)customViewDarkTexturedBorderColor;
77 | + (id)customViewDarkBorderColor;
78 | + (id)customViewLightBorderColor;
79 | + (id)toolbarItemContainerFillColor;
80 | + (id)lightSpotlightColor;
81 | + (id)darkSpotlightColor;
82 | + (id)spotlightBorderColor;
83 | + (id)lightPurpleSpotlightColor;
84 | + (id)darkPurpleSpotlightColor;
85 | + (id)spotlightTextColor;
86 | + (id)lightestSlateColor;
87 | + (id)lighterSlateColor;
88 | + (id)lightSlateColor;
89 | + (id)slateColor;
90 | + (id)darkSlateColor;
91 | + (id)darkerSlateColor;
92 | + (id)darkestSlateColor;
93 | + (id)darkestSlateHUDBackgroundColor;
94 | + (id)darkerSlateHUDBackgroundColor;
95 | + (id)darkSlateHUDBackgroundColor;
96 | + (id)slateHUDBackgroundColor;
97 | + (id)lightSlateHUDBackgroundColor;
98 | + (id)slateWarningColor;
99 | + (id)darkSlateWarningColor;
100 |
101 | @end
102 |
103 |
--------------------------------------------------------------------------------
/BWToolkit/Resources/License.rtf:
--------------------------------------------------------------------------------
1 | {\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf250
2 | {\fonttbl\f0\fnil\fcharset0 Verdana;\f1\fnil\fcharset0 LucidaGrande;}
3 | {\colortbl;\red255\green255\blue255;\red73\green73\blue73;}
4 | {\*\listtable{\list\listtemplateid1\listhybrid{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\*\levelmarker \{disc\}}{\leveltext\leveltemplateid1\'01\uc0\u8226 ;}{\levelnumbers;}\fi-360\li720\lin720 }{\listname ;}\listid1}}
5 | {\*\listoverridetable{\listoverride\listid1\listoverridecount0\ls1}}
6 | \deftab720
7 | \pard\pardeftab720\sl400\sa280\ql\qnatural
8 |
9 | \f0\fs24 \cf2 Copyright (c) 2010, Brandon Walkin
10 | \f1 \uc0\u8232
11 | \f0 All rights reserved.\
12 | Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:\
13 | \pard\tx220\tx720\pardeftab720\li720\fi-720\sl400\sa20\ql\qnatural
14 | \ls1\ilvl0\cf2 {\listtext \'95 }Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.\
15 | {\listtext \'95 }Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.\
16 | {\listtext \'95 }Neither the name of the Brandon Walkin nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.\
17 | \pard\pardeftab720\sl400\sa280\ql\qnatural
18 | \cf2 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.}
--------------------------------------------------------------------------------