Development Thread

But what happens when the label is really long? Doesn't it push the dropdowns over to the right so they have to line up after it? That's what I meant by it couldn't go outside its vbox, the one containing the shorter labels next to the dropdowns.

For the spacer, try finding a flag that makes the vertical space not expanding. Search for the equivalent H one and change it to V.

Yes, but that's only happening if the label is longer than the dropdown labels, like you said. That's why I check all languages before using it.

On the second one I can't quite follow you. Do you mean putting this
Code:
screen.setLayoutFlag(spacer, "LAYOUT_SIZE_HPREFERREDEXPANDING")
into the spacer definition?
 
Yes, but that's only happening if the label is longer than the dropdown labels, like you said. That's why I check all languages before using it.

If you have problems with ITA, I can try to shorten the translation of some specific label (already done here and there in the layout we are using now).
 
On the second one I can't quite follow you. Do you mean putting this
Code:
screen.setLayoutFlag(spacer, "LAYOUT_SIZE_HPREFERREDEXPANDING")
into the spacer definition?

Hmm, it's currently using "CF_LABEL_DEFAULTSIZE" on the label itself. I wonder if setLayoutFlag() has any effect on labels.

I only know about the values used in the original options screen, and not exactly how they operate. I had to poke around with different combinations to get what I have now. It's been a year since I wrote that code, and hopefully you can find a combination that produces better results with the new layouts.
 
I've just committed a change that will make all the columns the minimum height necessary to fit their controls. It results in all of the tabs pushing the controls as high as possible.

Check it out and see if it's what you like. If you want space before a horizontal dividing line, you can always add a spacer before it.
 
I've just committed a change that will make all the columns the minimum height necessary to fit their controls. It results in all of the tabs pushing the controls as high as possible.

Check it out and see if it's what you like. If you want space before a horizontal dividing line, you can always add a spacer before it.

Works perfect. :goodjob: Now everything looks as intended. I added some spacers to compensate for the old table behavior on some screens.
To get a more solid look of the logging and unit naming tab, I added a table as well but the text fields don't align so nicely:



Is it possible to fix this? If not, I'll just revert to the old look which isn't that bad. :D

@Cam: There is one particular term that is a bit too long: "Funzionamento di filtri" on the plot list tab. I don't know if it can be shortened but it would be great if it wouldn't be longer than "Raggruppamento" or "Filter Behavior". :)
 
I'll take a look at that when I get home today. I don't know why those labels are bunching up like that. The only difference between this tab and the others is that you're lining up text edit boxes, right? The controls on the right shouldn't affect the labels on the left a) given that they're in different vboxes and b) they are the same size as dropdowns. :confused:
 
@Cam: There is one particular term that is a bit too long: "Funzionamento di filtri" on the plot list tab. I don't know if it can be shortened but it would be great if it wouldn't be longer than "Raggruppamento" or "Filter Behavior". :)

You may try "Modalità filtri", it should fit...
 
OK, I've made my first commit. Let's hope I didn't screw anything up. :p

Added the ForeignCivicDetector module that does the determination of Favorite Civics when playing under Random Personalities.

Added a new Attitude class to AttitudeUtils.py that I used in the FCD. The class should implement all the previously existing util functions but the other stuff is still there.

Revamped the Foreign Advisor Info Screen so that it lists the active player first, lists attitude, diplo bonuses/penalties for religion & favorite civics, hides trade income if there's none possible due to no route/war/civic choices, and is hopefully laid out prettier.

Almost all the text that was added for the info screen needs to be kept short to preserve the layout; I did my best to use the pre-existing text in all the languages if it wasn't too long. A few things (such as German "Leader" abbreviation) will need to be added though.
 
Revamped the Foreign Advisor Info Screen so that it lists the active player first, lists attitude, diplo bonuses/penalties for religion & favorite civics, hides trade income if there's none possible due to no route/war/civic choices, and is hopefully laid out prettier.

Almost all the text that was added for the info screen needs to be kept short to preserve the layout; I did my best to use the pre-existing text in all the languages if it wasn't too long. A few things (such as German "Leader" abbreviation) will need to be added though.

