iOS Masonry的簡單使用

2022-08-21 18:36:11 字數 1093 閱讀 4657

最近搭見面嘗試了下masonry,感覺挺不錯的,比手寫frame快多了,又避免了storyboard和xib的複雜約束。

這是效果圖 ps:以前看到這樣的就愁死了,各種計算座標,用masonry分分鐘的事。

//故障記錄

[errorrecordingbtn mas_makeconstraints:^(masconstraintmaker *make) ];

//裝置狀態

[equipmentstatebtn mas_makeconstraints:^(masconstraintmaker *make) ];

//遠端控制

[remotecontrolbtn mas_makeconstraints:^(masconstraintmaker *make) ];

//裝置曲線圖

[equipmentgraphbtn mas_makeconstraints:^(masconstraintmaker *make) ];

//使用說明

[guidebtn mas_makeconstraints:^(masconstraintmaker *make) ];

}@end

iOS Masonry使用詳解

1 magicnumber autoresizingmask autolayout 以上是純手寫 所經歷的關於頁面布局的三個時期 那如何快速的上手autolayout呢?說實話 當年ios6推出的同時新增了autolayout的特性 我看了一下官方文件和demo 就立馬拋棄到一邊了 因為實在過於的繁...

vcbuild的簡單使用

vcbuild 命令列 更新 2007 年 11 月 vcbuild 工具使用以下命令列語法來生成 visual c 專案和解決方案。複製 vcbuild options project solution config all 標誌 options生成選項。有關更多資訊,請參見 vcbuild 選項...

QList的簡單使用

qlistlist list 1 2 3 4 5 6 7 8 qlist的插入 voidinsert int i,const t value 在qlist其中某個位置插入value,假如沒 宣告i i 預設size 及在最後插入value iteratorinsert iterator before...