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
0
votes
0 answers

Render bug with NSSlider within NSPopover in dark mode

Is it me or there is an bug with NSSlider when it is a subview of an NSPopover view? Here's the code I use: popover = NSPopover.new; popover.contentViewController = NSViewController.new; NSView *view = [[NSView alloc]…
jeanlain
  • 382
  • 1
  • 3
  • 13
0
votes
2 answers

NSTimer - NSSlider

I have a NSTimer and a NSSlider in my app. How do I make, that the time interval of the timer would respond instantly to the slider value? For now it responds just at the beginning. Once the timer is already fired, it doesn't respond any…
Damijan
  • 183
  • 1
  • 2
  • 7
0
votes
3 answers

How to set NSSlider value in a NSToolbar - Swift Cocoa + Storyboard

I am quite new to Swift programming and I am trying to set a slider min, max and value in a NSToolbar. As an hypothetical exemple, I have a list of client and I want to use the slider in the toolbar to select a client data page. I will firt to…
S Lareau
  • 159
  • 1
  • 5
0
votes
1 answer

NSSlider custom subclass - how to maintain the link between the knob position and user interaction?

Trying to create a custom NSSlider. Overriding the drawKnob() method of the NSSliderCell changes the knob's appearance but doing this somehow disconnects the link between the knob's position and user interactions with the slider. In the objective C…
chemFour
  • 140
  • 7
0
votes
1 answer

setHidden with NSSlider doesn't work - Objective C

Hy guys, I'm new at ObjC and I'm still learning; [sliderContrast setHidden:YES] (i also used slider.hidden = YES) doesn't make the slider invisible, instead it works fine with textfields. Do you know why? I've also tried using property and…
0
votes
1 answer

mouseDown event on NSSlider

I have hit a bit of a wall and would really appreciate some help. I have an NSSlider that I am using to control the jog speed of a QTMovie. I want the rate of the video to playback according to the slider value. This is easy to do. The problem is…
adamteale
  • 940
  • 2
  • 12
  • 27
0
votes
1 answer

How to change NSSlider tickmarks color?

I know should change the function drawTickMarks,but what should I do to change tickmarks color?
Txink
  • 3
  • 2
0
votes
2 answers

Can't pass value from FirstVC to SecondVC using segue

I have two ViewControllers connected via Show segue. I need to pass NSSlider's value from ViewController to SecondViewCotroller. So, moving slider in ViewController a variable updates in SecondViewController. How to update a value of imagesQty…
Andy Jazz
  • 49,178
  • 17
  • 136
  • 220
0
votes
0 answers

NSSlider object crashes code when it's moved on view

I've created an NSViewController with corresponding XIB in IB. FWIW, I have the following window/view hierarchy: class RxDemoController: NSWindowController { @IBOutlet weak var statusPaneView: NSView! @IBOutlet weak var annunciatorPaneView:…
rawhide
  • 49
  • 4
0
votes
1 answer

Reuse a value from NSSlider in variable

I have a little problem but I can't figured out ... I code a sort a Shutdown countdown and I need to re-use the variable name "x" in the following code : @IBAction func valueChange(sender: NSSlider) { let x = sender.intValue …
Pablo Clsn
  • 13
  • 1
  • 6
0
votes
1 answer

Faulty drawings in Cocoa with CoreGraphics at my custom NSSlider

I have to redesign some controls. There is no Problem with NSButton, but NSSlider has drawing errors while I hold the mouse and move the knob around. If I release the mouse, it draws correctly. This is the drawing code (my class inherits from…
0
votes
1 answer

Ask NSSlider if the user still has the mouse button pressed? (swift)

Hi I'm implementing a subclass of NSSlider and NSSliderCell in swift, I would like to check/retrieve the _scFlags.isPressed property from NSSliderCell, I found that there is a 'hack' in Objective-C to do it when calling from another class (which is…
gbdavid
  • 1,639
  • 18
  • 40
0
votes
2 answers

Sending in values in a NSTextField: objective c

Ok, so I have an NSTextField and an NSSlider. In interface builder, I got the float value from the NSSlider to go into the NSTextField. BUT, I need a button that sends the text from the text field in so I can get the value in my code. That text…
objectiveccoder001
  • 2,981
  • 10
  • 48
  • 72
0
votes
1 answer

Creating control as a child of another control

ALL, I am trying to learn Cocoa programming and am stumbled on the following: It seems that every resource including SO says that in order to use labels with NSSlider one needs to create those labels as a child of the panel/dialog/Main Window where…
Igor
  • 5,620
  • 11
  • 51
  • 103
0
votes
1 answer

NSSlider labels

ALL, I couldn't find anything in the Cocoa documentation about making labels for some NSSlider values. Is this functionality does not exist or I am missing something? If this is not exist how do place the labels for the vertically placed NSSlider…
Igor
  • 5,620
  • 11
  • 51
  • 103