{"id":19847029,"url":"https://github.com/polidea/framelayout","last_synced_at":"2026-06-28T22:31:33.103Z","repository":{"id":33023842,"uuid":"36658888","full_name":"Polidea/FrameLayout","owner":"Polidea","description":"AutoLayout on frames. This repo has been moved to","archived":false,"fork":false,"pushed_at":"2015-09-25T08:19:21.000Z","size":240,"stargazers_count":1,"open_issues_count":3,"forks_count":0,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-02-12T00:18:19.195Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://github.com/Polidea/PLXFrameLayout","language":"Objective-C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Polidea.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2015-06-01T12:20:19.000Z","updated_at":"2015-09-25T08:17:31.000Z","dependencies_parsed_at":"2022-08-29T18:00:13.193Z","dependency_job_id":null,"html_url":"https://github.com/Polidea/FrameLayout","commit_stats":null,"previous_names":[],"tags_count":3,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Polidea%2FFrameLayout","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Polidea%2FFrameLayout/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Polidea%2FFrameLayout/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Polidea%2FFrameLayout/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Polidea","download_url":"https://codeload.github.com/Polidea/FrameLayout/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241226031,"owners_count":19930325,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-12T13:13:15.410Z","updated_at":"2026-06-28T22:31:33.097Z","avatar_url":"https://github.com/Polidea.png","language":"Objective-C","funding_links":[],"categories":[],"sub_categories":[],"readme":"# FrameLayout\n\n---\n\nThis repo is deprecated. It has been moved to https://github.com/Polidea/PLXFrameLayout.\n\n---\n\n###Short Desciption\n**FrameLayout** is a small tool for positioning, sizing and arranging views without using CGRects. **FrameLayout** also provides sets of convinient read-write properties that extract/set discrete values from view's frame, like: width, height, minX/Y, maxX/Y.\n\n###How it works\n**FrameLayout** is defined as a category on `UIView` class. It contains set of methods to configure view's sizes and positions in relation to its superviews or other views. Under the hood all **FrameLayout** methods calculates and sets `view.frame` property.\n\n###Instalation\n\n#####Pods instalation\n\n1. Add the pod **FrameLayout** to your Podfile:\n\n\t```\n\tpod 'FrameLayout'\n\t```\n2. Run ```pod install``` from Terminal, then open your app's .xcworkspace file to launch yout IDE.\n\n3. Import the header file:\n \n\t```\n\t#import \"UIView+PLFrameLayout.h\"\n\t```\n\n#####Manual instalation\n1. Drag and drop `UIView+PLFrameLayout.h` and `UIView+PLFrameLayout.m`  to your project;\n2. In *File Inspector*, make sure that `UIView+PLFrameLayout.m` belongs to your app target;\n3. Add `#import UIView+PLFrameLayout.h` to your file.\n\n###Usage\nTo make sure that superview's frame is already set, you should place all methods from **FrameLayout** library in your view's ```-layoutSubviews``` method.\n\n\n###Examples\nAligning to top-left corner with 50 points margin:\n\n```\n- (instancetype)initWithFrame:(CGRect)frame {\n\tself = [super initWithFrame:frame];\n\tif (self) {\n\t\tUIView *view = [UIView new]; // Calls `initWithFrame:CGRectZero` by default.\n\t\t[self addSubviews:view];\n\t\tself.myView = view;\n\t}\n}\n\n- (void)layoutSubviews {\n\t[super layoutSubviews];\n\tself.myView.pl_size = CGSizeMake(70.0, 70.0);\n\t[self.myView pl_alignToSuperView:NSLayoutAttributeTop withMargin:50.0];\n\t[self.myView pl_alignToSuperView:NSLayoutAttributeLeft withMargin:50.0];\n}\n```\n\nFor more, see example app.\n\n###Contribution\n**Frame Layout** project is on early stage. Feel free to contribute by pull requests.\n\n###License\n**FrameLayout** is released under a MIT License. See LICENSE file for details.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolidea%2Fframelayout","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpolidea%2Fframelayout","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpolidea%2Fframelayout/lists"}