Skip to content

Instantly share code, notes, and snippets.

@mayoff
Created January 12, 2016 16:41
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mayoff/b1a09e00b360f3b2a0ef to your computer and use it in GitHub Desktop.
Save mayoff/b1a09e00b360f3b2a0ef to your computer and use it in GitHub Desktop.
Map view inside scroll view with screen edge available for paging
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="9531" systemVersion="15C50" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" useTraitCollections="YES" initialViewController="BYZ-38-t0r">
<dependencies>
<deployment identifier="iOS"/>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="9529"/>
</dependencies>
<scenes>
<!--View Controller-->
<scene sceneID="tne-QT-ifu">
<objects>
<viewController id="BYZ-38-t0r" sceneMemberID="viewController">
<layoutGuides>
<viewControllerLayoutGuide type="top" id="y3c-jy-aDJ"/>
<viewControllerLayoutGuide type="bottom" id="wfy-db-euE"/>
</layoutGuides>
<view key="view" contentMode="scaleToFill" id="8bC-Xf-vdC">
<rect key="frame" x="0.0" y="0.0" width="1200" height="600"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<subviews>
<scrollView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" pagingEnabled="YES" translatesAutoresizingMaskIntoConstraints="NO" id="5JE-Wk-bF7">
<rect key="frame" x="0.0" y="0.0" width="1200" height="600"/>
<subviews>
<view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="SAd-1h-3aI" userLabel="MapHolder">
<rect key="frame" x="0.0" y="0.0" width="400" height="600"/>
<subviews>
<mapView clipsSubviews="YES" multipleTouchEnabled="YES" contentMode="scaleToFill" misplaced="YES" mapType="standard" translatesAutoresizingMaskIntoConstraints="NO" id="gr5-5k-VnZ">
<rect key="frame" x="0.0" y="0.0" width="400" height="600"/>
</mapView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="gr5-5k-VnZ" firstAttribute="leading" secondItem="SAd-1h-3aI" secondAttribute="leading" id="P0A-uS-4tb"/>
<constraint firstAttribute="bottom" secondItem="gr5-5k-VnZ" secondAttribute="bottom" id="QEd-xV-GBc"/>
<constraint firstItem="gr5-5k-VnZ" firstAttribute="top" secondItem="SAd-1h-3aI" secondAttribute="top" id="by6-eh-IJn"/>
</constraints>
</view>
<view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="np6-4l-y9h" userLabel="Pink">
<rect key="frame" x="400" y="0.0" width="400" height="600"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="Page 2" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="nas-eg-Hrr">
<rect key="frame" x="168" y="289" width="53" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" red="0.99919813869999996" green="0.79837877270000002" blue="0.94132425559999999" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstItem="nas-eg-Hrr" firstAttribute="centerY" secondItem="np6-4l-y9h" secondAttribute="centerY" id="OAM-dI-wUy"/>
<constraint firstItem="nas-eg-Hrr" firstAttribute="centerX" secondItem="np6-4l-y9h" secondAttribute="centerX" id="mzr-cK-ftm"/>
</constraints>
</view>
<view contentMode="scaleToFill" misplaced="YES" translatesAutoresizingMaskIntoConstraints="NO" id="010-Bh-qi2" userLabel="Green">
<rect key="frame" x="800" y="0.0" width="400" height="600"/>
<subviews>
<label opaque="NO" userInteractionEnabled="NO" contentMode="left" horizontalHuggingPriority="251" verticalHuggingPriority="251" misplaced="YES" text="Page 3" textAlignment="natural" lineBreakMode="tailTruncation" baselineAdjustment="alignBaselines" adjustsFontSizeToFit="NO" translatesAutoresizingMaskIntoConstraints="NO" id="YdF-KR-7jL">
<rect key="frame" x="173" y="289" width="54" height="21"/>
<fontDescription key="fontDescription" type="system" pointSize="17"/>
<color key="textColor" cocoaTouchSystemColor="darkTextColor"/>
<nil key="highlightedColor"/>
</label>
</subviews>
<color key="backgroundColor" red="0.7743756423" green="1" blue="0.84614103839999999" alpha="1" colorSpace="calibratedRGB"/>
<constraints>
<constraint firstItem="YdF-KR-7jL" firstAttribute="centerX" secondItem="010-Bh-qi2" secondAttribute="centerX" id="2lP-pw-v4O"/>
<constraint firstItem="YdF-KR-7jL" firstAttribute="centerY" secondItem="010-Bh-qi2" secondAttribute="centerY" id="Xse-Rv-D7q"/>
</constraints>
</view>
</subviews>
<constraints>
<constraint firstItem="SAd-1h-3aI" firstAttribute="leading" secondItem="5JE-Wk-bF7" secondAttribute="leading" id="3r1-dh-qrV"/>
<constraint firstItem="np6-4l-y9h" firstAttribute="leading" secondItem="SAd-1h-3aI" secondAttribute="trailing" constant="44" id="Hw6-Qv-a65"/>
<constraint firstAttribute="trailing" secondItem="010-Bh-qi2" secondAttribute="trailing" id="OQN-ey-jLP"/>
<constraint firstItem="np6-4l-y9h" firstAttribute="centerY" secondItem="SAd-1h-3aI" secondAttribute="centerY" id="PD4-GF-Wac"/>
<constraint firstAttribute="bottom" secondItem="SAd-1h-3aI" secondAttribute="bottom" id="b4u-6e-39a"/>
<constraint firstItem="010-Bh-qi2" firstAttribute="centerY" secondItem="SAd-1h-3aI" secondAttribute="centerY" id="mpx-jR-3Ou"/>
<constraint firstItem="np6-4l-y9h" firstAttribute="leading" secondItem="gr5-5k-VnZ" secondAttribute="trailing" id="nIC-gt-ewP"/>
<constraint firstItem="SAd-1h-3aI" firstAttribute="top" secondItem="5JE-Wk-bF7" secondAttribute="top" id="ogV-yO-z15"/>
<constraint firstItem="010-Bh-qi2" firstAttribute="leading" secondItem="np6-4l-y9h" secondAttribute="trailing" id="zMP-aR-nu0"/>
</constraints>
<variation key="default">
<mask key="constraints">
<exclude reference="nIC-gt-ewP"/>
</mask>
</variation>
</scrollView>
</subviews>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
<constraints>
<constraint firstItem="gr5-5k-VnZ" firstAttribute="width" secondItem="8bC-Xf-vdC" secondAttribute="width" id="4mf-90-pnO"/>
<constraint firstItem="5JE-Wk-bF7" firstAttribute="top" secondItem="8bC-Xf-vdC" secondAttribute="top" id="FWC-t7-b1v"/>
<constraint firstItem="np6-4l-y9h" firstAttribute="height" secondItem="8bC-Xf-vdC" secondAttribute="height" id="bad-kM-VeQ"/>
<constraint firstAttribute="trailing" secondItem="5JE-Wk-bF7" secondAttribute="trailing" id="cPm-89-QaM"/>
<constraint firstItem="wfy-db-euE" firstAttribute="top" secondItem="5JE-Wk-bF7" secondAttribute="bottom" id="iVF-hc-0wQ"/>
<constraint firstItem="5JE-Wk-bF7" firstAttribute="leading" secondItem="8bC-Xf-vdC" secondAttribute="leading" id="mUK-6f-eD8"/>
<constraint firstItem="np6-4l-y9h" firstAttribute="width" secondItem="8bC-Xf-vdC" secondAttribute="width" id="mW0-Ef-hTT"/>
<constraint firstItem="SAd-1h-3aI" firstAttribute="width" secondItem="8bC-Xf-vdC" secondAttribute="width" constant="-44" id="tno-SX-AYr"/>
<constraint firstItem="SAd-1h-3aI" firstAttribute="height" secondItem="8bC-Xf-vdC" secondAttribute="height" id="toJ-Du-VcW"/>
<constraint firstItem="010-Bh-qi2" firstAttribute="width" secondItem="8bC-Xf-vdC" secondAttribute="width" id="uWP-jH-Im1"/>
<constraint firstItem="010-Bh-qi2" firstAttribute="height" secondItem="8bC-Xf-vdC" secondAttribute="height" id="wIj-Zd-FhA"/>
</constraints>
</view>
<freeformSimulatedSizeMetrics key="simulatedDestinationMetrics"/>
<size key="freeformSize" width="1200" height="600"/>
</viewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="dkx-z0-nzr" sceneMemberID="firstResponder"/>
</objects>
<point key="canvasLocation" x="-1451" y="-1894"/>
</scene>
</scenes>
</document>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment