EQ2Interface.com
Search Downloads


Go Back   EQ2Interface > Developer Discussion > XML Modification Help & Info

Reply
 
Thread Tools Search this Thread Display Modes
  #1  
Unread 12-06-2010, 05:25 PM
Draven_Caine's Avatar
Draven_Caine Draven_Caine is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Oct 2009
Server: Unrest
Posts: 155
Default On content change

Greetings,
I looked through the forum and didn't find anything about this so here I am again.

Is there a way to reset list to bottom (or top) on content change?

Example: My target window icons show only 2 rows, now if a 3rd row is present it moved the icon list up so that the last row is visible. I was able to do this in VG so wasn't sure if I could here.

Thanks,
Draven
Reply With Quote
  #2  
Unread 12-06-2010, 05:45 PM
Drumstix42's Avatar
Drumstix42 Drumstix42 is offline
A Griffon
Featured
 
Join Date: Oct 2004
Server: Antonia Bayle
Posts: 3,287
Default

If you mean move it up so that you would now see row 2 and 3, but row 1 would be hidden, it might be possible, but I'm not sure if you can put the target effects inside another page or not.

You could try putting it inside a page, and using the ScrollExtent property. The scrollextent is used to return the actual width/height of the elements in a page, rather than just the visible area (normal height/width).

It'd probably take a lot of fooling though, since there's no way to trigger something when a random element's property changes.
__________________
"I'm afraid you're guilty of thought-crime. Don't bother getting the door, we'll let ourselves in..."
<Donate to DrumsUI> < [DrumsUI] Updater > < [DrumsUI] Full Interface> < Drumstix42 on Twitch.tv
>
Reply With Quote
  #3  
Unread 12-06-2010, 06:00 PM
Draven_Caine's Avatar
Draven_Caine Draven_Caine is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Oct 2009
Server: Unrest
Posts: 155
Default

Ahh, i see. VG had a variable for it so eq2 doesn't so its "break it and see" time hehe

With the scroll extent, will it refocus the visible area on the bottom or top? I can mess with it and see what i can come up with. In a raid or big debuff group it almost breaks my target window and ... I ... Have ... Put ... Too ... Work ... Into ... IT!!

Thanks,
Draven
Reply With Quote
  #4  
Unread 12-07-2010, 10:56 AM
Landiin Landiin is offline
Slayer of clock cycles
This person is a EQ2Map developer.
Featured
 
Join Date: Nov 2004
Server: Oasis
Posts: 3,464
Default

There really isn't much you can do with the Iconbank object other then how it sorts the icon objects. It'ed be nice if it had a index property but it don't so all you can do is ask Rothgar and maybe he can find the time although I doubt it.
__________________
Landiin's EQ2MAP Updater Discussion Download
Reply With Quote
  #5  
Unread 02-11-2011, 08:59 PM
Draven_Caine's Avatar
Draven_Caine Draven_Caine is offline
A Griffon
Interface Author - Click to view interfaces
 
Join Date: Oct 2009
Server: Unrest
Posts: 155
Default

OK, i am trying to do this to a diffrent window since i couldnt really do it to the window i was after now here is the plan boys and girls

Its the maintained windows:
  • I have 10 buffs in my window
  • Only 8 of these 10 buffs are visible due to the size of the window. (user resiable)
  • how do i get it to show the last 8 buffs in the list instead of the first 8?

Thanks,
Draven
Reply With Quote
  #6  
Unread 02-11-2011, 11:59 PM
Zonx's Avatar
Zonx Zonx is offline
A Green Troll
This person is a EQ2Map developer.
Featured
 
Join Date: Dec 2004
Server: Blackburrow
Posts: 2,221
Default

The ScrollLocation property controls the x,y offset of the viewable area.

To do what I think you're after (scroll the last visible icon into view) I'd do the following...

Note: Pseudo code... and you'll probably have to fiddle with the math to get the desired results, but this should give you a place to start. This assumes your volume page always flows left to right, top to bottom. If instead you are using the edge detection variable flow feature used in the default Maintained window, you'll need to add code to determine the flow and adjust accordingly.

Give each icon page an OnShow script that does the following...

Cols = window.width / iconPage.width
Cols = int(Cols + 0.5)
Rows = window.height / iconPage.height
Rows = int(Rows + 0.5)
LastRow = ceil(iconNumber / Cols)
RowDiff = LastRow - Rows
yOffset = RowDiff * iconPage.height
window.ScrollLocation = "0," ## yOffset

Also give each iconPage an OnHide script that does almost the same thing but subtracts the hidden icon...

LastIconNum = iconNumber -1
Cols = window.width / iconPage.width
Cols = int(Cols + 0.5)
Rows = window.height / iconPage.height
Rows = int(Rows + 0.5)
LastRow = ceil(LastIconNum / Cols)
RowDiff = LastRow - Rows
yOffset = RowDiff * iconPage.height
window.ScrollLocation = "0," ## yOffset

So in short you have scripts on all icons that adjust the scroll location to bring an icon into view if it was previously hidden. Likewise you have scripts on all icons to adjust the scroll location when a previously visible icon is hidden, to remove the now empty space by scrolling the prior visible icon into view.
Reply With Quote
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 01:26 PM.


Our Network
EQInterface | EQ2Interface | WoWInterface | LoTROInterface | ESOUI | MMOUI