強火で進め

このブログではプログラム関連の記事を中心に書いてます。

iPhone/iPad で C# のプログラムが出来るアプリ「Continuous」

アプリ画面

画面構成はこんな感じです。



同梱のサンプル

チップの計算アプリ


似顔絵作成アプリ


マップアプリ


テキスト一覧表示




お絵描きアプリ


iOSAPI コール

iOSAPI を呼ぶことも可能です。呼び出し方はマップアプリを参考にすると良いでしょう。
マップアプリは以下の様なコードで作られています。

//
// Map Example
//
// Displays a point on a map
//
// Experiments:
// 1. Change the coordinate to your home
// 2. Add more pins
// 3. Change the map type to a satellite view
//

using System;

using UIKit;
using CoreGraphics;
using CoreLocation;
using MapKit;

// Create a view that displays the map
var mapView = new MKMapView (new CGRect(0,0,320,320));

// Note a 2D coordinate to display
var coord = new CLLocationCoordinate2D(
    47.6062, -122.3321);

// Place a pin at the coordinate
var pin = new MKPointAnnotation() {
    Coordinate = coord
};
mapView.AddAnnotations(pin);

// Center the map
mapView.SetRegion(MKCoordinateRegion.FromDistance(coord, 2000, 2000), false);

// Display
var v = new UIView();
var Main = mapView;