Skip to content

Commit

Permalink
修正一些提示,添加gif使用动画
Browse files Browse the repository at this point in the history
  • Loading branch information
tanpengsccd committed May 10, 2019
1 parent 4740ee5 commit 76b8c33
Show file tree
Hide file tree
Showing 8 changed files with 152 additions and 44 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
# TPJSONFormatter
A Mac App for [HandyJSON](https://github.com/alibaba/HandyJSON)
#How to use?
![image](https://github.com/tanpengsccd/TPJSONFormatter/blob/master/UseWay.gif)



4 changes: 2 additions & 2 deletions TPJSONFormatter.xcodeproj/project.pbxproj
Original file line number Diff line number Diff line change
Expand Up @@ -519,7 +519,7 @@
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_TEAM = S88X462LQ7;
DEVELOPMENT_TEAM = 69NY7TFEUP;
INFOPLIST_FILE = TPJSONFormatterUITests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.tanpengcd.TPJSONFormatterUITests;
Expand All @@ -535,7 +535,7 @@
ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES = YES;
CODE_SIGN_STYLE = Automatic;
COMBINE_HIDPI_IMAGES = YES;
DEVELOPMENT_TEAM = S88X462LQ7;
DEVELOPMENT_TEAM = 69NY7TFEUP;
INFOPLIST_FILE = TPJSONFormatterUITests/Info.plist;
LD_RUNPATH_SEARCH_PATHS = "$(inherited) @executable_path/../Frameworks @loader_path/../Frameworks";
PRODUCT_BUNDLE_IDENTIFIER = com.tanpengcd.TPJSONFormatterUITests;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,111 @@
<?xml version="1.0" encoding="UTF-8"?>
<Scheme
LastUpgradeVersion = "1020"
version = "1.3">
<BuildAction
parallelizeBuildables = "YES"
buildImplicitDependencies = "YES">
<BuildActionEntries>
<BuildActionEntry
buildForTesting = "YES"
buildForRunning = "YES"
buildForProfiling = "YES"
buildForArchiving = "YES"
buildForAnalyzing = "YES">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97AE72027246100B2D13A"
BuildableName = "TPJSONFormatter.app"
BlueprintName = "TPJSONFormatter"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</BuildActionEntry>
</BuildActionEntries>
</BuildAction>
<TestAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
shouldUseLaunchSchemeArgsEnv = "YES">
<Testables>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97AF92027246100B2D13A"
BuildableName = "TPJSONFormatterTests.xctest"
BlueprintName = "TPJSONFormatterTests"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</TestableReference>
<TestableReference
skipped = "NO">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97B042027246100B2D13A"
BuildableName = "TPJSONFormatterUITests.xctest"
BlueprintName = "TPJSONFormatterUITests"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</TestableReference>
</Testables>
<MacroExpansion>
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97AE72027246100B2D13A"
BuildableName = "TPJSONFormatter.app"
BlueprintName = "TPJSONFormatter"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</MacroExpansion>
<AdditionalOptions>
</AdditionalOptions>
</TestAction>
<LaunchAction
buildConfiguration = "Debug"
selectedDebuggerIdentifier = "Xcode.DebuggerFoundation.Debugger.LLDB"
selectedLauncherIdentifier = "Xcode.DebuggerFoundation.Launcher.LLDB"
launchStyle = "0"
useCustomWorkingDirectory = "NO"
ignoresPersistentStateOnLaunch = "NO"
debugDocumentVersioning = "YES"
debugServiceExtension = "internal"
allowLocationSimulation = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97AE72027246100B2D13A"
BuildableName = "TPJSONFormatter.app"
BlueprintName = "TPJSONFormatter"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
<AdditionalOptions>
</AdditionalOptions>
</LaunchAction>
<ProfileAction
buildConfiguration = "Release"
shouldUseLaunchSchemeArgsEnv = "YES"
savedToolIdentifier = ""
useCustomWorkingDirectory = "NO"
debugDocumentVersioning = "YES">
<BuildableProductRunnable
runnableDebuggingMode = "0">
<BuildableReference
BuildableIdentifier = "primary"
BlueprintIdentifier = "7BD97AE72027246100B2D13A"
BuildableName = "TPJSONFormatter.app"
BlueprintName = "TPJSONFormatter"
ReferencedContainer = "container:TPJSONFormatter.xcodeproj">
</BuildableReference>
</BuildableProductRunnable>
</ProfileAction>
<AnalyzeAction
buildConfiguration = "Debug">
</AnalyzeAction>
<ArchiveAction
buildConfiguration = "Release"
revealArchiveInOrganizer = "YES">
</ArchiveAction>
</Scheme>
44 changes: 3 additions & 41 deletions TPJSONFormatter/Base.lproj/Main.storyboard
Original file line number Diff line number Diff line change
Expand Up @@ -723,44 +723,6 @@
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
<size key="minSize" width="528" height="546"/>
<size key="maxSize" width="1040" height="10000000"/>
<attributedString key="textStorage">
<fragment>
<string key="content">{
"object": {
"string": "string",
"double": 22.22,
"int": 20,
"boolean": true,
"sdouble": "22.22",
"sint": "20",
"sboolean": "true",
"object": {
"nullArray":[],
"array": [
{
"stringA":"string"
},
{
"stringB":"string",
"stringC":"string"
}
],
"nestArray": [["String"]]
}
}
}
</string>
<attributes>
<color key="NSColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
<font key="NSFont" size="12" name="Courier"/>
<real key="NSKern" value="0.0"/>
<paragraphStyle key="NSParagraphStyle" alignment="left" lineBreakMode="wordWrapping" baseWritingDirection="leftToRight" minimumLineHeight="14" defaultTabInterval="36" tighteningFactorForTruncation="0.0" allowsDefaultTighteningForTruncation="NO">
<tabStops/>
</paragraphStyle>
<color key="NSStrokeColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
</attributes>
</fragment>
</attributedString>
<color key="insertionPointColor" name="textColor" catalog="System" colorSpace="catalog"/>
</textView>
</subviews>
Expand All @@ -786,7 +748,7 @@
<color key="textColor" name="textColor" catalog="System" colorSpace="catalog"/>
<color key="backgroundColor" name="textBackgroundColor" catalog="System" colorSpace="catalog"/>
<size key="minSize" width="525" height="546"/>
<size key="maxSize" width="525" height="10000000"/>
<size key="maxSize" width="527" height="10000000"/>
<color key="insertionPointColor" name="textColor" catalog="System" colorSpace="catalog"/>
</textView>
</subviews>
Expand Down Expand Up @@ -814,8 +776,8 @@
</connections>
</button>
<button verticalHuggingPriority="750" translatesAutoresizingMaskIntoConstraints="NO" id="NbU-sY-1gg">
<rect key="frame" x="991" y="47" width="67" height="32"/>
<buttonCell key="cell" type="push" title="复制" bezelStyle="rounded" alignment="center" state="on" borderStyle="border" inset="2" id="KbF-KT-P2y">
<rect key="frame" x="986" y="47" width="72" height="32"/>
<buttonCell key="cell" type="push" title="Copy" bezelStyle="rounded" alignment="center" state="on" borderStyle="border" inset="2" id="KbF-KT-P2y">
<behavior key="behavior" pushIn="YES" lightByBackground="YES" lightByGray="YES"/>
<font key="font" metaFont="system"/>
<connections>
Expand Down
2 changes: 1 addition & 1 deletion TPJSONFormatter/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<string>0.0.3</string>
<key>CFBundleVersion</key>
<string>1</string>
<key>LSMinimumSystemVersion</key>
Expand Down
1 change: 1 addition & 0 deletions TPJSONFormatter/Main/TPInstanceParser.swift
Original file line number Diff line number Diff line change
Expand Up @@ -114,3 +114,4 @@ class TPInstanceParser{




30 changes: 30 additions & 0 deletions TPJSONFormatter/ViewController.swift
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,36 @@ class ViewController: NSViewController,NSTextViewDelegate {
self.title = "Converter"
onProccess(nil)
inputTextView.delegate = self


#if DEBUG
inputTextView.string = """
{
"object": {
"string": "string",
"double": 22.22,
"int": 20,
"boolean": true,
"sdouble": "22.22",
"sint": "20",
"sboolean": "true",
"object": {
"nullArray":[],
"array": [
{
"stringA":"string"
},
{
"stringB":"string",
"stringC":"string"
}
],
"nestArray": [[[["sss"]]]]
}
}
}
"""
#endif

}
override var representedObject: Any? {
Expand Down
Binary file added UseWay.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 76b8c33

Please sign in to comment.