From 13f0987ede3e43f3bfeb71824d446477da8dd9c8 Mon Sep 17 00:00:00 2001 From: Dirk Thomas Date: Fri, 22 Jan 2016 19:46:51 -0800 Subject: [PATCH] improve docs about grouped settings See https://github.com/atom/settings-view/pull/698#issuecomment-171725215 --- src/config.coffee | 36 ++++++++++++++++++++---------------- 1 file changed, 20 insertions(+), 16 deletions(-) diff --git a/src/config.coffee b/src/config.coffee index 2a883a57d..7c9714c86 100644 --- a/src/config.coffee +++ b/src/config.coffee @@ -203,22 +203,6 @@ ScopeDescriptor = require './scope-descriptor' # maximum: 11.5 # ``` # -# #### object -# -# Value must be an object. This allows you to nest config options. Sub options -# must be under a `properties key` -# -# ```coffee -# config: -# someSetting: -# type: 'object' -# properties: -# myChildIntOption: -# type: 'integer' -# minimum: 1.5 -# maximum: 11.5 -# ``` -# # #### color # # Values will be coerced into a {Color} with `red`, `green`, `blue`, and `alpha` @@ -234,6 +218,23 @@ ScopeDescriptor = require './scope-descriptor' # default: 'white' # ``` # +# ### Grouping +# +# A config setting with the type `object` allows grouping a set of config +# settings. The group will be visualy separated and has its own group headline. +# The sub options must be listed under a `properties` key. +# +# ```coffee +# config: +# someSetting: +# type: 'object' +# properties: +# myChildIntOption: +# type: 'integer' +# minimum: 1.5 +# maximum: 11.5 +# ``` +# # ### Other Supported Keys # # #### enum @@ -274,6 +275,9 @@ ScopeDescriptor = require './scope-descriptor' # # Descriptions will be displayed below the title in the settings view. # +# For a group of config settings the humanized key or the title and the +# description are used for the group headline. +# # ```coffee # config: # someSetting: