zoukankan      html  css  js  c++  java
  • Windows下Xamarin.iOS xib无法调整大小问题

    Windows下Xamarin.iOS xib无法调整大小问题

    开发环境windows10,Visual Studio 2017

    Simulated Metrics Size 选择Freeform,按道理此时xib中View应该可以自定义大小,但是实际上是不行的。

    使用代码编辑器打开xib文件,查看源码中有这样一行代码:<size key="freeformSize" width="414" height="736"/>,删除其中的width和height即可。

     1 <?xml version="1.0" encoding="UTF-8" standalone="no"?>
     2 <document type="com.apple.InterfaceBuilder3.CocoaTouch.XIB" version="3.0" toolsVersion="13771" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" colorMatched="YES">
     3     <dependencies>
     4         <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="13772"/>
     5         <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>
     6     </dependencies>
     7     <objects>
     8         <placeholder placeholderIdentifier="IBFilesOwner" id="-1" userLabel="File's Owner"/>
     9         <placeholder placeholderIdentifier="IBFirstResponder" id="-2" customClass="UIResponder"/>
    10         <view contentMode="scaleToFill" id="1">
    11             <rect key="frame" x="0.0" y="0.0" width="414" height="736"/>
    12             <autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
    13             <color key="backgroundColor" red="1" green="1" blue="1" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
    14             <freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
    15             <size key="freeformSize" width="414" height="736"/>
    16         </view>
    17     </objects>
    18     <resources>
    19         <image name="ITunesArtwork" width="512" height="512"/>
    20         <image name="ITunesArtwork@2x" width="512" height="512"/>
    21         <image name="photo.png" width="96" height="96"/>
    22     </resources>
    23 </document>
  • 相关阅读:
    枚举类型
    [ Java学习 ] “goto语句“ 和 “continue + 标号” 的不同待遇
    [ Java学习 ] 其他知识总结(重要)
    [ Java学习 ] Java变量以及内存分配(非常重要)
    [ Java学习 ] 包语句 package等语句的汇总整理
    [ Java学习 ] 破除思维定势之 C++ 和 Java 的差异 003
    P1601一道高精度的题
    啊哈,我又来了
    算了,有一道水题
    再水一道题
  • 原文地址:https://www.cnblogs.com/devin_zhou/p/8038434.html
Copyright © 2011-2022 走看看