Created
September 29, 2013 16:23
-
-
Save dastels/6753981 to your computer and use it in GitHub Desktop.
Sample iLisp code for using abutton
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (let ((w (.window *app*)) | |
| (b (UIButton/buttonWithType: UIButtonTypeSystem))) | |
| (.frame= b '((10 100) (100 44))) | |
| (.backgroundColor= b (UIColor/lightGrayColor)) | |
| (.setTitle:forState: b "Push Me" UIControlStateNormal) | |
| (.setTitleColor:forState: b (UIColor/blackColor) UIControlStateNormal) | |
| (.when b UIControlEventTouchUpInside | |
| (lambda (sender) | |
| (trace "click!"))) | |
| (.addSubview w b)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment