<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Ping Wei on Medium]]></title>
        <description><![CDATA[Stories by Ping Wei on Medium]]></description>
        <link>https://medium.com/@jeff22337?source=rss-24ee18617eb6------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*GL2kThZN-I_lSK2hq5iTCg.jpeg</url>
            <title>Stories by Ping Wei on Medium</title>
            <link>https://medium.com/@jeff22337?source=rss-24ee18617eb6------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 02:30:17 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@jeff22337/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[#13調色大師]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/13%E8%AA%BF%E8%89%B2%E5%A4%A7%E5%B8%AB-b3edc3345fa?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/b3edc3345fa</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Thu, 14 May 2020 16:48:48 GMT</pubDate>
            <atom:updated>2020-05-14T16:48:48.489Z</atom:updated>
            <content:encoded><![CDATA[<p>coding</p><p>最近工作比較忙，再加上需要陪老婆去看醫生的關係</p><p>沒有太多時間可以寫作業～～（其實是花很多時間在看小說上orz)</p><p>這一次的作業跟上班的東西有些關聯性</p><p>上班用的是PLC控制器，在字畫設備上當然不能只有PLC</p><p>還需要搭配HMI，簡單來說就是操作用的螢幕</p><p>畢竟PLC本身是沒有螢幕的，單純只是一個主機</p><p>而HMI上的顯示元件會與PLC做對應的關係</p><p>例如：</p><p>修改參數不需要拿筆電連接PLC，只需在HMI上輸入</p><p>但前提是你的PLC與HMI有做好相應的連接</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/712/1*nNao9HsW6qFKC5giSDz2jg.png" /></figure><p>這一次的作業為控制slider來改變顏色</p><p>首先利用＠IBOutlet來讓slider與程式做連接</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*arLL4aPHaVEAc2eGY7i8Gg.png" /></figure><p>定義完成後</p><p>還需要建立＠IBAction</p><p>因為我們是移動slider來改變顏色，所以須建立＠IBAction來執行function</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*QkkiK3YHXxHSfjxcr-zH_A.png" /></figure><p>到這裡我們就可以進行拖曳slider改變顏色了</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/160/1*aQ_wRokcnJHdSTE9rYEUKA.gif" /></figure><p>這時候應該有人發現改變的鹽掃怪怪的…</p><p>因為我在定義＠IBOutlet的時候有拉錯線…</p><p>再來是亂數的效果，我們先看結果</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/160/1*3ODkJM_RHrc21cCNRbywyw.gif" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/840/1*eyS8yYDi2LbtPPVgcqLXhg.png" /></figure><p>利用random來產生變數，範圍在0~1之間</p><p>這次作業就到這邊了，有些地方解釋不是很標準，等我功力深厚點應該可以再講得直白一點</p><p>參考文章：</p><p><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84%E8%A9%A6%E7%85%89-%E5%8B%87%E8%80%85%E7%9A%84-100-%E9%81%93-swift-ios-app-%E8%AC%8E%E9%A1%8C/%E8%AA%BF%E8%89%B2%E5%A4%A7%E5%B8%AB-swift-ios-app-%E4%BD%9C%E6%A5%AD-a8ab4d968034">#13 調色大師</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b3edc3345fa" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/13%E8%AA%BF%E8%89%B2%E5%A4%A7%E5%B8%AB-b3edc3345fa">#13調色大師</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[運用 UIBezierPath 繪製Pikachu]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E9%81%8B%E7%94%A8-uibezierpath-%E7%B9%AA%E8%A3%BDpikachu-d0e721e1aa5d?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/d0e721e1aa5d</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sat, 18 Apr 2020 03:54:56 GMT</pubDate>
            <atom:updated>2020-04-18T03:54:56.850Z</atom:updated>
            <content:encoded><![CDATA[<h3>UIBezierPath</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*0PMEyCvURV9LtJGycTeVQA.png" /></figure><p>花了不少時間，終於完成了Pikachu</p><p>先來看看成品</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/710/1*QhrIoQm5EF7tZWDbdnUk_A.png" /></figure><p>恩。。。其實還是有不少地方不及格。。。</p><p>但是哥。。。盡力了</p><p>製作的過程中使用了：</p><pre>畫曲線＿path.addQuadCurve<br>畫直線path.addLine<br>畫圓path = UIBezierPath(ovalIn: CGRect(x: x, y: x, width: x, height: x))</pre><p>以下為程式碼</p><pre><strong>import</strong> SwiftUI</pre><pre><strong>struct</strong> DrawView: UIViewRepresentable {</pre><pre><strong>func</strong> makeUIView(context: Context) -&gt; UIView {</pre><pre><strong>let</strong> view = UIView()</pre><pre>//yellowBody</pre><pre><strong>var</strong> path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:86,y:95))</pre><pre>path.addQuadCurve(to: CGPoint(x: 3, y: 70), controlPoint: CGPoint(x:37, y: 95))</pre><pre>path.addQuadCurve(to: CGPoint(x: 99, y: 80), controlPoint: CGPoint(x:52, y: 59))</pre><pre>path.addQuadCurve(to: CGPoint(x: 169, y: 77), controlPoint: CGPoint(x:128, y: 61))</pre><pre>path.addQuadCurve(to: CGPoint(x: 246, y: 3), controlPoint: CGPoint(x:191, y: 33))</pre><pre>path.addQuadCurve(to: CGPoint(x: 189, y: 96), controlPoint: CGPoint(x:222, y: 62))</pre><pre>path.addQuadCurve(to: CGPoint(x: 193, y: 170), controlPoint: CGPoint(x:207, y: 121))</pre><pre>path.addQuadCurve(to: CGPoint(x: 203, y: 282), controlPoint: CGPoint(x:235, y: 246))</pre><pre>path.addQuadCurve(to: CGPoint(x: 146, y: 283), controlPoint: CGPoint(x:190, y: 291))</pre><pre>path.addQuadCurve(to: CGPoint(x: 78, y: 258), controlPoint: CGPoint(x:91, y: 300))</pre><pre>path.addQuadCurve(to: CGPoint(x: 86, y: 217), controlPoint: CGPoint(x:77, y: 237))</pre><pre>path.addQuadCurve(to: CGPoint(x: 91, y: 181), controlPoint: CGPoint(x:86, y: 198))</pre><pre>path.addQuadCurve(to: CGPoint(x: 73, y: 128), controlPoint: CGPoint(x:56, y: 153))</pre><pre>path.addQuadCurve(to: CGPoint(x:86,y:95), controlPoint: CGPoint(x:74, y: 109))</pre><pre><strong>let</strong> leftEarBlack = CAShapeLayer()</pre><pre>leftEarBlack.path = path.cgPath</pre><pre>view.layer.addSublayer(leftEarBlack)</pre><pre>leftEarBlack.fillColor = CGColor (srgbRed:253/255, green: 224/255, blue: 98/255, alpha: 255)</pre><pre>leftEarBlack.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>leftEarBlack.lineWidth = 2</pre><pre>//tail</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:216,y:239))</pre><pre>path.addLine(to: CGPoint(x: 239, y: 217))</pre><pre>path.addLine(to: CGPoint(x: 215, y: 203))</pre><pre>path.addLine(to: CGPoint(x: 230, y: 178))</pre><pre>path.addLine(to: CGPoint(x: 199, y: 168))</pre><pre>path.addLine(to: CGPoint(x: 254, y: 89))</pre><pre>path.addLine(to: CGPoint(x: 300, y: 170))</pre><pre>//        path.addLine(to: CGPoint(x: 290, y: 191))</pre><pre>path.addLine(to: CGPoint(x: 269, y: 175))</pre><pre>path.addLine(to: CGPoint(x: 250, y: 206))</pre><pre>path.addLine(to: CGPoint(x: 273, y: 217))</pre><pre>path.addLine(to: CGPoint(x: 216, y: 253))</pre><pre><strong>let</strong> tail = CAShapeLayer()</pre><pre>tail.path = path.cgPath</pre><pre>view.layer.addSublayer(tail)</pre><pre>tail.fillColor = CGColor (srgbRed:253/255, green: 224/255, blue: 98/255, alpha: 255)</pre><pre>tail.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>tail.lineWidth = 2</pre><pre>//foot</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:200,y:284))</pre><pre>path.addQuadCurve(to: CGPoint(x:205,y:317), controlPoint: CGPoint(x:209, y: 295))</pre><pre>path.addQuadCurve(to: CGPoint(x:198,y:300), controlPoint: CGPoint(x:203, y: 307))</pre><pre>path.move(to: CGPoint(x:205,y:320))</pre><pre>path.addQuadCurve(to: CGPoint(x:173,y:287), controlPoint: CGPoint(x:182, y: 307))</pre><pre>path.addQuadCurve(to: CGPoint(x:202,y:282), controlPoint: CGPoint(x:193, y: 289))</pre><pre>path.move(to: CGPoint(x:201,y:317))</pre><pre>path.addLine(to: CGPoint(x: 191, y: 300))</pre><pre>path.move(to: CGPoint(x:122,y:289))</pre><pre>path.addQuadCurve(to: CGPoint(x:79,y:307), controlPoint: CGPoint(x:104, y: 307))</pre><pre>path.addLine(to: CGPoint(x: 75, y: 305))</pre><pre>path.addQuadCurve(to: CGPoint(x:91,y:281), controlPoint: CGPoint(x:78, y: 288))</pre><pre>path.move(to: CGPoint(x:75,y:304))</pre><pre>path.addQuadCurve(to: CGPoint(x:83,y:296), controlPoint: CGPoint(x:80, y: 301))</pre><pre>path.move(to: CGPoint(x:80,y:307))</pre><pre>path.addQuadCurve(to: CGPoint(x:92,y:296), controlPoint: CGPoint(x:85, y: 304))</pre><pre>path.move(to: CGPoint(x:91,y:280))</pre><pre>path.addQuadCurve(to: CGPoint(x:120,y:287), controlPoint: CGPoint(x:102, y: 288))</pre><pre><strong>let</strong> foot = CAShapeLayer()</pre><pre>foot.path = path.cgPath</pre><pre>view.layer.addSublayer(foot)</pre><pre>foot.fillColor = CGColor (srgbRed:250/255, green: 226/255, blue: 99/255, alpha: 255)</pre><pre>foot.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>foot.lineWidth = 2</pre><pre>// brown</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:216,y:239))</pre><pre>path.addLine(to: CGPoint(x: 230, y: 227))</pre><pre>path.addLine(to: CGPoint(x: 229, y: 232))</pre><pre>path.addLine(to: CGPoint(x: 234, y: 229))</pre><pre>path.addLine(to: CGPoint(x: 236, y: 228))</pre><pre>path.addLine(to: CGPoint(x: 231, y: 236))</pre><pre>path.addLine(to: CGPoint(x: 241, y: 233))</pre><pre>path.addLine(to: CGPoint(x: 236, y: 239))</pre><pre>path.addLine(to: CGPoint(x: 215, y: 254))</pre><pre>path.move(to: CGPoint(x:217,y:240))</pre><pre>path.addLine(to: CGPoint(x: 190, y: 238))</pre><pre>path.addLine(to: CGPoint(x: 213.5, y: 223))</pre><pre>path.move(to: CGPoint(x:209,y:208))</pre><pre>path.addLine(to: CGPoint(x: 191, y: 206))</pre><pre>path.addLine(to: CGPoint(x: 205, y: 196))</pre><pre><strong>let</strong> brown = CAShapeLayer()</pre><pre>brown.path = path.cgPath</pre><pre>view.layer.addSublayer(brown)</pre><pre>brown.fillColor = CGColor (srgbRed:164/255, green: 87/255, blue: 31/255, alpha: 255)</pre><pre>//        brown.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 0).cgColor</pre><pre>//        brown.lineWidth = 0</pre><pre>//hand</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:180,y:217))</pre><pre>path.addQuadCurve(to: CGPoint(x:169,y:248), controlPoint: CGPoint(x:178, y: 234))</pre><pre>path.addQuadCurve(to: CGPoint(x:166,y:256), controlPoint: CGPoint(x:169, y: 250))</pre><pre>path.addQuadCurve(to: CGPoint(x:162,y:253), controlPoint: CGPoint(x:163, y: 256))</pre><pre>path.addQuadCurve(to: CGPoint(x:160,y:257), controlPoint: CGPoint(x:162, y: 255))</pre><pre>path.addQuadCurve(to: CGPoint(x:157,y:252), controlPoint: CGPoint(x:158, y: 255))</pre><pre>path.addQuadCurve(to: CGPoint(x:154,y:256), controlPoint: CGPoint(x:155, y: 256))</pre><pre>path.addQuadCurve(to: CGPoint(x:153,y:249), controlPoint: CGPoint(x:152, y: 256))</pre><pre>path.addQuadCurve(to: CGPoint(x:148,y:252), controlPoint: CGPoint(x:150, y: 253))</pre><pre>path.addQuadCurve(to: CGPoint(x:150,y:245), controlPoint: CGPoint(x:149, y: 248))</pre><pre>path.addQuadCurve(to: CGPoint(x:156,y:201), controlPoint: CGPoint(x:149, y: 223))</pre><pre><strong>let</strong> hand = CAShapeLayer()</pre><pre>hand.path = path.cgPath</pre><pre>view.layer.addSublayer(hand)</pre><pre>hand.fillColor = CGColor (srgbRed:253/255, green: 219/255, blue: 71/255, alpha: 255)</pre><pre>hand.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>hand.lineWidth = 2</pre><pre>//leftHand</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:115,y:203))</pre><pre>path.addQuadCurve(to: CGPoint(x:114,y:240), controlPoint: CGPoint(x:119, y: 224))</pre><pre>path.addQuadCurve(to: CGPoint(x:116,y:248), controlPoint: CGPoint(x:115, y: 242))</pre><pre>path.addQuadCurve(to: CGPoint(x:111,y:245), controlPoint: CGPoint(x:115, y: 253))</pre><pre>path.addQuadCurve(to: CGPoint(x:109,y:253), controlPoint: CGPoint(x:113, y: 252))</pre><pre>path.addQuadCurve(to: CGPoint(x:107,y:246), controlPoint: CGPoint(x:105, y: 255))</pre><pre>path.addQuadCurve(to: CGPoint(x:101,y:253), controlPoint: CGPoint(x:105, y: 253))</pre><pre>path.addQuadCurve(to: CGPoint(x:101,y:246), controlPoint: CGPoint(x:101, y: 250))</pre><pre>path.addQuadCurve(to: CGPoint(x:95,y:252), controlPoint: CGPoint(x:97, y: 252))</pre><pre>path.addQuadCurve(to: CGPoint(x:94,y:246), controlPoint: CGPoint(x:93, y: 248))</pre><pre>path.addQuadCurve(to: CGPoint(x:94,y:240), controlPoint: CGPoint(x:94, y: 238))</pre><pre>path.addQuadCurve(to: CGPoint(x:86,y:215), controlPoint: CGPoint(x:88, y: 230))</pre><pre><strong>let</strong> leftHand = CAShapeLayer()</pre><pre>leftHand.path = path.cgPath</pre><pre>view.layer.addSublayer(leftHand)</pre><pre>leftHand.fillColor = CGColor (srgbRed:253/255, green: 219/255, blue: 71/255, alpha: 255)</pre><pre>leftHand.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>leftHand.lineWidth = 2</pre><pre>//ray</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:107,y:179))</pre><pre>path.addQuadCurve(to: CGPoint(x:144,y:178), controlPoint: CGPoint(x:125, y: 182))</pre><pre>path.addQuadCurve(to: CGPoint(x:128,y:202), controlPoint: CGPoint(x:141, y: 197))</pre><pre>path.addQuadCurve(to: CGPoint(x:108,y:180), controlPoint: CGPoint(x:118, y: 191))</pre><pre><strong>let</strong> ray = CAShapeLayer()</pre><pre>ray.path = path.cgPath</pre><pre>view.layer.addSublayer(ray)</pre><pre>ray.fillColor = CGColor (srgbRed:241/255, green: 193/255, blue: 64/255, alpha: 255)</pre><pre>ray.strokeColor = UIColor(red: 241/255, green: 193/255, blue: 64/255, alpha: 255).cgColor</pre><pre>ray.lineWidth = 2</pre><pre>//red</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:71,y:136))</pre><pre>path.addQuadCurve(to: CGPoint(x:73,y:159), controlPoint: CGPoint(x:82, y: 147))</pre><pre>path.addQuadCurve(to: CGPoint(x:71,y:136), controlPoint: CGPoint(x:67, y: 147))</pre><pre>path.move(to: CGPoint(x:71,y:136))</pre><pre><strong>let</strong> red = CAShapeLayer()</pre><pre>red.path = path.cgPath</pre><pre>view.layer.addSublayer(red)</pre><pre>red.fillColor = CGColor (srgbRed:252/255, green: 96/255, blue: 78/255, alpha: 255)</pre><pre>red.strokeColor = UIColor(red: 252/255, green: 96/255, blue: 78/255, alpha: 255).cgColor</pre><pre>red.lineWidth = 2</pre><pre>//resCirco</pre><pre>path = UIBezierPath()</pre><pre>path = UIBezierPath(ovalIn: CGRect(x: 155, y: 143, width: 25, height: 25))</pre><pre><strong>let</strong> resCirco = CAShapeLayer()</pre><pre>resCirco.path = path.cgPath</pre><pre>view.layer.addSublayer(resCirco)</pre><pre>resCirco.fillColor = CGColor (srgbRed:252/255, green: 96/255, blue: 78/255, alpha: 255)</pre><pre>resCirco.strokeColor = UIColor(red: 252/255, green: 96/255, blue: 78/255, alpha: 255).cgColor<br></pre><pre>//black</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:44,y:90))</pre><pre>path.addQuadCurve(to: CGPoint(x:3,y:70), controlPoint: CGPoint(x:17, y: 83))</pre><pre>path.addQuadCurve(to: CGPoint(x:32,y:67), controlPoint: CGPoint(x:16, y: 66))</pre><pre>path.addQuadCurve(to: CGPoint(x:44,y:90), controlPoint: CGPoint(x:33, y: 80))</pre><pre>path.move(to: CGPoint(x:220,y:20))</pre><pre>path.addQuadCurve(to: CGPoint(x:246,y:3), controlPoint: CGPoint(x:228, y: 12))</pre><pre>path.addQuadCurve(to: CGPoint(x:220,y:57), controlPoint: CGPoint(x:241, y: 25))</pre><pre>path.addQuadCurve(to: CGPoint(x:220,y:20), controlPoint: CGPoint(x:228, y: 33))</pre><pre><strong>let</strong> black = CAShapeLayer()</pre><pre>black.path = path.cgPath</pre><pre>view.layer.addSublayer(black)</pre><pre>black.fillColor = CGColor (srgbRed:41/255, green: 27/255, blue: 26/255, alpha: 255)</pre><pre>black.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>//blackLeftEye</pre><pre>path = UIBezierPath()</pre><pre>path = UIBezierPath(ovalIn: CGRect(x: 80, y: 110, width: 20, height: 25))</pre><pre><strong>let</strong> blackLeftEye = CAShapeLayer()</pre><pre>blackLeftEye.path = path.cgPath</pre><pre>view.layer.addSublayer(blackLeftEye)</pre><pre>blackLeftEye.fillColor = CGColor (srgbRed:50/255, green: 38/255, blue: 28/255, alpha: 255)</pre><pre>//blackRightEye</pre><pre>path = UIBezierPath()</pre><pre>path = UIBezierPath(ovalIn: CGRect(x: 140, y: 106, width: 28, height: 28))</pre><pre><strong>let</strong> blackRightEye = CAShapeLayer()</pre><pre>blackRightEye.path = path.cgPath</pre><pre>view.layer.addSublayer(blackRightEye)</pre><pre>blackRightEye.fillColor = CGColor (srgbRed:50/255, green: 38/255, blue: 28/255, alpha: 255)</pre><pre>// whiteLeftEye</pre><pre>path = UIBezierPath()</pre><pre>path = UIBezierPath(ovalIn: CGRect(x: 88, y: 114, width: 8, height: 11.5))</pre><pre><strong>let</strong> whiteLeftEye = CAShapeLayer()</pre><pre>whiteLeftEye.path = path.cgPath</pre><pre>view.layer.addSublayer(whiteLeftEye)</pre><pre>whiteLeftEye.fillColor = CGColor (srgbRed:253/255, green: 253/255, blue: 253/255, alpha: 255)</pre><pre>// whiteRightEye</pre><pre>path = UIBezierPath()</pre><pre>path = UIBezierPath(ovalIn: CGRect(x: 145, y: 111, width: 12, height: 12))</pre><pre><strong>let</strong> whiteRightEye = CAShapeLayer()</pre><pre>whiteRightEye.path = path.cgPath</pre><pre>view.layer.addSublayer(whiteRightEye)</pre><pre>whiteRightEye.fillColor = CGColor (srgbRed:253/255, green: 253/255, blue: 253/255, alpha: 255)</pre><pre>//nose</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:105,y:140))</pre><pre>path.addQuadCurve(to: CGPoint(x:117,y:140), controlPoint: CGPoint(x:108, y: 141))</pre><pre>path.addQuadCurve(to: CGPoint(x:111,y:145), controlPoint: CGPoint(x:112, y: 146))</pre><pre><strong>let</strong> nose = CAShapeLayer()</pre><pre>nose.path = path.cgPath</pre><pre>view.layer.addSublayer(nose)</pre><pre>nose.fillColor = CGColor (srgbRed:41/255, green: 27/255, blue: 26/255, alpha: 255)</pre><pre>//mouth</pre><pre>path = UIBezierPath()</pre><pre>path.move(to: CGPoint(x:97,y:154))</pre><pre>path.addQuadCurve(to: CGPoint(x:107,y:160), controlPoint: CGPoint(x:98, y: 160))</pre><pre>path.move(to: CGPoint(x:104,y:160))</pre><pre>path.addQuadCurve(to: CGPoint(x:114,y:154), controlPoint: CGPoint(x:115, y: 160))</pre><pre>path.move(to: CGPoint(x:114,y:154))</pre><pre>path.addQuadCurve(to: CGPoint(x:126,y:160), controlPoint: CGPoint(x:115, y: 160))</pre><pre>path.move(to: CGPoint(x:120,y:160))</pre><pre>path.addQuadCurve(to: CGPoint(x:134,y:154), controlPoint: CGPoint(x:132, y: 160))</pre><pre><strong>let</strong> mouth = CAShapeLayer()</pre><pre>mouth.path = path.cgPath</pre><pre>view.layer.addSublayer(mouth)</pre><pre>mouth.fillColor = CGColor (srgbRed:41/255, green: 27/255, blue: 26/255, alpha: 255)</pre><pre>mouth.strokeColor = UIColor(red: 41/255, green: 27/255, blue: 26/255, alpha: 255).cgColor</pre><pre>mouth.lineWidth = 1<br></pre><pre><strong>return</strong> view</pre><pre>}</pre><pre><strong>func</strong> updateUIView(<strong>_</strong> uiView: UIView, context: Context) {</pre><pre>}</pre><pre>}</pre><pre><strong>struct</strong> ContentView: View {</pre><pre><strong>var</strong> body: <strong>some</strong> View {</pre><pre>DrawView()</pre><pre>}</pre><pre>}</pre><pre><strong>struct</strong> ContentView_Previews: PreviewProvider {</pre><pre><strong>static</strong> <strong>var</strong> previews: <strong>some</strong> View {</pre><pre>ContentView()</pre><pre>}</pre><pre>}</pre><p>可以好好睡了～</p><p>參考文章：</p><ul><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84%E8%A9%A6%E7%85%89-%E5%8B%87%E8%80%85%E7%9A%84-100-%E9%81%93-swift-ios-app-%E8%AC%8E%E9%A1%8C/%E9%81%8B%E7%94%A8-uibezierpath-%E7%B9%AA%E8%A3%BD%E5%8F%AF%E6%84%9B%E5%9C%96%E6%A1%88-%E6%AF%94%E6%96%B9%E9%9B%AA%E4%BA%BA-%E7%B1%B3%E5%A5%87-%E5%8F%AF%E6%84%9B%E5%8B%95%E7%89%A9-12d3a5ef1d6c">#52 運用 UIBezierPath 模仿繪製可愛圖案，比方 Swift &amp; Hello Kitty</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E5%95%8F%E9%A1%8C%E8%A7%A3%E7%AD%94%E9%9B%86/%E5%B0%87-view-%E8%AE%8A%E6%88%90%E4%BB%BB%E6%84%8F%E5%BD%A2%E7%8B%80%E7%9A%84%E4%B8%89%E7%A8%AE%E6%96%B9%E6%B3%95-d43e6e4b8fb5">將 view 變成任意形狀的三種方法</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E5%95%8F%E9%A1%8C%E8%A7%A3%E7%AD%94%E9%9B%86/%E4%BD%BF%E7%94%A8-swiftui-%E9%A0%90%E8%A6%BD-uibezierpath-%E7%9A%84%E7%B9%AA%E5%9C%96%E7%B5%90%E6%9E%9C-5d5b8e679287">使用 SwiftUI 預覽 UIBezierPath 的繪圖結果</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E5%95%8F%E9%A1%8C%E8%A7%A3%E7%AD%94%E9%9B%86/%E9%81%8B%E7%94%A8-uibezierpath-%E7%B9%AA%E8%A3%BD%E5%BD%A2-3c858e194676">運用 UIBezierPath 繪製各種形狀</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d0e721e1aa5d" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E9%81%8B%E7%94%A8-uibezierpath-%E7%B9%AA%E8%A3%BDpikachu-d0e721e1aa5d">運用 UIBezierPath 繪製Pikachu</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[定義 function，印出讓自己一秒落淚的情歌歌詞]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E5%AE%9A%E7%BE%A9-function-%E5%8D%B0%E5%87%BA%E8%AE%93%E8%87%AA%E5%B7%B1%E4%B8%80%E7%A7%92%E8%90%BD%E6%B7%9A%E7%9A%84%E6%83%85%E6%AD%8C%E6%AD%8C%E8%A9%9E-56ee82949473?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/56ee82949473</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 12 Apr 2020 15:33:03 GMT</pubDate>
            <atom:updated>2020-04-12T15:33:03.667Z</atom:updated>
            <content:encoded><![CDATA[<p>讓我很有感覺的歌[讓我留在你身邊]</p><p>Peter上課的時候總是會穿插一些Peter很有感覺的歌</p><p>今天我也來分享一首我很有感覺的歌</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/998/1*uiqrrObABfrsNhOJ-t84Mg.png" /><figcaption><a href="https://www.kkbox.com/tw/tc/song/yDC00XKTH8ImwbVgmwbVg0XL-index.html">https://www.kkbox.com/tw/tc/song/yDC00XKTH8ImwbVgmwbVg0XL-index.html</a></figcaption></figure><p>歌詞：</p><pre>我從來不說話<br>因為我害怕 沒有人回答<br>我從來不掙扎<br>因為我知道 這世界太大</pre><pre>太多時間浪費 太多事要面對<br>太多已無所謂 太多難辨真偽<br>太多紛擾是非 在你身邊是誰</pre><pre>最渺小的我 有大大的夢<br>時間向前走一定只有路口沒有盡頭<br>紛紛擾擾這個世界 所有的了解</pre><pre>只要 讓我留在你身邊</pre><pre>最渺小的我 有大大的夢<br>我願意安靜的活在每個有你的角落<br>如果生活還有什麼 會讓你難過<br>別怕 讓我留在你身邊 都陪你渡過<br>最渺小的我 最卑微的夢</pre><pre>我發現這世界沒有那麼那麼的不同<br>現實如果對你不公 別計較太多<br>走吧 暴風雨後的彩虹<br>也許會落空 也許會普通<br>也許這庸庸碌碌的黑白世界你不懂<br>生命中所有的路口 絕不是盡頭</pre><pre>別怕 讓我留在你身邊 都陪你渡過</pre><pre>func 我從來不說話() {<br>   print(&quot;我從來不說話&quot;)<br>   print(&quot;因為我害怕 沒有人回答&quot;)<br>   print(&quot;我從來不掙扎&quot;)<br>   print(&quot;因為我知道 這世界太大&quot;)<br>}<br>func 太多時間浪費() {<br>   print(&quot;太多時間浪費 太多事要面對&quot;)<br>   print(&quot;太多已無所謂 太多難辨真偽&quot;)<br>   print(&quot;太多紛擾是非 在你身邊是誰&quot;)<br>}<br>func 時間向前走() {<br>   print(&quot;最渺小的我 有大大的夢&quot;)<br>   print(&quot;時間向前走一定只有路口沒有盡頭&quot;)<br>   print(&quot;紛紛擾擾這個世界 所有的了解&quot;)<br>}<br>func 只要() {<br>   print(&quot;只要 讓我留在你身邊&quot;)<br>}<br>func 最渺小的我() {<br>   print(&quot;最渺小的我 有大大的夢&quot;)<br>   print(&quot;我願意安靜的活在每個有你的角落&quot;)<br>   print(&quot;如果生活還有什麼 會讓你難過&quot;)<br>   print(&quot;別怕 讓我留在你身邊 都陪你渡過&quot;)<br>   print(&quot;最渺小的我 最卑微的夢&quot;)<br>}<br>func 我發現這世界沒有那麼那麼的不同() {<br>   print(&quot;我發現這世界沒有那麼那麼的不同&quot;)<br>   print(&quot;現實如果對你不公 別計較太多&quot;)<br>   print(&quot;走吧 暴風雨後的彩虹&quot;)<br>   print(&quot;也許會落空 也許會普通&quot;)<br>   print(&quot;也許這庸庸碌碌的黑白世界你不懂&quot;)<br>   print(&quot;生命中所有的路口 絕不是盡頭&quot;)<br>}<br>func 別怕() {<br>   print(&quot;別怕 讓我留在你身邊 都陪你渡過&quot;)<br>}</pre><pre>我從來不說話()<br>太多時間浪費()<br>時間向前走()<br>只要()<br>最渺小的我()<br>我發現這世界沒有那麼那麼的不同()<br>別怕()</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/706/1*K9ECqx5EYe06veEI1aKHdA.png" /></figure><p>歌詞來源：</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FbWdawOZ0mDI%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DbWdawOZ0mDI&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FbWdawOZ0mDI%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/1174b233d0fad0cad61d88bc060e9750/href">https://medium.com/media/1174b233d0fad0cad61d88bc060e9750/href</a></iframe><p>參考文章：</p><ul><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84%E8%A9%A6%E7%85%89-%E5%8B%87%E8%80%85%E7%9A%84-100-%E9%81%93-swift-ios-app-%E8%AC%8E%E9%A1%8C/%E5%AE%9A%E7%BE%A9-function-%E5%8D%B0%E5%87%BA%E8%AE%93%E8%87%AA%E5%B7%B1%E4%B8%80%E7%A7%92%E8%90%BD%E6%B7%9A%E7%9A%84%E6%83%85%E6%AD%8C%E6%AD%8C%E8%A9%9E-851ff4147fda">#64 定義 function，印出讓自己一秒落淚的情歌歌詞</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E6%95%99%E5%AE%A4/%E5%9C%A8-medium-%E8%B2%BC%E4%B8%8A%E7%B6%AD%E6%8C%81%E7%B8%AE%E6%8E%92%E7%9A%84%E6%BC%82%E4%BA%AE%E7%A8%8B%E5%BC%8F-c4bb488520a5">在 Medium 貼上彩色的 Swift 程式</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=56ee82949473" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E5%AE%9A%E7%BE%A9-function-%E5%8D%B0%E5%87%BA%E8%AE%93%E8%87%AA%E5%B7%B1%E4%B8%80%E7%A7%92%E8%90%BD%E6%B7%9A%E7%9A%84%E6%83%85%E6%AD%8C%E6%AD%8C%E8%A9%9E-56ee82949473">定義 function，印出讓自己一秒落淚的情歌歌詞</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[法國國旗]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E6%B3%95%E5%9C%8B%E5%9C%8B%E6%97%97-60e72e8b846e?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/60e72e8b846e</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 12 Apr 2020 14:50:25 GMT</pubDate>
            <atom:updated>2020-04-12T15:34:43.554Z</atom:updated>
            <content:encoded><![CDATA[<h3>SwiftUI 預覽 UIBezierPath，addSubview 和 UIBezierPath</h3><p>最近主管覺得加班時數太少，導致加班的時間變長，寫作業的時間變短，程式真的要常看，看習慣後理解code的速度也會變快，好加在最近上班有機會接觸C#與Omron程式，C#與Swift滿類似的就是語法寫法不同，Omron則是與三菱PLC的不同在與不只是使用階梯語言，它的st指令也很完善。</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*RVzF3-6-KAgRceWp" /><figcaption>Photo by <a href="https://unsplash.com/@sortino?utm_source=medium&amp;utm_medium=referral">Joshua Sortino</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>這一次主要熟悉UIBezierPath、addSublayer寫法，並使用SwiftUI 預覽即時的顯示程式的表現</p><pre>import SwiftUI<br>struct DrawView: UIViewRepresentable {<br>    func makeUIView(context: Context) -&gt; UIView {<br>        let view = UIView()<br>        <br>//藍色方塊<br>        var path = UIBezierPath()<br>        path.move(to: CGPoint(x: 4, y: 1))<br>        path.addLine(to: CGPoint(x: 4, y: 212))<br>        path.addLine(to: CGPoint(x: 106, y: 212))<br>        path.addLine(to: CGPoint(x: 106, y: 1))<br>        path.close()<br>        let CountryFaceBlue = CAShapeLayer()<br>        CountryFaceBlue.path = path.cgPath<br>        <br>        view.layer.addSublayer(CountryFaceBlue)<br>        CountryFaceBlue.fillColor = CGColor (srgbRed:0, green: 0, blue: 1, alpha: 255)<br>        CountryFaceBlue.strokeColor = UIColor.black.cgColor<br>        <br>//白色方塊<br>        path = UIBezierPath()<br>        path.move(to: CGPoint(x: 106, y: 1))<br>        path.addLine(to: CGPoint(x: 106, y: 212))<br>        path.addLine(to: CGPoint(x: 212, y: 212))<br>        path.addLine(to: CGPoint(x: 212, y: 1))<br>        path.close()<br>        let CountryFaceWhite = CAShapeLayer()<br>        CountryFaceWhite.path = path.cgPath<br>        view.layer.addSublayer(CountryFaceWhite)<br>        CountryFaceWhite.fillColor = CGColor (srgbRed: 255, green: 255, blue: 255, alpha: 255)<br>        CountryFaceWhite.strokeColor = UIColor.black.cgColor<br>//紅色方塊<br>        path = UIBezierPath()<br>        path.move(to: CGPoint(x: 212, y: 1))<br>        path.addLine(to: CGPoint(x: 212, y: 212))<br>        path.addLine(to: CGPoint(x: 320, y: 212))<br>        path.addLine(to: CGPoint(x: 320, y: 1))<br>        path.close()<br>        let CountryFaceRed = CAShapeLayer()<br>        CountryFaceRed.path = path.cgPath<br>        view.layer.addSublayer(CountryFaceRed)<br>        CountryFaceRed.fillColor = CGColor (srgbRed: 1, green: 0, blue: 0, alpha: 255)<br>        CountryFaceRed.strokeColor = UIColor.black.cgColor<br>        <br>        return view<br>    }<br>    <br>    func updateUIView(_ uiView: UIView, context: Context) {<br>    }<br>    <br>}<br>struct ContentView: View {<br>    var body: some View {<br>        DrawView()<br>    }<br>}<br>struct ContentView_Previews: PreviewProvider {<br>    static var previews: some View {<br>        ContentView()<br>    }<br>}</pre><figure><img alt="" src="https://cdn-images-1.medium.com/max/838/1*PLA7x9WFM8C_VVSafc9Lzw.png" /></figure><p>參考文章：</p><ul><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84%E8%A9%A6%E7%85%89-%E5%8B%87%E8%80%85%E7%9A%84-100-%E9%81%93-swift-ios-app-%E8%AC%8E%E9%A1%8C/43-%E5%BE%9E%E7%A8%8B%E5%BC%8F%E8%A3%BD%E4%BD%9C%E5%9C%8B%E6%97%97%E5%9C%96%E6%A1%88-b3a1a913fe2e">#43 從程式製作國旗圖案</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E5%95%8F%E9%A1%8C%E8%A7%A3%E7%AD%94%E9%9B%86/%E4%BD%BF%E7%94%A8-swiftui-%E9%A0%90%E8%A6%BD-uibezierpath-%E7%9A%84%E7%B9%AA%E5%9C%96%E7%B5%90%E6%9E%9C-5d5b8e679287">使用 SwiftUI 預覽 UIBezierPath 的繪圖結果</a></li><li><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84%E8%A9%A6%E7%85%89-%E5%8B%87%E8%80%85%E7%9A%84-100-%E9%81%93-swift-ios-app-%E8%AC%8E%E9%A1%8C/%E9%81%8B%E7%94%A8-uibezierpath-%E7%B9%AA%E8%A3%BD%E5%8F%AF%E6%84%9B%E5%9C%96%E6%A1%88-%E6%AF%94%E6%96%B9%E9%9B%AA%E4%BA%BA-%E7%B1%B3%E5%A5%87-%E5%8F%AF%E6%84%9B%E5%8B%95%E7%89%A9-12d3a5ef1d6c">#52 運用 UIBezierPath 模仿繪製可愛圖案，比方 Swift &amp; Hello Kitty</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=60e72e8b846e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E6%B3%95%E5%9C%8B%E5%9C%8B%E6%97%97-60e72e8b846e">法國國旗</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[用 Swift 打造跳舞機器人 BoogieBot]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E7%94%A8-swift-%E6%89%93%E9%80%A0%E8%B7%B3%E8%88%9E%E6%A9%9F%E5%99%A8%E4%BA%BA-boogiebot-f71fca460b3?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/f71fca460b3</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 05 Apr 2020 15:00:00 GMT</pubDate>
            <atom:updated>2020-04-06T04:25:43.030Z</atom:updated>
            <content:encoded><![CDATA[<p>上了幾堂Peter的課程這次開始寫code了</p><p>真是讓人開心的</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*tQyHOcPCeWF6vEbN" /><figcaption>Photo by <a href="https://unsplash.com/@jemsahagun?utm_source=medium&amp;utm_medium=referral">Jem Sahagun</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/160/1*x2gJXiXZt3eKghcFQhqU7Q.gif" /></figure><p>以上為舞棍阿婆在跳舞</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IkXha6JmqUyDFbVUAoP2tw.png" /></figure><p>這是程式</p><p>利用func來將幾種動作組合在一起</p><p>再將舊得func：</p><p>ShankeACircle</p><p>TwoArmUp</p><p>TwoArmDown</p><p>UpDown</p><p>放入新的func裡面</p><p>Dance</p><p>文章參考：</p><p><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E6%95%99%E5%AE%A4/%E7%94%A8-swift-%E6%89%93%E9%80%A0%E8%B7%B3%E8%88%9E%E6%A9%9F%E5%99%A8%E4%BA%BA-boogiebot-199d07d9bb95">用 Swift 打造跳舞機器人 BoogieBot</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=f71fca460b3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E7%94%A8-swift-%E6%89%93%E9%80%A0%E8%B7%B3%E8%88%9E%E6%A9%9F%E5%99%A8%E4%BA%BA-boogiebot-f71fca460b3">用 Swift 打造跳舞機器人 BoogieBot</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Storyboard 電子書 App]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/storyboard-%E9%9B%BB%E5%AD%90%E6%9B%B8-app-8daf57d71f1b?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/8daf57d71f1b</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 29 Mar 2020 15:32:27 GMT</pubDate>
            <atom:updated>2020-03-29T15:33:48.270Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*X_eeXv4V2Au-qtI5" /><figcaption>Photo by <a href="https://unsplash.com/@alxndr_london?utm_source=medium&amp;utm_medium=referral">Alexander London</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>這次不使用任何coding，來完成電子書App</p><p>使用功能如下：</p><ol><li>tab bar controller</li><li>navigation controller</li><li>table view controller</li><li>segue</li><li>iOS SDK UI</li><li>text view</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*bjn5EfOc2YLeslqZl0eC9w.png" /></figure><p>以下為App操作</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/128/1*4k27BAujeqGVGaWaEfXs5w.gif" /></figure><p>這是一個電影時刻表的App，可以看電影資訊與地圖＆網站</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8daf57d71f1b" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/storyboard-%E9%9B%BB%E5%AD%90%E6%9B%B8-app-8daf57d71f1b">Storyboard 電子書 App</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Grid Photo Wall 照片牆]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/grid-photo-wall-%E7%85%A7%E7%89%87%E7%89%86-6b88772fefc?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/6b88772fefc</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Mon, 23 Mar 2020 16:13:34 GMT</pubDate>
            <atom:updated>2020-03-23T16:18:29.423Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*I6-ZN5mfrIrWKBUU" /><figcaption>Photo by <a href="https://unsplash.com/@marjan_blan?utm_source=medium&amp;utm_medium=referral">Марьян Блан | @marjanblan</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><p>這次的作業是使用StoryBoard 來做一個Grid Photo Wall</p><p>當然也是沒有寫Code啦</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*juv3WjrMM8lLEmPWa0x6gw.png" /></figure><p>使用的功能如下：</p><ol><li>Table View Controller</li><li>View Controller</li><li>Scroll View</li><li>View</li><li>Navigation Controller</li><li>Tab Bar Controller</li></ol><p>以下為App操作GIF</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/200/1*Ibu0ExhK534Bex9oSgaUng.gif" /></figure><p>以下是GitHub 連結</p><p><a href="https://github.com/Dick-Tseng/Grid-Photo-Wall">https://github.com/Dick-Tseng/Grid-Photo-Wall</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6b88772fefc" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/grid-photo-wall-%E7%85%A7%E7%89%87%E7%89%86-6b88772fefc">Grid Photo Wall 照片牆</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[#46 利用 marvel App 製作 prototype app]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/46-%E5%88%A9%E7%94%A8-marvel-app-%E8%A3%BD%E4%BD%9C-prototype-app-c3128cc95daa?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/c3128cc95daa</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 22 Mar 2020 09:01:22 GMT</pubDate>
            <atom:updated>2020-03-22T09:54:44.202Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*2-QzL7jhlrtXEyF9" /><figcaption>Photo by <a href="https://unsplash.com/@_javardh_001?utm_source=medium&amp;utm_medium=referral">Javardh</a> on <a href="https://unsplash.com/?utm_source=medium&amp;utm_medium=referral">Unsplash</a></figcaption></figure><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fmarvelapp.com%2F55b776a%3Femb%3D1%26&amp;display_name=MarvelApp&amp;url=https%3A%2F%2Fmarvelapp.com%2F55b776a&amp;image=https%3A%2F%2Fmarvel-live.freetls.fastly.net%2Fserve%2F2020%2F3%2F2c73788095f2455f890c9b9986953c71.png%3Fquality%3D95%26fake%3D.png&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=marvelapp" width="1125" height="2460" frameborder="0" scrolling="no"><a href="https://medium.com/media/9037adad19264c0fff775f1322255c88/href">https://medium.com/media/9037adad19264c0fff775f1322255c88/href</a></iframe><p>這次呢我將利用marvel App來這製作一個App</p><p>首先進入amrvel App的網址下：</p><p><a href="https://marvelapp.com/apps/">Apps | Marvel</a></p><p>創建一個免費帳號</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/258/1*zMcI8WmdufK1eCZAixUWFA.png" /></figure><p>選擇製作的裝置，我則是選擇IPHONE</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*dJNi1X5Mv92iNJNaGb_d2A.png" /></figure><p>選擇New Design</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*sHHqI58qVTERcEqPsFk4sg.png" /></figure><p>可以開始製作App了</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*XYiblkTt8kRiJhKomtkHtg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*9Ew_JGXrTk2ogHBHeamJHg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/738/1*ekDkG5bhXXljl_bmB_9l3A.png" /></figure><p>接下來說明如何利用按鈕來更換畫面</p><p>按下Prototype</p><p>圈選要更換畫面的按鈕，就成功了</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/386/1*S0n4nALbCAaAaTV38xHTlA.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*W78-Em7eq0PbjxnIdPAdug.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c3128cc95daa" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/46-%E5%88%A9%E7%94%A8-marvel-app-%E8%A3%BD%E4%BD%9C-prototype-app-c3128cc95daa">#46 利用 marvel App 製作 prototype app</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[錄製App操作影片與上傳Code 至GitHub]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E9%8C%84%E8%A3%BDapp%E6%93%8D%E4%BD%9C%E5%BD%B1%E7%89%87%E8%88%87%E4%B8%8A%E5%82%B3code-%E8%87%B3github-5447fb7dbfd3?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/5447fb7dbfd3</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sun, 15 Mar 2020 16:29:56 GMT</pubDate>
            <atom:updated>2020-03-22T09:56:00.590Z</atom:updated>
            <content:encoded><![CDATA[<p>錄製App操作影片與上傳Code 至GitHub</p><p>當我們在Ｘcode製作好一個App</p><p>在還沒有上架的時候想要跟朋友分享甚至是老闆的時候</p><p>我們就可以直接將製作的App操作過程錄製</p><p>利用錄製來呈現App的操作</p><ol><li>我使用QickTime Player來進行錄製</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/268/1*r-YJJUrt1csJs9YakVVMGA.png" /></figure><p>2.打開QickTime Player後我們點選File. -&gt; New Screen Recording</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*TNL_R-1KFQdvq1upuXFL1A.png" /></figure><p>3.將虛線框框拖曳成模擬器Iphone的大小按下Record即可以開始錄製操作</p><p>4.錄製完成後按下螢幕右上角的按鈕，即可停止錄製操作</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/54/1*p29N1Km1mKpUW1gZuuW43w.png" /></figure><p>5.最後的步驟為：將錄製好的影片轉檔成GIF檔</p><p>以下是我錄製的一小段操作影片</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/320/1*oFZALczmcQVDt2joEHOzvw.gif" /></figure><p>~~ 由於檔案大小的限制所以畫質有點差，之後再想想看有沒有比較好的方法可以使用</p><p>今天要介紹的第二項為上傳Code 至GitHub</p><p>當我們辛辛苦苦製作一個App的過程中，我們往往會有許多新的想法產生</p><p>在實踐這些新的想法之前，為了讓我們更好的分辨專案製作的進度</p><p>我們可以在製作App的過程中適時的使用GitHub</p><p>這樣就能夠製作類似中斷點於我們撰寫的App中</p><p>當我們卡關想使用時光機時，就可以將程式回復至其他的中斷點</p><p>以下是我上傳至GitHub的網址</p><p><a href="https://github.com/Dick-Tseng/20200307/tree/v.01/20200307">Dick-Tseng/20200307</a></p><p>GitHub上傳教學可以看Peter的文章</p><p><a href="https://medium.com/%E5%BD%BC%E5%BE%97%E6%BD%98%E7%9A%84-swift-ios-app-%E9%96%8B%E7%99%BC%E5%95%8F%E9%A1%8C%E8%A7%A3%E7%AD%94%E9%9B%86/%E5%A6%82%E4%BD%95%E5%B0%87-ios-app-%E4%BD%9C%E6%A5%AD%E4%B8%8A%E5%82%B3%E5%88%B0-github-135416069dfd">如何將 iOS App 作業上傳到 GitHub</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5447fb7dbfd3" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E9%8C%84%E8%A3%BDapp%E6%93%8D%E4%BD%9C%E5%BD%B1%E7%89%87%E8%88%87%E4%B8%8A%E5%82%B3code-%E8%87%B3github-5447fb7dbfd3">錄製App操作影片與上傳Code 至GitHub</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[第一次親密接觸]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E7%AC%AC%E4%B8%80%E6%AC%A1%E8%A6%AA%E5%AF%86%E6%8E%A5%E8%A7%B8-581a5fa29137?source=rss-24ee18617eb6------2</link>
            <guid isPermaLink="false">https://medium.com/p/581a5fa29137</guid>
            <dc:creator><![CDATA[Ping Wei]]></dc:creator>
            <pubDate>Sat, 14 Mar 2020 05:21:34 GMT</pubDate>
            <atom:updated>2020-03-22T09:56:21.435Z</atom:updated>
            <content:encoded><![CDATA[<p>出社會後很少有這種補習的機會</p><p>這一次是為了學習新的專業技能而報名了Peter的ios app課程</p><p>如果我有貝多芬的音樂才能，我就可以到處表演了</p><p>我有音樂才能嗎？沒有</p><p>我只記得垃圾車的旋律</p><p>如果我有高超的籃球技巧，我就可以打入NBA了</p><p>我有籃球天分嗎？沒有</p><p>我身高只有169</p><p>如果我有鋼鐵人的愛國者1號，我就可以拯救台灣了</p><p>我有愛國者嗎？沒有</p><p>我只有看過鋼鐵人1~3 集</p><p>如果我會寫ios app，我就可以用app征服全世界了</p><p>我會寫嗎？不會</p><p>所以我報名了Peter的ios app課程</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=581a5fa29137" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E7%AC%AC%E4%B8%80%E6%AC%A1%E8%A6%AA%E5%AF%86%E6%8E%A5%E8%A7%B8-581a5fa29137">第一次親密接觸</a> was originally published in <a href="https://medium.com/peter-pan-swift-ios-class">彼得潘的 Swift iOS / Flutter App 開發教室</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>