<commit_before>### define
../setting_views/color_setting_view : ColorSettingView
../setting_views/slider_setting_view : SliderSettingView
./category_view : CategoryView
###

class ColorsCategoryView extends CategoryView


  caption : "Colors"


  subviewCreators :

    "brightness" : ->

      return new SliderSettingView(
        model : @model
        options :
          name : "brightness"
          displayName : "Brightness"
          min : -256
          max : 256
          step : 5
      )

    "contrast" : ->

      return new SliderSettingView(
        model : @model
        options :
          name : "contrast"
          displayName : "Contrast"
          min : 0.5
          max : 5
          step : 0.1
      )

  initialize : ->

    for key, color of @model.get("layerColors")

      @subviewCreators[key] = -> new ColorSettingView(
        model : @model
        options :
          name : "layerColors.#{key}"
          displayName : "Layer: #{key}"
      )

    super()<commit_msg>#545 Fix individual layer colors<commit_after>### define
../setting_views/color_setting_view : ColorSettingView
../setting_views/slider_setting_view : SliderSettingView
./category_view : CategoryView
###

class ColorsCategoryView extends CategoryView


  caption : "Colors"


  subviewCreators :

    "brightness" : ->

      return new SliderSettingView(
        model : @model
        options :
          name : "brightness"
          displayName : "Brightness"
          min : -256
          max : 256
          step : 5
      )

    "contrast" : ->

      return new SliderSettingView(
        model : @model
        options :
          name : "contrast"
          displayName : "Contrast"
          min : 0.5
          max : 5
          step : 0.1
      )

  initialize : ->

    for key of @model.get("layerColors")

      do (key) =>
        @subviewCreators[key] = -> new ColorSettingView(
          model : @model
          options :
            name : "layerColors.#{key}"
            displayName : "Layer: #{key}"
        )

    super()
{'fraction_non_alphanumeric': 0.10331384015594541, 'fraction_numerical': 0.013157894736842105, 'mean_word_length': 1.7631224764468372, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 12, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3114036', 'n_tokens_mistral': 625, 'n_tokens_neox': 576, 'n_words': 138}