├── DVPieChart
├── DVPieChart.xcodeproj
│ ├── project.xcworkspace
│ │ └── contents.xcworkspacedata
│ └── project.pbxproj
├── DVPieChart
│ ├── ViewController.h
│ ├── DVDishPieHeader
│ │ ├── DVFoodPieModel.m
│ │ ├── DVPieCenterView.h
│ │ ├── DVPieChart.h
│ │ ├── DVFoodPieModel.h
│ │ ├── DVPieCenterView.m
│ │ └── DVPieChart.m
│ ├── AppDelegate.h
│ ├── main.m
│ ├── Info.plist
│ ├── Base.lproj
│ │ ├── Main.storyboard
│ │ └── LaunchScreen.storyboard
│ ├── Assets.xcassets
│ │ └── AppIcon.appiconset
│ │ │ └── Contents.json
│ ├── AppDelegate.m
│ └── ViewController.m
├── DVPieChartTests
│ ├── Info.plist
│ └── DVPieChartTests.m
└── DVPieChartUITests
│ ├── Info.plist
│ └── DVPieChartUITests.m
├── README.md
└── .gitignore
/DVPieChart/DVPieChart.xcodeproj/project.xcworkspace/contents.xcworkspacedata:
--------------------------------------------------------------------------------
1 |
2 |
4 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/ViewController.h:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.h
3 | // DVPieChart
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface ViewController : UIViewController
12 |
13 |
14 | @end
15 |
16 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVFoodPieModel.m:
--------------------------------------------------------------------------------
1 | //
2 | // DVFoodPieModel.m
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/27.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import "DVFoodPieModel.h"
10 |
11 | @implementation DVFoodPieModel
12 |
13 | @end
14 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | # DVPieChart
2 | 
3 |
4 | > 图中不论每个扇形多小,都可以从指引线处将指引的数据分割开来,不会重叠。解决饼图数据显示的问题
5 |
6 |
7 | ### 更多内容请去看[我的简书](https://www.jianshu.com/p/bc9029c32fc1),里面详细讲解了具体的实现过程。
8 | * [https://www.jianshu.com/p/bc9029c32fc1](https://www.jianshu.com/p/bc9029c32fc1)
9 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/AppDelegate.h:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.h
3 | // DVPieChart
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface AppDelegate : UIResponder
12 |
13 | @property (strong, nonatomic) UIWindow *window;
14 |
15 |
16 | @end
17 |
18 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVPieCenterView.h:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieCenterView.h
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/27.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface DVPieCenterView : UIView
12 |
13 |
14 | @property (strong, nonatomic) UILabel *nameLabel;
15 |
16 |
17 | @end
18 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/main.m:
--------------------------------------------------------------------------------
1 | //
2 | // main.m
3 | // DVPieChart
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import
10 | #import "AppDelegate.h"
11 |
12 | int main(int argc, char * argv[]) {
13 | @autoreleasepool {
14 | return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
15 | }
16 | }
17 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVPieChart.h:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieChart.h
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/26.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface DVPieChart : UIView
12 |
13 | /**
14 | 数据数组
15 | */
16 | @property (strong, nonatomic) NSArray *dataArray;
17 |
18 | /**
19 | 标题
20 | */
21 | @property (copy, nonatomic) NSString *title;
22 |
23 | /**
24 | 绘制方法
25 | */
26 | - (void)draw;
27 |
28 | @end
29 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVFoodPieModel.h:
--------------------------------------------------------------------------------
1 | //
2 | // DVFoodPieModel.h
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/27.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import
10 | #import
11 |
12 | @interface DVFoodPieModel : NSObject
13 |
14 | /**
15 | 名称
16 | */
17 | @property (copy, nonatomic) NSString *name;
18 |
19 | /**
20 | 数值
21 | */
22 | @property (assign, nonatomic) CGFloat value;
23 |
24 | /**
25 | 比例
26 | */
27 | @property (assign, nonatomic) CGFloat rate;
28 |
29 | @end
30 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChartTests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleVersion
20 | 1
21 |
22 |
23 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChartUITests/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | BNDL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleVersion
20 | 1
21 |
22 |
23 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChartTests/DVPieChartTests.m:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieChartTests.m
3 | // DVPieChartTests
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface DVPieChartTests : XCTestCase
12 |
13 | @end
14 |
15 | @implementation DVPieChartTests
16 |
17 | - (void)setUp {
18 | [super setUp];
19 | // Put setup code here. This method is called before the invocation of each test method in the class.
20 | }
21 |
22 | - (void)tearDown {
23 | // Put teardown code here. This method is called after the invocation of each test method in the class.
24 | [super tearDown];
25 | }
26 |
27 | - (void)testExample {
28 | // This is an example of a functional test case.
29 | // Use XCTAssert and related functions to verify your tests produce the correct results.
30 | }
31 |
32 | - (void)testPerformanceExample {
33 | // This is an example of a performance test case.
34 | [self measureBlock:^{
35 | // Put the code you want to measure the time of here.
36 | }];
37 | }
38 |
39 | @end
40 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChartUITests/DVPieChartUITests.m:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieChartUITests.m
3 | // DVPieChartUITests
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import
10 |
11 | @interface DVPieChartUITests : XCTestCase
12 |
13 | @end
14 |
15 | @implementation DVPieChartUITests
16 |
17 | - (void)setUp {
18 | [super setUp];
19 |
20 | // Put setup code here. This method is called before the invocation of each test method in the class.
21 |
22 | // In UI tests it is usually best to stop immediately when a failure occurs.
23 | self.continueAfterFailure = NO;
24 | // UI tests must launch the application that they test. Doing this in setup will make sure it happens for each test method.
25 | [[[XCUIApplication alloc] init] launch];
26 |
27 | // In UI tests it’s important to set the initial state - such as interface orientation - required for your tests before they run. The setUp method is a good place to do this.
28 | }
29 |
30 | - (void)tearDown {
31 | // Put teardown code here. This method is called after the invocation of each test method in the class.
32 | [super tearDown];
33 | }
34 |
35 | - (void)testExample {
36 | // Use recording to get started writing UI tests.
37 | // Use XCTAssert and related functions to verify your tests produce the correct results.
38 | }
39 |
40 | @end
41 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDevelopmentRegion
6 | $(DEVELOPMENT_LANGUAGE)
7 | CFBundleExecutable
8 | $(EXECUTABLE_NAME)
9 | CFBundleIdentifier
10 | $(PRODUCT_BUNDLE_IDENTIFIER)
11 | CFBundleInfoDictionaryVersion
12 | 6.0
13 | CFBundleName
14 | $(PRODUCT_NAME)
15 | CFBundlePackageType
16 | APPL
17 | CFBundleShortVersionString
18 | 1.0
19 | CFBundleVersion
20 | 1
21 | LSRequiresIPhoneOS
22 |
23 | UILaunchStoryboardName
24 | LaunchScreen
25 | UIMainStoryboardFile
26 | Main
27 | UIRequiredDeviceCapabilities
28 |
29 | armv7
30 |
31 | UISupportedInterfaceOrientations
32 |
33 | UIInterfaceOrientationPortrait
34 | UIInterfaceOrientationLandscapeLeft
35 | UIInterfaceOrientationLandscapeRight
36 |
37 | UISupportedInterfaceOrientations~ipad
38 |
39 | UIInterfaceOrientationPortrait
40 | UIInterfaceOrientationPortraitUpsideDown
41 | UIInterfaceOrientationLandscapeLeft
42 | UIInterfaceOrientationLandscapeRight
43 |
44 |
45 |
46 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | # Xcode
2 | #
3 | # gitignore contributors: remember to update Global/Xcode.gitignore, Objective-C.gitignore & Swift.gitignore
4 |
5 | ## Build generated
6 | build/
7 | DerivedData/
8 |
9 | ## Various settings
10 | *.pbxuser
11 | !default.pbxuser
12 | *.mode1v3
13 | !default.mode1v3
14 | *.mode2v3
15 | !default.mode2v3
16 | *.perspectivev3
17 | !default.perspectivev3
18 | xcuserdata/
19 |
20 | ## Other
21 | *.moved-aside
22 | *.xccheckout
23 | *.xcscmblueprint
24 |
25 | ## Obj-C/Swift specific
26 | *.hmap
27 | *.ipa
28 | *.dSYM.zip
29 | *.dSYM
30 |
31 | # CocoaPods
32 | #
33 | # We recommend against adding the Pods directory to your .gitignore. However
34 | # you should judge for yourself, the pros and cons are mentioned at:
35 | # https://guides.cocoapods.org/using/using-cocoapods.html#should-i-check-the-pods-directory-into-source-control
36 | #
37 | # Pods/
38 |
39 | # Carthage
40 | #
41 | # Add this line if you want to avoid checking in source code from Carthage dependencies.
42 | # Carthage/Checkouts
43 |
44 | Carthage/Build
45 |
46 | # fastlane
47 | #
48 | # It is recommended to not store the screenshots in the git repo. Instead, use fastlane to re-generate the
49 | # screenshots whenever they are needed.
50 | # For more information about the recommended setup visit:
51 | # https://docs.fastlane.tools/best-practices/source-control/#source-control
52 |
53 | fastlane/report.xml
54 | fastlane/Preview.html
55 | fastlane/screenshots
56 | fastlane/test_output
57 |
58 | # Code Injection
59 | #
60 | # After new code Injection tools there's a generated folder /iOSInjectionProject
61 | # https://github.com/johnno1962/injectionforxcode
62 |
63 | iOSInjectionProject/
64 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/Base.lproj/Main.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/Base.lproj/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVPieCenterView.m:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieCenterView.m
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/27.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import "DVPieCenterView.h"
10 |
11 | @interface DVPieCenterView ()
12 |
13 | @property (strong, nonatomic) UIView *centerView;
14 |
15 | @end
16 |
17 |
18 |
19 | @implementation DVPieCenterView
20 |
21 |
22 | - (instancetype)initWithFrame:(CGRect)frame {
23 |
24 | if (self = [super initWithFrame:frame]) {
25 |
26 | self.backgroundColor = [[UIColor whiteColor] colorWithAlphaComponent:0.4];
27 |
28 |
29 |
30 | UIView *centerView = [[UIView alloc] init];
31 |
32 | centerView.backgroundColor = [UIColor whiteColor];
33 |
34 | [self addSubview:centerView];
35 | self.centerView = centerView;
36 |
37 |
38 | UILabel *nameLabel = [[UILabel alloc] init];
39 | nameLabel.textColor = [UIColor colorWithRed:51/255.0 green:51/255.0 blue:51/255.0 alpha:1];
40 | nameLabel.font = [UIFont systemFontOfSize:18];
41 |
42 | nameLabel.textAlignment = NSTextAlignmentCenter;
43 |
44 | self.nameLabel = nameLabel;
45 |
46 |
47 | [centerView addSubview:nameLabel];
48 | }
49 |
50 | return self;
51 | }
52 |
53 |
54 | - (void)layoutSubviews {
55 |
56 | [super layoutSubviews];
57 |
58 | self.layer.cornerRadius = self.frame.size.width * 0.5;
59 | self.layer.masksToBounds = true;
60 |
61 | self.centerView.frame = CGRectMake(6, 6, self.frame.size.width - 6 * 2, self.frame.size.height - 6 * 2);
62 | self.centerView.layer.cornerRadius = self.centerView.frame.size.width * 0.5;
63 | self.centerView.layer.masksToBounds = true;
64 |
65 | self.nameLabel.frame = self.centerView.bounds;
66 | }
67 |
68 |
69 | @end
70 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/Assets.xcassets/AppIcon.appiconset/Contents.json:
--------------------------------------------------------------------------------
1 | {
2 | "images" : [
3 | {
4 | "idiom" : "iphone",
5 | "size" : "20x20",
6 | "scale" : "2x"
7 | },
8 | {
9 | "idiom" : "iphone",
10 | "size" : "20x20",
11 | "scale" : "3x"
12 | },
13 | {
14 | "idiom" : "iphone",
15 | "size" : "29x29",
16 | "scale" : "2x"
17 | },
18 | {
19 | "idiom" : "iphone",
20 | "size" : "29x29",
21 | "scale" : "3x"
22 | },
23 | {
24 | "idiom" : "iphone",
25 | "size" : "40x40",
26 | "scale" : "2x"
27 | },
28 | {
29 | "idiom" : "iphone",
30 | "size" : "40x40",
31 | "scale" : "3x"
32 | },
33 | {
34 | "idiom" : "iphone",
35 | "size" : "60x60",
36 | "scale" : "2x"
37 | },
38 | {
39 | "idiom" : "iphone",
40 | "size" : "60x60",
41 | "scale" : "3x"
42 | },
43 | {
44 | "idiom" : "ipad",
45 | "size" : "20x20",
46 | "scale" : "1x"
47 | },
48 | {
49 | "idiom" : "ipad",
50 | "size" : "20x20",
51 | "scale" : "2x"
52 | },
53 | {
54 | "idiom" : "ipad",
55 | "size" : "29x29",
56 | "scale" : "1x"
57 | },
58 | {
59 | "idiom" : "ipad",
60 | "size" : "29x29",
61 | "scale" : "2x"
62 | },
63 | {
64 | "idiom" : "ipad",
65 | "size" : "40x40",
66 | "scale" : "1x"
67 | },
68 | {
69 | "idiom" : "ipad",
70 | "size" : "40x40",
71 | "scale" : "2x"
72 | },
73 | {
74 | "idiom" : "ipad",
75 | "size" : "76x76",
76 | "scale" : "1x"
77 | },
78 | {
79 | "idiom" : "ipad",
80 | "size" : "76x76",
81 | "scale" : "2x"
82 | },
83 | {
84 | "idiom" : "ipad",
85 | "size" : "83.5x83.5",
86 | "scale" : "2x"
87 | }
88 | ],
89 | "info" : {
90 | "version" : 1,
91 | "author" : "xcode"
92 | }
93 | }
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/AppDelegate.m:
--------------------------------------------------------------------------------
1 | //
2 | // AppDelegate.m
3 | // DVPieChart
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import "AppDelegate.h"
10 |
11 | @interface AppDelegate ()
12 |
13 | @end
14 |
15 | @implementation AppDelegate
16 |
17 |
18 | - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
19 | // Override point for customization after application launch.
20 | return YES;
21 | }
22 |
23 |
24 | - (void)applicationWillResignActive:(UIApplication *)application {
25 | // Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
26 | // Use this method to pause ongoing tasks, disable timers, and invalidate graphics rendering callbacks. Games should use this method to pause the game.
27 | }
28 |
29 |
30 | - (void)applicationDidEnterBackground:(UIApplication *)application {
31 | // Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
32 | // If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
33 | }
34 |
35 |
36 | - (void)applicationWillEnterForeground:(UIApplication *)application {
37 | // Called as part of the transition from the background to the active state; here you can undo many of the changes made on entering the background.
38 | }
39 |
40 |
41 | - (void)applicationDidBecomeActive:(UIApplication *)application {
42 | // Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
43 | }
44 |
45 |
46 | - (void)applicationWillTerminate:(UIApplication *)application {
47 | // Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
48 | }
49 |
50 |
51 | @end
52 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/ViewController.m:
--------------------------------------------------------------------------------
1 | //
2 | // ViewController.m
3 | // DVPieChart
4 | //
5 | // Created by Fire on 2018/3/22.
6 | // Copyright © 2018年 Fire. All rights reserved.
7 | //
8 |
9 | #import "ViewController.h"
10 | #import "DVPieChart.h"
11 | #import "DVFoodPieModel.h"
12 |
13 | @interface ViewController ()
14 |
15 | @end
16 |
17 | @implementation ViewController
18 |
19 | - (void)viewDidLoad {
20 | [super viewDidLoad];
21 | // Do any additional setup after loading the view, typically from a nib.
22 |
23 | CGFloat width = [UIScreen mainScreen].bounds.size.width;
24 |
25 | DVPieChart *chart = [[DVPieChart alloc] initWithFrame:CGRectMake(0, 30, width, 320)];
26 |
27 | [self.view addSubview:chart];
28 |
29 |
30 | DVFoodPieModel *model1 = [[DVFoodPieModel alloc] init];
31 |
32 | model1.rate = 0.7261;
33 | model1.name = @"哈哈哈哈哈哈";
34 | model1.value = 423651.23;
35 |
36 |
37 | DVFoodPieModel *model2 = [[DVFoodPieModel alloc] init];
38 |
39 | model2.rate = 0.068;
40 | model2.name = @"哈哈哈哈哈哈";
41 | model2.value = 423651.23;
42 |
43 |
44 | DVFoodPieModel *model3 = [[DVFoodPieModel alloc] init];
45 |
46 | model3.rate = 0.068;
47 | model3.name = @"哈哈";
48 | model3.value = 423651.23;
49 |
50 |
51 | DVFoodPieModel *model4 = [[DVFoodPieModel alloc] init];
52 |
53 | model4.rate = 0.0594;
54 | model4.name = @"哈哈哈哈哈哈";
55 | model4.value = 423651.23;
56 |
57 |
58 | DVFoodPieModel *model5 = [[DVFoodPieModel alloc] init];
59 |
60 | model5.rate = 0.0393;
61 | model5.name = @"哈哈";
62 | model5.value = 423651.23;
63 |
64 |
65 | DVFoodPieModel *model6 = [[DVFoodPieModel alloc] init];
66 |
67 | model6.rate = 0.0391;
68 | model6.name = @"哈哈哈哈哈哈哈哈哈哈哈哈";
69 | model6.value = 423651.23;
70 |
71 |
72 | NSArray *dataArray = @[model1, model2, model3, model4, model5, model6];
73 |
74 | chart.dataArray = dataArray;
75 |
76 | chart.title = @"金额";
77 |
78 | [chart draw];
79 |
80 |
81 |
82 |
83 |
84 | DVPieChart *chart1 = [[DVPieChart alloc] initWithFrame:CGRectMake(0, 330, width, 300)];
85 |
86 | [self.view addSubview:chart1];
87 |
88 |
89 | DVFoodPieModel *model7 = [[DVFoodPieModel alloc] init];
90 |
91 | model7.rate = 0.01;
92 | model7.name = @"哈哈";
93 | model7.value = 423651.23;
94 |
95 |
96 | DVFoodPieModel *model8 = [[DVFoodPieModel alloc] init];
97 |
98 | model8.rate = 0.01;
99 | model8.name = @"哈哈哈哈哈哈";
100 | model8.value = 423651.23;
101 |
102 |
103 | DVFoodPieModel *model9 = [[DVFoodPieModel alloc] init];
104 |
105 | model9.rate = 0.01;
106 | model9.name = @"哈哈";
107 | model9.value = 423651.23;
108 |
109 |
110 | DVFoodPieModel *model10 = [[DVFoodPieModel alloc] init];
111 |
112 | model10.rate = 0.01;
113 | model10.name = @"哈哈哈哈哈哈";
114 | model10.value = 423651.23;
115 |
116 |
117 | DVFoodPieModel *model11 = [[DVFoodPieModel alloc] init];
118 |
119 | model11.rate = 0.01;
120 | model11.name = @"哈哈哈哈哈哈";
121 | model11.value = 423651.23;
122 |
123 |
124 | DVFoodPieModel *model12 = [[DVFoodPieModel alloc] init];
125 |
126 | model12.rate = 0.95;
127 | model12.name = @"哈哈哈哈哈哈哈哈哈哈哈哈";
128 | model12.value = 423651.23;
129 |
130 |
131 | NSArray *dataArray1 = @[model7, model8, model9, model10, model11, model12];
132 |
133 | chart1.dataArray = dataArray1;
134 |
135 | chart1.title = @"金额";
136 |
137 | [chart1 draw];
138 |
139 |
140 | }
141 |
142 |
143 | - (void)didReceiveMemoryWarning {
144 | [super didReceiveMemoryWarning];
145 | // Dispose of any resources that can be recreated.
146 | }
147 |
148 |
149 | @end
150 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart/DVDishPieHeader/DVPieChart.m:
--------------------------------------------------------------------------------
1 | //
2 | // DVPieChart.m
3 | // DVPieChart
4 | //
5 | // Created by SmithDavid on 2018/2/26.
6 | // Copyright © 2018年 SmithDavid. All rights reserved.
7 | //
8 |
9 | #import "DVPieChart.h"
10 | #import "DVFoodPieModel.h"
11 | #import "DVPieCenterView.h"
12 |
13 | #define COLOR_ARRAY @[\
14 | [UIColor colorWithRed:251/255.0 green:166.9/255.0 blue:96.5/255.0 alpha:1],\
15 | [UIColor colorWithRed:151.9/255.0 green:188/255.0 blue:95.8/255.0 alpha:1],\
16 | [UIColor colorWithRed:245/255.0 green:94/255.0 blue:102/255.0 alpha:1],\
17 | [UIColor colorWithRed:29/255.0 green:140/255.0 blue:140/255.0 alpha:1],\
18 | [UIColor colorWithRed:121/255.0 green:113/255.0 blue:199/255.0 alpha:1],\
19 | [UIColor colorWithRed:16/255.0 green:149/255.0 blue:224/255.0 alpha:1]\
20 | ]
21 |
22 | #define CHART_MARGIN 50
23 |
24 | @interface DVPieChart ()
25 |
26 | @property (nonatomic, strong) NSMutableArray *modelArray;
27 | @property (nonatomic, strong) NSMutableArray *colorArray;
28 |
29 | @end
30 |
31 |
32 | @implementation DVPieChart
33 |
34 | - (instancetype)initWithFrame:(CGRect)frame {
35 |
36 | if (self = [super initWithFrame:frame]) {
37 | self.backgroundColor = [UIColor whiteColor];
38 | }
39 | return self;
40 | }
41 |
42 |
43 |
44 | - (void)draw {
45 | [self.subviews makeObjectsPerformSelector:@selector(removeFromSuperview)];
46 | [self setNeedsDisplay];
47 | }
48 |
49 |
50 | -(void)drawRect:(CGRect)rect{
51 |
52 | CGFloat min = self.bounds.size.width > self.bounds.size.height ? self.bounds.size.height : self.bounds.size.width;
53 |
54 | CGPoint center = CGPointMake(self.bounds.size.width * 0.5, self.bounds.size.height * 0.5);
55 | CGFloat radius = min * 0.5 - CHART_MARGIN;
56 | CGFloat start = 0;
57 | CGFloat angle = 0;
58 | CGFloat end = start;
59 |
60 |
61 | if (self.dataArray.count == 0) {
62 |
63 | end = start + M_PI * 2;
64 |
65 | UIColor *color = COLOR_ARRAY.firstObject;
66 |
67 | UIBezierPath *path = [UIBezierPath bezierPathWithArcCenter:center radius:radius startAngle:start endAngle:end clockwise:true];
68 |
69 | [color set];
70 |
71 | //添加一根线到圆心
72 | [path addLineToPoint:center];
73 | [path fill];
74 |
75 | } else {
76 |
77 | NSMutableArray *pointArray = [NSMutableArray array];
78 | NSMutableArray *centerArray = [NSMutableArray array];
79 |
80 | self.modelArray = [NSMutableArray array];
81 | self.colorArray = [NSMutableArray array];
82 |
83 | for (int i = 0; i < self.dataArray.count; i++) {
84 |
85 | DVFoodPieModel *model = self.dataArray[i];
86 | CGFloat percent = model.rate;
87 | UIColor *color = COLOR_ARRAY[i];
88 |
89 | start = end;
90 |
91 | angle = percent * M_PI * 2;
92 |
93 | end = start + angle;
94 |
95 | UIBezierPath *path = [UIBezierPath bezierPathWithArcCenter:center radius:radius startAngle:start endAngle:end clockwise:true];
96 |
97 | [color set];
98 |
99 | //添加一根线到圆心
100 | [path addLineToPoint:center];
101 | [path fill];
102 |
103 |
104 | // 获取弧度的中心角度
105 | CGFloat radianCenter = (start + end) * 0.5;
106 |
107 |
108 | // 获取指引线的起点
109 | CGFloat lineStartX = self.frame.size.width * 0.5 + radius * cos(radianCenter);
110 | CGFloat lineStartY = self.frame.size.height * 0.5 + radius * sin(radianCenter);
111 |
112 |
113 | CGPoint point = CGPointMake(lineStartX, lineStartY);
114 |
115 | if (i <= self.dataArray.count / 2 - 1) {
116 | [pointArray insertObject:[NSValue valueWithCGPoint:point] atIndex:0];
117 | [centerArray insertObject:[NSNumber numberWithFloat:radianCenter] atIndex:0];
118 | [self.modelArray insertObject:model atIndex:0];
119 | [self.colorArray insertObject:color atIndex:0];
120 | } else {
121 | [pointArray addObject:[NSValue valueWithCGPoint:point]];
122 | [centerArray addObject:[NSNumber numberWithFloat:radianCenter]];
123 | [self.modelArray addObject:model];
124 | [self.colorArray addObject:color];
125 | }
126 |
127 |
128 | // 绘出指引线
129 | // [self addLineWithColor:color X:lineStartX Y:lineStartY name:model.name number:[NSString stringWithFormat:@"%.2f%%", model.rate * 100] radianCenter:radianCenter];
130 | }
131 |
132 | // 通过pointArray绘制指引线
133 | [self drawLineWithPointArray:pointArray centerArray:centerArray];
134 |
135 | }
136 |
137 | // 在中心添加label
138 | DVPieCenterView *centerView = [[DVPieCenterView alloc] init];
139 | centerView.frame = CGRectMake(0, 0, 80, 80);
140 |
141 | CGRect frame = centerView.frame;
142 | frame.origin = CGPointMake(self.frame.size.width * 0.5 - frame.size.width * 0.5, self.frame.size.height * 0.5 - frame.size.width * 0.5);
143 | centerView.frame = frame;
144 |
145 | centerView.nameLabel.text = self.title;
146 |
147 | [self addSubview:centerView];
148 | }
149 |
150 |
151 | // 绘画指引线
152 | - (void)addLineWithColor:(UIColor *)color X:(CGFloat)x Y:(CGFloat)y name:(NSString *)name number:(NSString *)number radianCenter:(CGFloat)radianCenter {
153 |
154 | // 指引线的折点
155 | CGFloat breakPointX = x + 10 * cos(radianCenter);
156 | CGFloat breakPointY = y + 10 * sin(radianCenter);
157 |
158 | // 指引线的终点
159 | CGFloat endX;
160 | CGFloat endY;
161 |
162 | // 数字的frame
163 | CGFloat numberWidth = 80.f;
164 | CGFloat numberHeight = 15.f;
165 |
166 | CGFloat numberX = breakPointX;
167 | CGFloat numberY = breakPointY - numberHeight;
168 |
169 |
170 | // title的frame
171 | CGFloat titleWidth = numberWidth;
172 | CGFloat titleHeight = numberHeight;
173 |
174 | CGFloat titleX = breakPointX;
175 | CGFloat titleY = breakPointY + 2;
176 |
177 | NSMutableParagraphStyle * paragraph = [[NSMutableParagraphStyle alloc]init];
178 | paragraph.alignment = NSTextAlignmentRight;
179 |
180 | if (x > self.frame.size.width * 0.5) {
181 |
182 | endX = breakPointX + numberWidth;
183 | endY = breakPointY;
184 |
185 | } else {
186 |
187 | endX = breakPointX - numberWidth;
188 | endY = breakPointY;
189 |
190 | paragraph.alignment = NSTextAlignmentLeft;
191 |
192 | numberX = endX;
193 | titleX = endX;
194 | }
195 |
196 |
197 | // 绘制指引线
198 | //1.获取上下文
199 | CGContextRef ctx = UIGraphicsGetCurrentContext();
200 | //2.绘制路径
201 | UIBezierPath *path = [UIBezierPath bezierPath];
202 |
203 | [path moveToPoint:CGPointMake(x, y)];
204 |
205 | [path addLineToPoint:CGPointMake(breakPointX, breakPointY)];
206 |
207 | [path addLineToPoint:CGPointMake(endX, endY)];
208 |
209 | CGContextSetLineWidth(ctx, 1);
210 |
211 | //设置颜色
212 | [color set];
213 |
214 | //3.把绘制的内容添加到上下文当中
215 | CGContextAddPath(ctx, path.CGPath);
216 | //4.把上下文的内容显示到View上(渲染到View的layer)(stroke fill)
217 | CGContextStrokePath(ctx);
218 |
219 | CGFloat point = -5;
220 | if (x > self.frame.size.width * 0.5) {
221 | point = 0;
222 | }
223 |
224 | // 在终点处添加点
225 | UIView *view = [[UIView alloc] init];
226 | view.backgroundColor = color;
227 | [self addSubview:view];
228 | CGRect rect = view.frame;
229 | rect.size = CGSizeMake(5, 5);
230 | rect.origin = CGPointMake(endX + point, endY - 2.5);
231 | view.frame = rect;
232 | view.layer.cornerRadius = 2.5;
233 | view.layer.masksToBounds = true;
234 |
235 | // UIColor *strColor = [UIColor colorWithRed:51/255.0 green:51/255.0 blue:51/255.0 alpha:1];
236 | UIColor *strColor = color;
237 | //指引线上面的数字
238 | [name drawInRect:CGRectMake(numberX, numberY, numberWidth, numberHeight) withAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:10.0], NSForegroundColorAttributeName:strColor,NSParagraphStyleAttributeName:paragraph}];
239 |
240 | // 指引线下面的title
241 | [number drawInRect:CGRectMake(titleX, titleY, titleWidth, titleHeight) withAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:10.0],NSForegroundColorAttributeName:strColor,NSParagraphStyleAttributeName:paragraph}];
242 | }
243 |
244 |
245 | - (void)drawLineWithPointArray:(NSArray *)pointArray centerArray:(NSArray *)centerArray {
246 |
247 | // 记录每一个指引线包括数据所占用位置的和(总体位置)
248 | CGRect rect = CGRectZero;
249 |
250 | // 用于计算指引线长度
251 | CGFloat width = self.bounds.size.width * 0.5;
252 |
253 | for (int i = 0; i < pointArray.count; i++) {
254 |
255 | // 取出数据
256 | NSValue *value = pointArray[i];
257 |
258 | // 每个圆弧中心店的位置
259 | CGPoint point = value.CGPointValue;
260 |
261 | // 每个圆弧中心点的角度
262 | CGFloat radianCenter = [centerArray[i] floatValue];
263 |
264 | // 颜色(绘制数据时要用)
265 | UIColor *color = self.colorArray[i % 6];
266 |
267 | // 模型数据(绘制数据时要用)
268 | DVFoodPieModel *model = self.modelArray[i];
269 |
270 | // 模型的数据
271 | NSString *name = model.name;
272 | NSString *number = [NSString stringWithFormat:@"%.2f%%", model.rate * 100];
273 |
274 |
275 | // 圆弧中心点的x值和y值
276 | CGFloat x = point.x;
277 | CGFloat y = point.y;
278 |
279 | // 指引线终点的位置(x, y)
280 | CGFloat startX = x + 10 * cos(radianCenter);
281 | CGFloat startY = y + 10 * sin(radianCenter);
282 |
283 | // 指引线转折点的位置(x, y)
284 | CGFloat breakPointX = x + 20 * cos(radianCenter);
285 | CGFloat breakPointY = y + 20 * sin(radianCenter);
286 |
287 | // 转折点到中心竖线的垂直长度(为什么+20, 在实际做出的效果中,有的转折线很丑,+20为了美化)
288 | CGFloat margin = fabs(width - breakPointX) + 20;
289 |
290 | // 指引线长度
291 | CGFloat lineWidth = width - margin;
292 |
293 | // 指引线起点(x, y)
294 | CGFloat endX;
295 | CGFloat endY;
296 |
297 | // 绘制文字和数字时,所占的size(width和height)
298 | // width使用lineWidth更好,我这么写固定值是为了达到产品要求
299 | CGFloat numberWidth = 80.f;
300 | CGFloat numberHeight = 15.f;
301 |
302 | CGFloat titleWidth = numberWidth;
303 | CGFloat titleHeight = numberHeight;
304 |
305 | // 绘制文字和数字时的起始位置(x, y)与上面的合并起来就是frame
306 | CGFloat numberX;// = breakPointX;
307 | CGFloat numberY = breakPointY - numberHeight;
308 |
309 | CGFloat titleX = breakPointX;
310 | CGFloat titleY = breakPointY + 2;
311 |
312 |
313 | // 文本段落属性(绘制文字和数字时需要)
314 | NSMutableParagraphStyle * paragraph = [[NSMutableParagraphStyle alloc]init];
315 | // 文字靠右
316 | paragraph.alignment = NSTextAlignmentRight;
317 |
318 | // 判断x位置,确定在指引线向左还是向右绘制
319 | // 根据需要变更指引线的起始位置
320 | // 变更文字和数字的位置
321 | if (x <= width) { // 在左边
322 |
323 | endX = 10;
324 | endY = breakPointY;
325 |
326 | // 文字靠左
327 | paragraph.alignment = NSTextAlignmentLeft;
328 |
329 | numberX = endX;
330 | titleX = endX;
331 |
332 | } else { // 在右边
333 |
334 | endX = self.bounds.size.width - 10;
335 | endY = breakPointY;
336 |
337 | numberX = endX - numberWidth;
338 | titleX = endX - titleWidth;
339 | }
340 |
341 |
342 | if (i != 0) {
343 |
344 | // 当i!=0时,就需要计算位置总和(方法开始出的rect)与rect1(将进行绘制的位置)是否有重叠
345 | CGRect rect1 = CGRectMake(numberX, numberY, numberWidth, titleY + titleHeight - numberY);
346 |
347 | CGFloat margin = 0;
348 |
349 | if (CGRectIntersectsRect(rect, rect1)) {
350 | // 两个面积重叠
351 | // 三种情况
352 | // 1. 压上面
353 | // 2. 压下面
354 | // 3. 包含
355 | // 通过计算让面积重叠的情况消除
356 | if (CGRectContainsRect(rect, rect1)) {// 包含
357 |
358 | if (i % self.dataArray.count <= self.dataArray.count * 0.5 - 1) {
359 | // 将要绘制的位置在总位置偏上
360 | margin = CGRectGetMaxY(rect1) - rect.origin.y;
361 | endY -= margin;
362 | } else {
363 | // 将要绘制的位置在总位置偏下
364 | margin = CGRectGetMaxY(rect) - rect1.origin.y;
365 | endY += margin;
366 | }
367 |
368 |
369 | } else { // 相交
370 |
371 | if (CGRectGetMaxY(rect1) > rect.origin.y && rect1.origin.y < rect.origin.y) { // 压在总位置上面
372 | margin = CGRectGetMaxY(rect1) - rect.origin.y;
373 | endY -= margin;
374 |
375 | } else if (rect1.origin.y < CGRectGetMaxY(rect) && CGRectGetMaxY(rect1) > CGRectGetMaxY(rect)) { // 压总位置下面
376 | margin = CGRectGetMaxY(rect) - rect1.origin.y;
377 | endY += margin;
378 | }
379 |
380 | }
381 | }
382 | titleY = endY + 2;
383 | numberY = endY - numberHeight;
384 |
385 |
386 | // 通过计算得出的将要绘制的位置
387 | CGRect rect2 = CGRectMake(numberX, numberY, numberWidth, titleY + titleHeight - numberY);
388 |
389 | // 把新获得的rect和之前的rect合并
390 | if (numberX == rect.origin.x) {
391 | // 当两个位置在同一侧的时候才需要合并
392 | if (rect2.origin.y < rect.origin.y) {
393 | rect = CGRectMake(rect.origin.x, rect2.origin.y, rect.size.width, rect.size.height + rect2.size.height);
394 | } else {
395 | rect = CGRectMake(rect.origin.x, rect.origin.y, rect.size.width, rect.size.height + rect2.size.height);
396 | }
397 | }
398 |
399 | } else {
400 | rect = CGRectMake(numberX, numberY, numberWidth, titleY + titleHeight - numberY);
401 | }
402 |
403 |
404 | // 重新制定转折点
405 | if (endX == 10) {
406 | breakPointX = endX + lineWidth;
407 | } else {
408 | breakPointX = endX - lineWidth;
409 | }
410 |
411 | breakPointY = endY;
412 |
413 | //1.获取上下文
414 | CGContextRef ctx = UIGraphicsGetCurrentContext();
415 | //2.绘制路径
416 | UIBezierPath *path = [UIBezierPath bezierPath];
417 |
418 | [path moveToPoint:CGPointMake(endX, endY)];
419 |
420 | [path addLineToPoint:CGPointMake(breakPointX, breakPointY)];
421 |
422 | [path addLineToPoint:CGPointMake(startX, startY)];
423 |
424 | CGContextSetLineWidth(ctx, 0.5);
425 |
426 | //设置颜色
427 | [color set];
428 |
429 | //3.把绘制的内容添加到上下文当中
430 | CGContextAddPath(ctx, path.CGPath);
431 | //4.把上下文的内容显示到View上(渲染到View的layer)(stroke fill)
432 | CGContextStrokePath(ctx);
433 |
434 |
435 |
436 | // 在终点处添加点(小圆点)
437 | // movePoint,让转折线指向小圆点中心
438 | CGFloat movePoint = -2.5;
439 |
440 | UIView *view = [[UIView alloc] init];
441 | view.backgroundColor = color;
442 | [self addSubview:view];
443 | CGRect rect = view.frame;
444 | rect.size = CGSizeMake(5, 5);
445 | rect.origin = CGPointMake(startX + movePoint, startY - 2.5);
446 | view.frame = rect;
447 | view.layer.cornerRadius = 2.5;
448 | view.layer.masksToBounds = true;
449 |
450 |
451 |
452 | //指引线上面的数字
453 | [name drawInRect:CGRectMake(numberX, numberY, numberWidth, numberHeight) withAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:9.0], NSForegroundColorAttributeName:color,NSParagraphStyleAttributeName:paragraph}];
454 |
455 | // 指引线下面的title
456 | [number drawInRect:CGRectMake(titleX, titleY, titleWidth, titleHeight) withAttributes:@{NSFontAttributeName:[UIFont systemFontOfSize:9.0],NSForegroundColorAttributeName:color,NSParagraphStyleAttributeName:paragraph}];
457 |
458 | }
459 |
460 |
461 | }
462 |
463 |
464 | @end
465 |
466 |
--------------------------------------------------------------------------------
/DVPieChart/DVPieChart.xcodeproj/project.pbxproj:
--------------------------------------------------------------------------------
1 | // !$*UTF8*$!
2 | {
3 | archiveVersion = 1;
4 | classes = {
5 | };
6 | objectVersion = 48;
7 | objects = {
8 |
9 | /* Begin PBXBuildFile section */
10 | 42F9E61D206392F400F8DD4B /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E61C206392F400F8DD4B /* AppDelegate.m */; };
11 | 42F9E620206392F400F8DD4B /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E61F206392F400F8DD4B /* ViewController.m */; };
12 | 42F9E623206392F400F8DD4B /* Main.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 42F9E621206392F400F8DD4B /* Main.storyboard */; };
13 | 42F9E625206392F400F8DD4B /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 42F9E624206392F400F8DD4B /* Assets.xcassets */; };
14 | 42F9E628206392F400F8DD4B /* LaunchScreen.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 42F9E626206392F400F8DD4B /* LaunchScreen.storyboard */; };
15 | 42F9E62B206392F400F8DD4B /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E62A206392F400F8DD4B /* main.m */; };
16 | 42F9E635206392F400F8DD4B /* DVPieChartTests.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E634206392F400F8DD4B /* DVPieChartTests.m */; };
17 | 42F9E640206392F400F8DD4B /* DVPieChartUITests.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E63F206392F400F8DD4B /* DVPieChartUITests.m */; };
18 | 42F9E6552063931000F8DD4B /* DVPieCenterView.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E6512063931000F8DD4B /* DVPieCenterView.m */; };
19 | 42F9E6562063931000F8DD4B /* DVPieChart.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E6532063931000F8DD4B /* DVPieChart.m */; };
20 | 42F9E659206393A700F8DD4B /* DVFoodPieModel.m in Sources */ = {isa = PBXBuildFile; fileRef = 42F9E658206393A700F8DD4B /* DVFoodPieModel.m */; };
21 | /* End PBXBuildFile section */
22 |
23 | /* Begin PBXContainerItemProxy section */
24 | 42F9E631206392F400F8DD4B /* PBXContainerItemProxy */ = {
25 | isa = PBXContainerItemProxy;
26 | containerPortal = 42F9E610206392F400F8DD4B /* Project object */;
27 | proxyType = 1;
28 | remoteGlobalIDString = 42F9E617206392F400F8DD4B;
29 | remoteInfo = DVPieChart;
30 | };
31 | 42F9E63C206392F400F8DD4B /* PBXContainerItemProxy */ = {
32 | isa = PBXContainerItemProxy;
33 | containerPortal = 42F9E610206392F400F8DD4B /* Project object */;
34 | proxyType = 1;
35 | remoteGlobalIDString = 42F9E617206392F400F8DD4B;
36 | remoteInfo = DVPieChart;
37 | };
38 | /* End PBXContainerItemProxy section */
39 |
40 | /* Begin PBXFileReference section */
41 | 42F9E618206392F400F8DD4B /* DVPieChart.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = DVPieChart.app; sourceTree = BUILT_PRODUCTS_DIR; };
42 | 42F9E61B206392F400F8DD4B /* AppDelegate.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = AppDelegate.h; sourceTree = ""; };
43 | 42F9E61C206392F400F8DD4B /* AppDelegate.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = AppDelegate.m; sourceTree = ""; };
44 | 42F9E61E206392F400F8DD4B /* ViewController.h */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.h; path = ViewController.h; sourceTree = ""; };
45 | 42F9E61F206392F400F8DD4B /* ViewController.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = ViewController.m; sourceTree = ""; };
46 | 42F9E622206392F400F8DD4B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/Main.storyboard; sourceTree = ""; };
47 | 42F9E624206392F400F8DD4B /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; };
48 | 42F9E627206392F400F8DD4B /* Base */ = {isa = PBXFileReference; lastKnownFileType = file.storyboard; name = Base; path = Base.lproj/LaunchScreen.storyboard; sourceTree = ""; };
49 | 42F9E629206392F400F8DD4B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
50 | 42F9E62A206392F400F8DD4B /* main.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = main.m; sourceTree = ""; };
51 | 42F9E630206392F400F8DD4B /* DVPieChartTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = DVPieChartTests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
52 | 42F9E634206392F400F8DD4B /* DVPieChartTests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DVPieChartTests.m; sourceTree = ""; };
53 | 42F9E636206392F400F8DD4B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
54 | 42F9E63B206392F400F8DD4B /* DVPieChartUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = DVPieChartUITests.xctest; sourceTree = BUILT_PRODUCTS_DIR; };
55 | 42F9E63F206392F400F8DD4B /* DVPieChartUITests.m */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.c.objc; path = DVPieChartUITests.m; sourceTree = ""; };
56 | 42F9E641206392F400F8DD4B /* Info.plist */ = {isa = PBXFileReference; lastKnownFileType = text.plist.xml; path = Info.plist; sourceTree = ""; };
57 | 42F9E6502063931000F8DD4B /* DVPieCenterView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DVPieCenterView.h; sourceTree = ""; };
58 | 42F9E6512063931000F8DD4B /* DVPieCenterView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DVPieCenterView.m; sourceTree = ""; };
59 | 42F9E6522063931000F8DD4B /* DVPieChart.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DVPieChart.h; sourceTree = ""; };
60 | 42F9E6532063931000F8DD4B /* DVPieChart.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DVPieChart.m; sourceTree = ""; };
61 | 42F9E657206393A700F8DD4B /* DVFoodPieModel.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = DVFoodPieModel.h; sourceTree = ""; };
62 | 42F9E658206393A700F8DD4B /* DVFoodPieModel.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = DVFoodPieModel.m; sourceTree = ""; };
63 | /* End PBXFileReference section */
64 |
65 | /* Begin PBXFrameworksBuildPhase section */
66 | 42F9E615206392F400F8DD4B /* Frameworks */ = {
67 | isa = PBXFrameworksBuildPhase;
68 | buildActionMask = 2147483647;
69 | files = (
70 | );
71 | runOnlyForDeploymentPostprocessing = 0;
72 | };
73 | 42F9E62D206392F400F8DD4B /* Frameworks */ = {
74 | isa = PBXFrameworksBuildPhase;
75 | buildActionMask = 2147483647;
76 | files = (
77 | );
78 | runOnlyForDeploymentPostprocessing = 0;
79 | };
80 | 42F9E638206392F400F8DD4B /* Frameworks */ = {
81 | isa = PBXFrameworksBuildPhase;
82 | buildActionMask = 2147483647;
83 | files = (
84 | );
85 | runOnlyForDeploymentPostprocessing = 0;
86 | };
87 | /* End PBXFrameworksBuildPhase section */
88 |
89 | /* Begin PBXGroup section */
90 | 42F9E60F206392F400F8DD4B = {
91 | isa = PBXGroup;
92 | children = (
93 | 42F9E61A206392F400F8DD4B /* DVPieChart */,
94 | 42F9E633206392F400F8DD4B /* DVPieChartTests */,
95 | 42F9E63E206392F400F8DD4B /* DVPieChartUITests */,
96 | 42F9E619206392F400F8DD4B /* Products */,
97 | );
98 | sourceTree = "";
99 | };
100 | 42F9E619206392F400F8DD4B /* Products */ = {
101 | isa = PBXGroup;
102 | children = (
103 | 42F9E618206392F400F8DD4B /* DVPieChart.app */,
104 | 42F9E630206392F400F8DD4B /* DVPieChartTests.xctest */,
105 | 42F9E63B206392F400F8DD4B /* DVPieChartUITests.xctest */,
106 | );
107 | name = Products;
108 | sourceTree = "";
109 | };
110 | 42F9E61A206392F400F8DD4B /* DVPieChart */ = {
111 | isa = PBXGroup;
112 | children = (
113 | 42F9E64D2063931000F8DD4B /* DVDishPieHeader */,
114 | 42F9E61B206392F400F8DD4B /* AppDelegate.h */,
115 | 42F9E61C206392F400F8DD4B /* AppDelegate.m */,
116 | 42F9E61E206392F400F8DD4B /* ViewController.h */,
117 | 42F9E61F206392F400F8DD4B /* ViewController.m */,
118 | 42F9E621206392F400F8DD4B /* Main.storyboard */,
119 | 42F9E624206392F400F8DD4B /* Assets.xcassets */,
120 | 42F9E626206392F400F8DD4B /* LaunchScreen.storyboard */,
121 | 42F9E629206392F400F8DD4B /* Info.plist */,
122 | 42F9E62A206392F400F8DD4B /* main.m */,
123 | );
124 | path = DVPieChart;
125 | sourceTree = "";
126 | };
127 | 42F9E633206392F400F8DD4B /* DVPieChartTests */ = {
128 | isa = PBXGroup;
129 | children = (
130 | 42F9E634206392F400F8DD4B /* DVPieChartTests.m */,
131 | 42F9E636206392F400F8DD4B /* Info.plist */,
132 | );
133 | path = DVPieChartTests;
134 | sourceTree = "";
135 | };
136 | 42F9E63E206392F400F8DD4B /* DVPieChartUITests */ = {
137 | isa = PBXGroup;
138 | children = (
139 | 42F9E63F206392F400F8DD4B /* DVPieChartUITests.m */,
140 | 42F9E641206392F400F8DD4B /* Info.plist */,
141 | );
142 | path = DVPieChartUITests;
143 | sourceTree = "";
144 | };
145 | 42F9E64D2063931000F8DD4B /* DVDishPieHeader */ = {
146 | isa = PBXGroup;
147 | children = (
148 | 42F9E6502063931000F8DD4B /* DVPieCenterView.h */,
149 | 42F9E6512063931000F8DD4B /* DVPieCenterView.m */,
150 | 42F9E6522063931000F8DD4B /* DVPieChart.h */,
151 | 42F9E6532063931000F8DD4B /* DVPieChart.m */,
152 | 42F9E657206393A700F8DD4B /* DVFoodPieModel.h */,
153 | 42F9E658206393A700F8DD4B /* DVFoodPieModel.m */,
154 | );
155 | path = DVDishPieHeader;
156 | sourceTree = "";
157 | };
158 | /* End PBXGroup section */
159 |
160 | /* Begin PBXNativeTarget section */
161 | 42F9E617206392F400F8DD4B /* DVPieChart */ = {
162 | isa = PBXNativeTarget;
163 | buildConfigurationList = 42F9E644206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChart" */;
164 | buildPhases = (
165 | 42F9E614206392F400F8DD4B /* Sources */,
166 | 42F9E615206392F400F8DD4B /* Frameworks */,
167 | 42F9E616206392F400F8DD4B /* Resources */,
168 | );
169 | buildRules = (
170 | );
171 | dependencies = (
172 | );
173 | name = DVPieChart;
174 | productName = DVPieChart;
175 | productReference = 42F9E618206392F400F8DD4B /* DVPieChart.app */;
176 | productType = "com.apple.product-type.application";
177 | };
178 | 42F9E62F206392F400F8DD4B /* DVPieChartTests */ = {
179 | isa = PBXNativeTarget;
180 | buildConfigurationList = 42F9E647206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChartTests" */;
181 | buildPhases = (
182 | 42F9E62C206392F400F8DD4B /* Sources */,
183 | 42F9E62D206392F400F8DD4B /* Frameworks */,
184 | 42F9E62E206392F400F8DD4B /* Resources */,
185 | );
186 | buildRules = (
187 | );
188 | dependencies = (
189 | 42F9E632206392F400F8DD4B /* PBXTargetDependency */,
190 | );
191 | name = DVPieChartTests;
192 | productName = DVPieChartTests;
193 | productReference = 42F9E630206392F400F8DD4B /* DVPieChartTests.xctest */;
194 | productType = "com.apple.product-type.bundle.unit-test";
195 | };
196 | 42F9E63A206392F400F8DD4B /* DVPieChartUITests */ = {
197 | isa = PBXNativeTarget;
198 | buildConfigurationList = 42F9E64A206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChartUITests" */;
199 | buildPhases = (
200 | 42F9E637206392F400F8DD4B /* Sources */,
201 | 42F9E638206392F400F8DD4B /* Frameworks */,
202 | 42F9E639206392F400F8DD4B /* Resources */,
203 | );
204 | buildRules = (
205 | );
206 | dependencies = (
207 | 42F9E63D206392F400F8DD4B /* PBXTargetDependency */,
208 | );
209 | name = DVPieChartUITests;
210 | productName = DVPieChartUITests;
211 | productReference = 42F9E63B206392F400F8DD4B /* DVPieChartUITests.xctest */;
212 | productType = "com.apple.product-type.bundle.ui-testing";
213 | };
214 | /* End PBXNativeTarget section */
215 |
216 | /* Begin PBXProject section */
217 | 42F9E610206392F400F8DD4B /* Project object */ = {
218 | isa = PBXProject;
219 | attributes = {
220 | LastUpgradeCheck = 0920;
221 | ORGANIZATIONNAME = Fire;
222 | TargetAttributes = {
223 | 42F9E617206392F400F8DD4B = {
224 | CreatedOnToolsVersion = 9.2;
225 | ProvisioningStyle = Automatic;
226 | };
227 | 42F9E62F206392F400F8DD4B = {
228 | CreatedOnToolsVersion = 9.2;
229 | ProvisioningStyle = Automatic;
230 | TestTargetID = 42F9E617206392F400F8DD4B;
231 | };
232 | 42F9E63A206392F400F8DD4B = {
233 | CreatedOnToolsVersion = 9.2;
234 | ProvisioningStyle = Automatic;
235 | TestTargetID = 42F9E617206392F400F8DD4B;
236 | };
237 | };
238 | };
239 | buildConfigurationList = 42F9E613206392F400F8DD4B /* Build configuration list for PBXProject "DVPieChart" */;
240 | compatibilityVersion = "Xcode 8.0";
241 | developmentRegion = en;
242 | hasScannedForEncodings = 0;
243 | knownRegions = (
244 | en,
245 | Base,
246 | );
247 | mainGroup = 42F9E60F206392F400F8DD4B;
248 | productRefGroup = 42F9E619206392F400F8DD4B /* Products */;
249 | projectDirPath = "";
250 | projectRoot = "";
251 | targets = (
252 | 42F9E617206392F400F8DD4B /* DVPieChart */,
253 | 42F9E62F206392F400F8DD4B /* DVPieChartTests */,
254 | 42F9E63A206392F400F8DD4B /* DVPieChartUITests */,
255 | );
256 | };
257 | /* End PBXProject section */
258 |
259 | /* Begin PBXResourcesBuildPhase section */
260 | 42F9E616206392F400F8DD4B /* Resources */ = {
261 | isa = PBXResourcesBuildPhase;
262 | buildActionMask = 2147483647;
263 | files = (
264 | 42F9E628206392F400F8DD4B /* LaunchScreen.storyboard in Resources */,
265 | 42F9E625206392F400F8DD4B /* Assets.xcassets in Resources */,
266 | 42F9E623206392F400F8DD4B /* Main.storyboard in Resources */,
267 | );
268 | runOnlyForDeploymentPostprocessing = 0;
269 | };
270 | 42F9E62E206392F400F8DD4B /* Resources */ = {
271 | isa = PBXResourcesBuildPhase;
272 | buildActionMask = 2147483647;
273 | files = (
274 | );
275 | runOnlyForDeploymentPostprocessing = 0;
276 | };
277 | 42F9E639206392F400F8DD4B /* Resources */ = {
278 | isa = PBXResourcesBuildPhase;
279 | buildActionMask = 2147483647;
280 | files = (
281 | );
282 | runOnlyForDeploymentPostprocessing = 0;
283 | };
284 | /* End PBXResourcesBuildPhase section */
285 |
286 | /* Begin PBXSourcesBuildPhase section */
287 | 42F9E614206392F400F8DD4B /* Sources */ = {
288 | isa = PBXSourcesBuildPhase;
289 | buildActionMask = 2147483647;
290 | files = (
291 | 42F9E659206393A700F8DD4B /* DVFoodPieModel.m in Sources */,
292 | 42F9E6552063931000F8DD4B /* DVPieCenterView.m in Sources */,
293 | 42F9E620206392F400F8DD4B /* ViewController.m in Sources */,
294 | 42F9E6562063931000F8DD4B /* DVPieChart.m in Sources */,
295 | 42F9E62B206392F400F8DD4B /* main.m in Sources */,
296 | 42F9E61D206392F400F8DD4B /* AppDelegate.m in Sources */,
297 | );
298 | runOnlyForDeploymentPostprocessing = 0;
299 | };
300 | 42F9E62C206392F400F8DD4B /* Sources */ = {
301 | isa = PBXSourcesBuildPhase;
302 | buildActionMask = 2147483647;
303 | files = (
304 | 42F9E635206392F400F8DD4B /* DVPieChartTests.m in Sources */,
305 | );
306 | runOnlyForDeploymentPostprocessing = 0;
307 | };
308 | 42F9E637206392F400F8DD4B /* Sources */ = {
309 | isa = PBXSourcesBuildPhase;
310 | buildActionMask = 2147483647;
311 | files = (
312 | 42F9E640206392F400F8DD4B /* DVPieChartUITests.m in Sources */,
313 | );
314 | runOnlyForDeploymentPostprocessing = 0;
315 | };
316 | /* End PBXSourcesBuildPhase section */
317 |
318 | /* Begin PBXTargetDependency section */
319 | 42F9E632206392F400F8DD4B /* PBXTargetDependency */ = {
320 | isa = PBXTargetDependency;
321 | target = 42F9E617206392F400F8DD4B /* DVPieChart */;
322 | targetProxy = 42F9E631206392F400F8DD4B /* PBXContainerItemProxy */;
323 | };
324 | 42F9E63D206392F400F8DD4B /* PBXTargetDependency */ = {
325 | isa = PBXTargetDependency;
326 | target = 42F9E617206392F400F8DD4B /* DVPieChart */;
327 | targetProxy = 42F9E63C206392F400F8DD4B /* PBXContainerItemProxy */;
328 | };
329 | /* End PBXTargetDependency section */
330 |
331 | /* Begin PBXVariantGroup section */
332 | 42F9E621206392F400F8DD4B /* Main.storyboard */ = {
333 | isa = PBXVariantGroup;
334 | children = (
335 | 42F9E622206392F400F8DD4B /* Base */,
336 | );
337 | name = Main.storyboard;
338 | sourceTree = "";
339 | };
340 | 42F9E626206392F400F8DD4B /* LaunchScreen.storyboard */ = {
341 | isa = PBXVariantGroup;
342 | children = (
343 | 42F9E627206392F400F8DD4B /* Base */,
344 | );
345 | name = LaunchScreen.storyboard;
346 | sourceTree = "";
347 | };
348 | /* End PBXVariantGroup section */
349 |
350 | /* Begin XCBuildConfiguration section */
351 | 42F9E642206392F400F8DD4B /* Debug */ = {
352 | isa = XCBuildConfiguration;
353 | buildSettings = {
354 | ALWAYS_SEARCH_USER_PATHS = NO;
355 | CLANG_ANALYZER_NONNULL = YES;
356 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
357 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
358 | CLANG_CXX_LIBRARY = "libc++";
359 | CLANG_ENABLE_MODULES = YES;
360 | CLANG_ENABLE_OBJC_ARC = YES;
361 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
362 | CLANG_WARN_BOOL_CONVERSION = YES;
363 | CLANG_WARN_COMMA = YES;
364 | CLANG_WARN_CONSTANT_CONVERSION = YES;
365 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
366 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
367 | CLANG_WARN_EMPTY_BODY = YES;
368 | CLANG_WARN_ENUM_CONVERSION = YES;
369 | CLANG_WARN_INFINITE_RECURSION = YES;
370 | CLANG_WARN_INT_CONVERSION = YES;
371 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
372 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
373 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
374 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
375 | CLANG_WARN_STRICT_PROTOTYPES = YES;
376 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
377 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
378 | CLANG_WARN_UNREACHABLE_CODE = YES;
379 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
380 | CODE_SIGN_IDENTITY = "iPhone Developer";
381 | COPY_PHASE_STRIP = NO;
382 | DEBUG_INFORMATION_FORMAT = dwarf;
383 | ENABLE_STRICT_OBJC_MSGSEND = YES;
384 | ENABLE_TESTABILITY = YES;
385 | GCC_C_LANGUAGE_STANDARD = gnu11;
386 | GCC_DYNAMIC_NO_PIC = NO;
387 | GCC_NO_COMMON_BLOCKS = YES;
388 | GCC_OPTIMIZATION_LEVEL = 0;
389 | GCC_PREPROCESSOR_DEFINITIONS = (
390 | "DEBUG=1",
391 | "$(inherited)",
392 | );
393 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
394 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
395 | GCC_WARN_UNDECLARED_SELECTOR = YES;
396 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
397 | GCC_WARN_UNUSED_FUNCTION = YES;
398 | GCC_WARN_UNUSED_VARIABLE = YES;
399 | IPHONEOS_DEPLOYMENT_TARGET = 11.2;
400 | MTL_ENABLE_DEBUG_INFO = YES;
401 | ONLY_ACTIVE_ARCH = YES;
402 | SDKROOT = iphoneos;
403 | };
404 | name = Debug;
405 | };
406 | 42F9E643206392F400F8DD4B /* Release */ = {
407 | isa = XCBuildConfiguration;
408 | buildSettings = {
409 | ALWAYS_SEARCH_USER_PATHS = NO;
410 | CLANG_ANALYZER_NONNULL = YES;
411 | CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE;
412 | CLANG_CXX_LANGUAGE_STANDARD = "gnu++14";
413 | CLANG_CXX_LIBRARY = "libc++";
414 | CLANG_ENABLE_MODULES = YES;
415 | CLANG_ENABLE_OBJC_ARC = YES;
416 | CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES;
417 | CLANG_WARN_BOOL_CONVERSION = YES;
418 | CLANG_WARN_COMMA = YES;
419 | CLANG_WARN_CONSTANT_CONVERSION = YES;
420 | CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR;
421 | CLANG_WARN_DOCUMENTATION_COMMENTS = YES;
422 | CLANG_WARN_EMPTY_BODY = YES;
423 | CLANG_WARN_ENUM_CONVERSION = YES;
424 | CLANG_WARN_INFINITE_RECURSION = YES;
425 | CLANG_WARN_INT_CONVERSION = YES;
426 | CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES;
427 | CLANG_WARN_OBJC_LITERAL_CONVERSION = YES;
428 | CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR;
429 | CLANG_WARN_RANGE_LOOP_ANALYSIS = YES;
430 | CLANG_WARN_STRICT_PROTOTYPES = YES;
431 | CLANG_WARN_SUSPICIOUS_MOVE = YES;
432 | CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE;
433 | CLANG_WARN_UNREACHABLE_CODE = YES;
434 | CLANG_WARN__DUPLICATE_METHOD_MATCH = YES;
435 | CODE_SIGN_IDENTITY = "iPhone Developer";
436 | COPY_PHASE_STRIP = NO;
437 | DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
438 | ENABLE_NS_ASSERTIONS = NO;
439 | ENABLE_STRICT_OBJC_MSGSEND = YES;
440 | GCC_C_LANGUAGE_STANDARD = gnu11;
441 | GCC_NO_COMMON_BLOCKS = YES;
442 | GCC_WARN_64_TO_32_BIT_CONVERSION = YES;
443 | GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR;
444 | GCC_WARN_UNDECLARED_SELECTOR = YES;
445 | GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
446 | GCC_WARN_UNUSED_FUNCTION = YES;
447 | GCC_WARN_UNUSED_VARIABLE = YES;
448 | IPHONEOS_DEPLOYMENT_TARGET = 11.2;
449 | MTL_ENABLE_DEBUG_INFO = NO;
450 | SDKROOT = iphoneos;
451 | VALIDATE_PRODUCT = YES;
452 | };
453 | name = Release;
454 | };
455 | 42F9E645206392F400F8DD4B /* Debug */ = {
456 | isa = XCBuildConfiguration;
457 | buildSettings = {
458 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
459 | CODE_SIGN_STYLE = Automatic;
460 | INFOPLIST_FILE = DVPieChart/Info.plist;
461 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
462 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChart;
463 | PRODUCT_NAME = "$(TARGET_NAME)";
464 | TARGETED_DEVICE_FAMILY = "1,2";
465 | };
466 | name = Debug;
467 | };
468 | 42F9E646206392F400F8DD4B /* Release */ = {
469 | isa = XCBuildConfiguration;
470 | buildSettings = {
471 | ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
472 | CODE_SIGN_STYLE = Automatic;
473 | INFOPLIST_FILE = DVPieChart/Info.plist;
474 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks";
475 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChart;
476 | PRODUCT_NAME = "$(TARGET_NAME)";
477 | TARGETED_DEVICE_FAMILY = "1,2";
478 | };
479 | name = Release;
480 | };
481 | 42F9E648206392F400F8DD4B /* Debug */ = {
482 | isa = XCBuildConfiguration;
483 | buildSettings = {
484 | BUNDLE_LOADER = "$(TEST_HOST)";
485 | CODE_SIGN_STYLE = Automatic;
486 | INFOPLIST_FILE = DVPieChartTests/Info.plist;
487 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
488 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChartTests;
489 | PRODUCT_NAME = "$(TARGET_NAME)";
490 | TARGETED_DEVICE_FAMILY = "1,2";
491 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/DVPieChart.app/DVPieChart";
492 | };
493 | name = Debug;
494 | };
495 | 42F9E649206392F400F8DD4B /* Release */ = {
496 | isa = XCBuildConfiguration;
497 | buildSettings = {
498 | BUNDLE_LOADER = "$(TEST_HOST)";
499 | CODE_SIGN_STYLE = Automatic;
500 | INFOPLIST_FILE = DVPieChartTests/Info.plist;
501 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
502 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChartTests;
503 | PRODUCT_NAME = "$(TARGET_NAME)";
504 | TARGETED_DEVICE_FAMILY = "1,2";
505 | TEST_HOST = "$(BUILT_PRODUCTS_DIR)/DVPieChart.app/DVPieChart";
506 | };
507 | name = Release;
508 | };
509 | 42F9E64B206392F400F8DD4B /* Debug */ = {
510 | isa = XCBuildConfiguration;
511 | buildSettings = {
512 | CODE_SIGN_STYLE = Automatic;
513 | INFOPLIST_FILE = DVPieChartUITests/Info.plist;
514 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
515 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChartUITests;
516 | PRODUCT_NAME = "$(TARGET_NAME)";
517 | TARGETED_DEVICE_FAMILY = "1,2";
518 | TEST_TARGET_NAME = DVPieChart;
519 | };
520 | name = Debug;
521 | };
522 | 42F9E64C206392F400F8DD4B /* Release */ = {
523 | isa = XCBuildConfiguration;
524 | buildSettings = {
525 | CODE_SIGN_STYLE = Automatic;
526 | INFOPLIST_FILE = DVPieChartUITests/Info.plist;
527 | LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/Frameworks @loader_path/Frameworks";
528 | PRODUCT_BUNDLE_IDENTIFIER = Sun.DVPieChartUITests;
529 | PRODUCT_NAME = "$(TARGET_NAME)";
530 | TARGETED_DEVICE_FAMILY = "1,2";
531 | TEST_TARGET_NAME = DVPieChart;
532 | };
533 | name = Release;
534 | };
535 | /* End XCBuildConfiguration section */
536 |
537 | /* Begin XCConfigurationList section */
538 | 42F9E613206392F400F8DD4B /* Build configuration list for PBXProject "DVPieChart" */ = {
539 | isa = XCConfigurationList;
540 | buildConfigurations = (
541 | 42F9E642206392F400F8DD4B /* Debug */,
542 | 42F9E643206392F400F8DD4B /* Release */,
543 | );
544 | defaultConfigurationIsVisible = 0;
545 | defaultConfigurationName = Release;
546 | };
547 | 42F9E644206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChart" */ = {
548 | isa = XCConfigurationList;
549 | buildConfigurations = (
550 | 42F9E645206392F400F8DD4B /* Debug */,
551 | 42F9E646206392F400F8DD4B /* Release */,
552 | );
553 | defaultConfigurationIsVisible = 0;
554 | defaultConfigurationName = Release;
555 | };
556 | 42F9E647206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChartTests" */ = {
557 | isa = XCConfigurationList;
558 | buildConfigurations = (
559 | 42F9E648206392F400F8DD4B /* Debug */,
560 | 42F9E649206392F400F8DD4B /* Release */,
561 | );
562 | defaultConfigurationIsVisible = 0;
563 | defaultConfigurationName = Release;
564 | };
565 | 42F9E64A206392F400F8DD4B /* Build configuration list for PBXNativeTarget "DVPieChartUITests" */ = {
566 | isa = XCConfigurationList;
567 | buildConfigurations = (
568 | 42F9E64B206392F400F8DD4B /* Debug */,
569 | 42F9E64C206392F400F8DD4B /* Release */,
570 | );
571 | defaultConfigurationIsVisible = 0;
572 | defaultConfigurationName = Release;
573 | };
574 | /* End XCConfigurationList section */
575 | };
576 | rootObject = 42F9E610206392F400F8DD4B /* Project object */;
577 | }
578 |
--------------------------------------------------------------------------------