I would like to add a vertical slider to my cocoa menulet application. Just like the vertical slider in the system volume menulet. How do I add this using Interface Builder? And if not with Interface Builder then how?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This is the sort of thing that will have to be done programmatically (as far as I’m aware). You can create the slider in interface builder and make it vertical and have an outlet to it and all that. You can also create the
NSMenuItemand theNSMenuin Interface Builder as well, but you’ll have to embed the slider in the menuitem through code. That sort of thing can’t be done in IB.However, from there it’s pretty straightforward:
Don’t forget to hook up the target/action mechanism of the slider to whomever is supposed to handle the sliding.