{"action":"created","issue":{"url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/192","repository_url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView","labels_url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/192/labels{/name}","comments_url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/192/comments","events_url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/192/events","html_url":"https://github.com/kishikawakatsumi/SpreadsheetView/issues/192","id":329858318,"node_id":"MDU6SXNzdWUzMjk4NTgzMTg=","number":192,"title":"Can't draw a line in this Cell","user":{"login":"xiaoruiling","id":8361817,"node_id":"MDQ6VXNlcjgzNjE4MTc=","avatar_url":"https://avatars3.githubusercontent.com/u/8361817?v=4","gravatar_id":"","url":"https://api.github.com/users/xiaoruiling","html_url":"https://github.com/xiaoruiling","followers_url":"https://api.github.com/users/xiaoruiling/followers","following_url":"https://api.github.com/users/xiaoruiling/following{/other_user}","gists_url":"https://api.github.com/users/xiaoruiling/gists{/gist_id}","starred_url":"https://api.github.com/users/xiaoruiling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xiaoruiling/subscriptions","organizations_url":"https://api.github.com/users/xiaoruiling/orgs","repos_url":"https://api.github.com/users/xiaoruiling/repos","events_url":"https://api.github.com/users/xiaoruiling/events{/privacy}","received_events_url":"https://api.github.com/users/xiaoruiling/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2018-06-06T13:03:52Z","updated_at":"2018-06-15T02:19:29Z","closed_at":null,"author_association":"NONE","body":"## Expected Behavior\r\nI want to draw a line on the cell, but it doesn't show\r\n\r\n`\r\noverride func draw(_ rect: CGRect) {\r\n\r\n    guard let context = UIGraphicsGetCurrentContext() else { return }\r\n\r\n    let path = CGMutablePath()\r\n\r\n    path.move(to: CGPoint(x:10, y:0))\r\n\r\n    path.addLine(to:CGPoint(x:10, y:56))\r\n\r\n    context.addPath(path)\r\n\r\n    context.setLineWidth(10)\r\n\r\n    context.setStrokeColor(UIColor.red.cgColor)\r\n\r\n    context.strokePath()\r\n\r\n  }\r\n`\r\nThe code is correct that cells inherited from the UItableViewCell display a 10-pixel straight line, but cells inherited from SpreadsheetView do not display correctly\r\n"},"comment":{"url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/comments/397493776","html_url":"https://github.com/kishikawakatsumi/SpreadsheetView/issues/192#issuecomment-397493776","issue_url":"https://api.github.com/repos/kishikawakatsumi/SpreadsheetView/issues/192","id":397493776,"node_id":"MDEyOklzc3VlQ29tbWVudDM5NzQ5Mzc3Ng==","user":{"login":"xiaoruiling","id":8361817,"node_id":"MDQ6VXNlcjgzNjE4MTc=","avatar_url":"https://avatars3.githubusercontent.com/u/8361817?v=4","gravatar_id":"","url":"https://api.github.com/users/xiaoruiling","html_url":"https://github.com/xiaoruiling","followers_url":"https://api.github.com/users/xiaoruiling/followers","following_url":"https://api.github.com/users/xiaoruiling/following{/other_user}","gists_url":"https://api.github.com/users/xiaoruiling/gists{/gist_id}","starred_url":"https://api.github.com/users/xiaoruiling/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/xiaoruiling/subscriptions","organizations_url":"https://api.github.com/users/xiaoruiling/orgs","repos_url":"https://api.github.com/users/xiaoruiling/repos","events_url":"https://api.github.com/users/xiaoruiling/events{/privacy}","received_events_url":"https://api.github.com/users/xiaoruiling/received_events","type":"User","site_admin":false},"created_at":"2018-06-15T02:19:29Z","updated_at":"2018-06-15T02:19:29Z","author_association":"NONE","body":"`\r\n\r\n     class HourCell: Cell {\r\n        let label = UILabel()\r\n\r\n       override init(frame: CGRect) {\r\n        super.init(frame: frame)\r\n        label.frame = bounds\r\n\r\n        label.autoresizingMask = [.flexibleWidth, .flexibleHeight]\r\n        label.backgroundColor = UIColor.green\r\n        label.font = UIFont.systemFont(ofSize: 12)\r\n        label.textColor = .white\r\n        label.textAlignment = .center\r\n        label.numberOfLines = 2\r\n\r\n         addSubview(label)\r\n      }\r\n\r\n       required init?(coder aDecoder: NSCoder) {\r\n          super.init(coder: aDecoder)\r\n       }\r\n  \r\n     override func draw(_ rect: CGRect) {\r\n      guard let context = UIGraphicsGetCurrentContext() else { return }\r\n      debugPrint(\"\\(context)\")\r\n      let path = CGMutablePath()\r\n      path.move(to: CGPoint(x:10, y:0))\r\n      path.addLine(to:CGPoint(x:10, y:100))\r\n      context.addPath(path)\r\n      context.setLineWidth(10)\r\n      context.setStrokeColor(UIColor.red.cgColor)\r\n      context.strokePath()\r\n        }\r\n      }\r\n`\r\n\r\nyou can put this code replace the  example of HourCell in Timetable , and HourCell can not show a red line  "}}
{"actor":{"display_login":"xiaoruiling"}}