Quinn-Curtis Forums
Quinn-Curtis Forums
Home | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Tools for Java
 QCRTGraph for Java
 RTControlScrollBar min value

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

Screensize:
UserName:
Password:
Format Mode:
Format: BoldItalicizedUnderlineStrikethrough Align LeftCenteredAlign Right Horizontal Rule Insert HyperlinkInsert EmailInsert Image Insert CodeInsert QuoteInsert List
   
Message:

* HTML is OFF
* Forum Code is ON
Smilies
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Clown [:o)]
Black Eye [B)] Eight Ball [8] Frown [:(] Shy [8)]
Shocked [:0] Angry [:(!] Dead [xx(] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
   

T O P I C    R E V I E W
chippr Posted - 04 Sep 2008 : 13:56:29
When a RTControlScrollBar I'm using is at it's farthest rightmost point, and I do a getRTValue(), it is returning 10.0 rather than 0.0. When I do a getRTMinimum() it returns 0.0. Am I doing something wrong?

Thanks
7   L A T E S T    R E P L I E S    (Newest First)
chippr Posted - 04 Sep 2008 : 17:04:46
Yeah I had the same theory. I just assume the min is 10 now...
quinncurtis Posted - 04 Sep 2008 : 16:57:07
It appears that the entire width of the JScrollBar is initialized 0-100 (or whatever min-max you choose). But the left edge of the "thumb" is what value is returned. Since the left edge of the thumb is not at the maximum, it returns a value less than the maximum. It this case the thumb has a width 1/10 of the width of the scroll bar, so when the thumb is furthest to the right, the left edge is at 90. At least that's our theory.
quinncurtis Posted - 04 Sep 2008 : 16:36:54
We had it wrong. Though it does seem counter-intuitive for horizontal scroll bars. The minimum is on the right. I think someone inverted it because we wanted vertical scroll bars, which is what we use 90% of the time, to have their maximum value at the top position.

The underlying JScrollbar control, when initialized for a range of 0 to 100, seems to return a value of 90 when at the maximum. So our software uses that value in the calculation, which when inverted results in the 10. I don't know why but there is probably some explanation out there on the web. We will have to look into it.
chippr Posted - 04 Sep 2008 : 15:50:30
I meant the "tickfrequency" not the "smallchange" arg
chippr Posted - 04 Sep 2008 : 15:48:54
Also in your polygraph example, you set RTValue to 100 for the time axis control scroll bar and at least when I run your demo the slider starts at the left most position. Maybe the 10 comes from the "smallchange" arg I'm using in the constructor?
chippr Posted - 04 Sep 2008 : 15:30:09
Hmmmmm....When I set RTValue of my scrollbar to zero it moves it all the way to the right. When I print the values out, the farthest left is 100 and right 10. Maybe it's because I'm using the old 1.4 version?

quinncurtis Posted - 04 Sep 2008 : 15:24:02
Maybe we are missing something.
When a scroll bar is at the rightmost position, it is at its maximum value, which in your case is 10.0. When it is at the leftmost position, it is at its mimimum value, or 0.0 in your case. We don't know why you are expecting the opposite.

Quinn-Curtis Forums © 2000-2018 Quinn-Curtis, Inc. Go To Top Of Page
Powered By: Snitz Forums 2000 Version 3.4.07