From the course: Cocoa with Swift 3 Essential Training

Unlock this course with a free trial

Join today to access over 22,400 courses taught by industry experts.

Slider controls

Slider controls

- [Instructor] Let's look at working with sliders. We're going to filter for a slider in the object library, and then click and drag a horizontal slider onto the screen. You can actually expand or contract the width of the slider by just dragging those handles. Note that there are other types of sliders in the object library. Horizontal, vertical, and circular. There's also this slider cell, which is for styling a slider, so, for now, we're not going to work with that. I do want to point out, however, that these three sliders use the same NSSlider class, and, in the attributes inspector they're nearly identical. So, just about everything that applies as we work with the horizontal slider should also apply to the vertical slider and the circular slider, as well. With the slider selected, let's go to the attributes inspector. In the slider section, you can see that you can change the style from linear to circular. Normally, I don't do that, because, if you change it to circular, and…

Contents