<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>w6500</author_name>
  <author_url>https://blog.hatena.ne.jp/w6500/</author_url>
  <blog_title>tanihiro.log</blog_title>
  <blog_url>https://tanihiro.hatenablog.com/</blog_url>
  <categories>
    <anon>swift</anon>
    <anon>iOS</anon>
  </categories>
  <description>swiftで独自のViewを定義した時に、見た目をxibで整える方法をまとめます。 1. 独自のViewクラスの定義 class CustomView: UIView { } 2. 空のxibファイルを作成 3. xibで見た目を作成 4. File's Ownerで先ほどの独自Viewクラスを指定 これで、とりあえずxibファイルとViewクラスが紐付いたので、各要素のOutletやActionを定義できるようになります。 5. Viewクラス側でxibファイルを読み込み、xibファイルで定義した一番親のViewを追加する File's Ownerでクラスを指定しただけでは、xibファイルを…</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Ftanihiro.hatenablog.com%2Fentry%2F2015%2F10%2F13%2F092710&quot; title=&quot;【iOS】【swift】カスタムViewとxibを紐付ける - tanihiro.log&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url>http://cdn-ak.f.st-hatena.com/images/fotolife/w/w6500/20151013/20151013090133.png</image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2015-10-13 09:27:10</published>
  <title>【iOS】【swift】カスタムViewとxibを紐付ける</title>
  <type>rich</type>
  <url>https://tanihiro.hatenablog.com/entry/2015/10/13/092710</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
