Add a flag for user defined colormaps in the context. Do not overload the colormap if the user changed it. Inherit the Ninja theme from the cmake one. Explanations about themes in the README.
19 lines
525 B
Python
19 lines
525 B
Python
|
|
import colout_cmake
|
|
|
|
def theme(context):
|
|
# Ninja theme
|
|
|
|
# Inherit from the CMake theme
|
|
context,th = colout_cmake.theme(context)
|
|
|
|
# Because Ninja note progress as a fraction, we do not want the scale of a percentage
|
|
context["scale"] = (0,1)
|
|
|
|
# Link (ninja)
|
|
th.append( [ "^\[[0-9/]+\]\s?(Linking .* )(library|executable) (.*/)*(.+(\.[aso]+)*)$",
|
|
"blue", "normal,normal,bold" ] )
|
|
# progress percentage (ninja)
|
|
th.append( [ "^(\[[0-9]+/[0-9]+\])","Scale" ] )
|
|
|
|
return context,th
|