Questions tagged [nsslider]

NSSlider object belongs to Apple's class it displays a range of values. NSSlider can be used for volume control, colors selection, brightness adjust, etc.. It has continous and discrete modes.

An NSSlider object displays a range of values for something in the application. Sliders can be vertical or horizontal bars or circular dials. An indicator, or knob, notes the current setting. The user can move the knob in the slider’s bar—or rotate the knob in a circular slider to change the setting.

The NSSlider class uses the NSSliderCell class to implement its user interface.

NSSlider Class Reference.

85 questions
2
votes
1 answer

Let NSSlider move in other ways?

I am trying to figure out how to make a slide action without dragging. Usually when I want to change values using slider, I do either "leftClick anywhere on the slider field" or, continuously "leftClick the knob and drag it". What I would like to…
2
votes
1 answer

Setting the position/width of an NSSlider inside an NSMenuItem

I've got an NSMenu attached to an NSStatusItem, and inside that NSMenu I have a NSMenuItem for which I've set the view property to an NSSlider object. That works (it got me what I was after) almost. The result looks like this: NSSlider in an NSMenu…
Jim Rubenstein
  • 6,836
  • 4
  • 36
  • 54
2
votes
2 answers

Best strategy to handle incoming midi signal from MIDIReadProc in cocoa

I have to move some NSSlider by hardware midi controller, I have programmed a midi learn procedure to assign hardware cursor to NSSlider(sub class of), and up there it's all right. Inside MIDIReadProc, I handle moving NSSlider wich depends from…
tritono
  • 21
  • 3
1
vote
2 answers

Required NSSlider method (sliderDidMove) declaration not found on Apple's Developer Documentation

Working on a tutorial with a NSSlider. What I want: Moving the slider will show slider value in NSTextField. Tutorial explains that following method will show slider value in text field: - (IBAction)sliderDidMove:(id)sender { NSSlider *slider =…
user1010563
1
vote
1 answer

Loop for NSSlider

I am instituting a NSSlider into my project that needs to call different methods when moved up or down. So if it is moved up it will do one method, which is a AppleScript, and the opposite if moved in the other direction, another AppleScript. Would…
Stevezie
  • 111
  • 2
  • 11
1
vote
1 answer

Using NSLevelIndicators with NSSliders Objective-C

I'm learning Objective-c and made a little practice app to take input from an NSSlider and set the level to it. However, I would like to know if there is any way to make the level indicator update with the dragging of the slider. Currently, it only…
1
vote
2 answers

control NSSlider with arrows on NSMenu for a NSStatusItem- Objective-C/Cocoa

I would like to create a status item with a vertical slider in it, much like the sound control provided by Apple. My question is: how do I make it react to the up/down arrow keys, just like the slider in the sound menu? I have tried to create a…
Alex
  • 5,009
  • 3
  • 39
  • 73
1
vote
1 answer

Changing the content of a NSTextField via code when it's focused / gets edited by the user

I have a NSSlider which updates the content of an NSTextField. So far so good. It works as long as the NSTextField isn't focused or gets edited by the user (typing or staying blank etc.). What I'm trying to get working is to force the update of the…
ghostrifle
  • 1,029
  • 1
  • 14
  • 24
1
vote
0 answers

show a spinner inside NSSlider's knob

I'd like to use NSSlider to control an ext. device. Because the ext. device is slow the slider shall display NSProgressIndicator WITHIN IT'S KNOB until the device achieves the value specified by the slider. But neither the bar nor the spinner are…
ClosedID
  • 619
  • 6
  • 12
1
vote
1 answer

Mac Custom NSSlider how to override tick mark drawing outside slider frame

I'm creating a custom NSSlider where I want to draw labels underneath each of the tick marks. I'm currently doing this in the custom NSSliderCell -(NSRect)rectOfTickMarkAtIndex however because the height of NSSlider is fixed, the label I'm drawing…
Tristan Warner-Smith
  • 9,631
  • 6
  • 46
  • 75
1
vote
0 answers

Create Interface Builder palette for exposeBinding

I followed my understanding of how to expose a property of an NSSlider subclass in Interface Builder but it is not showing up. I want to be able to bind the property in a viewcontroller through Interface Builder to track the movement of the…
G J
  • 341
  • 2
  • 7
1
vote
1 answer

How to animate NSSlider value change in Cocoa application using Swift

How do I animate NSSlider value change so it looks continuous? I tried using NSAnimation context private func moveSlider(videoTime: VLCTime) { DispatchQueue.main.async { [weak self] in NSAnimationContext.beginGrouping() …
adincebic
  • 91
  • 1
  • 8
1
vote
2 answers

iphone/ipad custom UISlider controller

Here i want to create a custom uislider which is similar to media player forward and backward ie programatically moving slider at a particular time interval. for example consider am having a video for this video i need to implement slider to…
nik
  • 2,289
  • 6
  • 37
  • 60
1
vote
3 answers

NSSlider event not firing

I have got an event on my NSSlider with this code: - (IBAction)optOndoorzichtigheidChange:(id)sender { NSUserDefaults* defaults = [NSUserDefaults standardUserDefaults]; NSString *opacity = [NSString…
icant
  • 878
  • 4
  • 10
  • 28
1
vote
1 answer

NSSlider: how to send value and action at the same time?

I thought it would be simple, but seemingly it´s not. I have a NSSlider from which the value I want to be shown in a label, like in this picture. With a setup as shown in this picture it´s working fine, using a binding takeIntValueFrom. Now I want…
Josch Hazard
  • 323
  • 3
  • 20