diff --git a/Pie Charts/Pie Charts.xcodeproj/project.pbxproj b/Pie Charts/Pie Charts.xcodeproj/project.pbxproj new file mode 100644 index 0000000..3ecdd17 --- /dev/null +++ b/Pie Charts/Pie Charts.xcodeproj/project.pbxproj @@ -0,0 +1,604 @@ +// !$*UTF8*$! +{ + archiveVersion = 1; + classes = { + }; + objectVersion = 56; + objects = { + +/* Begin PBXBuildFile section */ + 9C33E7472AA89025004BBC2E /* PieChartBeta.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C33E7462AA89025004BBC2E /* PieChartBeta.swift */; }; + 9C8A36472AA969C800061420 /* PieChartContentView.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9CA8FF912AA843470039867B /* PieChartContentView.swift */; }; + 9C8A364B2AA96B4200061420 /* PieChartNavigation.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C8A364A2AA96B4200061420 /* PieChartNavigation.swift */; }; + 9C8A364D2AA97AE200061420 /* GenreCalc.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C8A364C2AA97AE200061420 /* GenreCalc.swift */; }; + 9C8A36512AA99A5B00061420 /* GenreDataMod.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C8A36502AA99A5B00061420 /* GenreDataMod.swift */; }; + 9C8A36532AA9B5F600061420 /* 5sTimer.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9C8A36522AA9B5F600061420 /* 5sTimer.swift */; }; + 9CA8FF902AA843470039867B /* Pie_ChartsApp.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9CA8FF8F2AA843470039867B /* Pie_ChartsApp.swift */; }; + 9CA8FF942AA8434A0039867B /* Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 9CA8FF932AA8434A0039867B /* Assets.xcassets */; }; + 9CA8FF972AA8434A0039867B /* Preview Assets.xcassets in Resources */ = {isa = PBXBuildFile; fileRef = 9CA8FF962AA8434A0039867B /* Preview Assets.xcassets */; }; + 9CA8FFA12AA8434A0039867B /* Pie_ChartsTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9CA8FFA02AA8434A0039867B /* Pie_ChartsTests.swift */; }; + 9CA8FFAB2AA8434A0039867B /* Pie_ChartsUITests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9CA8FFAA2AA8434A0039867B /* Pie_ChartsUITests.swift */; }; + 9CA8FFAD2AA8434A0039867B /* Pie_ChartsUITestsLaunchTests.swift in Sources */ = {isa = PBXBuildFile; fileRef = 9CA8FFAC2AA8434A0039867B /* Pie_ChartsUITestsLaunchTests.swift */; }; +/* End PBXBuildFile section */ + +/* Begin PBXContainerItemProxy section */ + 9CA8FF9D2AA8434A0039867B /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 9CA8FF842AA843470039867B /* Project object */; + proxyType = 1; + remoteGlobalIDString = 9CA8FF8B2AA843470039867B; + remoteInfo = "Pie Charts"; + }; + 9CA8FFA72AA8434A0039867B /* PBXContainerItemProxy */ = { + isa = PBXContainerItemProxy; + containerPortal = 9CA8FF842AA843470039867B /* Project object */; + proxyType = 1; + remoteGlobalIDString = 9CA8FF8B2AA843470039867B; + remoteInfo = "Pie Charts"; + }; +/* End PBXContainerItemProxy section */ + +/* Begin PBXFileReference section */ + 9C33E7462AA89025004BBC2E /* PieChartBeta.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PieChartBeta.swift; sourceTree = ""; }; + 9C8A364A2AA96B4200061420 /* PieChartNavigation.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PieChartNavigation.swift; sourceTree = ""; }; + 9C8A364C2AA97AE200061420 /* GenreCalc.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GenreCalc.swift; sourceTree = ""; }; + 9C8A36502AA99A5B00061420 /* GenreDataMod.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = GenreDataMod.swift; sourceTree = ""; }; + 9C8A36522AA9B5F600061420 /* 5sTimer.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = 5sTimer.swift; sourceTree = ""; }; + 9CA8FF8C2AA843470039867B /* Pie Charts.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = "Pie Charts.app"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9CA8FF8F2AA843470039867B /* Pie_ChartsApp.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pie_ChartsApp.swift; sourceTree = ""; }; + 9CA8FF912AA843470039867B /* PieChartContentView.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = PieChartContentView.swift; sourceTree = ""; }; + 9CA8FF932AA8434A0039867B /* Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = Assets.xcassets; sourceTree = ""; }; + 9CA8FF962AA8434A0039867B /* Preview Assets.xcassets */ = {isa = PBXFileReference; lastKnownFileType = folder.assetcatalog; path = "Preview Assets.xcassets"; sourceTree = ""; }; + 9CA8FF9C2AA8434A0039867B /* Pie ChartsTests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Pie ChartsTests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9CA8FFA02AA8434A0039867B /* Pie_ChartsTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pie_ChartsTests.swift; sourceTree = ""; }; + 9CA8FFA62AA8434A0039867B /* Pie ChartsUITests.xctest */ = {isa = PBXFileReference; explicitFileType = wrapper.cfbundle; includeInIndex = 0; path = "Pie ChartsUITests.xctest"; sourceTree = BUILT_PRODUCTS_DIR; }; + 9CA8FFAA2AA8434A0039867B /* Pie_ChartsUITests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pie_ChartsUITests.swift; sourceTree = ""; }; + 9CA8FFAC2AA8434A0039867B /* Pie_ChartsUITestsLaunchTests.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = Pie_ChartsUITestsLaunchTests.swift; sourceTree = ""; }; +/* End PBXFileReference section */ + +/* Begin PBXFrameworksBuildPhase section */ + 9CA8FF892AA843470039867B /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FF992AA8434A0039867B /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FFA32AA8434A0039867B /* Frameworks */ = { + isa = PBXFrameworksBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXFrameworksBuildPhase section */ + +/* Begin PBXGroup section */ + 9CA8FF832AA843470039867B = { + isa = PBXGroup; + children = ( + 9CA8FF8E2AA843470039867B /* Pie Charts */, + 9CA8FF9F2AA8434A0039867B /* Pie ChartsTests */, + 9CA8FFA92AA8434A0039867B /* Pie ChartsUITests */, + 9CA8FF8D2AA843470039867B /* Products */, + ); + sourceTree = ""; + }; + 9CA8FF8D2AA843470039867B /* Products */ = { + isa = PBXGroup; + children = ( + 9CA8FF8C2AA843470039867B /* Pie Charts.app */, + 9CA8FF9C2AA8434A0039867B /* Pie ChartsTests.xctest */, + 9CA8FFA62AA8434A0039867B /* Pie ChartsUITests.xctest */, + ); + name = Products; + sourceTree = ""; + }; + 9CA8FF8E2AA843470039867B /* Pie Charts */ = { + isa = PBXGroup; + children = ( + 9CA8FF8F2AA843470039867B /* Pie_ChartsApp.swift */, + 9CA8FF912AA843470039867B /* PieChartContentView.swift */, + 9C33E7462AA89025004BBC2E /* PieChartBeta.swift */, + 9C8A364A2AA96B4200061420 /* PieChartNavigation.swift */, + 9C8A364C2AA97AE200061420 /* GenreCalc.swift */, + 9C8A36522AA9B5F600061420 /* 5sTimer.swift */, + 9CA8FF932AA8434A0039867B /* Assets.xcassets */, + 9CA8FF952AA8434A0039867B /* Preview Content */, + ); + path = "Pie Charts"; + sourceTree = ""; + }; + 9CA8FF952AA8434A0039867B /* Preview Content */ = { + isa = PBXGroup; + children = ( + 9C8A36502AA99A5B00061420 /* GenreDataMod.swift */, + 9CA8FF962AA8434A0039867B /* Preview Assets.xcassets */, + ); + path = "Preview Content"; + sourceTree = ""; + }; + 9CA8FF9F2AA8434A0039867B /* Pie ChartsTests */ = { + isa = PBXGroup; + children = ( + 9CA8FFA02AA8434A0039867B /* Pie_ChartsTests.swift */, + ); + path = "Pie ChartsTests"; + sourceTree = ""; + }; + 9CA8FFA92AA8434A0039867B /* Pie ChartsUITests */ = { + isa = PBXGroup; + children = ( + 9CA8FFAA2AA8434A0039867B /* Pie_ChartsUITests.swift */, + 9CA8FFAC2AA8434A0039867B /* Pie_ChartsUITestsLaunchTests.swift */, + ); + path = "Pie ChartsUITests"; + sourceTree = ""; + }; +/* End PBXGroup section */ + +/* Begin PBXNativeTarget section */ + 9CA8FF8B2AA843470039867B /* Pie Charts */ = { + isa = PBXNativeTarget; + buildConfigurationList = 9CA8FFB02AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie Charts" */; + buildPhases = ( + 9CA8FF882AA843470039867B /* Sources */, + 9CA8FF892AA843470039867B /* Frameworks */, + 9CA8FF8A2AA843470039867B /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + ); + name = "Pie Charts"; + productName = "Pie Charts"; + productReference = 9CA8FF8C2AA843470039867B /* Pie Charts.app */; + productType = "com.apple.product-type.application"; + }; + 9CA8FF9B2AA8434A0039867B /* Pie ChartsTests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 9CA8FFB32AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie ChartsTests" */; + buildPhases = ( + 9CA8FF982AA8434A0039867B /* Sources */, + 9CA8FF992AA8434A0039867B /* Frameworks */, + 9CA8FF9A2AA8434A0039867B /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 9CA8FF9E2AA8434A0039867B /* PBXTargetDependency */, + ); + name = "Pie ChartsTests"; + productName = "Pie ChartsTests"; + productReference = 9CA8FF9C2AA8434A0039867B /* Pie ChartsTests.xctest */; + productType = "com.apple.product-type.bundle.unit-test"; + }; + 9CA8FFA52AA8434A0039867B /* Pie ChartsUITests */ = { + isa = PBXNativeTarget; + buildConfigurationList = 9CA8FFB62AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie ChartsUITests" */; + buildPhases = ( + 9CA8FFA22AA8434A0039867B /* Sources */, + 9CA8FFA32AA8434A0039867B /* Frameworks */, + 9CA8FFA42AA8434A0039867B /* Resources */, + ); + buildRules = ( + ); + dependencies = ( + 9CA8FFA82AA8434A0039867B /* PBXTargetDependency */, + ); + name = "Pie ChartsUITests"; + productName = "Pie ChartsUITests"; + productReference = 9CA8FFA62AA8434A0039867B /* Pie ChartsUITests.xctest */; + productType = "com.apple.product-type.bundle.ui-testing"; + }; +/* End PBXNativeTarget section */ + +/* Begin PBXProject section */ + 9CA8FF842AA843470039867B /* Project object */ = { + isa = PBXProject; + attributes = { + BuildIndependentTargetsInParallel = 1; + LastSwiftUpdateCheck = 1430; + LastUpgradeCheck = 1500; + TargetAttributes = { + 9CA8FF8B2AA843470039867B = { + CreatedOnToolsVersion = 14.3.1; + }; + 9CA8FF9B2AA8434A0039867B = { + CreatedOnToolsVersion = 14.3.1; + TestTargetID = 9CA8FF8B2AA843470039867B; + }; + 9CA8FFA52AA8434A0039867B = { + CreatedOnToolsVersion = 14.3.1; + TestTargetID = 9CA8FF8B2AA843470039867B; + }; + }; + }; + buildConfigurationList = 9CA8FF872AA843470039867B /* Build configuration list for PBXProject "Pie Charts" */; + compatibilityVersion = "Xcode 14.0"; + developmentRegion = en; + hasScannedForEncodings = 0; + knownRegions = ( + en, + Base, + ); + mainGroup = 9CA8FF832AA843470039867B; + productRefGroup = 9CA8FF8D2AA843470039867B /* Products */; + projectDirPath = ""; + projectRoot = ""; + targets = ( + 9CA8FF8B2AA843470039867B /* Pie Charts */, + 9CA8FF9B2AA8434A0039867B /* Pie ChartsTests */, + 9CA8FFA52AA8434A0039867B /* Pie ChartsUITests */, + ); + }; +/* End PBXProject section */ + +/* Begin PBXResourcesBuildPhase section */ + 9CA8FF8A2AA843470039867B /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 9CA8FF972AA8434A0039867B /* Preview Assets.xcassets in Resources */, + 9CA8FF942AA8434A0039867B /* Assets.xcassets in Resources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FF9A2AA8434A0039867B /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FFA42AA8434A0039867B /* Resources */ = { + isa = PBXResourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXResourcesBuildPhase section */ + +/* Begin PBXSourcesBuildPhase section */ + 9CA8FF882AA843470039867B /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 9CA8FF902AA843470039867B /* Pie_ChartsApp.swift in Sources */, + 9C8A36532AA9B5F600061420 /* 5sTimer.swift in Sources */, + 9C8A364D2AA97AE200061420 /* GenreCalc.swift in Sources */, + 9C33E7472AA89025004BBC2E /* PieChartBeta.swift in Sources */, + 9C8A36472AA969C800061420 /* PieChartContentView.swift in Sources */, + 9C8A364B2AA96B4200061420 /* PieChartNavigation.swift in Sources */, + 9C8A36512AA99A5B00061420 /* GenreDataMod.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FF982AA8434A0039867B /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 9CA8FFA12AA8434A0039867B /* Pie_ChartsTests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; + 9CA8FFA22AA8434A0039867B /* Sources */ = { + isa = PBXSourcesBuildPhase; + buildActionMask = 2147483647; + files = ( + 9CA8FFAD2AA8434A0039867B /* Pie_ChartsUITestsLaunchTests.swift in Sources */, + 9CA8FFAB2AA8434A0039867B /* Pie_ChartsUITests.swift in Sources */, + ); + runOnlyForDeploymentPostprocessing = 0; + }; +/* End PBXSourcesBuildPhase section */ + +/* Begin PBXTargetDependency section */ + 9CA8FF9E2AA8434A0039867B /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 9CA8FF8B2AA843470039867B /* Pie Charts */; + targetProxy = 9CA8FF9D2AA8434A0039867B /* PBXContainerItemProxy */; + }; + 9CA8FFA82AA8434A0039867B /* PBXTargetDependency */ = { + isa = PBXTargetDependency; + target = 9CA8FF8B2AA843470039867B /* Pie Charts */; + targetProxy = 9CA8FFA72AA8434A0039867B /* PBXContainerItemProxy */; + }; +/* End PBXTargetDependency section */ + +/* Begin XCBuildConfiguration section */ + 9CA8FFAE2AA8434A0039867B /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = dwarf; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_TESTABILITY = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_DYNAMIC_NO_PIC = NO; + GCC_NO_COMMON_BLOCKS = YES; + GCC_OPTIMIZATION_LEVEL = 0; + GCC_PREPROCESSOR_DEFINITIONS = ( + "DEBUG=1", + "$(inherited)", + ); + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; + MTL_ENABLE_DEBUG_INFO = INCLUDE_SOURCE; + MTL_FAST_MATH = YES; + ONLY_ACTIVE_ARCH = YES; + SDKROOT = iphoneos; + SWIFT_ACTIVE_COMPILATION_CONDITIONS = DEBUG; + SWIFT_OPTIMIZATION_LEVEL = "-Onone"; + }; + name = Debug; + }; + 9CA8FFAF2AA8434A0039867B /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_SEARCH_USER_PATHS = NO; + CLANG_ANALYZER_NONNULL = YES; + CLANG_ANALYZER_NUMBER_OBJECT_CONVERSION = YES_AGGRESSIVE; + CLANG_CXX_LANGUAGE_STANDARD = "gnu++20"; + CLANG_ENABLE_MODULES = YES; + CLANG_ENABLE_OBJC_ARC = YES; + CLANG_ENABLE_OBJC_WEAK = YES; + CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING = YES; + CLANG_WARN_BOOL_CONVERSION = YES; + CLANG_WARN_COMMA = YES; + CLANG_WARN_CONSTANT_CONVERSION = YES; + CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS = YES; + CLANG_WARN_DIRECT_OBJC_ISA_USAGE = YES_ERROR; + CLANG_WARN_DOCUMENTATION_COMMENTS = YES; + CLANG_WARN_EMPTY_BODY = YES; + CLANG_WARN_ENUM_CONVERSION = YES; + CLANG_WARN_INFINITE_RECURSION = YES; + CLANG_WARN_INT_CONVERSION = YES; + CLANG_WARN_NON_LITERAL_NULL_CONVERSION = YES; + CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF = YES; + CLANG_WARN_OBJC_LITERAL_CONVERSION = YES; + CLANG_WARN_OBJC_ROOT_CLASS = YES_ERROR; + CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES; + CLANG_WARN_RANGE_LOOP_ANALYSIS = YES; + CLANG_WARN_STRICT_PROTOTYPES = YES; + CLANG_WARN_SUSPICIOUS_MOVE = YES; + CLANG_WARN_UNGUARDED_AVAILABILITY = YES_AGGRESSIVE; + CLANG_WARN_UNREACHABLE_CODE = YES; + CLANG_WARN__DUPLICATE_METHOD_MATCH = YES; + COPY_PHASE_STRIP = NO; + DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym"; + ENABLE_NS_ASSERTIONS = NO; + ENABLE_STRICT_OBJC_MSGSEND = YES; + ENABLE_USER_SCRIPT_SANDBOXING = YES; + GCC_C_LANGUAGE_STANDARD = gnu11; + GCC_NO_COMMON_BLOCKS = YES; + GCC_WARN_64_TO_32_BIT_CONVERSION = YES; + GCC_WARN_ABOUT_RETURN_TYPE = YES_ERROR; + GCC_WARN_UNDECLARED_SELECTOR = YES; + GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE; + GCC_WARN_UNUSED_FUNCTION = YES; + GCC_WARN_UNUSED_VARIABLE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 17.0; + MTL_ENABLE_DEBUG_INFO = NO; + MTL_FAST_MATH = YES; + SDKROOT = iphoneos; + SWIFT_COMPILATION_MODE = wholemodule; + SWIFT_OPTIMIZATION_LEVEL = "-O"; + VALIDATE_PRODUCT = YES; + }; + name = Release; + }; + 9CA8FFB12AA8434A0039867B /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"Pie Charts/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-Charts"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Debug; + }; + 9CA8FFB22AA8434A0039867B /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon; + ASSETCATALOG_COMPILER_GLOBAL_ACCENT_COLOR_NAME = AccentColor; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + DEVELOPMENT_ASSET_PATHS = "\"Pie Charts/Preview Content\""; + ENABLE_PREVIEWS = YES; + GENERATE_INFOPLIST_FILE = YES; + INFOPLIST_KEY_UIApplicationSceneManifest_Generation = YES; + INFOPLIST_KEY_UIApplicationSupportsIndirectInputEvents = YES; + INFOPLIST_KEY_UILaunchScreen_Generation = YES; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPad = "UIInterfaceOrientationPortrait UIInterfaceOrientationPortraitUpsideDown UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + INFOPLIST_KEY_UISupportedInterfaceOrientations_iPhone = "UIInterfaceOrientationPortrait UIInterfaceOrientationLandscapeLeft UIInterfaceOrientationLandscapeRight"; + LD_RUNPATH_SEARCH_PATHS = ( + "$(inherited)", + "@executable_path/Frameworks", + ); + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-Charts"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = YES; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + }; + name = Release; + }; + 9CA8FFB42AA8434A0039867B /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-ChartsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Pie Charts.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Pie Charts"; + }; + name = Debug; + }; + 9CA8FFB52AA8434A0039867B /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + BUNDLE_LOADER = "$(TEST_HOST)"; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + IPHONEOS_DEPLOYMENT_TARGET = 16.4; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-ChartsTests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_HOST = "$(BUILT_PRODUCTS_DIR)/Pie Charts.app/$(BUNDLE_EXECUTABLE_FOLDER_PATH)/Pie Charts"; + }; + name = Release; + }; + 9CA8FFB72AA8434A0039867B /* Debug */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-ChartsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = "Pie Charts"; + }; + name = Debug; + }; + 9CA8FFB82AA8434A0039867B /* Release */ = { + isa = XCBuildConfiguration; + buildSettings = { + ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES; + CODE_SIGN_STYLE = Automatic; + CURRENT_PROJECT_VERSION = 1; + GENERATE_INFOPLIST_FILE = YES; + MARKETING_VERSION = 1.0; + PRODUCT_BUNDLE_IDENTIFIER = "com.example.Pie-ChartsUITests"; + PRODUCT_NAME = "$(TARGET_NAME)"; + SWIFT_EMIT_LOC_STRINGS = NO; + SWIFT_VERSION = 5.0; + TARGETED_DEVICE_FAMILY = "1,2"; + TEST_TARGET_NAME = "Pie Charts"; + }; + name = Release; + }; +/* End XCBuildConfiguration section */ + +/* Begin XCConfigurationList section */ + 9CA8FF872AA843470039867B /* Build configuration list for PBXProject "Pie Charts" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 9CA8FFAE2AA8434A0039867B /* Debug */, + 9CA8FFAF2AA8434A0039867B /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 9CA8FFB02AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie Charts" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 9CA8FFB12AA8434A0039867B /* Debug */, + 9CA8FFB22AA8434A0039867B /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 9CA8FFB32AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie ChartsTests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 9CA8FFB42AA8434A0039867B /* Debug */, + 9CA8FFB52AA8434A0039867B /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; + 9CA8FFB62AA8434A0039867B /* Build configuration list for PBXNativeTarget "Pie ChartsUITests" */ = { + isa = XCConfigurationList; + buildConfigurations = ( + 9CA8FFB72AA8434A0039867B /* Debug */, + 9CA8FFB82AA8434A0039867B /* Release */, + ); + defaultConfigurationIsVisible = 0; + defaultConfigurationName = Release; + }; +/* End XCConfigurationList section */ + }; + rootObject = 9CA8FF842AA843470039867B /* Project object */; +} diff --git a/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/contents.xcworkspacedata b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/contents.xcworkspacedata new file mode 100644 index 0000000..919434a --- /dev/null +++ b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/contents.xcworkspacedata @@ -0,0 +1,7 @@ + + + + + diff --git a/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist new file mode 100644 index 0000000..18d9810 --- /dev/null +++ b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist @@ -0,0 +1,8 @@ + + + + + IDEDidComputeMac32BitWarning + + + diff --git a/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcuserdata/i3lt-040.xcuserdatad/UserInterfaceState.xcuserstate b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcuserdata/i3lt-040.xcuserdatad/UserInterfaceState.xcuserstate new file mode 100644 index 0000000..7087222 Binary files /dev/null and b/Pie Charts/Pie Charts.xcodeproj/project.xcworkspace/xcuserdata/i3lt-040.xcuserdatad/UserInterfaceState.xcuserstate differ diff --git a/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist b/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist new file mode 100644 index 0000000..da4a721 --- /dev/null +++ b/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist @@ -0,0 +1,24 @@ + + + + + + + + + diff --git a/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcschemes/xcschememanagement.plist b/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcschemes/xcschememanagement.plist new file mode 100644 index 0000000..8cb8033 --- /dev/null +++ b/Pie Charts/Pie Charts.xcodeproj/xcuserdata/i3lt-040.xcuserdatad/xcschemes/xcschememanagement.plist @@ -0,0 +1,14 @@ + + + + + SchemeUserState + + Pie Charts.xcscheme_^#shared#^_ + + orderHint + 0 + + + + diff --git a/Pie Charts/Pie Charts/5sTimer.swift b/Pie Charts/Pie Charts/5sTimer.swift new file mode 100644 index 0000000..ee8cff7 --- /dev/null +++ b/Pie Charts/Pie Charts/5sTimer.swift @@ -0,0 +1,29 @@ +import Foundation + +class TimerExample { + var timer: Timer? + + init() { + startTimer() + } + + func startTimer() { + timer = Timer.scheduledTimer(withTimeInterval: 5.0, repeats: false) { timer in + // This closure will be executed after 5 seconds + print("Timer fired after 5 seconds!") + + // You can perform any action you want here + + // Don't forget to invalidate the timer to release resources + timer.invalidate() + } + } + + // Make sure to invalidate the timer when it's no longer needed + deinit { + timer?.invalidate() + } +} + +// Create an instance of TimerExample +let example = TimerExample() diff --git a/Pie Charts/Pie Charts/Assets.xcassets/AccentColor.colorset/Contents.json b/Pie Charts/Pie Charts/Assets.xcassets/AccentColor.colorset/Contents.json new file mode 100644 index 0000000..eb87897 --- /dev/null +++ b/Pie Charts/Pie Charts/Assets.xcassets/AccentColor.colorset/Contents.json @@ -0,0 +1,11 @@ +{ + "colors" : [ + { + "idiom" : "universal" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie Charts/Assets.xcassets/AppIcon.appiconset/Contents.json b/Pie Charts/Pie Charts/Assets.xcassets/AppIcon.appiconset/Contents.json new file mode 100644 index 0000000..13613e3 --- /dev/null +++ b/Pie Charts/Pie Charts/Assets.xcassets/AppIcon.appiconset/Contents.json @@ -0,0 +1,13 @@ +{ + "images" : [ + { + "idiom" : "universal", + "platform" : "ios", + "size" : "1024x1024" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/Contents.json b/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/Contents.json new file mode 100644 index 0000000..d3701b9 --- /dev/null +++ b/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "The_Weeknd_-_After_Hours.png", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/The_Weeknd_-_After_Hours.png b/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/The_Weeknd_-_After_Hours.png new file mode 100644 index 0000000..b8366ee Binary files /dev/null and b/Pie Charts/Pie Charts/Assets.xcassets/CirclePicture.imageset/The_Weeknd_-_After_Hours.png differ diff --git a/Pie Charts/Pie Charts/Assets.xcassets/Contents.json b/Pie Charts/Pie Charts/Assets.xcassets/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/Pie Charts/Pie Charts/Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/Contents.json b/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/Contents.json new file mode 100644 index 0000000..f83f2c1 --- /dev/null +++ b/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/Contents.json @@ -0,0 +1,21 @@ +{ + "images" : [ + { + "filename" : "test.jpg", + "idiom" : "universal", + "scale" : "1x" + }, + { + "idiom" : "universal", + "scale" : "2x" + }, + { + "idiom" : "universal", + "scale" : "3x" + } + ], + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/test.jpg b/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/test.jpg new file mode 100644 index 0000000..d67475d Binary files /dev/null and b/Pie Charts/Pie Charts/Assets.xcassets/Testimage.imageset/test.jpg differ diff --git a/Pie Charts/Pie Charts/GenreCalc.swift b/Pie Charts/Pie Charts/GenreCalc.swift new file mode 100644 index 0000000..8f0f953 --- /dev/null +++ b/Pie Charts/Pie Charts/GenreCalc.swift @@ -0,0 +1,57 @@ +import SwiftUI + +struct GenreDataMod: View { + var body: some View { + let data = [ + Genre(name: "Pop", count: 6, color: Color(.green)), + Genre(name: "Rock", count: 2, color: Color(.yellow)), + Genre(name: "Indie", count: 3, color: Color(.orange)), + Genre(name: "Jazz", count: 4, color: Color(.red)), + Genre(name: "Hip-Hop", count: 5, color: Color(.purple)), + Genre(name: "R&B", count: 7, color: Color(.blue)) + ] + GenreCalc(data:data) + } +} +struct Genre { + var name: String + var count: Int + var color: Color +} + +struct GenreCalc: View { + @State var data:Array=[] + + var body: some View { + ZStack{ + Circle() + .foregroundColor(.white) + VStack(alignment: .leading) { + let data = data.sorted { + $0.count > $1.count + } + + ForEach(data, id: \.name) { item in + HStack { + Image(systemName: "circle.fill") + .foregroundStyle(item.color) + Text("\(item.name)").bold() + .foregroundColor(.black) + Spacer() + Text("\(item.count)%") + } + } + } + .padding(.horizontal, 40) + } + .frame(width: 234, height: 234) + } +} +struct GenreCalc_Previews: PreviewProvider { + static var previews: some View { + GenreDataMod() + } +} +//#Preview { +// GenreDataMod() +//} diff --git a/Pie Charts/Pie Charts/PieChartBeta.swift b/Pie Charts/Pie Charts/PieChartBeta.swift new file mode 100644 index 0000000..fc2759f --- /dev/null +++ b/Pie Charts/Pie Charts/PieChartBeta.swift @@ -0,0 +1,125 @@ +//// +//// PieChartBeta.swift +//// Pie Charts +//// +//// Created by I3LT-040 on 6/9/23. +//// +// +//import SwiftUI +//import Charts +// + +// +// +// +//#Preview { +// PieChartBeta() +//} + + +import SwiftUI +import Charts + + + +@available(macOS 14.0, *) + +struct PlottableValue: Identifiable { + var id = UUID() + var name: String + var value: Double + var color: Color +} + +struct PieChartExampleView: View { + let colors: [Color] = [.gray, .red, .orange, .yellow, + .green, .blue, .purple, .pink] + + + @State private var fgColor: Color = .gray + @State private var imageString: String = "CirclePicture" + + @State private var counter:Int=0 + + let data = [ + (name: "Pop", count: 70, color: Color(.green)), + (name: "Rock", count: 2, color: Color(.yellow)), + (name: "Indie", count: 3, color: Color(.orange)), + (name: "Jazz", count: 4, color: Color(.red)), + (name: "Hip-Hop", count: 5, color: Color(.purple)), + (name: "R&B", count: 7, color: Color(.blue)), + ] + var body: some View { + VStack{ + Text("Steve Jobs") + .font( + .title2 + ) + .bold()// FOR CHANGING NAME + + ZStack{ + Chart(data, id: \.name) { name, count, color in + SectorMark(angle: .value("Value", count), + innerRadius: .ratio(0.8), + angularInset: 1.5) + .cornerRadius(5) + .foregroundStyle(color) + } + +// .foregroundStyle( // Gradient shading +// LinearGradient( +// colors: [ .orange,.yellow], +// startPoint: .leading, +// endPoint: .trailing +// ) +// ) + .frame(height: 300) + + GenreDataMod() + + Image(imageString) // Replace with your image asset name + .resizable() + .frame(width: 234, height: 234) + .clipShape(Circle()) + .overlay(Circle().stroke(Color.white, lineWidth: 0)) + .foregroundColor(fgColor) + .contentShape(Circle()) // Set the content shape to Circle + .onTapGesture(count: 1) { +// fgColor = colors.randomElement()! + if counter==0{ + imageString = "" + counter+=1 + }else{ + imageString = "CirclePicture" + counter-=1 + + } + + + + } + } + Spacer() +// Image(systemName: "pencil.circle.fill") +// .resizable() +// .frame(width: 200, height: 200) +// .foregroundColor(fgColor) +// .contentShape(Circle()) // Set the content shape to Circle +// .onTapGesture(count: 1) { +// fgColor = colors.randomElement()! +// } + } + } +} + +@available(macOS 14.0, *) +#Preview { + PieChartExampleView() +} + + +struct ContentView_Previews: PreviewProvider { + static var previews: some View { + PieChartExampleView() + } +} diff --git a/Pie Charts/Pie Charts/PieChartContentView.swift b/Pie Charts/Pie Charts/PieChartContentView.swift new file mode 100644 index 0000000..094a772 --- /dev/null +++ b/Pie Charts/Pie Charts/PieChartContentView.swift @@ -0,0 +1,26 @@ +// +// ContentView.swift +// Pie Charts +// +// Created by I3LT-040 on 6/9/23. +// + +import SwiftUI + + +struct ContentView: View { + + var body: some View { + ZStack { + Text("test") + } + } +} + + + +//struct ContentView_Previews: PreviewProvider { +// static var previews: some View { +// ContentView() +// } +//} diff --git a/Pie Charts/Pie Charts/PieChartNavigation.swift b/Pie Charts/Pie Charts/PieChartNavigation.swift new file mode 100644 index 0000000..8c7e79c --- /dev/null +++ b/Pie Charts/Pie Charts/PieChartNavigation.swift @@ -0,0 +1,32 @@ +// +// PieChartNavigation.swift +// Pie Charts +// +// Created by I3LT-040 on 7/9/23. +// + +import SwiftUI + + +//let circleView = UIView(frame: CGRect(x: 0, y: 0, width: 100, height: 100)) +//circleView.layer.cornerRadius = circleView.frame.size.width/2 +//circleView.clipsToBounds = true +// +// +//override func touchesBegan(_ touches: Set, with event: UIEvent?) { +// UIView.animate(withDuration: 0.3) { +// self.circleView.transform = CGAffineTransform(scaleX: 1.3, y: 1.3) +// } +//} +// +//override func touchesEnded(_ touches: Set, with event: UIEvent?) { +// UIView.animate(withDuration: 0.3) { +// self.circleView.transform = CGAffineTransform.identity +// } +//} +// +//override func touchesCancelled(_ touches: Set, with event: UIEvent?) { +// UIView.animate(withDuration: 0.3) { +// self.circleView.transform = CGAffineTransform.identity +// } +//} diff --git a/Pie Charts/Pie Charts/Pie_ChartsApp.swift b/Pie Charts/Pie Charts/Pie_ChartsApp.swift new file mode 100644 index 0000000..174c0c9 --- /dev/null +++ b/Pie Charts/Pie Charts/Pie_ChartsApp.swift @@ -0,0 +1,17 @@ +// +// Pie_ChartsApp.swift +// Pie Charts +// +// Created by I3LT-040 on 6/9/23. +// + +import SwiftUI + +@main +struct Pie_ChartsApp: App { + var body: some Scene { + WindowGroup { + ContentView() + } + } +} diff --git a/Pie Charts/Pie Charts/Preview Content/GenreDataMod.swift b/Pie Charts/Pie Charts/Preview Content/GenreDataMod.swift new file mode 100644 index 0000000..550aa1e --- /dev/null +++ b/Pie Charts/Pie Charts/Preview Content/GenreDataMod.swift @@ -0,0 +1,32 @@ +// +// GenreDataMod.swift +// Pie Charts +// +// Created by I3LT-040 on 7/9/23. +// +// +//import SwiftUI +// +//struct GenreDataMod: View { +// +// +// var body: some View { +// +// +// let data = [ +// Genre(name: "Pop", count: 100, color: Color(red: 0.8, green: 0.5, blue: 0)), +// Genre(name: "Rock", count: 2, color: Color(red: 0.7, green: 0.4, blue: 0)), +// Genre(name: "Indie", count: 3, color: Color(red: 0.6, green: 0.3, blue: 0)), +// Genre(name: "Jazz", count: 4, color: Color(red: 0.5, green: 0.2, blue: 0)), +// Genre(name: "Hip-Hop", count: 5, color: Color(red: 0.4, green: 0.1, blue: 0)), +// Genre(name: "R&B", count: 7, color: Color(red: 0.3, green: 0, blue: 0)) +// ] +// +// GenreCalc(data:data) +// +// } +//} +// +//#Preview { +// GenreDataMod() +//} diff --git a/Pie Charts/Pie Charts/Preview Content/Preview Assets.xcassets/Contents.json b/Pie Charts/Pie Charts/Preview Content/Preview Assets.xcassets/Contents.json new file mode 100644 index 0000000..73c0059 --- /dev/null +++ b/Pie Charts/Pie Charts/Preview Content/Preview Assets.xcassets/Contents.json @@ -0,0 +1,6 @@ +{ + "info" : { + "author" : "xcode", + "version" : 1 + } +} diff --git a/Pie Charts/Pie ChartsTests/Pie_ChartsTests.swift b/Pie Charts/Pie ChartsTests/Pie_ChartsTests.swift new file mode 100644 index 0000000..de0b376 --- /dev/null +++ b/Pie Charts/Pie ChartsTests/Pie_ChartsTests.swift @@ -0,0 +1,36 @@ +// +// Pie_ChartsTests.swift +// Pie ChartsTests +// +// Created by I3LT-040 on 6/9/23. +// + +import XCTest +@testable import Pie_Charts + +final class Pie_ChartsTests: XCTestCase { + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + } + + func testExample() throws { + // This is an example of a functional test case. + // Use XCTAssert and related functions to verify your tests produce the correct results. + // Any test you write for XCTest can be annotated as throws and async. + // Mark your test throws to produce an unexpected failure when your test encounters an uncaught error. + // Mark your test async to allow awaiting for asynchronous code to complete. Check the results with assertions afterwards. + } + + func testPerformanceExample() throws { + // This is an example of a performance test case. + self.measure { + // Put the code you want to measure the time of here. + } + } + +} diff --git a/Pie Charts/Pie ChartsUITests/Pie_ChartsUITests.swift b/Pie Charts/Pie ChartsUITests/Pie_ChartsUITests.swift new file mode 100644 index 0000000..58e1722 --- /dev/null +++ b/Pie Charts/Pie ChartsUITests/Pie_ChartsUITests.swift @@ -0,0 +1,41 @@ +// +// Pie_ChartsUITests.swift +// Pie ChartsUITests +// +// Created by I3LT-040 on 6/9/23. +// + +import XCTest + +final class Pie_ChartsUITests: XCTestCase { + + override func setUpWithError() throws { + // Put setup code here. This method is called before the invocation of each test method in the class. + + // In UI tests it is usually best to stop immediately when a failure occurs. + continueAfterFailure = false + + // 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. + } + + override func tearDownWithError() throws { + // Put teardown code here. This method is called after the invocation of each test method in the class. + } + + func testExample() throws { + // UI tests must launch the application that they test. + let app = XCUIApplication() + app.launch() + + // Use XCTAssert and related functions to verify your tests produce the correct results. + } + + func testLaunchPerformance() throws { + if #available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 7.0, *) { + // This measures how long it takes to launch your application. + measure(metrics: [XCTApplicationLaunchMetric()]) { + XCUIApplication().launch() + } + } + } +} diff --git a/Pie Charts/Pie ChartsUITests/Pie_ChartsUITestsLaunchTests.swift b/Pie Charts/Pie ChartsUITests/Pie_ChartsUITestsLaunchTests.swift new file mode 100644 index 0000000..41f02f5 --- /dev/null +++ b/Pie Charts/Pie ChartsUITests/Pie_ChartsUITestsLaunchTests.swift @@ -0,0 +1,32 @@ +// +// Pie_ChartsUITestsLaunchTests.swift +// Pie ChartsUITests +// +// Created by I3LT-040 on 6/9/23. +// + +import XCTest + +final class Pie_ChartsUITestsLaunchTests: XCTestCase { + + override class var runsForEachTargetApplicationUIConfiguration: Bool { + true + } + + override func setUpWithError() throws { + continueAfterFailure = false + } + + func testLaunch() throws { + let app = XCUIApplication() + app.launch() + + // Insert steps here to perform after app launch but before taking a screenshot, + // such as logging into a test account or navigating somewhere in the app + + let attachment = XCTAttachment(screenshot: app.screenshot()) + attachment.name = "Launch Screen" + attachment.lifetime = .keepAlways + add(attachment) + } +}