0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

buttonを丸角に!

0
Posted at

SwiftにおけるButtonの装飾についての備忘録

Swiftにおいてcss的な役割をするものは何だろうと思い、調べた結果を以下に記します。

ViewController.swift

import UIKit

class ViewController: UIViewController {

    @IBOutlet weak var nextButton: UIButton!
    
    override func viewDidLoad() {
        super.viewDidLoad()
        
        nextButton.layer.cornerRadius = 20 //ここで丸角を指定
    }
}

・buttonの名前をnextButtonとしました。

結果

スクリーンショット 2020-02-04 23.45.39.png

以上になります、ご参考までに。。。

0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?