<?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 黃昱瑋 on Medium]]></title>
        <description><![CDATA[Stories by 黃昱瑋 on Medium]]></description>
        <link>https://medium.com/@away082004?source=rss-4a279cd7f07f------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*JTSXfS7bMT6MVKKyeYnJwg@2x.jpeg</url>
            <title>Stories by 黃昱瑋 on Medium</title>
            <link>https://medium.com/@away082004?source=rss-4a279cd7f07f------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 21 Nov 2026 23:50:46 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@away082004/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[遇見Swift小王子]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E9%81%87%E8%A6%8Bswift%E5%B0%8F%E7%8E%8B%E5%AD%90-81cc0ec938fe?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/81cc0ec938fe</guid>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[ios]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Tue, 02 Oct 2018 08:17:26 GMT</pubDate>
            <atom:updated>2018-10-02T10:06:42.507Z</atom:updated>
            <content:encoded><![CDATA[<p>一直嚷嚷著要學寫程式app已經有幾年了，親朋好友可能覺得我也只是說說。在離開了工作六年的前東家之後，放空了好些日子想著雖然已過而立之年，人生還有好多事沒做。尤其是從小玩遊戲玩到大，總有一天要寫一個遊戲APP給其他人玩。</p><p>於是決定問問Google大神，打入關鍵字 IOS / APP，映入眼簾的第一個相關網站就是愛瘋一切為蘋果的彼得潘（<a href="http://apppeterpan.strikingly.com/">http://apppeterpan.strikingly.com</a>）。</p><p>大概看了課程內容與最下方幾篇文章，最打動我的莫過於這句話。<strong>「 你不需要很厲害才能開始，但你需要開始，才會很厲害。」</strong>小王子還在底下附註<strong>「 其實願意開始的人很多，難的是開始之後，你會持續多久。花 100 個小時練習的你，絕對比花 10 個小時的你厲害。」。</strong></p><p>其他玲琅滿目的寫了許多保證與上課內容雖然看起來像個廣告詞，但是從文筆之下可以感受到彼得潘的真誠。由於當時文組班與彼得潘班都還在前一屆的課程途中，決定先上博客來買書來看看，前後挑了兩本其中一本就是彼得潘的著作。</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/623/1*Oe9XVXio-1cVmtxVaABm_A.png" /></figure><p>帶著姑且一試的心態看了幾頁，就被小王子幽默輕鬆的口吻吸引，一連看了兩三章。原本應該是複雜無聊的程式碼與觀念，居然可以用如此有趣的描述與故事來呈現。因為本身機械系畢業也不算相關科系，後來就決定同時報名彼得潘班與文組生班。</p><p>小王子在一開始的課堂上介紹許多學習Swift的資源。活用了諸如 Trello / Medium / Github 等，帶領學生快速上手。教學也是與時俱進，用最新版的X code與IOS，作業雖然跟山一樣高，但是絕對是進步的最佳良藥。小王子總是苦口婆心的要大家挑自己有興趣的去發揮。的確學到的就是自己，且程式碼不實際自己打入是很難學以致用的。所有小作業累積起來也不少，有好好練習不知不覺也會提升許多實力。</p><p>他一向跟我們說：<strong>「我不是你們的老師，我是你們的朋友。有問題隨時歡迎。」</strong></p><p>是的未來有問題一定找小王子，也希望未來有機會合作一款APP。最後感謝小王子兩個月的教導！</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/%E8%B6%85%E9%81%8E-30-%E6%AD%B2-%E9%96%8B%E5%A7%8B%E5%AD%B8%E7%A8%8B%E5%BC%8F%E4%BE%86%E5%BE%97%E5%8F%8A%E5%97%8E-cc7d3af772af"><em>超過 30 歲，開始學程式還來得及嗎 ?​</em></a></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/%E8%B6%85%E9%81%8E-30-%E6%AD%B2-%E9%96%8B%E5%A7%8B%E5%AD%B8%E7%A8%8B%E5%BC%8F%E4%BE%86%E5%BE%97%E5%8F%8A%E5%97%8E-cc7d3af772af">超過 30 歲，開始學程式還來得及嗎 ?</a></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/app-%E6%80%8E%E9%BA%BC%E5%AD%B8-%E4%B8%8A%E8%AA%B2%E9%82%84%E6%98%AF%E8%87%AA%E5%AD%B8-db3d9314ac89"><em>App 怎麼學？上課還是自學？</em></a></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/app-%E6%80%8E%E9%BA%BC%E5%AD%B8-%E4%B8%8A%E8%AA%B2%E9%82%84%E6%98%AF%E8%87%AA%E5%AD%B8-db3d9314ac89">App 怎麼學? 上課還是自學?</a></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%95%B6%E4%BD%A0%E5%8A%AA%E5%8A%9B%E6%83%B3%E5%AD%B8%E7%BF%92-swift-%E6%99%82-%E5%85%A8%E4%B8%96%E7%95%8C%E9%83%BD%E6%9C%83%E4%BE%86%E5%B9%AB%E4%BD%A0-b11dca643686"><em>當你努力想學習 Swift 時，全世界都會來幫你</em></a></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%95%B6%E4%BD%A0%E5%8A%AA%E5%8A%9B%E6%83%B3%E5%AD%B8%E7%BF%92-swift-%E6%99%82-%E5%85%A8%E4%B8%96%E7%95%8C%E9%83%BD%E6%9C%83%E4%BE%86%E5%B9%AB%E4%BD%A0-b11dca643686">當你努力想學習 Swift 時，全世界都會來幫你</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=81cc0ec938fe" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E9%81%87%E8%A6%8Bswift%E5%B0%8F%E7%8E%8B%E5%AD%90-81cc0ec938fe">遇見Swift小王子</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/%E8%B3%AD%E5%8D%9A%E9%BB%98%E7%A4%BA%E9%8C%84-%E7%9A%87%E5%B8%9D%E7%89%8C-91df8a12421c?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/91df8a12421c</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[card-game]]></category>
            <category><![CDATA[xcode]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Fri, 31 Aug 2018 08:34:27 GMT</pubDate>
            <atom:updated>2018-08-31T08:34:27.214Z</atom:updated>
            <content:encoded><![CDATA[<p>卡片app</p><p>這次期末app弄了一個卡牌遊戲</p><p>出處是從賭博默示錄的漫畫/電影裡面的皇帝牌</p><p>目前只是最初的版本</p><p>所以功能非常陽春</p><p>分出勝負以後要按Replay</p><p>另外背景配樂是用神劍闖江湖的OST增加氣氛</p><p>有興趣的朋友可以去Github下載玩玩看</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/400/1*zeLi6_uaw-GkAo4_yzcX7w.jpeg" /><figcaption>電影：賭博默示錄</figcaption></figure><p>畫面如下</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/335/1*A_kyWXdSEb1oBmnNVwdayQ.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/335/1*LZgfatMTdU7mKK5TvJVzJg.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/332/1*NUXFVbMQ5l3dwfGsNG3e_g.png" /><figcaption>遊戲畫面</figcaption></figure><p>運行Gif</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/394/1*VKEJWnFgjd5p6jg8bXOQBQ.gif" /></figure><p>Github</p><p><a href="https://github.com/JackHuang0110/Ecardgame">JackHuang0110/Ecardgame</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=91df8a12421c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E8%B3%AD%E5%8D%9A%E9%BB%98%E7%A4%BA%E9%8C%84-%E7%9A%87%E5%B8%9D%E7%89%8C-91df8a12421c">賭博默示錄-皇帝牌</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[#54 愛你最好的距離-那些年我們一起追的公主]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E3%84%93-54-%E6%84%9B%E4%BD%A0%E6%9C%80%E5%A5%BD%E7%9A%84%E8%B7%9D%E9%9B%A2-%E9%82%A3%E4%BA%9B%E5%B9%B4%E6%88%91%E5%80%91%E4%B8%80%E8%B5%B7%E8%BF%BD%E7%9A%84%E5%85%AC%E4%B8%BB-b9b6c3caa56f?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/b9b6c3caa56f</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[xcode]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Thu, 16 Aug 2018 09:26:57 GMT</pubDate>
            <atom:updated>2018-08-16T09:32:39.782Z</atom:updated>
            <content:encoded><![CDATA[<p>目的: 學習偵測 slider 的 value 變化。</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/780/1*k6TRWlbfG4gk-3hxmT-omg.png" /><figcaption>勇敢追愛的馬力歐</figcaption></figure><p>這次的作業非常有趣</p><p>並搭配那些年我們一起追的女孩台詞梗</p><p>加上背景音樂完成的可愛小App</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/768/1*RAzs0PhKfb0CUGubPRpNdA.gif" /><figcaption>第一次撩妹就上手的馬力歐</figcaption></figure><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FxWzlwGVQ6_Q%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DxWzlwGVQ6_Q&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FxWzlwGVQ6_Q%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="640" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/6a73dee400001957a24fda48c14ff44a/href">https://medium.com/media/6a73dee400001957a24fda48c14ff44a/href</a></iframe><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><strong>import</strong> AVFoundation</pre><pre><strong>class</strong> ViewController: UIViewController {</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> pagyTextField: UITextField!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> marioTextField: UITextField!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> marioImageView: UIImageView!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> pagyImageView: UIImageView!</pre><pre><strong>var</strong> myPlayer:AVAudioPlayer?</pre><pre><strong>@IBAction</strong> <strong>func</strong> moveCloserSlider(<strong>_</strong> sender: UISlider) {</pre><pre>marioImageView.frame.origin.x = CGFloat(58 + 160 * sender.value)</pre><pre>pagyImageView.frame.origin.x = CGFloat(503 - 160 * sender.value)</pre><pre><strong>if</strong> sender.value == Float(0.94) {</pre><pre>pagyTextField.isHidden = <strong>false</strong></pre><pre>marioTextField.isHidden = <strong>false</strong></pre><pre>myPlayer?.stop()</pre><pre>myPlayer?.currentTime = 0.0</pre><pre>myPlayer?.play()</pre><pre>}<strong>else</strong>{</pre><pre>pagyTextField.isHidden = <strong>true</strong></pre><pre>marioTextField.isHidden = <strong>true</strong></pre><pre>}</pre><pre>}</pre><pre><strong>override</strong> <strong>func</strong> viewDidLoad() {</pre><pre><strong>super</strong>.viewDidLoad()</pre><pre><strong>if</strong> <strong>let</strong> path = Bundle.main.path(forResource: &quot;theyear&quot;, ofType: &quot;mp3&quot;){</pre><pre><strong>do</strong> {</pre><pre>myPlayer = <strong>try</strong> AVAudioPlayer(contentsOf: URL(fileURLWithPath: path))</pre><pre>}<strong>catch</strong>{</pre><pre>myPlayer = <strong>nil</strong></pre><pre>}</pre><pre>}        <em>// Do any additional setup after loading the view, typically from a nib.</em></pre><pre>}</pre><pre>}</pre><p>GitHub</p><p><a href="https://github.com/JackHuang0110/moveCloser">JackHuang0110/moveCloser</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b9b6c3caa56f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E3%84%93-54-%E6%84%9B%E4%BD%A0%E6%9C%80%E5%A5%BD%E7%9A%84%E8%B7%9D%E9%9B%A2-%E9%82%A3%E4%BA%9B%E5%B9%B4%E6%88%91%E5%80%91%E4%B8%80%E8%B5%B7%E8%BF%BD%E7%9A%84%E5%85%AC%E4%B8%BB-b9b6c3caa56f">#54 愛你最好的距離-那些年我們一起追的公主</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加強版，用 slider 調整講話的音調和速度]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E9%96%8B%E4%B8%8D%E4%BA%86%E5%8F%A3%E7%9A%84%E5%91%8A%E7%99%BD-app%E5%8A%A0%E5%BC%B7%E7%89%88-%E7%94%A8-slider-%E8%AA%BF%E6%95%B4%E8%AC%9B%E8%A9%B1%E7%9A%84%E9%9F%B3%E8%AA%BF%E5%92%8C%E9%80%9F%E5%BA%A6-6bbe79320d0c?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/6bbe79320d0c</guid>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[swift]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Thu, 16 Aug 2018 04:16:11 GMT</pubDate>
            <atom:updated>2018-08-16T04:18:10.850Z</atom:updated>
            <content:encoded><![CDATA[<p>這次主要是練習加入Slider來控制講話音調與速度</p><p>另外加入label顯示目前拉的數值</p><p>有興趣的朋友可以參考以下Github連結</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/385/1*bX1BjSLxzgGTrWT90CMyWg.png" /><figcaption>App畫面</figcaption></figure><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><strong>import</strong> AVFoundation</pre><pre><strong>class</strong> ViewController: UIViewController {</pre><pre><em>//音調＆速度Label顯示到小數點第二位</em></pre><pre><strong>@IBAction</strong> <strong>func</strong> changeSlider(<strong>_</strong> sender: <strong>Any</strong>) {</pre><pre>speedRateText.text = String(format: &quot;%.2f&quot;, speedRate.value)</pre><pre>voiceTypeText.text = String(format: &quot;%.2f&quot;, voiceType.value)</pre><pre>}</pre><pre><em>//outlet專區</em></pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> speedRateText: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> voiceType: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> voiceTypeText: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> speedRate: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> loveTextField: UITextField!</pre><pre><em>//說中文加入音調＆速度功能</em></pre><pre><strong>@IBAction</strong> <strong>func</strong> buttunPressed(<strong>_</strong> sender: <strong>Any</strong>) {</pre><pre><strong>let</strong> speechUtterance = AVSpeechUtterance(string: loveTextField.text!)</pre><pre><strong>let</strong> synthesizer = AVSpeechSynthesizer()</pre><pre>speechUtterance.voice = AVSpeechSynthesisVoice(language: &quot;zh-TW&quot;)</pre><pre>speechUtterance.pitchMultiplier = voiceType.value</pre><pre>speechUtterance.rate = speedRate.value</pre><pre>synthesizer.speak(speechUtterance)</pre><pre>}</pre><pre><strong>override</strong> <strong>func</strong> viewDidLoad() {</pre><pre><strong>super</strong>.viewDidLoad()</pre><pre><em>// Do any additional setup after loading the view, typically from a nib.</em></pre><pre>}</pre><pre>}</pre><p>GitHub</p><p><a href="https://github.com/JackHuang0110/newdemo">JackHuang0110/newdemo</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6bbe79320d0c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E9%96%8B%E4%B8%8D%E4%BA%86%E5%8F%A3%E7%9A%84%E5%91%8A%E7%99%BD-app%E5%8A%A0%E5%BC%B7%E7%89%88-%E7%94%A8-slider-%E8%AA%BF%E6%95%B4%E8%AC%9B%E8%A9%B1%E7%9A%84%E9%9F%B3%E8%AA%BF%E5%92%8C%E9%80%9F%E5%BA%A6-6bbe79320d0c">開不了口的告白 App加強版，用 slider 調整講話的音調和速度</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[#43 從程式製作國旗圖案-不.美利堅合眾國國旗]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/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-%E4%B8%8D-%E7%BE%8E%E5%88%A9%E5%A0%85%E5%90%88%E7%9C%BE%E5%9C%8B%E5%9C%8B%E6%97%97-57bd8f5281fa?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/57bd8f5281fa</guid>
            <category><![CDATA[playground]]></category>
            <category><![CDATA[swift]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Tue, 14 Aug 2018 09:01:18 GMT</pubDate>
            <atom:updated>2018-08-14T09:07:23.551Z</atom:updated>
            <content:encoded><![CDATA[<p>目的: 學習從程式製作畫面和 CAShapeLayer。</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*4nk_Yannap73gc0SB8eOJg.png" /><figcaption><strong>美利堅合眾國國旗</strong></figcaption></figure><p>看大家努力完成各國國旗</p><p>所以決定來挑戰一下美國</p><p>但是到最後發現星星真的弄不出來阿…</p><p>於是誕生了這個自創國旗</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/383/1*b1kX4bT2LB5jgacKCsalGw.png" /><figcaption><strong>不.美利堅合眾國國旗</strong></figcaption></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/286/1*CjXbFyzxc_vix-vlUbPNwA.png" /><figcaption>步美表示想去</figcaption></figure><p>真是可惜</p><p>只好當作是練習</p><p>只能再找時間找Peter泡茶聊天兼研究</p><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><em>//白底</em></pre><pre><strong>var</strong> rect = CGRect(x:0,y:0,width:380,height:200)</pre><pre><strong>let</strong> backgroundView = UIView(frame: rect)</pre><pre>backgroundView.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre><em>//七紅條</em></pre><pre><strong>var</strong> rectRed = CGRect(x:0,y:0,width:380,height:200/13)</pre><pre><strong>let</strong> rectRedView = UIView(frame: rectRed)</pre><pre>rectRedView.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRedView)</pre><pre><strong>var</strong> rectRed1 = CGRect(x:0,y:(backgroundView.frame.height)*2/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed1View = UIView(frame: rectRed1)</pre><pre>rectRed1View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed1View)</pre><pre><strong>var</strong> rectRed2 = CGRect(x:0,y:(backgroundView.frame.height)*4/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed2View = UIView(frame: rectRed2)</pre><pre>rectRed2View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed2View)</pre><pre><strong>var</strong> rectRed3 = CGRect(x:0,y:(backgroundView.frame.height)*6/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed3View = UIView(frame: rectRed3)</pre><pre>rectRed3View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed3View)</pre><pre><strong>var</strong> rectRed4 = CGRect(x:0,y:(backgroundView.frame.height)*8/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed4View = UIView(frame: rectRed4)</pre><pre>rectRed4View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed4View)</pre><pre><strong>var</strong> rectRed5 = CGRect(x:0,y:(backgroundView.frame.height)*10/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed5View = UIView(frame: rectRed5)</pre><pre>rectRed5View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed5View)</pre><pre><strong>var</strong> rectRed6 = CGRect(x:0,y:(backgroundView.frame.height)*12/13,width:380,height:200/13)</pre><pre><strong>let</strong> rectRed6View = UIView(frame: rectRed6)</pre><pre>rectRed6View.backgroundColor = UIColor(red: 0.698, green: 0.1333, blue: 0.2039, alpha: 1.0) <em>/* #b22234 */</em></pre><pre>backgroundView.addSubview(rectRed6View)</pre><pre><em>//藍色區塊</em></pre><pre><strong>var</strong> rectBlue = CGRect(x:0,y:0,width:200*0.76,height:200*0.5385)</pre><pre><strong>let</strong> rectBlueView = UIView(frame: rectBlue)</pre><pre>rectBlueView.backgroundColor = UIColor(red: 0.2353, green: 0.2314, blue: 0.4314, alpha: 1.0) <em>/* #3c3b6e */</em></pre><pre>backgroundView.addSubview(rectBlueView)</pre><pre><em>//六圓圈第一排</em></pre><pre><strong>var</strong> rectStar1 = CGRect(x:200*0.0633 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar1View = UIView(frame: rectStar1)</pre><pre>rectStar1View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar1View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar1View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar1View)</pre><pre><strong>var</strong> rectStar2 = CGRect(x:200*0.0633*3 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar2View = UIView(frame: rectStar2)</pre><pre>rectStar2View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar2View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar2View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar2View)</pre><pre><strong>var</strong> rectStar3 = CGRect(x:200*0.0633*5 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar3View = UIView(frame: rectStar3)</pre><pre>rectStar3View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar3View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar3View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar3View)</pre><pre><strong>var</strong> rectStar4 = CGRect(x:200*0.0633*7 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar4View = UIView(frame: rectStar4)</pre><pre>rectStar4View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar4View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar4View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar4View)</pre><pre><strong>var</strong> rectStar5 = CGRect(x:200*0.0633*9 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar5View = UIView(frame: rectStar5)</pre><pre>rectStar5View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar5View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar5View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar5View)</pre><pre><strong>var</strong> rectStar6 = CGRect(x:200*0.0633*11 - 6.33 ,y:200*0.0538/2,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar6View = UIView(frame: rectStar6)</pre><pre>rectStar6View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar6View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar6View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar6View)</pre><pre><em>//六圓圈第二排</em></pre><pre><strong>var</strong> rectStar21 = CGRect(x:200*0.0633 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar21View = UIView(frame: rectStar21)</pre><pre>rectStar21View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar21View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar21View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar21View)</pre><pre><strong>var</strong> rectStar22 = CGRect(x:200*0.0633*3 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar22View = UIView(frame: rectStar22)</pre><pre>rectStar22View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar22View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar22View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar22View)</pre><pre><strong>var</strong> rectStar23 = CGRect(x:200*0.0633*5 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar23View = UIView(frame: rectStar23)</pre><pre>rectStar23View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar23View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar23View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar23View)</pre><pre><strong>var</strong> rectStar24 = CGRect(x:200*0.0633*7 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar24View = UIView(frame: rectStar24)</pre><pre>rectStar24View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar24View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar24View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar24View)</pre><pre><strong>var</strong> rectStar25 = CGRect(x:200*0.0633*9 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar25View = UIView(frame: rectStar25)</pre><pre>rectStar25View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar25View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar25View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar25View)</pre><pre><strong>var</strong> rectStar26 = CGRect(x:200*0.0633*11 - 6.33 ,y:200*0.0538*3 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar26View = UIView(frame: rectStar26)</pre><pre>rectStar26View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar26View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar26View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar26View)</pre><pre><em>//六圓圈第三排</em></pre><pre><strong>var</strong> rectStar31 = CGRect(x:200*0.0633 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar31View = UIView(frame: rectStar31)</pre><pre>rectStar31View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar31View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar31View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar31View)</pre><pre><strong>var</strong> rectStar32 = CGRect(x:200*0.0633*3 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar32View = UIView(frame: rectStar32)</pre><pre>rectStar32View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar32View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar32View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar32View)</pre><pre><strong>var</strong> rectStar33 = CGRect(x:200*0.0633*5 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar33View = UIView(frame: rectStar33)</pre><pre>rectStar33View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar33View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar33View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar33View)</pre><pre><strong>var</strong> rectStar34 = CGRect(x:200*0.0633*7 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar34View = UIView(frame: rectStar34)</pre><pre>rectStar34View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar34View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar34View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar34View)</pre><pre><strong>var</strong> rectStar35 = CGRect(x:200*0.0633*9 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar35View = UIView(frame: rectStar35)</pre><pre>rectStar35View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar35View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar35View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar35View)</pre><pre><strong>var</strong> rectStar36 = CGRect(x:200*0.0633*11 - 6.33 ,y:200*0.0538*5 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar36View = UIView(frame: rectStar36)</pre><pre>rectStar36View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar36View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar36View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar36View)</pre><pre>///六圓圈第四排</pre><pre><strong>var</strong> rectStar41 = CGRect(x:200*0.0633 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar41View = UIView(frame: rectStar41)</pre><pre>rectStar41View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar41View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar41View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar41View)</pre><pre><strong>var</strong> rectStar42 = CGRect(x:200*0.0633*3 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar42View = UIView(frame: rectStar42)</pre><pre>rectStar42View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar42View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar42View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar42View)</pre><pre><strong>var</strong> rectStar43 = CGRect(x:200*0.0633*5 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar43View = UIView(frame: rectStar43)</pre><pre>rectStar43View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar43View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar43View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar43View)</pre><pre><strong>var</strong> rectStar44 = CGRect(x:200*0.0633*7 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar44View = UIView(frame: rectStar44)</pre><pre>rectStar44View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar44View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar44View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar44View)</pre><pre><strong>var</strong> rectStar45 = CGRect(x:200*0.0633*9 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar45View = UIView(frame: rectStar45)</pre><pre>rectStar45View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar45View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar45View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar45View)</pre><pre><strong>var</strong> rectStar46 = CGRect(x:200*0.0633*11 - 6.33 ,y:200*0.0538*7 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar46View = UIView(frame: rectStar46)</pre><pre>rectStar46View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar46View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar46View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar46View)</pre><pre>///六圓圈第五排</pre><pre><strong>var</strong> rectStar51 = CGRect(x:200*0.0633 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar51View = UIView(frame: rectStar51)</pre><pre>rectStar51View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar51View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar51View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar51View)</pre><pre><strong>var</strong> rectStar52 = CGRect(x:200*0.0633*3 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar52View = UIView(frame: rectStar52)</pre><pre>rectStar52View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar52View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar52View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar52View)</pre><pre><strong>var</strong> rectStar53 = CGRect(x:200*0.0633*5 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar53View = UIView(frame: rectStar53)</pre><pre>rectStar53View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar53View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar53View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar53View)</pre><pre><strong>var</strong> rectStar54 = CGRect(x:200*0.0633*7 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar54View = UIView(frame: rectStar54)</pre><pre>rectStar54View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar54View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar54View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar54View)</pre><pre><strong>var</strong> rectStar55 = CGRect(x:200*0.0633*9 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar55View = UIView(frame: rectStar55)</pre><pre>rectStar55View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar55View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar55View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar55View)</pre><pre><strong>var</strong> rectStar56 = CGRect(x:200*0.0633*11 - 6.33 ,y:200*0.0538*9 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> rectStar56View = UIView(frame: rectStar56)</pre><pre>rectStar56View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>rectStar56View.layer.cornerRadius = 200*0.0616/2</pre><pre>rectStar56View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(rectStar56View)</pre><pre><em>//五圓圈第一排</em></pre><pre><strong>var</strong> circle1 = CGRect(x:200*0.0633*2 - 6.33 ,y:200*0.0538*2 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle1View = UIView(frame: circle1)</pre><pre>circle1View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle1View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle1View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle1View)</pre><pre><strong>var</strong> circle2 = CGRect(x:200*0.0633*4 - 6.33 ,y:200*0.0538*2 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle2View = UIView(frame: circle2)</pre><pre>circle2View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle2View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle2View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle2View)</pre><pre><strong>var</strong> circle3 = CGRect(x:200*0.0633*6 - 6.33 ,y:200*0.0538*2 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle3View = UIView(frame: circle3)</pre><pre>circle3View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle3View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle3View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle3View)</pre><pre><strong>var</strong> circle4 = CGRect(x:200*0.0633*8 - 6.33 ,y:200*0.0538*2 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle4View = UIView(frame: circle4)</pre><pre>circle4View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle4View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle4View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle4View)</pre><pre><strong>var</strong> circle5 = CGRect(x:200*0.0633*10 - 6.33 ,y:200*0.0538*2 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle5View = UIView(frame: circle5)</pre><pre>circle5View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle5View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle5View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle5View)</pre><pre><em>//五圓圈第二排</em></pre><pre><strong>var</strong> circle21 = CGRect(x:200*0.0633*2 - 6.33 ,y:200*0.0538*4 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle21View = UIView(frame: circle21)</pre><pre>circle21View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle21View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle21View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle21View)</pre><pre><strong>var</strong> circle22 = CGRect(x:200*0.0633*4 - 6.33 ,y:200*0.0538*4 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle22View = UIView(frame: circle22)</pre><pre>circle22View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle22View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle22View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle22View)</pre><pre><strong>var</strong> circle23 = CGRect(x:200*0.0633*6 - 6.33 ,y:200*0.0538*4 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle23View = UIView(frame: circle23)</pre><pre>circle23View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle23View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle23View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle23View)</pre><pre><strong>var</strong> circle24 = CGRect(x:200*0.0633*8 - 6.33 ,y:200*0.0538*4 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle24View = UIView(frame: circle24)</pre><pre>circle24View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle24View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle24View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle24View)</pre><pre><strong>var</strong> circle25 = CGRect(x:200*0.0633*10 - 6.33 ,y:200*0.0538*4 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle25View = UIView(frame: circle25)</pre><pre>circle25View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle25View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle25View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle25View)</pre><pre><em>//五圓圈第三排</em></pre><pre><strong>var</strong> circle31 = CGRect(x:200*0.0633*2 - 6.33 ,y:200*0.0538*6 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle31View = UIView(frame: circle31)</pre><pre>circle31View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle31View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle31View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle31View)</pre><pre><strong>var</strong> circle32 = CGRect(x:200*0.0633*4 - 6.33 ,y:200*0.0538*6 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle32View = UIView(frame: circle32)</pre><pre>circle32View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle32View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle32View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle32View)</pre><pre><strong>var</strong> circle33 = CGRect(x:200*0.0633*6 - 6.33 ,y:200*0.0538*6 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle33View = UIView(frame: circle33)</pre><pre>circle33View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle33View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle33View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle33View)</pre><pre><strong>var</strong> circle34 = CGRect(x:200*0.0633*8 - 6.33 ,y:200*0.0538*6 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle34View = UIView(frame: circle34)</pre><pre>circle34View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle34View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle34View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle34View)</pre><pre><strong>var</strong> circle35 = CGRect(x:200*0.0633*10 - 6.33 ,y:200*0.0538*6 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle35View = UIView(frame: circle35)</pre><pre>circle35View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle35View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle35View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle35View)</pre><pre><em>//五圓圈第四排</em></pre><pre><strong>var</strong> circle41 = CGRect(x:200*0.0633*2 - 6.33 ,y:200*0.0538*8 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle41View = UIView(frame: circle41)</pre><pre>circle41View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle41View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle41View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle41View)</pre><pre><strong>var</strong> circle42 = CGRect(x:200*0.0633*4 - 6.33 ,y:200*0.0538*8 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle42View = UIView(frame: circle42)</pre><pre>circle42View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle42View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle42View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle42View)</pre><pre><strong>var</strong> circle43 = CGRect(x:200*0.0633*6 - 6.33 ,y:200*0.0538*8 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle43View = UIView(frame: circle43)</pre><pre>circle43View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle43View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle43View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle43View)</pre><pre><strong>var</strong> circle44 = CGRect(x:200*0.0633*8 - 6.33 ,y:200*0.0538*8 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle44View = UIView(frame: circle44)</pre><pre>circle44View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle44View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle44View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle44View)</pre><pre><strong>var</strong> circle45 = CGRect(x:200*0.0633*10 - 6.33 ,y:200*0.0538*8 - 5.38,width:200*0.0616,height:200*0.0616)</pre><pre><strong>let</strong> circle45View = UIView(frame: circle45)</pre><pre>circle45View.backgroundColor = UIColor(red: 1, green: 1, blue: 1, alpha: 1.0) <em>/* #ffffff */</em></pre><pre>circle45View.layer.cornerRadius = 200*0.0616/2</pre><pre>circle45View.clipsToBounds = <strong>true</strong></pre><pre>rectBlueView.addSubview(circle45View)</pre><pre>backgroundView</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=57bd8f5281fa" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/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-%E4%B8%8D-%E7%BE%8E%E5%88%A9%E5%A0%85%E5%90%88%E7%9C%BE%E5%9C%8B%E5%9C%8B%E6%97%97-57bd8f5281fa">#43 從程式製作國旗圖案-不.美利堅合眾國國旗</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[#41 文字的縮放和字數 — UISlider & UITextField 練習]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/41-%E6%96%87%E5%AD%97%E7%9A%84%E7%B8%AE%E6%94%BE%E5%92%8C%E5%AD%97%E6%95%B8-uislider-uitextfield-%E7%B7%B4%E7%BF%92-4f3e77bc538a?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/4f3e77bc538a</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[xcode]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Thu, 09 Aug 2018 09:20:31 GMT</pubDate>
            <atom:updated>2018-08-09T09:20:31.517Z</atom:updated>
            <content:encoded><![CDATA[<p>目的: 學習偵測 UISlider &amp; UITextField 的 action。</p><p>1 拖曳 slider 控制文字的大小，並在下方的 label 顯示文字目前的大小。</p><p>2 在 text field 輸入文字，在字數的 label 顯示目前的字數。</p><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><strong>class</strong> ViewController: UIViewController {</pre><pre><strong>var</strong> fontSize : Float = 0.0</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> showTextField: UITextField!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> fontLenghLabel: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> fontSizeSlider: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> fontSizeLabel: UILabel!</pre><pre><strong>@IBAction</strong> <strong>func</strong> fontSizeSliderChanged(<strong>_</strong> sender: UISlider) {</pre><pre><em>//取得目前字體</em></pre><pre><strong>let</strong> font = showTextField.font!</pre><pre>fontSize = sender.value</pre><pre><em>//數字變字串顯示到小數點第二位</em></pre><pre>fontSizeLabel.text = String(format: &quot;%.2f&quot;, fontSize)</pre><pre><em>//指定字體大小 &amp; Float 變 CGFloat</em></pre><pre>showTextField.font = font.withSize(CGFloat(fontSize))</pre><pre>}</pre><pre><strong>@IBAction</strong> <strong>func</strong> entryTextField(<strong>_</strong> sender: UITextField) {</pre><pre>fontSizeLabel.text = String(fontSizeSlider.value)</pre><pre><em>//確認字數</em></pre><pre>fontLenghLabel.text = String(showTextField.text!.count)</pre><pre>}</pre><pre><strong>override</strong> <strong>func</strong> viewDidLoad() {</pre><pre><strong>super</strong>.viewDidLoad()</pre><pre><em>// Do any additional setup after loading the view, typically from a nib.</em></pre><pre>}</pre><pre>}</pre><p>運行畫面</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/378/1*FMkEN-_ktPC2wEq9s-z0Sw.gif" /></figure><p>Github</p><p><a href="https://github.com/JackHuang0110/FontSize">JackHuang0110/FontSize</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4f3e77bc538a" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/41-%E6%96%87%E5%AD%97%E7%9A%84%E7%B8%AE%E6%94%BE%E5%92%8C%E5%AD%97%E6%95%B8-uislider-uitextfield-%E7%B7%B4%E7%BF%92-4f3e77bc538a">#41 文字的縮放和字數 — UISlider &amp; UITextField 練習</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/@away082004/function%E6%A6%82%E5%BF%B5-cfb63601d41e?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/cfb63601d41e</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[xcode]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Tue, 07 Aug 2018 13:00:12 GMT</pubDate>
            <atom:updated>2018-08-07T14:55:11.925Z</atom:updated>
            <content:encoded><![CDATA[<p>熟悉function</p><p>上課練習題</p><p>就是一個概念</p><pre>func 打羽球(){</pre><pre>準備衣服褲子毛巾()</pre><pre>準備球拍球鞋()</pre><pre>洗澡()</pre><pre>牽車()</pre><pre>出發()</pre><pre>停車()</pre><pre>熱身()</pre><pre>練習長球()</pre><pre>雙打比賽()</pre><pre>收拾球場()</pre><pre>回家()</pre><pre>}</pre><pre>打羽球()</pre><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cfb63601d41e" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[#38 愛情的模樣 — 小熊維尼語錄]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/38-%E6%84%9B%E6%83%85%E7%9A%84%E6%A8%A1%E6%A8%A3-%E5%B0%8F%E7%86%8A%E7%B6%AD%E5%B0%BC%E8%AA%9E%E9%8C%84-81720e8ed310?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/81720e8ed310</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[xcode]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Mon, 06 Aug 2018 05:31:38 GMT</pubDate>
            <atom:updated>2018-08-06T05:31:38.035Z</atom:updated>
            <content:encoded><![CDATA[<p>目的: 學習從程式設定圖片，UISegmentedControl &amp; UIButton 的 action。</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*tdXj46z43RKWZj3WeHFHaw.png" /></figure><p>這次的作業主要是練習SegmentedControl</p><p>並利用程式控制顯示圖片</p><p>選擇可愛的小熊維尼語錄</p><p>運行畫面如下</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/384/1*zgkJ0qH1D4Wf8wtE7Ehk1Q.gif" /></figure><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><strong>class</strong> ViewController: UIViewController {</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> myImageView: UIImageView!</pre><pre><strong>@IBAction</strong> <strong>func</strong> changeSegmented(<strong>_</strong> sender: UISegmentedControl) {</pre><pre><strong>if</strong> sender.selectedSegmentIndex == 0 {</pre><pre>myImageView.image = UIImage(named: &quot;SegmentedLove&quot;)</pre><pre>}</pre><pre><strong>else</strong> <strong>if</strong> sender.selectedSegmentIndex == 1 {</pre><pre>myImageView.image = UIImage(named: &quot;SegmentedYou&quot;)</pre><pre>}</pre><pre><strong>else</strong> {</pre><pre>myImageView.image = UIImage(named: &quot;SegmentedForever&quot;)</pre><pre>}</pre><pre>}</pre><pre><strong>override</strong> <strong>func</strong> viewDidLoad() {</pre><pre><strong>super</strong>.viewDidLoad()</pre><pre><em>// Do any additional setup after loading the view, typically from a nib.</em></pre><pre>}</pre><pre>}</pre><p>Github</p><p><a href="https://github.com/JackHuang0110/aboutlove">JackHuang0110/aboutlove</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=81720e8ed310" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/38-%E6%84%9B%E6%83%85%E7%9A%84%E6%A8%A1%E6%A8%A3-%E5%B0%8F%E7%86%8A%E7%B6%AD%E5%B0%BC%E8%AA%9E%E9%8C%84-81720e8ed310">#38 愛情的模樣 — 小熊維尼語錄</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/%E8%AA%BF%E8%89%B2%E5%A4%A7%E5%B8%AB-4a273761a654?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/4a273761a654</guid>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[star-wars]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Wed, 01 Aug 2018 05:43:34 GMT</pubDate>
            <atom:updated>2018-08-01T05:46:48.064Z</atom:updated>
            <content:encoded><![CDATA[<p>Star War 光劍</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/383/1*tq4Rwqlo9t5ByoOKIzjqug.png" /></figure><p>這次的調色大師app選用Star War為主題</p><p>其中有一個特別的“天選之劍”</p><p>就是運用了剛學到的亂數</p><p>運行畫面如下</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/364/1*PyKgRoNnyZq9bfNKkB3uxw.gif" /></figure><p>程式碼</p><pre><strong>import</strong> UIKit</pre><pre><strong>class</strong> ViewController: UIViewController {</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> blueValueLabel: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> greenValueLabel: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> redValueLabel: UILabel!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> Redslider: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> Greenslider: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> Blueslider: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> Alphaslider: UISlider!</pre><pre><strong>@IBOutlet</strong> <strong>weak</strong> <strong>var</strong> StarladyImageview: UIImageView!</pre><pre><strong>@IBAction</strong> <strong>func</strong> RandomColor(<strong>_</strong> sender: UIButton) {</pre><pre><strong>let</strong> red = CGFloat.random(in: 0...1)</pre><pre><strong>let</strong> green = CGFloat.random(in: 0...1)</pre><pre><strong>let</strong> blue = CGFloat.random(in: 0...1)</pre><pre><strong>let</strong> alpha = CGFloat.random(in: 0...1)</pre><pre>StarladyImageview.backgroundColor = UIColor(red: red, green: green, blue: blue, alpha: alpha)</pre><pre>}</pre><pre><strong>@IBAction</strong> <strong>func</strong> Colorchange(<strong>_</strong> sender: UISlider) {</pre><pre>StarladyImageview.backgroundColor = UIColor(red: CGFloat(Redslider.value), green: CGFloat(Greenslider.value), blue: CGFloat(Blueslider.value), alpha: CGFloat(Alphaslider.value))</pre><pre>redValueLabel.text = String(format: &quot;%.2f&quot;, Redslider.value)</pre><pre>greenValueLabel.text = String(format: &quot;%.2f&quot;, Greenslider.value)</pre><pre>blueValueLabel.text = String(format: &quot;%.2f&quot;, Blueslider.value)</pre><pre>}</pre><pre><strong>override</strong> <strong>func</strong> viewDidLoad() {</pre><pre><strong>super</strong>.viewDidLoad()</pre><pre><em>// Do any additional setup after loading the view, typically from a nib.</em></pre><pre>}</pre><pre>}</pre><p>Github</p><p><a href="https://github.com/JackHuang0110/starwar">JackHuang0110/starwar</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=4a273761a654" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E8%AA%BF%E8%89%B2%E5%A4%A7%E5%B8%AB-4a273761a654">調色大師</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[搭配 sketch & zeplin 製作 iOS 的健康 App 畫面]]></title>
            <link>https://medium.com/peter-pan-swift-ios-class/%E6%90%AD%E9%85%8D-sketch-zeplin-%E8%A3%BD%E4%BD%9C-ios-%E7%9A%84%E5%81%A5%E5%BA%B7-app-%E7%95%AB%E9%9D%A2-ac6869ba3fda?source=rss-4a279cd7f07f------2</link>
            <guid isPermaLink="false">https://medium.com/p/ac6869ba3fda</guid>
            <category><![CDATA[xcode]]></category>
            <category><![CDATA[swift]]></category>
            <dc:creator><![CDATA[黃昱瑋]]></dc:creator>
            <pubDate>Thu, 26 Jul 2018 11:03:23 GMT</pubDate>
            <atom:updated>2018-07-26T11:03:23.772Z</atom:updated>
            <content:encoded><![CDATA[<p>畫面模仿</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*CRG5et9RIducCyDRCxOS3w.png" /></figure><p>1.先下載Peter給的模擬圖片跟icon如下</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/%E6%90%AD%E9%85%8D-sketch-zeplin-%E8%A3%BD%E4%BD%9C-ios-%E7%9A%84%E5%81%A5%E5%BA%B7-app-%E7%95%AB%E9%9D%A2-b6f077b5a023">搭配 sketch &amp; zeplin 製作 iOS 的健康 App 和 App Store 畫面</a></p><p>2.把圖片與icon匯入Assets</p><p>3.主要是畫面是由Tab bar controller/Navigator controller與三個空白的 view controller 就好</p><p>4.透過zeplin確認圖片size/間距等屬性</p><p>完成的gif</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/360/1*s1tpc2NELxE3PzLUIwV4Eg.gif" /></figure><p>Github</p><p><a href="https://github.com/JackHuang0110/Health">JackHuang0110/Health</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ac6869ba3fda" width="1" height="1" alt=""><hr><p><a href="https://medium.com/peter-pan-swift-ios-class/%E6%90%AD%E9%85%8D-sketch-zeplin-%E8%A3%BD%E4%BD%9C-ios-%E7%9A%84%E5%81%A5%E5%BA%B7-app-%E7%95%AB%E9%9D%A2-ac6869ba3fda">搭配 sketch &amp; zeplin 製作 iOS 的健康 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>
    </channel>
</rss>