Small screen adjustments on contract pages

For test results, bug reports, announcements of new builds etc.

Moderators: winston, another_commander, Getafix

Post Reply
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Small screen adjustments on contract pages

Post by phkb »

Note: If this is better off in the "Tweaking for fun and profit area" please let me know!

When wide fonts like "Dangerous Square" and "Xolonium" are used there are some small column alignment issues with contracts that have a high credit value. Here are some examples when using "Xolonium":

Image
Image
Image

I made some tweaks to the various script files to fix this. These are the changes I made:

oolite-contracts-cargo.js
Line 500 change from

Code: Select all

 		var columns = [10,16,21,26];
to

Code: Select all

 		var columns = [9,15,21,26];
Line 533 change from

Code: Select all

 				priceText = this.$helper._paddingText(priceText, 3.25)+priceText;
to

Code: Select all

 				priceText = this.$helper._paddingText(priceText, 3.5)+priceText;
Line 538 change from

Code: Select all

 				priceText = this.$helper._paddingText(priceText, 3.25)+priceText;
to

Code: Select all

 				priceText = this.$helper._paddingText(priceText, 3.5)+priceText;
oolite-contracts-parcels.js
Line 522 change from

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 2.5)+priceText;
to

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 3.5)+priceText;
oolite-contracts-passengers.js
Line 492 change from

Code: Select all

 	var columns = [12,18,23,28];
to

Code: Select all

 	var columns = [12,17.5,23,28];
Line 524 change from

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 3)+priceText;
to

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 3.5)+priceText;
Line 529 change from

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 3)+priceText;
to

Code: Select all

 		priceText = this.$helper._paddingText(priceText, 3.5)+priceText;
Last edited by phkb on Mon Aug 10, 2015 12:50 am, edited 1 time in total.
User avatar
Diziet Sma
---- E L I T E ----
---- E L I T E ----
Posts: 6312
Joined: Mon Apr 06, 2009 12:20 pm
Location: Aboard the Pitviper S.E. "Blackwidow"

Re: Small screen adjustments on contract pages

Post by Diziet Sma »

Thanks for those..
phkb wrote:
Note: If this is better off in the "Tweaking for fun and profit area" please let me know!
Until such time as Oolite itself can better accommodate such fonts, it might be worth posting it there (and maybe in the "Dangerous Square" and "Xolonium" theads) as well.

A thought.. assuming they'd over-ride the defaults, like plists do, the font packs themselves could include the tweaked scripts.. that could be a neat solution.
Most games have some sort of paddling-pool-and-water-wings beginning to ease you in: Oolite takes the rather more Darwinian approach of heaving you straight into the ocean, often with a brick or two in your pockets for luck. ~ Disembodied
User avatar
phkb
Impressively Grand Sub-Admiral
Impressively Grand Sub-Admiral
Posts: 5190
Joined: Tue Jan 21, 2014 10:37 pm
Location: Writing more OXPs, because the world needs more OXPs.

Re: Small screen adjustments on contract pages

Post by phkb »

Diziet Sma wrote:
it might be worth posting it there (and maybe in the "Dangerous Square" and "Xolonium" theads) as well
Done and done.
Post Reply