Re: SMDoubleSlider usability on GNUstep

2018-02-20 Thread Yavor Doganov
David Chisnall wrote: > Here’s a little test program that finds out: Thanks, that was really helpful. And it's not surprising that on GNUstep your test program causes infinite recursion here: > 2018-02-20 14:46:39.917 a.out[85231:11731363] -floatValue called > The correct fix is probably: [...]

Re: SMDoubleSlider usability on GNUstep

2018-02-20 Thread Fred Kiefer
David‘s analysis sounds correct to me. I will change that code when I am back home next week. Fred Unterwegs > Am 20.02.2018 um 15:55 schrieb David Chisnall : > >> On 20 Feb 2018, at 14:30, Yavor Doganov wrote: >> >> I think this condition is always false. _cell.has_valid_object_value >> is

Re: SMDoubleSlider usability on GNUstep

2018-02-20 Thread David Chisnall
On 20 Feb 2018, at 14:30, Yavor Doganov wrote: > > I think this condition is always false. _cell.has_valid_object_value > is NO and _object_value is nil. So it jumps to NSCell.m:269 and > SMDoubleSliderCell's -stringValue is called which calls -stringHiValue > which in turn calls -doubleHiValue

Re: SMDoubleSlider usability on GNUstep

2018-02-20 Thread Yavor Doganov
David Chisnall wrote: > This then checks whether the object responds to -doubleValue, and if > it does calls that: > > https://github.com/gnustep/libs-gui/blob/master/Source/NSCell.m#L265 > > Unfortunately, in this case, it appears that the object value is > self, so you get infinite recursion.

Re: SMDoubleSlider usability on GNUstep

2018-02-20 Thread David Chisnall
On 20 Feb 2018, at 12:33, Yavor Doganov wrote: > > #1 0x777d2015 in -[NSCell doubleValue] (self=0x562ef7f0, > _cmd=) at NSCell.m:269 > #2 0x7778362a in -[NSActionCell doubleValue] (self=0x562ef7f0, > _cmd=) at NSActionCell.m:187 > #3 0xbfdb in -[SMDoubleSl

SMDoubleSlider usability on GNUstep

2018-02-20 Thread Yavor Doganov
As part of my ongoing effort to port the latest Lynkeos release to GNUstep, I have encountered an issue with a custom class which is a subclass of NSSlider/NSSliderCell. The original code is available here [1] as .dmg only, I used 7z to unpack it. [1] http://developer.snowmintcs.com/controls/smdo