I made new ITA text that fits in. If you are able to increase the width of the coloumns of at least a couple of pixels, it will look better, but even as it is is OK.
Can you give a name to this mod (Revamped Foreign Advisor Info Screen? ;) )
and write asome lines of text about it? (similar to the readme's that have already been done for other similar mods) You can even write it here, and I'll put it in the proper format and then we'll translate it in ITA and DEU.
 
I'll take a look at that when I get home today. I don't know why those labels are bunching up like that. The only difference between this tab and the others is that you're lining up text edit boxes, right? The controls on the right shouldn't affect the labels on the left a) given that they're in different vboxes and b) they are the same size as dropdowns. :confused:

Did you find some time to look into it? :)
 
I've committed an updated tech-chooser (F6) screen. I moved the GP Tech Preference stuff to the left of the screen to free up the bottom section for when (if) we introduce tabs. This screen requires a restart of Civ4 for the BUG options to fully take effect.
 
With these new arranged icons for great persons, it's harder to recognize, what great person it is on the little button.
What about a hover text?
 
With these new arranged icons for great persons, it's harder to recognize, what great person it is on the little button.
What about a hover text?

I added the standard unit hover for the :gp: icons. It doesn't explain why they are there, but at least you can tell which :gp: is which. :)
 
Can you give a name to this mod (Revamped Foreign Advisor Info Screen? ;) )
and write asome lines of text about it? (similar to the readme's that have already been done for other similar mods) You can even write it here, and I'll put it in the proper format and then we'll translate it in ITA and DEU.

Improved Foreign Advisor Info Screen

  • Active Player now listed as the first row.
  • New Attitude column showing overall attitude of each player toward active player.
  • Religion column now lists any current attitude modifiers with the active player due to sharing (or not sharing) that religion.
  • Trade column will now be blank when trade is not possible due to war, lack of a trade route, or civics limitations.
  • Favorite Civics column now lists any current attitude modifiers with the active player due to sharing that civic.
  • When playing with the Random Personalities option, the last column changes to "Possible Favorite Civics." BUG will then track attitude changes throughout the game to determine the actual favorite civic of each AI player.
    • While the favorite civic is unknown, a question mark will appear in the column.
    • Once the choices have been narrowed to 5 or less, they will all be listed.
    • Once the favorite civic has been determined, it will be listed alone along with any current attitude modifier.
 
@Dresden - The screen looks great and very clean. :goodjob: Could you do one final cleanup and set the hit test to all the text labels (headings and data) so that they don't highlight? This makes them look like they are active buttons like the tabs at the bottom of the screen.

Code:
screen.setText(name, ...)
screen.setHitTest(name, HitTestTypes.HITTEST_NOHIT)

Hmm, I wonder what the other hit test types do?

  • ON (default?)
  • SOLID
  • CHILDREN
Also, I'd love to see some icons in the trade column detailing why you have no trade (not zero, but cannot trade) with a rival: crossed swords for war, anchor if you cannot trade over sea (dunno if you can tell that), open borders as last resort as it must be a civ between you that you cannot trade through. Can't think of an icon for Mercantilism, though.

Are there any other things that stop trade?
 
Regarding HitTest, sure. I always thought it was weird that they would hilight; nice to see there's a way to turn that off.

As for the trade situation, here are the reasons I can think of for no trade:
  • War
  • No open borders
  • No route
    • physical limitation (e.g. you need some roads)
    • tech limitation (e.g. you need astronomy)
    • Blocked by someone else (e.g. barb city in the way)
  • Civics
    • You run mercantilism
    • They run mercantilism

War is easy to detect and put an icon for. Civics are easy to detect but aside from the actual Merc icon, I can't think of anything to use. The various No route reasons, though, I'm not sure if we can detect them.

Should we move this discussion back to the Info Screen topic?
 
NikNaks, you made some changes to the Web site, but I was not able to keep them when I updated it today. What I'd like to do to is see what is changed from what you did, and while keeping the changes I made today, what things you'd like to have upload as well. Once that is done, I will commit them to the server.

This needs to be done ASAP, or I'm going to have to remove all changes you have made, and revert it to the version I originally had, as it doesn't look very good right now.

Thank you

Edit - I think I got everything changed over, but please double check and make sure. Please don't make any changes yourself.
 
Cam, can you go over the changes you made to the english help files, and make sure formatting is done properly. An example in the first page I looked at is a line like this:

The

BUG Mod combines mods....

please go through and make sure these are corrected. Once that's done I'll go through it and fix any grammatical errors I find.
 
Back
Top Bottom