cchen@sbcs.sunysb.edu (Chyouhwa Chen) (11/01/90)
Does anybody have any idea what I may be doing wrong with the form widget? I can only get its height to at most 32637 pixels. Everything has been working perfectly until I needed more real estate. I created its children fine, but when it is realized, it would only grow that high. So all the children locating lower than that magic number weren't exposed. Help! cchen@sbcs.sunysb.edu -----------------------
etaylor@wilkins.iaims.bcm.tmc.edu (Eric Taylor) (11/02/90)
32637 is very close to the maximum number a "short" can be. Shorts are used for various things such as Position. (Very unfortunate.) The authors of Xt got very hung up on types and used things like "short"'s when they thought that no one whould possibly ask for a number greater than 32637. I wish people would stop using "short" it always bites you in the ass eventually. -- Eric Taylor Baylor College of Medicine etaylor@wilkins.bmc.tmc.edu (713) 798-3776 -- Eric Taylor Baylor College of Medicine etaylor@wilkins.bmc.tmc.edu (713) 798-3776
toml@ninja.Solbourne.COM (Tom LaStrange) (11/02/90)
|> Does anybody have any idea what I may be doing wrong with |> the form widget? I can only get its height to at most |> 32637 pixels. Everything has been working perfectly until |> I needed more real estate. I created its children fine, |> but when it is realized, it would only grow that high. So |> all the children locating lower than that magic number |> weren't exposed. Help! Window dimensions are unsigned, but window coordinates are signed numbers which means that the largest possible positive coordinate will be 32637. It basically means you can create a much larger window than you can effectively use. -- Tom LaStrange Solbourne Computer Inc. ARPA: toml@Solbourne.COM 1900 Pike Rd. UUCP: ...!{boulder,sun}!stan!toml Longmont, CO 80501
converse@EXPO.LCS.MIT.EDU (11/02/90)
> The authors of Xt > got very hung up on types and used things like "short"'s when they thought that > no one whould possibly ask for a number greater than 32637. Look at the definition of the protocol request CreateWindow.
asente@adobe.com (Paul Asente) (11/02/90)
In article <2493@gazette.bcm.tmc.edu> etaylor@wilkins.iaims.bcm.tmc.edu (Eric Taylor) writes: > >32637 is very close to the maximum number a "short" >can be. Shorts are used for various things such as Position. >(Very unfortunate.) The authors of Xt got >very hung up on types and used things like "short"'s when they thought that >no one whould possibly ask for a number greater than 32637. I wish people >would stop using "short" it always bites you in the ass eventually. (Please put newlines into your messages) The decision that positions should be signed short values was not made in Xt, it was made in the protocol. If Xt had extended precision super extra long values for positions you still would not be able to use any more of the range than 16 signed bits worth. The decision made in the protocol was not perfect (since sizes are 16 bits unsigned but coordinates are 16 bits signed you can create a window with 75% of its area unusable (also known as "The Twilight Zone")) but choosing 16 bits over 32 was a tradeoff between memory and communication bandwidth costs vs. possible future hardware that could display humungous windows. The hardware still isn't around today; if you need more than 16 bits worth of positioning on current hardware you're not programming your application right. -paul asente asente@adobe.com ...decwrl!adobe!asente
av@kielo.uta.fi (Arto V. Viitanen) (11/02/90)
>>>>> On 1 Nov 90 18:02:17 GMT, toml@ninja.Solbourne.COM (Tom LaStrange) said:
Tom> Window dimensions are unsigned, but window coordinates are signed
Tom> numbers which means that the largest possible positive coordinate
Tom> will be 32637. It basically means you can create a much larger window
Tom> than you can effectively use.
But why 32637 ? xcalc says 2 ^ 15 -1 is 32767 ?
--
Arto V. Viitanen email: av@kielo.uta.fi
University Of Tampere, av@ohdake.cs.uta.fi
Finland
meo@rsiatl.UUCP (Miles ONeal) (11/04/90)
asente@adobe.com (Paul Asente) writes: >... The hardware still isn't around today; if you >need more than 16 bits worth of positioning on current hardware you're not >programming your application right. Thus, the magic of "scrollbars". At first, I was a bit miffed when I ran into the "limitation" of 16 bits. BUt that was purely a theortical, ivory tower type miffdom - the not-so-theoretical limits of my screen were far greater. In fact, it quickly became apparent that (as Paul notes) the solution was usually wrong if it led that way. Most users can't deal with too much data they can't see at one time (summaries are a separate issue - we're talking seeing only a small piece ofthe whole picture here. Secondly, even when you want to do something like this, you probably want more control anyway. Sure it's more effort, but if you set things up to pan via scrollbars, nobody's going to yell at you when it doesn't work with their setup of window manager, session manager, etc. Miles O'Neal {uunet | emory}!rsiatl!meo (home)
cjmchale@swift.cs.tcd.ie (11/05/90)
In article <AV.90Nov2094133@kielo.uta.fi>, av@kielo.uta.fi (Arto V. Viitanen) writes: >>>>>> On 1 Nov 90 18:02:17 GMT, toml@ninja.Solbourne.COM (Tom LaStrange) said: > > Tom> Window dimensions are unsigned, but window coordinates are signed > Tom> numbers which means that the largest possible positive coordinate > Tom> will be 32637. It basically means you can create a much larger window > Tom> than you can effectively use. > > But why 32637 ? xcalc says 2 ^ 15 -1 is 32767 ? Perhaps the window has a parent which is 30 pixels bigger than it's child. If the parent won't go past 32767 and insists on being 30 pixels bigger than the child then the child can only get to be 32737 pixels high. Which window might be 30 pixels taller than your window? How about the "title bar" which your window manager might put on your application. Then again, I could be speaking rubbish, in which case someone will correct me. Ciaran. -- Ciaran McHale "An inappropiate joke for every occasion" Department of Computer Science, Trinity College, Dublin 2, Ireland. Telephone: +353-1-772941 ext 1538 FAX: +353-1-772204 Telex: 93782 TCD EI email: cjmchale@cs.tcd.ie or cjmchale%cs.tcd.ie@cunyvm.cuny.edu My opinions are.