美文网首页
xcode打不开老项目的Main.storyboard文件

xcode打不开老项目的Main.storyboard文件

作者: 哪有猫不吃鱼 | 来源:发表于2021-10-10 11:29 被阅读0次

今天用xcoed打开非常老的项目时候一直转圈
后面发现是因为storyboard版本太老 当时的toolsVersion并没有Top Layout Guide和Bottom Layout Guide两个 所以导致打不开

一直打不开转圈圈

后面删了重装或者打开新建项目都可以打开Main和LaunchScreen

之后以xml的方式修改了两个文件中的这一段以后发现可以打开

<?xml version="1.0" encoding="UTF-8" standalone="no"?>

<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="13142" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" launchScreen="YES" useTraitCollections="YES" useSafeAreas="YES" colorMatched="YES" initialViewController="01J-lp-oVM">

    <dependencies>

        <plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="12042"/>

        <capability name="Constraints with non-1.0 multipliers" minToolsVersion="5.1"/>

        <capability name="Safe area layout guides" minToolsVersion="9.0"/>

        <capability name="documents saved in the Xcode 8 format" minToolsVersion="8.0"/>

    </dependencies>

之后排查以后发现主要是因为

toolsVersion="13142" 版本的原因导致了Main和LaunchScreen文件打不开

之前的工具版本为8150并不包含

Top Layout Guide和Bottom Layout Guide

相关文章

网友评论

      本文标题:xcode打不开老项目的Main.storyboard文件

      本文链接:https://www.haomeiwen.com/subject/kglholtx.html