View Single Post
Old 09-28-2002, 01:20 PM   #15
Arista
TimerMod Creator
 
Arista's Avatar
 
Join Date: Aug 2002
Posts: 292
Interface Author - Click to view interfaces
Post Friends Window, Tabs, and Stuff...

Edit (9/16): As of today's patch, the friends window now supports tabs, so the timer can now use the friends window.

From the looks of the replies so far, lots of folks are probably wondering, or will wonder, about the following:

1) Can this new timer be used in the friends window?
2) Can this timer be put on a separate tab in another window that already uses tabs?

The answer to both of these questions is "no", and both are due to the same reason: this mod uses tabs. It cannot be used in the friend's window because the friends window does not support tabs, and it cannot be put on a separate tab in another window that uses tabs because tabs cannot be nested.

By now, I'm sure most of you are wondering, "this mod doesn't look like it has tabs" or "why does this mod need to use tabs". I'll try to answer those here, please bear with me:

In my first prototype of a "slider" style timer (posted in this thread), I used an actual slider element (like the kind you'll find in the options window). The main problem with this approach is that the slider granularity is really bad. What I mean is, you can't position it exactly where you want it, because there are only a few valid positions along the bar. Other sliders that are hard-coded into the game to represent specific values had reasonable granularity, but add a dummy slider that doesn't do anything, and it'll have bad granularity.

In order to fix the granularity problem, I had to move away from actual slider elements altogether. Instead, I used a horizontal scroll bar, and made it "look" like a slider. That's right folks, that slider is actually the middle part of a horizontal scroll bar. Most importantly, this approach has the benefit of really good granularity (you can drag and position the "slider" wherever you want). It also has the side benefit of having directional buttons that can be used.

Getting a working scroll bar into the mod is a bit tricky. Of the "scrollable" elements (not counting windows themselves), the tab page is the only one that lets you control the size of the scrollable area. The list box and STML box, for instance, cannot be populated by a mod, so the scroll bar will not become active. So, in each timer, there is a transparent tab page overlay that houses the horizontal scroll bar.

The width of the scrollable area is controlled by putting a blank, dummy label element on the tab page, and setting its size. By adjusting this width, I can vary the speed at which the scroll bar moves when the < and > buttons are pressed. I've included this as a configurable option in the XML generator.

As a final (slightly unrelated) note, I've noticed that since the last patch, real slider elements no longer work in the friends window (the friends window version of my original prototype stopped working). Therefore, the friends window will not allow sliders of either type: "real" sliders, or "fake" scroll-bar sliders housed in a tab page. Even if it did allow real slider elements (which it doesn't appear to), I'm sticking to the scroll-bar slider, because it gives much better granularity.

Whew... that was a long one. Hope this clears some things up.
__________________
Arista
Former Enchanter of The Seventh Hammer
TimerMod - Timer Utility for EverQuest UI

Arista is offline