UI Improvements, Round 3: Home Screen
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, friarsol, Blacksmith, KrazyTheFox, Agetian, CCGHQ Admins
Re: UI Improvements, Round 3: Home Screen
by jmartus » 31 Jan 2012, 14:52
saving skip preferences are working for me since forge-1.2.3-20120130.125712-11
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 31 Jan 2012, 15:37
I have found a display bug with the quest mode. The SelectablePanel is cutting off the top of the FLabel lblName. I assume that the label area is not tall enough to display the text so the top portion is cut off.
I played around with the ViewQuest.SelectablePanel code and a few other areas but I was not able to get this adjusted to the point where it would be fixed.
During one of my edits it appeared that the FLabel lblName is scalable while the FTextArea tarDesc appears to not scale. This may not be related to the above problem. Then again, maybe not.
I use a Mac and there may be a difference in the system font used in Windows systems. I have included a picture below to show how it looks under Mac OS X.
Oh, the FTextArea tarDesc is not displayed using an italic font.
This may be another case where the differences between the Default fonts used by different OS's and regions can create display text oddities.
`
I played around with the ViewQuest.SelectablePanel code and a few other areas but I was not able to get this adjusted to the point where it would be fixed.
During one of my edits it appeared that the FLabel lblName is scalable while the FTextArea tarDesc appears to not scale. This may not be related to the above problem. Then again, maybe not.
I use a Mac and there may be a difference in the system font used in Windows systems. I have included a picture below to show how it looks under Mac OS X.
Oh, the FTextArea tarDesc is not displayed using an italic font.
- Code: Select all
tarDesc.setFont(skin.getItalicFont(12));
This may be another case where the differences between the Default fonts used by different OS's and regions can create display text oddities.
`
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 31 Jan 2012, 19:05
When I run forge from eclipse or run today's snapshot build and click on the quest tab It looks like I have a quesData.dat file in the project/quest folder but there is no quesData.dat file there.
There was a questData.dat file there yesterday but I removed and deleted the file as it was just a test. Even though the questData.dat file is no longer there it's data appears in the quest mode.
Is there a way to clear this old data out of forge? There must be some data outside of the questData.dat file itself.
There was a questData.dat file there yesterday but I removed and deleted the file as it was just a test. Even though the questData.dat file is no longer there it's data appears in the quest mode.
Is there a way to clear this old data out of forge? There must be some data outside of the questData.dat file itself.
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 31 Jan 2012, 19:52
`Chris H. wrote:When I run forge from eclipse or run today's snapshot build and click on the quest tab It looks like I have a quesData.dat file in the project/quest folder but there is no quesData.dat file there.
There was a questData.dat file there yesterday but I removed and deleted the file as it was just a test. Even though the questData.dat file is no longer there it's data appears in the quest mode.
Is there a way to clear this old data out of forge? There must be some data outside of the questData.dat file itself.
Ouch, I just found where on my Mac the questData.dat files have been going when I start forge. They are being moved out of the quest folder and onto the root of my startup hard drive:
EDIT:
I removed the data folder and the several .dat files listed below it and restarted forge. This time there was no record of a ongoing quest.
`
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by timmermac » 31 Jan 2012, 22:28
As of yesterday's (1/30 - r13675) daily build, layout settings are not persistent between games/matches/sessions.
"I just woke up, haven't had coffee, let alone a pee in 7 days, and I find out you stole my ass and made a ...mini-me! Carter, I should be irked currently, yes?" - Jack O'Neill
Re: UI Improvements, Round 3: Home Screen
by Doublestrike » 01 Feb 2012, 00:20
Finally found the reason for this and fixed. Working?friarsol wrote:I have 5 Challenges on my one quest when I click on the challenge tab, it scrolls down the screen instead of leaving the UI where it was.
Will have a look at these other bugs...sounds like they're OSX related? Screenshot of what I'm looking at attached.
Unfortunately, layout and phases are persisting between matches for me... :/
@some OSX user - perhaps try this fix for the quest events, in ViewQuest.java around line 560 (in SelectablePanel):
The two values in bold are the ones that have changed. Also, they're the main ones that drive resizing.final FLabel lblName = new FLabel(event.getTitle() + ": " + event.getDifficulty());
lblName.setFontScaleFactor(0.6);
this.add(lblName, "h 30px!, gap 0 0 10px 5px, wrap");
Last edited by Doublestrike on 01 Feb 2012, 00:30, edited 2 times in total.
---
A joke is a very serious thing.
A joke is a very serious thing.
-

Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: UI Improvements, Round 3: Home Screen
by friarsol » 01 Feb 2012, 00:28
Yep 5 challenges seems fixed. I'm on Win7, so the Pet box not resetting between Quest loads is definitely not an OSX issue.
- friarsol
- Global Moderator
- Posts: 7575
- Joined: 15 May 2010, 04:20
- Has thanked: 242 times
- Been thanked: 956 times
Re: UI Improvements, Round 3: Home Screen
by Doublestrike » 01 Feb 2012, 00:31
Yeah that is definitely not. Will be fixed shortly.friarsol wrote:Yep 5 challenges seems fixed. I'm on Win7, so the Pet box not resetting between Quest loads is definitely not an OSX issue.
EDIT - just noticed win/loss icons are reversed
EDIT2 - fixed.
---
A joke is a very serious thing.
A joke is a very serious thing.
-

Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 01 Feb 2012, 01:27
`Doublestrike wrote:@some OSX user - perhaps try this fix for the quest events, in ViewQuest.java around line 560 (in SelectablePanel):The two values in bold are the ones that have changed. Also, they're the main ones that drive resizing.final FLabel lblName = new FLabel(event.getTitle() + ": " + event.getDifficulty());
lblName.setFontScaleFactor(0.6);
this.add(lblName, "h 30px!, gap 0 0 10px 5px, wrap");
OK, this section now looks like this:
- Code: Select all
// Name
final FLabel lblName = new FLabel(event.getTitle() + ": " + event.getDifficulty());
lblName.setFontScaleFactor(0.6);
this.add(lblName, "h 31px!, gap 0 0 10px 5px, wrap");
// Description
final FTextArea tarDesc = new FTextArea();
tarDesc.setText(event.getDescription());
tarDesc.setFont(skin.getItalicFont(12));
this.add(tarDesc, "w 80%!, h 30px!");
"h 30px!" was not enough and I had to increase it to 31. The FLabel lblName now looks OK. The SelectablePanel now appears to need to be heightened by a few pixels:
`
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 01 Feb 2012, 01:41
I found the line that set the panel and increased it's height by 6 pixels:
It looks good under Mac OS X, I hope it looks OK under Windows. I will go ahead and commit.
`
- Code: Select all
this.eventPanelConstraints = "w 100%!, h 86px!, gap 0 0 5px 5px";
It looks good under Mac OS X, I hope it looks OK under Windows. I will go ahead and commit.
`
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 01 Feb 2012, 02:16
I removed the questData.dat file from my local Forge project and from the root level of my hard drive. Ran forge from Eclipse. Started a new quest.
There are no quest data .dat files in the /res/quest/ folder or the /res/quest/data/ folder.
At the root level of my hard drive I now have an empty folder named "data" and there is a "data\Test.dat" file located at the root level but it is not inside of the folder named "data".
I believe that Mac OS X does not recognize the backwards slash as a directory separator. I remember someone said to use the forward slash instead as Java will will handle this as a directory separator and might do a conversion if it is necessary for the OS that is being used.
There are no quest data .dat files in the /res/quest/ folder or the /res/quest/data/ folder.
At the root level of my hard drive I now have an empty folder named "data" and there is a "data\Test.dat" file located at the root level but it is not inside of the folder named "data".
I believe that Mac OS X does not recognize the backwards slash as a directory separator. I remember someone said to use the forward slash instead as Java will will handle this as a directory separator and might do a conversion if it is necessary for the OS that is being used.
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Doublestrike » 01 Feb 2012, 03:49
Fixed.friarsol wrote:Also Summon Pet Dialog still seems busted. The pet loads in, but it doesn't store my selection, and I did notice the old items from other quests. List said (No Pet, Wolf Pet, No Pet, Croc Pet) The drop-down box needs to be cleared out during a Quest Load.
Thanks for those tweaks Chris H! I'll take a look at the backslash problem now.
EDIT - changed everything to forward slashes and it appears everything is OK. How about your end?
---
A joke is a very serious thing.
A joke is a very serious thing.
-

Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 01 Feb 2012, 12:00
`Doublestrike wrote:EDIT - changed everything to forward slashes and it appears everything is OK. How about your end?
I removed all of the quest data ".dat" files from the project and the root folders of my hard drive and ran forge from Eclipse. I get a crash report.
I placed an old copy of "questData.dat" file from a quest started several months ago into the /res/quest/ folder and when forge is run this file is now correctly moved to the /res/quest/data/ folder. I do not see any ".dat" files moved to my root folder. And I do not see any "data" folders being created in my root folder.
I get the crash report below if I have the "questData.dat" file or not. Even without the "questData.dat" file being present.
Definitely an improvement.
- Crash Report | Open
- This is a Crash Report. An error has occurred. Please save this message to a file.
Please follow the instructions at this address to submit this Crash Report, plus what you were doing at the time:
http://tinyurl.com/3zzrnyb
Reporting bugs in Forge is very important. We thank you for your time.
Error loading Quest Data
Version:
Forge version SVN
OS: Mac OS X Version: 10.7.2 Architecture: x86_64
Java Version: 1.6.0_29 Vendor: Apple Inc.
Detailed error trace:
java.io.IOException: Not in GZIP format
at java.util.zip.GZIPInputStream.readHeader(GZIPInputStream.java:143)
at java.util.zip.GZIPInputStream.<init>(GZIPInputStream.java:58)
at java.util.zip.GZIPInputStream.<init>(GZIPInputStream.java:67)
at forge.quest.data.QuestDataIO.loadData(QuestDataIO.java:95)
at forge.control.home.ControlQuest.refreshQuests(ControlQuest.java:367)
at forge.view.home.ViewQuest.<init>(ViewQuest.java:178)
at forge.view.home.HomeTopLevel.<init>(HomeTopLevel.java:79)
at forge.control.FControl.changeState(FControl.java:141)
at forge.view.FView$3.run(FView.java:122)
at java.awt.event.InvocationEvent.dispatch(InvocationEvent.java:209)
at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:677)
at java.awt.EventQueue.access$000(EventQueue.java:85)
at java.awt.EventQueue$1.run(EventQueue.java:638)
at java.awt.EventQueue$1.run(EventQueue.java:636)
at java.security.AccessController.doPrivileged(Native Method)
at java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
at java.awt.EventQueue.dispatchEvent(EventQueue.java:647)
at java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
at java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: UI Improvements, Round 3: Home Screen
by Doublestrike » 01 Feb 2012, 13:38
Well that's a startChris H. wrote:Definitely an improvement.
---
A joke is a very serious thing.
A joke is a very serious thing.
-

Doublestrike - UI Programmer
- Posts: 715
- Joined: 08 Aug 2011, 09:07
- Location: Bali
- Has thanked: 183 times
- Been thanked: 161 times
Re: UI Improvements, Round 3: Home Screen
by Chris H. » 01 Feb 2012, 14:58
`Doublestrike wrote:Well that's a startChris H. wrote:Definitely an improvement.Late here so I'll attack this tomorrow...can't recall having gotten that error myself though...
The crash report states "Error loading Quest Data" even though there is no quest data ".dat" file in my project. It also states that "java.io.IOException: Not in GZIP format".
Could it be trying to load the empty "data" folder as the quest data ".dat" file?
I moved the "data" folder out of my project and refreshed. Ran Forge and everything is OK, no crash report. Went to quest mode and started a new quest and forge writes a new "data" folder and places the new quest data ".dat" file into this folder.
So let me quit and then restart forge. It launched OK this time. Hmm... Let me delete the new quest data ".dat" file and relaunch.
Now I get the same crash report again.
-

Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Who is online
Users browsing this forum: No registered users and 3 guests
