Skip to content

lekha-mishra/Draw-Shapes-iOS

Repository files navigation

DrawShapes-SwiftUI

Swift

About

A multi-platform app for creating shapes scaled to a Map Area using pure SwiftUI.


Contents

Introduction

We can easily draw shapes by simply giving their position and dimensions. For instance:

  1. Drawing a path simply requires the start position and the end position of the path
  2. Drawing a circle requires the center position and the radius of the circle
  3. Drawing a recatngle requires drawing 4 paths accordingly.

In this project, we create basic shapes scaled to a map. The shapes will be positioned at a particular position with respect to the map.

Here is a quick preview of the app
Mac
Saksham10

iOS
ezgif com-gif-maker (5)

Getting Started

This app is based on MVVM architecture. To set up an MVVM architecture, the project code has been divided into:

  1. Models
  2. Views
  3. ViewModels

The Views and ViewModels are kept together and the models are kept separate for ease of code.

Screenshot 2022-05-16 at 6 55 23 PM

Creating the input view

Draw Line

Draw Circle

Draw Rectangle

Delete Shapes

Scaling

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages