Some Refactoring of Faction::GetNearestFactionIndex

Work for #1641
Move of the bulk of the work for non-custom systems from the class method
to an instance method.
Class method now iterates using an iterator.
Have the class method call the instance method on the currently iterated
faction to test whether it's a better fit.
Merge branch 'build/vs2012' into perf/faction-colour
factionColour retrievable in SectorView without full sysgen

Work for #1641
Added Faction::GetNearestFactionColour class method.
Added Sector::ColourFactions method that populates a sector's
system with the correct base factionColour.
Setting of factionColour in SectorView::Draw3d removed.
Added call to populate factionColour for full sector to
SectorView::GetCache when a new sector is added to the cache.
Add some constants and use them

BAD_FACTION_COLOUR - the colour for system we found no faction for
FACTION_BASE_ALPHA - the alpha for faction systems where we don't know the population yet
Switch to checking population to get if a system in inhabited

Work for #1641
We need to know if a system is inhabited to mark uninhabited systems as not
part of a faction on the map.
Unfortunately there's no way to determine this without a full sysgen, so
we might as well switch to using population rather than count of starports
to check this and save ourselves a bunch of messy flag twiddling code.
Vary label brightness/alpha based on population

Okay I couldn't resist :)
Avoid Constructing Sectors we already have when getting Faction distances

Work for #1641
Refactored Faction::GetNearestFactionColour and associated methods to
take a Sector and a system index rather than a SystemPath, so we can avoid
constructing the Sector again (and doing mini-sysgen) just to get the
distance.
Added Sector::Contains method, answering whether a SystemPath is within
the Sector.
Uncomment incorrectly commented out code

Oops! Systems in the same sector as Faction homeworlds
should now be automatically being placed in that Faction
again.
Cache the homeworld Sector on the first distance calculation

We no longer construct the homeworld's Sector, doing mini-system
for each system it contains, every time we do a Faction distance
calculation.
Instead We cache the Sector the first time we do a distance
calculation, and then reuse it.
I considered caching the homeworld sector when the homeworld is
set from Lua, but Sector(0,0,0) constructed at that point
appears to be invalid (possibly Sol hasn't loaded yet?)
Expose radius attribute to Lua

Since we now have a Faction::Radius method, we might as
well allow you to get the value from Lua.
Bump availability of l_faction_attr_radius to Alpha 29

Since we're now in freeze for Alpha 28.
Also removed repetition of the word 'volume' from the comments
of the above method.
Allegiance calc. of systems in Faction's home sector less broken

I was setting closestFactionDistance to zero, rather than distance to
zero. Oops!
Use log scale for calculating label colour alpha in Sector View

Since most of our inhabited systems have <500 million inhabitants,
but we have a few systems with populations in the multi-billions
something log based makes more sense.
Also fixes the bug whereby systems coming into view whilst scrolling
were set the wrong initial alpha.
import wpzoom icon set
initial icon implementation
make icons white so we can use the material to colour them as we like
set icon color
expose Icon to Lua
fix spelling
establish some flags for controlling sizing