src
画像を変更し、ルックアップにオーバーレイを追加することで、TVMLCatalog の例に付属する ShowcaseTemplate を変更するだけです。
<carousel>
<section>
<lockup>
<img src="${this.BASEURL}resources/images/templates/gft.jpg" width="500" height="600" />
<overlay>
<title>Hello, this is title</title>
</overlay>
</lockup>
</section>
</carousel>
しかし、オーバーレイは表示されていません
これは XCODE ログが示すものです:
2015-12-07 11:25:47.851 TVMLCatalog[3953:3684153] #T:[Main] #Notice #SYSTEM : Template element: <IKViewElement: 0x7fcee0781f20>
2015-12-07 11:25:47.858 TVMLCatalog[3953:3684153] #T:[Main] #Notice #SYSTEM : Template controller: <_TVLoadingViewController: 0x7fcee04ba960>
2015-12-07 11:25:47.864 TVMLCatalog[3953:3684153] #T:[Main] #Notice #SYSTEM : Template element: <IKViewElement: 0x7fcee2176a50>
2015-12-07 11:25:47.865 TVMLCatalog[3953:3684153] #T:[Main] #Notice #SYSTEM : Template controller: <_TVShowcaseTemplateController: 0x7fcee0799c90>
Dec 7 11:25:47 TVMLCatalog[3953] <Error>: ImageIO: CreateMetadataFromXMPBufferInternal Threw error #203 (Duplicate property or field node)
Dec 7 11:25:47 TVMLCatalog[3953] <Error>: ImageIO: CreateMetadataFromXMPBufferInternal Threw error #203 (Duplicate property or field node)
2015-12-07 11:25:48.996 TVMLCatalog[3953:3684153] Unable to simultaneously satisfy constraints.
Probably at least one of the constraints in the following list is one you don't want.
Try this:
(1) look at each constraint and try to figure out which you don't expect;
(2) find the code that added the unwanted constraint or constraints and fix it.
(Note: If you're seeing NSAutoresizingMaskLayoutConstraints that you don't understand, refer to the documentation for the UIView property translatesAutoresizingMaskIntoConstraints)
(
"<NSAutoresizingMaskLayoutConstraint:0x7fcee0564910 h=--& v=--& V:[_TVStackingPosterView:0x7fcee051a1e0(46)]>",
"<NSLayoutConstraint:0x7fcee0554000 V:[TVLabel:0x7fcee0561020'Image1'(62)]>",
"<NSLayoutConstraint:0x7fcee0564250 V:|-(0)-[TVLabel:0x7fcee0561020'Image1'] (Names: '|':_TVStackingPosterView:0x7fcee051a1e0 )>",
"<NSLayoutConstraint:0x7fcee0564720 TVLabel:0x7fcee0561020'Image1'.bottom == _TVStackingPosterView:0x7fcee051a1e0.bottom>"
)
Will attempt to recover by breaking constraint
<NSLayoutConstraint:0x7fcee0564720 TVLabel:0x7fcee0561020'Image1'.bottom == _TVStackingPosterView:0x7fcee051a1e0.bottom>
Make a symbolic breakpoint at UIViewAlertForUnsatisfiableConstraints to catch this in the debugger.
The methods in the UIConstraintBasedLayoutDebugging category on UIView listed in <UIKit/UIView.h> may also be helpful.
これまで Swift や Objective-C を使用したことがないことに注意してください。だから私はここで完全に迷っています。どんな助けでも大歓迎です