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
  #7  
Unread 02-12-2011, 12:27 AM
gm9 gm9 is offline
gm10-1
Premium Member
EQ2Interface Super Mod
Featured
 
Join Date: Feb 2006
Posts: 6,479
Default

If you want to scroll why not just set MinimumScrollExtent?
__________________
P R O F I T U I ∙ R E B O R N [Auto-Updater] | [Portal] | [F.A.Q.] | [Support Forums]
~ Retired ~
If it does not work, you likely installed it incorrectly. Always try a clean install before reporting bugs.
Reply With Quote
  #8  
Unread 02-12-2011, 02:57 AM
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 to clarify basically i want this

Now:
------
|buff|
|buff|
|buff|
------
hidden
hidden

I want:
hidden
hidden
------
|buff|
|buff|
|buff|
------

SO basically right now if you have more buffs than the window hold its shows the first x number of buffs, what i want it to do is to show the bottom x number of buffs. This is exactly opposite of what the window does now.

This is helpful for temp buffs that I use on my main (defiler) if i have 10 buffs visible and I cast a ward as my 11th buff, i cant see it which is bad.

I hope this helps explain it a bit better.

Thanks,
Draven
Reply With Quote
  #9  
Unread 02-12-2011, 04:25 AM
Drumstix42's Avatar
Drumstix42 Drumstix42 is offline
A Griffon
Featured
 
Join Date: Oct 2004
Server: Antonia Bayle
Posts: 3,287
Default

You just need to turn the Scrollable option on for the VolumePage: UserScrollable="true"
__________________
"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
  #10  
Unread 02-12-2011, 04:28 AM
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

Yes i can make it scrollable but in battle scrollable isn't a good option ... for me anyways lol.

That is why i was looking for a automatic way to show the lasts buffs like my bad illustration lol,

Thanks,
Draven
Reply With Quote
  #11  
Unread 02-12-2011, 12:20 PM
gm9 gm9 is offline
gm10-1
Premium Member
EQ2Interface Super Mod
Featured
 
Join Date: Feb 2006
Posts: 6,479
Default

Quote:
Originally Posted by Draven_Caine View Post
Yes i can make it scrollable but in battle scrollable isn't a good option ... for me anyways lol.
why? just scroll the static buffs out of the way before you start battle and all you will see for the rest of the battle are your temporary buffs. that's how I always used to play anyway.
__________________
P R O F I T U I ∙ R E B O R N [Auto-Updater] | [Portal] | [F.A.Q.] | [Support Forums]
~ Retired ~
If it does not work, you likely installed it incorrectly. Always try a clean install before reporting bugs.
Reply With Quote
  #12  
Unread 02-12-2011, 02:14 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

Greetings,
Yes scrolling them out of the way before hand is an option but i was more looking for an automatic solution.

If the buffs automatically scroll than I wouldn't have to worry about remembering to scroll them out of the way to begin with. I personally think we shouldn't have to scroll them out of the way or alter Sony's code to make this happen seems a bit bad to not have your latest buff visible .. but that is just me i guess

Thanks,
Draven
Reply With Quote
  #13  
Unread 02-12-2011, 02:36 PM
Drumstix42's Avatar
Drumstix42 Drumstix42 is offline
A Griffon
Featured
 
Join Date: Oct 2004
Server: Antonia Bayle
Posts: 3,287
Default

You can only have 30 display at once no matter what you do. So if they're filled there's nothing you can do about it.

If you play with them expanded with all the info showing, then yeah 30 is a bit to show at once without scrolling.
__________________
"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
  #14  
Unread 02-12-2011, 03:09 PM
gm9 gm9 is offline
gm10-1
Premium Member
EQ2Interface Super Mod
Featured
 
Join Date: Feb 2006
Posts: 6,479
Default

Quote:
Originally Posted by Draven_Caine View Post
Greetings,
Yes scrolling them out of the way before hand is an option but i was more looking for an automatic solution.
Zonx posted how to do that above in case you missed it.
__________________
P R O F I T U I ∙ R E B O R N [Auto-Updater] | [Portal] | [F.A.Q.] | [Support Forums]
~ Retired ~
If it does not work, you likely installed it incorrectly. Always try a clean install before reporting bugs.
Reply With Quote
  #15  
Unread 02-12-2011, 03:15 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

Greetings,
Ok ill see what I can do with the code ... i might be back

Thanks,
Draven
Reply With Quote
  #16  
Unread 02-13-2011, 10:49 AM
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

Quote:
Originally Posted by Zonx View Post
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.
I am working off the default maintained window code, I had a question to what is meant by the IconPage.
The hierarchy is as follows:

Maintained (page)
- Volume (VolumePage)
-- Frame1 (Page)
--- CancelEffectButton (Button)
--- Icon (Image)
--- Target (text)
--- Subtitle (Text)
--- Name (Text)
-- Frame2
--- CancelEffectButton (Button)
--- Icon (Image)
--- Target (text)
--- Subtitle (Text)
--- Name (Text)
-- Frame3
--- CancelEffectButton (Button)
--- Icon (Image)
--- Target (text)
--- Subtitle (Text)
--- Name (Text)
- WindowFrame
-- Frame
-- Background

I add the element names next to the elements.

Now i had a thought, might be way off, but say the maintained window is 100 px tall and the volume page is 200px tall cant we tell the volume page to have a top location of -100?

Your code might do that just a amateur UI coder's thoughts lol

Thanks,
Draven

Last edited by Draven_Caine : 02-13-2011 at 01:44 PM.
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 10:33 AM.


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