Stacho
I’ve had a wee play with colour graduation lookup feature, at least as far as altitudes go.
First thing I noticed is that it does not work if the lookup is defined inside a layout.
… LayoutMapThisCave.thc [89] -- unknown option -- lookup altitude -title "Altitude legend"
But if I put it outside of the layout (effectively, even if not actually), inside the thconfig file (like a ‘text’ definition, it works just fine for altitudes.
It feels to me like it should be inside a layout, to be consistent, but perhaps you have a reason? Perhaps it does not matter.
The framework seems to be very flexible, allowing many pre defined lookup definitions, and works well for altitudes. I like it.
If you are happy for me to do so, I will tidy up the wiki entry that I made on this topic earlier today.
lookup altitude:banded -title "Altitude legend (banded)"
[105 150][] "top level"
90
75
[30 60] [] "lower level"
endlookup
It produces the legend below, and a map that is only partially coloured. The default legend item texts are incorrect.

lookup altitude:banded -title "Altitude legend (banded)"
[105 150][100 0 0] "top level"
90
75
[30 60] [0 0 100] "lower level"
endlookup
The colour graduation is correct, but the map produced only colours the scraps that are within the ‘top level’ and ‘lower level’ altitude range. The others (60m to 105m) are uncoloured.

lookup altitude:banded -title "Altitude legend (banded)"
[105 150][100 0 0] "top level"
90 [50 0 0]
75 [0 0 50]
[30 60] [0 0 100] "lower level"
endlookup
The map is still uncoloured in the middle altitudes (60m to 105m).



lookup altitude:banded -title "Altitude legend (banded)"
[105 150][100 0 0] "top level"
[60 105] [] "middle level"
[30 60] [0 0 100] "lower level"
endlookup
This worked perfectly, colouring all scraps according to their altitude band.

lookup altitude:banded -title "Altitude legend (banded)"
[105 150][100 0 0]
[60 105] []
[30 60] [0 0 100]
Endlookup
Again, perfect! The default text is OK this time.

Maybe tomorrow I’ll see if I can break dates, maps and scraps!
Regards
Bruce